sh.c (prepare_move_operands): Use operands[0] as temporary if no_new_pseudos.

* config/sh/sh.c (prepare_move_operands) [PIC]: Use operands[0] as
temporary if no_new_pseudos.

From-SVN: r39145
This commit is contained in:
Alexandre Oliva 2001-01-19 22:31:21 +00:00 committed by Alexandre Oliva
parent 111e0469ce
commit 68c37dc901
2 changed files with 10 additions and 2 deletions

View File

@ -1,3 +1,8 @@
2001-01-19 Alexandre Oliva <aoliva@redhat.com>
* config/sh/sh.c (prepare_move_operands) [PIC]: Use operands[0] as
temporary if no_new_pseudos.
2001-01-19 Neil Booth <neil@daikokuya.demon.co.uk>
* cppinternals.texi: Update.

View File

@ -475,11 +475,14 @@ prepare_move_operands (operands, mode)
&& GET_CODE (XEXP (operands[1], 0)) == PLUS
&& SYMBOLIC_CONST_P (XEXP (XEXP (operands[1], 0), 0)))
{
temp = no_new_pseudos ? operands[0] : gen_reg_rtx (Pmode);
temp = legitimize_pic_address (XEXP (XEXP (operands[1], 0), 0),
SImode, gen_reg_rtx (Pmode));
SImode, temp);
operands[1] = expand_binop (SImode, add_optab, temp,
XEXP (XEXP (operands[1], 0), 1),
gen_reg_rtx (Pmode), 0, OPTAB_LIB_WIDEN);
no_new_pseudos ? temp
: gen_reg_rtx (Pmode),
0, OPTAB_LIB_WIDEN);
}
}