(output_move_double): Use new local var
highest_first to make sure addreg1 gets handled in the overlap case.
In 2-reg-overlap case, really use proper reg in new address.
From-SVN: r4788
enum { REGOP, OFFSOP, MEMOP, PUSHOP, POPOP, CNSTOP, RNDOP } optype0, optype1;
rtx latehalf[2];
rtx addreg0 = 0, addreg1 = 0;
enum { REGOP, OFFSOP, MEMOP, PUSHOP, POPOP, CNSTOP, RNDOP } optype0, optype1;
rtx latehalf[2];
rtx addreg0 = 0, addreg1 = 0;
/* First classify both operands. */
/* First classify both operands. */
xops[0] = latehalf[0];
xops[1] = op0;
output_asm_insn ("adds %1,%0,%1", xops);
xops[0] = latehalf[0];
xops[1] = op0;
output_asm_insn ("adds %1,%0,%1", xops);
- operands[1] = gen_rtx (MEM, DImode, latehalf[0]);
+ operands[1] = gen_rtx (MEM, DImode, op0);
latehalf[1] = adj_offsettable_operand (operands[1], 4);
latehalf[1] = adj_offsettable_operand (operands[1], 4);
}
/* Do the late half first. */
}
/* Do the late half first. */
- output_asm_insn (singlemove_string (latehalf), latehalf);
- /* Then clobber. */
- return singlemove_string (operands);
- /* Normal case: do the two words, low-numbered first. */
+ /* Normal case: do the two words, low-numbered first.
+ Overlap case (highest_first set): do high-numbered word first. */
- output_asm_insn (singlemove_string (operands), operands);
+ if (! highest_first)
+ output_asm_insn (singlemove_string (operands), operands);
CC_STATUS_PARTIAL_INIT;
/* Make any unoffsettable addresses point at high-numbered word. */
CC_STATUS_PARTIAL_INIT;
/* Make any unoffsettable addresses point at high-numbered word. */
if (addreg1)
output_asm_insn ("adds -0x4,%0,%0", &addreg1);
if (addreg1)
output_asm_insn ("adds -0x4,%0,%0", &addreg1);
+ if (highest_first)
+ output_asm_insn (singlemove_string (operands), operands);
+
rtx latehalf[2];
rtx addreg0 = 0;
rtx addreg1 = 0;
rtx latehalf[2];
rtx addreg0 = 0;
rtx addreg1 = 0;
/* First classify both operands. */
/* First classify both operands. */
xops[0] = latehalf[0];
xops[1] = op0;
output_asm_insn ("add %1,%0,%1", xops);
xops[0] = latehalf[0];
xops[1] = op0;
output_asm_insn ("add %1,%0,%1", xops);
- operands[1] = gen_rtx (MEM, DImode, latehalf[0]);
+ operands[1] = gen_rtx (MEM, DImode, op0);
latehalf[1] = adj_offsettable_operand (operands[1], 4);
latehalf[1] = adj_offsettable_operand (operands[1], 4);
}
/* Do the late half first. */
}
/* Do the late half first. */
- output_asm_insn (singlemove_string (latehalf), latehalf);
- /* Then clobber. */
- return singlemove_string (operands);
- /* Normal case: do the two words, low-numbered first. */
+ /* Normal case: do the two words, low-numbered first.
+ Overlap case (highest_first set): do high-numbered word first. */
- output_asm_insn (singlemove_string (operands), operands);
+ if (! highest_first)
+ output_asm_insn (singlemove_string (operands), operands);
/* Make any unoffsettable addresses point at high-numbered word. */
if (addreg0)
/* Make any unoffsettable addresses point at high-numbered word. */
if (addreg0)
if (addreg1)
output_asm_insn ("add %0,-0x4,%0", &addreg1);
if (addreg1)
output_asm_insn ("add %0,-0x4,%0", &addreg1);
+ if (highest_first)
+ output_asm_insn (singlemove_string (operands), operands);
+