secondary_reload_class: treat pseudos like memory

From-SVN: r37042
This commit is contained in:
Aldy Hernandez 2000-10-25 03:13:19 +00:00 committed by Aldy Hernandez
parent a8ca775646
commit 15c097383f
2 changed files with 13 additions and 3 deletions

View File

@ -1,3 +1,8 @@
2000-10-24 Aldy Hernandez <aldyh@redhat.com>
* config/mn10300/mn10300.c (secondary_reload_class): Treat pseudos
like memory.
2000-10-24 Jim Wilson <wilson@cygnus.com>
* expmed.c (store_bit_field): Move integer pun code down after
@ -30,7 +35,6 @@
* expr.c (do_store_flag): Don't crash if either side of a
comparison is error_mark_node.
>>>>>>> 1.8059
2000-10-24 Jakub Jelinek <jakub@redhat.com>
* sibcall.c (purge_mem_unchanging_flag): New function.

View File

@ -555,9 +555,15 @@ secondary_reload_class (class, mode, in)
/* Memory loads less than a full word wide can't have an
address or stack pointer destination. They must use
a data register as an intermediate register. */
if (GET_CODE (in) == MEM
if ((GET_CODE (in) == MEM
|| (GET_CODE (in) == REG
&& REGNO (in) >= FIRST_PSEUDO_REGISTER)
|| (GET_CODE (in) == SUBREG
&& GET_CODE (SUBREG_REG (in)) == REG
&& REGNO (SUBREG_REG (in)) >= FIRST_PSEUDO_REGISTER))
&& (mode == QImode || mode == HImode)
&& (class == ADDRESS_REGS || class == SP_REGS))
&& (class == ADDRESS_REGS || class == SP_REGS
|| class == DATA_OR_ADDRESS_REGS))
{
if (TARGET_AM33)
return DATA_OR_EXTENDED_REGS;