On 11/27/2017 03:34 PM, Jakub Jelinek wrote:
> Hi!
> 
> As mentioned in the PR, my C FE rvalue folding patch allows folding
> const variable initializers into the uses of those variables in rvalue
> contexts more than before, and so we get warnings about UB in the test,
> because an unprototyped function is cast to a function type with ellipsis in
> it.
> 
> It isn't entirely clear what exactly the test wants to test, as mentioned
> in the PR, this is one of the options how to solve it, by dropping the
> const it can't be optimized in the FEs (the optimizers can still figure out
> the static vars are never written to).  Another option would be just
> add -w to dg-options, another one is const volatile.
> 
> Regtested on x86_64-linux and i686-linux, ok for trunk?
> 
> 2017-11-27  Jakub Jelinek  <ja...@redhat.com>
> 
>       PR c/83117
>       * gcc.target/x86_64/abi/ms-sysv/gen.cc (make_do_tests_decl): Drop
>       const from do_test_{u,v}*.
OK.
jeff

Reply via email to