diff options
author | Richard Kenner <kenner@gcc.gnu.org> | 1994-02-23 08:13:48 -0500 |
---|---|---|
committer | Richard Kenner <kenner@gcc.gnu.org> | 1994-02-23 08:13:48 -0500 |
commit | f8a9e02bc1443b3300c024454d7700f7bbe6967c (patch) | |
tree | 660eb66fa52670087f52393ee88807d2535bf165 /gcc | |
parent | fdff8c6d8831291ce820748667f08eb3b05f1987 (diff) | |
download | gcc-f8a9e02bc1443b3300c024454d7700f7bbe6967c.zip gcc-f8a9e02bc1443b3300c024454d7700f7bbe6967c.tar.gz gcc-f8a9e02bc1443b3300c024454d7700f7bbe6967c.tar.bz2 |
(choose_reload_regs): If EQUIV is a SUBREG, make a new REG.
From-SVN: r6612
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/reload1.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/gcc/reload1.c b/gcc/reload1.c index 503ebe3..ac75a51 100644 --- a/gcc/reload1.c +++ b/gcc/reload1.c @@ -5044,9 +5044,12 @@ choose_reload_regs (insn, avoid_return_reg) regno = REGNO (equiv); else if (GET_CODE (equiv) == SUBREG) { - regno = REGNO (SUBREG_REG (equiv)); - if (regno < FIRST_PSEUDO_REGISTER) - regno += SUBREG_WORD (equiv); + /* This must be a SUBREG of a hard register. + Make a new REG since this might be used in an + address and not all machines support SUBREGs + there. */ + regno = REGNO (SUBREG_REG (equiv)) + SUBREG_WORD (equiv); + equiv = gen_rtx (REG, reload_mode[r], regno); } else abort (); |