Commit 08664dff by Michael Meissner

Do not segfault if SUBREG uses something other than REG.

From-SVN: r9617
parent 201012cb
...@@ -2382,6 +2382,13 @@ mark_used_regs (needed, live, x, final, insn) ...@@ -2382,6 +2382,13 @@ mark_used_regs (needed, live, x, final, insn)
!= GET_MODE_SIZE (GET_MODE (SUBREG_REG (x))))) != GET_MODE_SIZE (GET_MODE (SUBREG_REG (x)))))
reg_changes_size[REGNO (SUBREG_REG (x))] = 1; reg_changes_size[REGNO (SUBREG_REG (x))] = 1;
/* In case the SUBREG is not of a register, don't optimize */
if (GET_CODE (SUBREG_REG (x)) != REG)
{
mark_used_regs (needed, live, SUBREG_REG (x), final, insn);
return;
}
/* While we're here, optimize this case. */ /* While we're here, optimize this case. */
x = SUBREG_REG (x); x = SUBREG_REG (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