]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
i386.c (ix86_binary_operator_ok): Use satisfies_constraint_L.
authorUros Bizjak <ubizjak@gmail.com>
Sat, 20 Aug 2011 11:05:43 +0000 (13:05 +0200)
committerUros Bizjak <uros@gcc.gnu.org>
Sat, 20 Aug 2011 11:05:43 +0000 (13:05 +0200)
* config/i386/i386.c (ix86_binary_operator_ok): Use
satisfies_constraint_L.

From-SVN: r177928

gcc/ChangeLog
gcc/config/i386/i386.c

index e72be38893619e1d6bf1af70ccbff8c55ee86ca9..2217302f643363a1e0fde775980b2e2976a79d92 100644 (file)
@@ -1,3 +1,8 @@
+2011-08-20  Uros Bizjak  <ubizjak@gmail.com>
+
+       * config/i386/i386.c (ix86_binary_operator_ok): Use
+       satisfies_constraint_L.
+
 2011-08-20  Uros Bizjak  <ubizjak@gmail.com>
            Michael Matz  <matz@suse.de>
 
index bdcbd26538ffefa88ab897142c569c0e5622c863..7b7ac8746ab75757e1e0ebb516fcd6100fef0772 100644 (file)
@@ -15787,16 +15787,12 @@ ix86_binary_operator_ok (enum rtx_code code, enum machine_mode mode,
 
   /* Source 1 cannot be a non-matching memory.  */
   if (MEM_P (src1) && !rtx_equal_p (dst, src1))
-    {
-      /* Support "andhi/andsi/anddi" as a zero-extending move.  */
-      return (code == AND
-             && (mode == HImode
-                 || mode == SImode
-                 || (TARGET_64BIT && mode == DImode))
-             && CONST_INT_P (src2)
-             && (INTVAL (src2) == 0xff
-                 || INTVAL (src2) == 0xffff));
-    }
+    /* Support "andhi/andsi/anddi" as a zero-extending move.  */
+    return (code == AND
+           && (mode == HImode
+               || mode == SImode
+               || (TARGET_64BIT && mode == DImode))
+           && satisfies_constraint_L (src2));
 
   return true;
 }