[ARC] Fix FLS, SETI patterns.
authorClaudiu Zissulescu <claziss@synopsys.com>
Mon, 23 Apr 2018 09:55:14 +0000 (11:55 +0200)
committerClaudiu Zissulescu <claziss@gcc.gnu.org>
Mon, 23 Apr 2018 09:55:14 +0000 (11:55 +0200)
Claudiu Zissulescu  <claziss@synopsys.com>

* config/arc/arc.md ("vunspec"): Delete it, unify all the unspec
enums into a single definition.
(fls): Fix predicates and printing.
(seti): Likewise.

From-SVN: r259558

gcc/ChangeLog
gcc/config/arc/arc.md

index 6044fbcb99067f80d1eeffd2c15a73f663105e26..4dcf45ec9f196772e24624b080b0cc9a920e1777 100644 (file)
@@ -1,3 +1,10 @@
+2018-04-23  Claudiu Zissulescu  <claziss@synopsys.com>
+
+       * config/arc/arc.md ("vunspec"): Delete it, unify all the unspec
+       enums into a single definition.
+       (fls): Fix predicates and printing.
+       (seti): Likewise.
+
 2018-04-23  Claudiu Zissulescu  <claziss@synopsys.com>
 
        * config/arc/arc-protos.h (check_if_valid_sleep_operand): Remove.
index c4bc300fd74468e93f4bac38c0116579c2843070..d19e99daca72136ac52be5dbb6235fcbd7eb4f85 100644 (file)
   UNSPEC_ARC_VMPY2H
   UNSPEC_ARC_VMPY2HU
   UNSPEC_ARC_STKTIE
-  ])
 
-(define_c_enum "vunspec" [
   VUNSPEC_ARC_RTIE
   VUNSPEC_ARC_SYNC
   VUNSPEC_ARC_BRK
    })
 
 (define_insn "fls"
-  [(set (match_operand:SI  0 "dest_reg_operand" "=w,w")
-       (unspec:SI [(match_operand:SI 1 "general_operand" "cL,Cal")]
+  [(set (match_operand:SI  0 "register_operand" "=r,r")
+       (unspec:SI [(match_operand:SI 1 "nonmemory_operand" "rL,Cal")]
                            UNSPEC_ARC_FLS))]
   "TARGET_NORM && TARGET_V2"
-  "@
-   fls \t%0, %1
-   fls \t%0, %1"
+  "fls\\t%0,%1"
   [(set_attr "length" "4,8")
    (set_attr "type" "two_cycle_core,two_cycle_core")])
 
 (define_insn "seti"
-  [(unspec_volatile:SI [(match_operand:SI 0 "general_operand" "rL")]
+  [(unspec_volatile:SI [(match_operand:SI 0 "nonmemory_operand" "rL")]
                       VUNSPEC_ARC_SETI)]
   "TARGET_V2"
-  "seti  %0"
+  "seti\\t%0"
   [(set_attr "length" "4")
    (set_attr "type" "misc")])