regmove.c (fixup_match_1): Don't move INSN in front of P if it would end up in the shadow of a live flags...
* regmove.c (fixup_match_1): Don't move INSN in front of P if it would end up in the shadow of a live flags regsiter. From-SVN: r29034
This commit is contained in:
parent
6c2a11802a
commit
2219e9215e
1452
gcc/ChangeLog
1452
gcc/ChangeLog
File diff suppressed because one or more lines are too long
|
@ -1737,6 +1737,13 @@ fixup_match_1 (insn, set, src, src_subreg, dst, backward, operand_number,
|
|||
if ((dst_note = find_regno_note (p, REG_DEAD, REGNO (dst)))
|
||||
&& (GET_MODE (XEXP (dst_note, 0)) == GET_MODE (dst)))
|
||||
{
|
||||
/* If we would be moving INSN, check that we won't move it
|
||||
into the shadow of a live a live flags register. */
|
||||
/* ??? We only try to move it in front of P, although
|
||||
we could move it anywhere between OVERLAP and P. */
|
||||
if (overlap && GET_MODE (PREV_INSN (p)) != VOIDmode)
|
||||
break;
|
||||
|
||||
if (! src_note)
|
||||
{
|
||||
rtx q;
|
||||
|
@ -1844,8 +1851,11 @@ fixup_match_1 (insn, set, src, src_subreg, dst, backward, operand_number,
|
|||
break;
|
||||
if (! src_note && reg_overlap_mentioned_p (src, PATTERN (p)))
|
||||
{
|
||||
/* INSN was already checked to be movable when
|
||||
we found no REG_DEAD note for src on it. */
|
||||
/* INSN was already checked to be movable wrt. the registers that it
|
||||
sets / uses when we found no REG_DEAD note for src on it, but it
|
||||
still might clobber the flags register. We'll have to check that
|
||||
we won't insert it into the shadow of a live flags register when
|
||||
we finally know where we are to move it. */
|
||||
overlap = p;
|
||||
src_note = find_reg_note (p, REG_DEAD, src);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue