[Bug middle-end/40095] [4.5 Regression] Revision 147342/147343 caused extra failures
hubicka at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Sun May 10 19:51:00 GMT 2009
------- Comment #1 from hubicka at gcc dot gnu dot org 2009-05-10 19:51 -------
This is latent problem in -Wunreachable.
We now unroll the loop:
void bar (void)
{
int i;
for (i = 0; i < 2; i++)
if (! foo (a[i]))
return;
baz (); /* { dg-bogus "will never be executed" } */
baz ();
baz ();
and last iteration of the loop gets copied including the i<2 test and thus the
following code is rendered dead.
I guess we can either
1) Fix testcase so it is no longer unrolled again :) (or XFAIL it)
2) Mark duplicated statements in some way and suppress unreachable warning on
them
3) Teach unroller to not copy the last iteration including the code after
exit condition.
Honza
--
hubicka at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2009-05-10 19:51:04
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40095
More information about the Gcc-bugs
mailing list