aboutsummaryrefslogtreecommitdiff
path: root/gcc/recog.c
diff options
context:
space:
mode:
authorSteven Bosscher <stevenb@suse.de>2005-01-31 21:14:44 +0000
committerSteven Bosscher <steven@gcc.gnu.org>2005-01-31 21:14:44 +0000
commit9ea888348fda5bbe3f33ec2b241d7adb1c94383b (patch)
tree307f8c382d41080ae71e44f27304f20bcafe33d1 /gcc/recog.c
parent75a3bd9d651df22415296c08a50f10869ec10d5a (diff)
downloadgcc-9ea888348fda5bbe3f33ec2b241d7adb1c94383b.zip
gcc-9ea888348fda5bbe3f33ec2b241d7adb1c94383b.tar.gz
gcc-9ea888348fda5bbe3f33ec2b241d7adb1c94383b.tar.bz2
recog.c (constrain_operands): Only look for earlyclobber operand conflicts if an '&' constraint was seen.
* recog.c (constrain_operands): Only look for earlyclobber operand conflicts if an '&' constraint was seen. From-SVN: r94493
Diffstat (limited to 'gcc/recog.c')
-rw-r--r--gcc/recog.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/gcc/recog.c b/gcc/recog.c
index 4dfdca1..28b2410 100644
--- a/gcc/recog.c
+++ b/gcc/recog.c
@@ -2233,6 +2233,7 @@ constrain_operands (int strict)
do
{
+ int seen_earlyclobber_at = -1;
int opno;
int lose = 0;
funny_match_index = 0;
@@ -2295,6 +2296,8 @@ constrain_operands (int strict)
case '&':
earlyclobber[opno] = 1;
+ if (seen_earlyclobber_at < 0)
+ seen_earlyclobber_at = opno;
break;
case '0': case '1': case '2': case '3': case '4':
@@ -2543,8 +2546,10 @@ constrain_operands (int strict)
/* See if any earlyclobber operand conflicts with some other
operand. */
- if (strict > 0)
- for (eopno = 0; eopno < recog_data.n_operands; eopno++)
+ if (strict > 0 && seen_earlyclobber_at >= 0)
+ for (eopno = seen_earlyclobber_at;
+ eopno < recog_data.n_operands;
+ eopno++)
/* Ignore earlyclobber operands now in memory,
because we would often report failure when we have
two memory operands, one of which was formerly a REG. */