[Bug tree-optimization/41905] [4.5 Regression] ICE with __attribute__((noreturn))
jason at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Mon Nov 9 17:18:00 GMT 2009
------- Comment #2 from jason at gcc dot gnu dot org 2009-11-09 17:18 -------
This is happening because in C++ mode the body of bar looks like
D.1729 = foo ();
D.1728 = D.1729;
whereas in the C front end it looks like
D.1986 = foo ();
and so gimple_seq_may_fallthru says that the body can fall through in the first
case, even though the first statement cannot fall through.
This difference seems to be because the INIT_EXPR within the RETURN_EXPR is
initializing a temporary in C++ vs. the RESULT_DECL in C.
I'm not sure where we ought to be pruning the dead assignment to D.1728, but it
doesn't seem like the front end's job.
--
jason at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jason at gcc dot gnu dot org
Component|c++ |tree-optimization
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41905
More information about the Gcc-bugs
mailing list