* arm.c (arm_reload_in_hi): Ensure that the scratch register does
not overlap our final result register. Fixes problem that causes Metafont in teTeX to crash.* arm.c (arm_reload_in_hi): Ensure that the scratch register does not overlap our final result register. Fixes problem that causes Metafont in teTeX to crash.
This commit is contained in:
parent
d79f15801a
commit
66b1593cdb
9
gnu/dist/toolchain/gcc/config/arm/arm.c
vendored
9
gnu/dist/toolchain/gcc/config/arm/arm.c
vendored
@ -3849,7 +3849,14 @@ arm_reload_in_hi (operands)
|
||||
}
|
||||
}
|
||||
|
||||
scratch = gen_rtx_REG (SImode, REGNO (operands[2]));
|
||||
/* Operands[2] may overlap operands[0] (though it won't overlap
|
||||
operands[1]), that's why we asked for a DImode reg -- so we can
|
||||
use the bit that does not overlap. */
|
||||
if (REGNO (operands[2]) == REGNO (operands[0]))
|
||||
scratch = gen_rtx_REG (SImode, REGNO (operands[2]) + 1);
|
||||
else
|
||||
scratch = gen_rtx_REG (SImode, REGNO (operands[2]));
|
||||
|
||||
emit_insn (gen_zero_extendqisi2 (scratch,
|
||||
gen_rtx_MEM (QImode,
|
||||
plus_constant (base,
|
||||
|
Loading…
Reference in New Issue
Block a user