(ashlsi3): Use nonmemory_operand as a predicate instead of shiftby_operand.
authorJim Wilson <wilson@gcc.gnu.org>
Tue, 11 Apr 1995 20:59:16 +0000 (13:59 -0700)
committerJim Wilson <wilson@gcc.gnu.org>
Tue, 11 Apr 1995 20:59:16 +0000 (13:59 -0700)
(ashlsi3): Use nonmemory_operand as a predicate instead of
shiftby_operand.  Don't use shiftby_operand in the output statement.
(lshrsi3): Likewise.

From-SVN: r9361

gcc/config/sh/sh.md

index c17575d87443e1e69b516715ff024e8362f89087..5825e7753c42ba884149a2c71d57412b63bbcd3f 100644 (file)
 (define_expand "ashlsi3"
   [(parallel[(set (match_operand:SI 0 "arith_reg_operand" "")
                  (ashift:SI (match_operand:SI 1 "arith_reg_operand" "")
-                            (match_operand:SI 2 "shiftby_operand" "")))
+                            (match_operand:SI 2 "nonmemory_operand" "")))
             (clobber (reg:SI 18))])]
   ""
-  "if (! shiftby_operand (operands[2], SImode)) FAIL;")
+  "
+{
+  if (! immediate_operand (operands[2], GET_MODE (operands[2])))
+    FAIL;
+}")
 
 ;
 ; arithmetic shift right
 (define_expand "lshrsi3"
   [(parallel[(set (match_operand:SI 0 "arith_reg_operand" "")
                  (lshiftrt:SI (match_operand:SI 1 "arith_reg_operand" "")
-                              (match_operand:SI 2 "shiftby_operand" "")))
+                              (match_operand:SI 2 "nonmemory_operand" "")))
             (clobber (reg:SI 18))])]
   ""
-  "if (! shiftby_operand (operands[2], SImode)) FAIL;")
+  "
+{
+  if (! immediate_operand (operands[2], GET_MODE (operands[2])))
+    FAIL;
+}")
 
 (define_insn "ashldi3_k"
   [(set (match_operand:DI 0 "arith_reg_operand" "=r")