Commit d540ae2c by Richard Henderson Committed by Richard Henderson

reload1.c (eliminate_regs [SET]): If [SUBREG] widened the mode of DEST for the spill...

* reload1.c (eliminate_regs [SET]): If [SUBREG] widened the mode of
DEST for the spill, adjust mode of SRC to compensate.

From-SVN: r16222
parent d2466160
Tue Oct 28 15:29:15 1997 Richard Henderson <rth@cygnus.com>
* reload1.c (eliminate_regs [SET]): If [SUBREG] widened the mode of
DEST for the spill, adjust mode of SRC to compensate.
Tue Oct 28 14:36:45 1997 Richard Henderson <rth@cygnus.com> Tue Oct 28 14:36:45 1997 Richard Henderson <rth@cygnus.com>
* alpha.md (reload_inqi): Check for MEM before strict_memory_address_p, * alpha.md (reload_inqi): Check for MEM before strict_memory_address_p,
......
...@@ -3271,6 +3271,12 @@ eliminate_regs (x, mem_mode, insn, storing) ...@@ -3271,6 +3271,12 @@ eliminate_regs (x, mem_mode, insn, storing)
&& GET_CODE (insn) != INSN_LIST) && GET_CODE (insn) != INSN_LIST)
emit_insn_after (gen_rtx (CLOBBER, VOIDmode, SET_DEST (x)), insn); emit_insn_after (gen_rtx (CLOBBER, VOIDmode, SET_DEST (x)), insn);
/* If SET_DEST was a partial-word subreg, NEW0 may have been widened
to spill the entire register (see SUBREG case above). If the
widths of SET_DEST and NEW0 no longer match, adjust NEW1. */
if (GET_MODE (SET_DEST (x)) != GET_MODE (new0))
new1 = gen_rtx (SUBREG, GET_MODE (new0), new1, 0);
if (new0 != SET_DEST (x) || new1 != SET_SRC (x)) if (new0 != SET_DEST (x) || new1 != SET_SRC (x))
return gen_rtx (SET, VOIDmode, new0, new1); return gen_rtx (SET, VOIDmode, new0, new1);
} }
......
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