diff options
author | Richard Kenner <kenner@gcc.gnu.org> | 1993-07-05 17:59:42 -0400 |
---|---|---|
committer | Richard Kenner <kenner@gcc.gnu.org> | 1993-07-05 17:59:42 -0400 |
commit | 3abe6f904a6f63df38ad7c3304bf8d42c03b3044 (patch) | |
tree | ba5323352fd47d7d95ee2dc682fab685237d35e3 | |
parent | 26f1a00ea1cbe0d9785292e5bb900ca2837647f5 (diff) | |
download | gcc-3abe6f904a6f63df38ad7c3304bf8d42c03b3044.zip gcc-3abe6f904a6f63df38ad7c3304bf8d42c03b3044.tar.gz gcc-3abe6f904a6f63df38ad7c3304bf8d42c03b3044.tar.bz2 |
(emit_reload_insns): Don't use gen_lowpart_common to get reload
register into proper mode.
From-SVN: r4855
-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 637e894..c7ea46f 100644 --- a/gcc/reload1.c +++ b/gcc/reload1.c @@ -5516,10 +5516,13 @@ emit_reload_insns (insn) oldequiv_reg = SUBREG_REG (oldequiv); /* Encapsulate both RELOADREG and OLDEQUIV into that mode, - then load RELOADREG from OLDEQUIV. */ + then load RELOADREG from OLDEQUIV. Note that we cannot use + gen_lowpart_common since it can do the wrong thing when + RELOADREG has a multi-word mode. Note that RELOADREG + must always be a REG here. */ if (GET_MODE (reloadreg) != mode) - reloadreg = gen_lowpart_common (mode, reloadreg); + reloadreg = gen_rtx (REG, mode, REGNO (reloadreg)); while (GET_CODE (oldequiv) == SUBREG && GET_MODE (oldequiv) != mode) oldequiv = SUBREG_REG (oldequiv); if (GET_MODE (oldequiv) != VOIDmode @@ -5981,7 +5984,7 @@ emit_reload_insns (insn) } if (GET_MODE (reloadreg) != mode) - reloadreg = gen_lowpart_common (mode, reloadreg); + reloadreg = gen_rtx (REG, mode, REGNO (reloadreg)); #ifdef SECONDARY_OUTPUT_RELOAD_CLASS |