Bad code from egcs-1.1b

Jason Merrill jason@cygnus.com
Sun Oct 25 21:25:00 GMT 1998


>>>>> Jeffrey A Law <law@cygnus.com> writes:

 > jump.c::duplicate_loop_exit_test simply refuses to roll loops in this
 > manner if it finds a BLOCK_{BEGIN,END} note.  We could do the same.  I
 > don't see many alternatives.

The jump code refuses because duplicating the notes is invalid.  Moving
them isn't, so long as the order is preserved, and it seems to me that the
order would only be broken iff the test contains block notes and the loop
body contains block notes.  That seems quite testable.

Another possibility would be to associate the fixup with something
other than a block; perhaps a code_label?

 > Is there any way to distinguish between a random BLOCK_{BEG,END} and one
 > used for placement of cleanups?

You could scan goto_fixup_chain, I suppose.  See expand_fixup for how they
are created.

Jason



More information about the Gcc-bugs mailing list