aboutsummaryrefslogtreecommitdiff
path: root/gcc/explow.c
diff options
context:
space:
mode:
authorRichard Kenner <kenner@vlsi1.ultra.nyu.edu>2001-11-08 22:56:52 +0000
committerRichard Kenner <kenner@gcc.gnu.org>2001-11-08 17:56:52 -0500
commit6608bd4de4b52a0519329caa878375641dbe9756 (patch)
treed8ef61e1d14c2b364aa45ac97858bdc1dc20446d /gcc/explow.c
parentf098ead2f5c96dece25043b9548226489a2f4683 (diff)
downloadgcc-6608bd4de4b52a0519329caa878375641dbe9756.zip
gcc-6608bd4de4b52a0519329caa878375641dbe9756.tar.gz
gcc-6608bd4de4b52a0519329caa878375641dbe9756.tar.bz2
explow.c (convert_memory_address, [...]): Only return inner object if SUBREG_PROMOTED_VAR_P or known to be pointer.
* explow.c (convert_memory_address, case SUBREG): Only return inner object if SUBREG_PROMOTED_VAR_P or known to be pointer. From-SVN: r46862
Diffstat (limited to 'gcc/explow.c')
-rw-r--r--gcc/explow.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/explow.c b/gcc/explow.c
index 940a839..874713f 100644
--- a/gcc/explow.c
+++ b/gcc/explow.c
@@ -363,6 +363,7 @@ convert_memory_address (to_mode, x)
case SUBREG:
if (POINTERS_EXTEND_UNSIGNED >= 0
+ && (SUBREG_PROMOTED_VAR_P (x) || REG_POINTER (SUBREG_REG (x)))
&& GET_MODE (SUBREG_REG (x)) == to_mode)
return SUBREG_REG (x);
break;