Uros reported that GCC after LRA submitting has a new test failure on
x86. The reason was in wrong update live info in EBB containing empty
BB as the last EBB block. For such case live_out of the last EBB was
undefined and actually a garbage. It resulted in triggering a code
which checks that pseudo assigned to call clobbered hard register does
not live through calls.
The following patch fixes the problem.
The patch was successfully tested and bootstrapped on x86.
Committed as rev. 192743.
2012-10-23 Vladimir Makarov <vmaka...@redhat.com>
* lra-constraints.c (update_ebb_live_info): Process empty blocks.
Index: lra-constraints.c
===================================================================
--- lra-constraints.c (revision 192719)
+++ lra-constraints.c (working copy)
@@ -4300,8 +4300,6 @@ update_ebb_live_info (rtx head, rtx tail
curr_insn = prev_insn)
{
prev_insn = PREV_INSN (curr_insn);
- if (! INSN_P (curr_insn))
- continue;
curr_bb = BLOCK_FOR_INSN (curr_insn);
if (curr_bb != prev_bb)
{
@@ -4336,7 +4334,7 @@ update_ebb_live_info (rtx head, rtx tail
prev_bb = curr_bb;
bitmap_and (&live_regs, &check_only_regs, df_get_live_out (curr_bb));
}
- if (DEBUG_INSN_P (curr_insn))
+ if (! NONDEBUG_INSN_P (curr_insn))
continue;
curr_id = lra_get_insn_recog_data (curr_insn);
remove_p = false;