Commit 94714ecc by Richard Kenner

(eliminate_regs, case USE): If using a register that is source of

elimination, show can't be eliminated.

From-SVN: r11277
parent a8a8cbb7
...@@ -2894,7 +2894,6 @@ eliminate_regs (x, mem_mode, insn) ...@@ -2894,7 +2894,6 @@ eliminate_regs (x, mem_mode, insn)
} }
/* Fall through to generic unary operation case. */ /* Fall through to generic unary operation case. */
case USE:
case STRICT_LOW_PART: case STRICT_LOW_PART:
case NEG: case NOT: case NEG: case NOT:
case SIGN_EXTEND: case ZERO_EXTEND: case SIGN_EXTEND: case ZERO_EXTEND:
...@@ -2983,6 +2982,19 @@ eliminate_regs (x, mem_mode, insn) ...@@ -2983,6 +2982,19 @@ eliminate_regs (x, mem_mode, insn)
return x; return x;
case USE:
/* If using a register that is the source of an eliminate we still
think can be performed, note it cannot be performed since we don't
know how this register is used. */
for (ep = reg_eliminate; ep < &reg_eliminate[NUM_ELIMINABLE_REGS]; ep++)
if (ep->from_rtx == XEXP (x, 0))
ep->can_eliminate = 0;
new = eliminate_regs (XEXP (x, 0), mem_mode, insn);
if (new != XEXP (x, 0))
return gen_rtx (code, GET_MODE (x), new);
return x;
case CLOBBER: case CLOBBER:
/* If clobbering a register that is the replacement register for an /* If clobbering a register that is the replacement register for an
elimination we still think can be performed, note that it cannot elimination we still think can be performed, note that it cannot
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment