This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch committed FT32] Pattern for CC to register move


The attached patch adds a pattern for CC to register move.

[gcc]

2015-11-11  James Bowman  <james.bowman@ftdichip.com>

        * config/ft32/ft32.md: New pattern *sne

Index: gcc/config/ft32/ft32.md
===================================================================
--- gcc/config/ft32/ft32.md     (revision 230144)
+++ gcc/config/ft32/ft32.md     (working copy)
@@ -255,6 +255,13 @@
 
 ;; SImode
 
+(define_insn "*sne"
+   [(set (match_operand:SI 0 "register_operand" "=r")
+         (reg:SI CC_REG))]
+   ""
+   "bextu.l %0,$cc,32|0\;xor.l %0,%0,-1"
+)
+
 ;; Push a register onto the stack
 (define_insn "movsi_push"
   [(set (mem:SI (pre_dec:SI (reg:SI SP_REG)))
@@ -884,6 +891,7 @@
   DONE;
 })
 
+
 (define_expand "epilogue"
   [(return)]
   ""


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]