middle-end/6180: Infinite loop in cc1 during dbr pass
John David Anglin
dave@hiauly1.hia.nrc.ca
Fri Apr 5 11:49:00 GMT 2002
> Infinite loop occurs compiling nm.c (binutils 2.12.90
> 20020404). The final loop in dbr_sequence loops forever
> because of a loop in the insn chain that occurs compiling
> the function filter_symbols. The insn chain appears ok
> when dbr_sequence is called.
This is what is causing the problem. There is a millicode call
insn in the function "return" just before the epilogue begin note.
dbr_schedule puts the first insn in the epilogue into the delay
slot of the call. This insn restores %r2 from the stack. It's
probably ok to put it into the delay slot of the millicode call
since it doesn't use %r2, but the start of the epilogue is now
in an indeterminate position. reposition_prologue_and_epilogue_notes
moves the epilogue begin note before the sequence. However, in
fixing the insn chain, it apparently doesn't check for a sequence
and the chain is left in a corrupt state. In particular, it doesn't
touch the numbering inside the sequence.
I probably can fix this by adding a blockage at the beginning
of the epilogue. However, this seems like overkill and simply
avoids the problem.
Suggestions?
Dave
--
J. David Anglin dave.anglin@nrc.ca
National Research Council of Canada (613) 990-0752 (FAX: 952-6605)
More information about the Gcc-bugs
mailing list