sh.h (EXTRA_CONSTRAINT_Z): New macro.
authorJ"orn Rennecke <joern.rennecke@superh.com>
Mon, 16 Dec 2002 17:21:50 +0000 (17:21 +0000)
committerJoern Rennecke <amylaar@gcc.gnu.org>
Mon, 16 Dec 2002 17:21:50 +0000 (17:21 +0000)
* sh.h (EXTRA_CONSTRAINT_Z): New macro.
(EXTRA_CONSTRAINT): Use it.
* sh.md (anddi3): Use 'Z' constraint for alternative 2.

From-SVN: r60173

gcc/ChangeLog
gcc/config/sh/sh.h
gcc/config/sh/sh.md

index 71233fb108153b2240c271b6242d5c560afba721..7d05e4e7bf7a6f7c75da21b84fc6dc9a47a02f31 100644 (file)
@@ -1,3 +1,9 @@
+Mon Dec 16 17:20:04 2002  J"orn Rennecke <joern.rennecke@superh.com>
+
+       * sh.h (EXTRA_CONSTRAINT_Z): New macro.
+       (EXTRA_CONSTRAINT): Use it.
+       * sh.md (anddi3): Use 'Z' constraint for alternative 2.
+
 2002-12-13  John David Anglin  <dave@hiauly1.hia.nrc.ca>
 
        * pa.c (output_millicode_call): Correct typo.
index 57ebbb311aff3c0ddb38310c690d914a6f85e3d8..6e3b91a76e49e21f53db37e6337f1b31b0998d61 100644 (file)
@@ -2321,12 +2321,18 @@ while (0)
           ? sh_const_vec ((OP), VOIDmode) \
           : sh_1el_vec ((OP), VOIDmode))))
 
+#define EXTRA_CONSTRAINT_Z(OP) \
+  (GET_CODE (OP) == CONST_INT \
+   && (INTVAL (OP) == (unsigned) 0xffffffff \
+       || INTVAL (OP) == (HOST_WIDE_INT) -1 << 32))
+
 #define EXTRA_CONSTRAINT(OP, C)                \
   ((C) == 'Q' ? EXTRA_CONSTRAINT_Q (OP)        \
    : (C) == 'S' ? EXTRA_CONSTRAINT_S (OP) \
    : (C) == 'T' ? EXTRA_CONSTRAINT_T (OP) \
    : (C) == 'U' ? EXTRA_CONSTRAINT_U (OP) \
    : (C) == 'W' ? EXTRA_CONSTRAINT_W (OP) \
+   : (C) == 'Z' ? EXTRA_CONSTRAINT_Z (OP) \
    : 0)
 \f
 /* GO_IF_LEGITIMATE_ADDRESS recognizes an RTL expression
index 4dbda27e4b9c1714b89b73f29f9c10127067d582..e3f4ea01d351fe29dfa113cc8e5204d4afff2aaa 100644 (file)
 (define_insn_and_split "anddi3"
   [(set (match_operand:DI 0 "arith_reg_operand" "=r,r,r")
        (and:DI (match_operand:DI 1 "arith_reg_operand" "%r,r,r")
-               (match_operand:DI 2 "and_operand" "r,P,n")))]
+               (match_operand:DI 2 "and_operand" "r,P,Z")))]
   "TARGET_SHMEDIA"
   "@
        and     %1, %2, %0