mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-03-21 15:41:09 +08:00
(emit_move_sequence): If reload in progress, replace reference to
pseudo with reference to corresponding MEM. From-SVN: r13056
This commit is contained in:
parent
3c9675679a
commit
8a642d97fd
@ -32,6 +32,7 @@ Boston, MA 02111-1307, USA. */
|
||||
#include "insn-attr.h"
|
||||
#include "flags.h"
|
||||
#include "tree.h"
|
||||
#include "reload.h"
|
||||
#include "c-tree.h"
|
||||
#include "expr.h"
|
||||
#include "obstack.h"
|
||||
@ -1059,6 +1060,22 @@ emit_move_sequence (operands, mode, scratch_reg)
|
||||
register rtx operand0 = operands[0];
|
||||
register rtx operand1 = operands[1];
|
||||
|
||||
if (reload_in_progress && GET_CODE (operand0) == REG
|
||||
&& REGNO (operand0) >= FIRST_PSEUDO_REGISTER)
|
||||
operand0 = reg_equiv_mem[REGNO (operand0)];
|
||||
else if (reload_in_progress && GET_CODE (operand0) == SUBREG
|
||||
&& GET_CODE (SUBREG_REG (operand0)) == REG
|
||||
&& REGNO (SUBREG_REG (operand0)) >= FIRST_PSEUDO_REGISTER)
|
||||
SUBREG_REG (operand0) = reg_equiv_mem[REGNO (SUBREG_REG (operand0))];
|
||||
|
||||
if (reload_in_progress && GET_CODE (operand1) == REG
|
||||
&& REGNO (operand1) >= FIRST_PSEUDO_REGISTER)
|
||||
operand1 = reg_equiv_mem[REGNO (operand1)];
|
||||
else if (reload_in_progress && GET_CODE (operand1) == SUBREG
|
||||
&& GET_CODE (SUBREG_REG (operand1)) == REG
|
||||
&& REGNO (SUBREG_REG (operand1)) >= FIRST_PSEUDO_REGISTER)
|
||||
SUBREG_REG (operand1) = reg_equiv_mem[REGNO (SUBREG_REG (operand1))];
|
||||
|
||||
/* Handle secondary reloads for loads/stores of FP registers from
|
||||
REG+D addresses where D does not fit in 5 bits, including
|
||||
(subreg (mem (addr))) cases. */
|
||||
|
Loading…
x
Reference in New Issue
Block a user