Re: [PATCH] Verify that last argument of __builtin_expect_with_probability is a real cst (PR c/87811).

2018-11-08 Thread Martin Sebor
On 11/07/2018 02:36 AM, Martin Liška wrote: On 11/5/18 7:00 PM, Martin Sebor wrote: On 11/01/2018 07:45 AM, Martin Liška wrote: On 11/1/18 1:15 PM, Jakub Jelinek wrote: On Thu, Nov 01, 2018 at 01:09:16PM +0100, Martin Liška wrote: -range 0.0 to 1.0, inclusive. +range 0.0 to 1.0, inclusive.

Re: [PATCH] Verify that last argument of __builtin_expect_with_probability is a real cst (PR c/87811).

2018-11-07 Thread Jeff Law
On 11/7/18 2:36 AM, Martin Liška wrote: > On 11/5/18 7:00 PM, Martin Sebor wrote: >> On 11/01/2018 07:45 AM, Martin Liška wrote: >>> On 11/1/18 1:15 PM, Jakub Jelinek wrote: On Thu, Nov 01, 2018 at 01:09:16PM +0100, Martin Liška wrote: > -range 0.0 to 1.0, inclusive. > +range 0.0 to

Re: [PATCH] Verify that last argument of __builtin_expect_with_probability is a real cst (PR c/87811).

2018-11-07 Thread Martin Liška
On 11/5/18 7:00 PM, Martin Sebor wrote: > On 11/01/2018 07:45 AM, Martin Liška wrote: >> On 11/1/18 1:15 PM, Jakub Jelinek wrote: >>> On Thu, Nov 01, 2018 at 01:09:16PM +0100, Martin Liška wrote: -range 0.0 to 1.0, inclusive. +range 0.0 to 1.0, inclusive.  The @var{probability} argument

Re: [PATCH] Verify that last argument of __builtin_expect_with_probability is a real cst (PR c/87811).

2018-11-05 Thread Martin Sebor
On 11/01/2018 07:45 AM, Martin Liška wrote: On 11/1/18 1:15 PM, Jakub Jelinek wrote: On Thu, Nov 01, 2018 at 01:09:16PM +0100, Martin Liška wrote: -range 0.0 to 1.0, inclusive. +range 0.0 to 1.0, inclusive. The @var{probability} argument must be +a compiler time constant. When you say must,

Re: [PATCH] Verify that last argument of __builtin_expect_with_probability is a real cst (PR c/87811).

2018-11-02 Thread Jeff Law
On 11/1/18 7:45 AM, Martin Liška wrote: > On 11/1/18 1:15 PM, Jakub Jelinek wrote: >> On Thu, Nov 01, 2018 at 01:09:16PM +0100, Martin Liška wrote: >>> -range 0.0 to 1.0, inclusive. >>> +range 0.0 to 1.0, inclusive. The @var{probability} argument must be >>> +a compiler time constant. >> When you

Re: [PATCH] Verify that last argument of __builtin_expect_with_probability is a real cst (PR c/87811).

2018-11-01 Thread Martin Liška
On 11/1/18 1:15 PM, Jakub Jelinek wrote: > On Thu, Nov 01, 2018 at 01:09:16PM +0100, Martin Liška wrote: >> -range 0.0 to 1.0, inclusive. >> +range 0.0 to 1.0, inclusive. The @var{probability} argument must be >> +a compiler time constant. > > When you say must, I think error_at should be used

Re: [PATCH] Verify that last argument of __builtin_expect_with_probability is a real cst (PR c/87811).

2018-11-01 Thread Jakub Jelinek
On Thu, Nov 01, 2018 at 01:09:16PM +0100, Martin Liška wrote: > -range 0.0 to 1.0, inclusive. > +range 0.0 to 1.0, inclusive. The @var{probability} argument must be > +a compiler time constant. When you say must, I think error_at should be used rather than warning_at. If others disagree I'm open

Re: [PATCH] Verify that last argument of __builtin_expect_with_probability is a real cst (PR c/87811).

2018-11-01 Thread Martin Liška
On 10/31/18 11:17 AM, Jakub Jelinek wrote: > On Wed, Oct 31, 2018 at 11:04:32AM +0100, Martin Liška wrote: >> Hi. >> >> As Jakub pointed out we should not ICE when last argument >> of __builtin_expect_with_probability is not a real cst. >> Plus I documented the behavior. > > That is not what

Re: [PATCH] Verify that last argument of __builtin_expect_with_probability is a real cst (PR c/87811).

2018-10-31 Thread Jakub Jelinek
On Wed, Oct 31, 2018 at 11:04:32AM +0100, Martin Liška wrote: > Hi. > > As Jakub pointed out we should not ICE when last argument > of __builtin_expect_with_probability is not a real cst. > Plus I documented the behavior. That is not what you've implemented. The documentation says that it must