]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
loop-iv.c (implies_p): In the final case, test that operands 0 of the two comparisons...
authorBernd Schmidt <bernd.schmidt@analog.com>
Fri, 13 Feb 2009 11:35:47 +0000 (11:35 +0000)
committerBernd Schmidt <bernds@gcc.gnu.org>
Fri, 13 Feb 2009 11:35:47 +0000 (11:35 +0000)
* loop-iv.c (implies_p): In the final case, test that operands 0
of the two comparisons match.

From-SVN: r144152

gcc/ChangeLog
gcc/loop-iv.c

index baa3e673a3fb922e04ae213e5ec91fdc5d1de848..53bb0b0ed3b77809e0f5e81b6d1d85f0b5bc7b3f 100644 (file)
@@ -1,3 +1,8 @@
+2008-02-13  Bernd Schmidt  <bernd.schmidt@analog.com>
+
+       * loop-iv.c (implies_p): In the final case, test that operands 0
+       of the two comparisons match.
+
 2009-02-13  Richard Guenther  <rguenther@suse.de>
 
        * configure.ac: Enable LFS.
index 3723dbd463aa29e4e0efc6d88c104a1bd960f035..e8e89bca1ebce2d54785e012eaabba4ee06afd36 100644 (file)
@@ -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;