summaryrefslogtreecommitdiffstats
path: root/gcc/combine.c
diff options
context:
space:
mode:
authorrth <rth@138bc75d-0d04-0410-961f-82ee72b054a4>2001-05-22 06:58:17 +0000
committerrth <rth@138bc75d-0d04-0410-961f-82ee72b054a4>2001-05-22 06:58:17 +0000
commit5063ebe7784707e54dfea47eff203c76c6ce44be (patch)
treec0a10a585f843312330734edc25eecf84e6f94a5 /gcc/combine.c
parent98cf095aceed6a89d0524b8cfbcb11a5ee823c70 (diff)
downloadppe42-gcc-5063ebe7784707e54dfea47eff203c76c6ce44be.tar.gz
ppe42-gcc-5063ebe7784707e54dfea47eff203c76c6ce44be.zip
* combine.c (subst): Do not substitute for a register as
a destination subreg/strict_low_part/zero_extract. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@42429 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/combine.c')
-rw-r--r--gcc/combine.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/gcc/combine.c b/gcc/combine.c
index e3ad70a9604..675b1fe3e91 100644
--- a/gcc/combine.c
+++ b/gcc/combine.c
@@ -3394,7 +3394,16 @@ subst (x, from, to, in_dest, unique_copy)
}
else if (fmt[i] == 'e')
{
- if (COMBINE_RTX_EQUAL_P (XEXP (x, i), from))
+ /* If this is a register being set, ignore it. */
+ new = XEXP (x, i);
+ if (in_dest
+ && (code == SUBREG || code == STRICT_LOW_PART
+ || code == ZERO_EXTRACT)
+ && i == 0
+ && GET_CODE (new) == REG)
+ ;
+
+ else if (COMBINE_RTX_EQUAL_P (XEXP (x, i), from))
{
/* In general, don't install a subreg involving two
modes not tieable. It can worsen register
OpenPOWER on IntegriCloud