Commit bbe37912 by Alexandre Oliva Committed by Alexandre Oliva

re PR middle-end/20491 (internal compiler error: in subreg_regno_offset, at rtlanal.c:3042)

PR middle-end/20491
* final.c (alter_subreg): Don't call subreg_regno for a non-REG.

From-SVN: r97444
parent 9f05ff0a
2005-04-02 Alexandre Oliva <aoliva@redhat.com> 2005-04-02 Alexandre Oliva <aoliva@redhat.com>
PR middle-end/20491
* final.c (alter_subreg): Don't call subreg_regno for a non-REG.
2005-04-02 Alexandre Oliva <aoliva@redhat.com>
PR rtl-optimization/20290 PR rtl-optimization/20290
* loop.c (for_each_insn_in_loop): Don't assume the loop body runs * loop.c (for_each_insn_in_loop): Don't assume the loop body runs
in every iteration if the entry point is the exit test. in every iteration if the entry point is the exit test.
......
...@@ -2547,11 +2547,10 @@ alter_subreg (rtx *xp) ...@@ -2547,11 +2547,10 @@ alter_subreg (rtx *xp)
if (new != 0) if (new != 0)
*xp = new; *xp = new;
else else if (REG_P (y))
{ {
/* Simplify_subreg can't handle some REG cases, but we have to. */ /* Simplify_subreg can't handle some REG cases, but we have to. */
unsigned int regno = subreg_regno (x); unsigned int regno = subreg_regno (x);
gcc_assert (REG_P (y));
*xp = gen_rtx_REG_offset (y, GET_MODE (x), regno, SUBREG_BYTE (x)); *xp = gen_rtx_REG_offset (y, GET_MODE (x), regno, SUBREG_BYTE (x));
} }
} }
......
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