http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52983
Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |aoliva at gcc dot gnu.org, | |jakub at gcc dot gnu.org --- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-04-24 13:15:35 UTC --- Caused by recent Alex' changes, http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=186422 . I see two issues: 1) when is dead_debug_insert_temp supposed to be called? E.g. word_dce_process_block calls it on all insns if debug.used is present, but dce_process_block calls it solely on insns that were initially not marked. >From looking at df_note_bb_compute I'd assume always, even when the insn stays if the reg isn't considered live after the insn debug insns still shouldn't refer to that register. So, IMHO either the dead_debug_insert_temp should be in a separate loop, guarded by the same condition as in word_dce_process_block. Or, if for some reason you really don't want to call it on insns that are needed, you should again wait after the current loop that sometimes marks otherwise unneeded insns as needed. 2) dead_debug_insert_temp with DEBUG_TEMP_BEFORE_WITH_VALUE should IMHO for AUTO_INC_DEC targets call cleanup_auto_inc_dec instead of copy_rtx in the couple of places where it calls it (and either cleanup_auto_inc_dec should be made public from combine.c and declared in a header, or it should move to df-problems.c and combine.c should use it from there). Alex, what do you think?