------- Comment #3 from ghazi at gcc dot gnu dot org  2010-09-02 15:24 -------
> Please check whether
> +/* { dg-add-options c99_runtime } */
> +/* { dg-require-effective-target c99_runtime } */

You're right that these foldings should succeed anyway, the c99_runtime should
not be necessary.  If requiring a c99 effective target eliminates the error,
it's only because the test doesn't run anymore.

The subject indicates the test fails at -O1, but I assume not -O0 or -O2.  This
leads me to guess that the failing line(s) are in the #ifdef __OPTIMIZE__
section.  These bits rely on some generic optimizations to fully fold away the
relevant code, which may not be happening here at -O1.

I don't have access to a test infrastructure ATM.  So if David could please
narrow down which line is failing to fold, it would help.  Each test line here
calls link_error(__LINE__) so if you add -fdump-tree-* you should be able to
see which one(s) aren't folding, and hopefully why.

I suspect it's something more than the c99 complex stuff.



Reply via email to