Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/external/gpl3/gcc/dist/gcc/config/vax Rework so that the ctz...



details:   https://anonhg.NetBSD.org/src/rev/3fe3b88d5cf5
branches:  trunk
changeset: 331632:3fe3b88d5cf5
user:      matt <matt%NetBSD.org@localhost>
date:      Sun Aug 17 16:25:21 2014 +0000

description:
Rework so that the ctzsi builtin is supported.

diffstat:

 external/gpl3/gcc/dist/gcc/config/vax/builtins.md |  8 ++++----
 external/gpl3/gcc/dist/gcc/config/vax/vax.c       |  1 +
 2 files changed, 5 insertions(+), 4 deletions(-)

diffs (36 lines):

diff -r af2572cd8980 -r 3fe3b88d5cf5 external/gpl3/gcc/dist/gcc/config/vax/builtins.md
--- a/external/gpl3/gcc/dist/gcc/config/vax/builtins.md Sun Aug 17 16:14:59 2014 +0000
+++ b/external/gpl3/gcc/dist/gcc/config/vax/builtins.md Sun Aug 17 16:25:21 2014 +0000
@@ -37,17 +37,17 @@
   "
 {
   rtx label = gen_label_rtx ();
-  emit_insn (gen_ffssi2_internal (operands[0], operands[1]));
+  emit_insn (gen_ctzsi2 (operands[0], operands[1]));
   emit_jump_insn (gen_condjump (gen_rtx_NE(VOIDmode, cc0_rtx, const0_rtx), label));
-  emit_insn (gen_negsi2 (operands[0], const1_rtx));
+  emit_move_insn (operands[0], constm1_rtx);
   emit_label (label);
   emit_insn (gen_addsi3 (operands[0], operands[0], const1_rtx));
   DONE;
 }")
 
-(define_insn "ffssi2_internal"
+(define_insn "ctzsi2"
   [(set (match_operand:SI 0 "nonimmediate_operand" "=rQ")
-       (ffs:SI (match_operand:SI 1 "general_operand" "nrmT")))
+       (ctz:SI (match_operand:SI 1 "general_operand" "nrmT")))
    (set (cc0) (match_dup 0))]
   ""
   "ffs $0,$32,%1,%0")
diff -r af2572cd8980 -r 3fe3b88d5cf5 external/gpl3/gcc/dist/gcc/config/vax/vax.c
--- a/external/gpl3/gcc/dist/gcc/config/vax/vax.c       Sun Aug 17 16:14:59 2014 +0000
+++ b/external/gpl3/gcc/dist/gcc/config/vax/vax.c       Sun Aug 17 16:25:21 2014 +0000
@@ -1117,6 +1117,7 @@
            case IOR:
            case XOR:
            case NOT:
+           case CTZ:
            case MEM:
            case REG:
              cc_status.flags = CC_NO_OVERFLOW;



Home | Main Index | Thread Index | Old Index