summaryrefslogtreecommitdiff
path: root/gcc/loop-iv.c
diff options
context:
space:
mode:
authorbernds <bernds@138bc75d-0d04-0410-961f-82ee72b054a4>2009-02-13 11:35:47 +0000
committerbernds <bernds@138bc75d-0d04-0410-961f-82ee72b054a4>2009-02-13 11:35:47 +0000
commit274408592e0daab6ba68f529aa336be2d25277e1 (patch)
tree76e727d26666afbcb1f0b59b6364fa215129625d /gcc/loop-iv.c
parent76549266028b511d4adc14a7fa8031a72140623e (diff)
downloadgcc-274408592e0daab6ba68f529aa336be2d25277e1.tar.gz
* loop-iv.c (implies_p): In the final case, test that operands 0
of the two comparisons match. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@144152 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/loop-iv.c')
-rw-r--r--gcc/loop-iv.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/loop-iv.c b/gcc/loop-iv.c
index 3723dbd463a..e8e89bca1eb 100644
--- a/gcc/loop-iv.c
+++ b/gcc/loop-iv.c
@@ -1556,7 +1556,8 @@ implies_p (rtx a, rtx b)
&& ((GET_CODE (a) == GT && op1 == constm1_rtx)
|| INTVAL (op1) >= 0)
&& GET_CODE (b) == LTU
- && GET_CODE (opb1) == CONST_INT)
+ && GET_CODE (opb1) == CONST_INT
+ && rtx_equal_p (op0, opb0))
return INTVAL (opb1) < 0;
return false;