[Patch AArch64] Fixup to fcvt patterns added in r237200
authorJames Greenhalgh <james.greenhalgh@arm.com>
Mon, 20 Jun 2016 13:40:07 +0000 (13:40 +0000)
committerJames Greenhalgh <jgreenhalgh@gcc.gnu.org>
Mon, 20 Jun 2016 13:40:07 +0000 (13:40 +0000)
gcc/

* config/aarch64/aarch64.md
(<FCVT_F2FIXED:fcvt_fixed_insn><GPF:mode>3): Add attributes to
iterators.
(<FCVT_FIXED2F:fcvt_fixed_insn><GPI:mode>3): Likewise.  Correct
attributes.
* config/aarch64/aarch64-builtins.c
(aarch64_types_binop_uss_qualifiers): Delete.
(TYPES_BINOP_USS): Likewise.
(aarch64_types_binop_sus_qualifiers): Likewise.
(TYPES_BINOP_SUS): Likewise.
(aarch64_types_fcvt_from_unsigned_qualifiers): New.
(TYPES_FCVTIMM_SUS): Likewise.
* config/aarch64/aarch64-simd-builtins.def (scvtf): Use SHIFTIMM
rather than BINOP.
(ucvtf): Use FCVTIMM_SUS rather than BINOP_SUS.
(fcvtzs): Use SHIFTIMM rather than BINOP.
(fcvtzu): Use SHIFTIMM_USS rather than BINOP_USS.

From-SVN: r237602

gcc/ChangeLog
gcc/config/aarch64/aarch64-builtins.c
gcc/config/aarch64/aarch64-simd-builtins.def
gcc/config/aarch64/aarch64.md

index e6f7e9e5233c55ce721013f5a18fa6b04bfba637..1e01322952f21b66b374cb89eb650e653bbd3762 100644 (file)
@@ -1,3 +1,23 @@
+2016-06-20  James Greenhalgh  <james.greenhalgh@arm.com>
+
+       * config/aarch64/aarch64.md
+       (<FCVT_F2FIXED:fcvt_fixed_insn><GPF:mode>3): Add attributes to
+       iterators.
+       (<FCVT_FIXED2F:fcvt_fixed_insn><GPI:mode>3): Likewise.  Correct
+       attributes.
+       * config/aarch64/aarch64-builtins.c
+       (aarch64_types_binop_uss_qualifiers): Delete.
+       (TYPES_BINOP_USS): Likewise.
+       (aarch64_types_binop_sus_qualifiers): Likewise.
+       (TYPES_BINOP_SUS): Likewise.
+       (aarch64_types_fcvt_from_unsigned_qualifiers): New.
+       (TYPES_FCVTIMM_SUS): Likewise.
+       * config/aarch64/aarch64-simd-builtins.def (scvtf): Use SHIFTIMM
+       rather than BINOP.
+       (ucvtf): Use FCVTIMM_SUS rather than BINOP_SUS.
+       (fcvtzs): Use SHIFTIMM rather than BINOP.
+       (fcvtzu): Use SHIFTIMM_USS rather than BINOP_USS.
+
 2016-06-20  James Greenhalgh  <james.greenhalgh@arm.com>
 
        * config/arm/aarch-cost-tables.h (cortexa57_extra_costs): Make FP
index 262ea1c519f4f01a1a0726296994e40a48f26680..6b90b2af5e9d2b5e7f48569ec1ebcb0ef16314ee 100644 (file)
@@ -139,14 +139,6 @@ aarch64_types_binop_ssu_qualifiers[SIMD_MAX_BUILTIN_ARGS]
   = { qualifier_none, qualifier_none, qualifier_unsigned };
 #define TYPES_BINOP_SSU (aarch64_types_binop_ssu_qualifiers)
 static enum aarch64_type_qualifiers
-aarch64_types_binop_uss_qualifiers[SIMD_MAX_BUILTIN_ARGS]
-  = { qualifier_unsigned, qualifier_none, qualifier_none };
-#define TYPES_BINOP_USS (aarch64_types_binop_uss_qualifiers)
-static enum aarch64_type_qualifiers
-aarch64_types_binop_sus_qualifiers[SIMD_MAX_BUILTIN_ARGS]
-  = { qualifier_none, qualifier_unsigned, qualifier_none };
-#define TYPES_BINOP_SUS (aarch64_types_binop_sus_qualifiers)
-static enum aarch64_type_qualifiers
 aarch64_types_binopp_qualifiers[SIMD_MAX_BUILTIN_ARGS]
   = { qualifier_poly, qualifier_poly, qualifier_poly };
 #define TYPES_BINOPP (aarch64_types_binopp_qualifiers)
@@ -181,6 +173,10 @@ aarch64_types_shift_to_unsigned_qualifiers[SIMD_MAX_BUILTIN_ARGS]
   = { qualifier_unsigned, qualifier_none, qualifier_immediate };
 #define TYPES_SHIFTIMM_USS (aarch64_types_shift_to_unsigned_qualifiers)
 static enum aarch64_type_qualifiers
+aarch64_types_fcvt_from_unsigned_qualifiers[SIMD_MAX_BUILTIN_ARGS]
+  = { qualifier_none, qualifier_unsigned, qualifier_immediate };
+#define TYPES_FCVTIMM_SUS (aarch64_types_fcvt_from_unsigned_qualifiers)
+static enum aarch64_type_qualifiers
 aarch64_types_unsigned_shift_qualifiers[SIMD_MAX_BUILTIN_ARGS]
   = { qualifier_unsigned, qualifier_unsigned, qualifier_immediate };
 #define TYPES_USHIFTIMM (aarch64_types_unsigned_shift_qualifiers)
index 1332734ce01da90d67c4eabfa0ce1cb6c70abfa5..02d465b8a0848d2f1676015462478a83e97e6b9b 100644 (file)
   BUILTIN_VSDQ_HSI (QUADOP_LANE, sqrdmlsh_laneq, 0)
 
   /* Implemented by <FCVT_F2FIXED/FIXED2F:fcvt_fixed_insn><*><*>3.  */
-  BUILTIN_VSDQ_SDI (BINOP, scvtf, 3)
-  BUILTIN_VSDQ_SDI (BINOP_SUS, ucvtf, 3)
-  BUILTIN_VALLF (BINOP, fcvtzs, 3)
-  BUILTIN_VALLF (BINOP_USS, fcvtzu, 3)
+  BUILTIN_VSDQ_SDI (SHIFTIMM, scvtf, 3)
+  BUILTIN_VSDQ_SDI (FCVTIMM_SUS, ucvtf, 3)
+  BUILTIN_VALLF (SHIFTIMM, fcvtzs, 3)
+  BUILTIN_VALLF (SHIFTIMM_USS, fcvtzu, 3)
 
   /* Implemented by aarch64_rsqrte<mode>.  */
   BUILTIN_VALLF (UNOP, rsqrte, 0)
index b4e6ba0047e0b0ac9d143793dbc1475384291eb2..bcb7db086574683597d58a69a0fff9f2723d569f 100644 (file)
         FCVT_F2FIXED))]
   ""
   "@
-   <FCVT_F2FIXED:fcvt_fixed_insn>\t%<w1>0, %<s>1, #%2
-   <FCVT_F2FIXED:fcvt_fixed_insn>\t%<s>0, %<s>1, #%2"
+   <FCVT_F2FIXED:fcvt_fixed_insn>\t%<GPF:w1>0, %<GPF:s>1, #%2
+   <FCVT_F2FIXED:fcvt_fixed_insn>\t%<GPF:s>0, %<GPF:s>1, #%2"
   [(set_attr "type" "f_cvtf2i, neon_fp_to_int_<GPF:Vetype>")
    (set_attr "fp" "yes, *")
    (set_attr "simd" "*, yes")]
         FCVT_FIXED2F))]
   ""
   "@
-   <FCVT_FIXED2F:fcvt_fixed_insn>\t%<s>0, %<w1>1, #%2
-   <FCVT_FIXED2F:fcvt_fixed_insn>\t%<s>0, %<s>1, #%2"
+   <FCVT_FIXED2F:fcvt_fixed_insn>\t%<GPI:v>0, %<GPI:w>1, #%2
+   <FCVT_FIXED2F:fcvt_fixed_insn>\t%<GPI:v>0, %<GPI:v>1, #%2"
   [(set_attr "type" "f_cvti2f, neon_int_to_fp_<GPI:Vetype>")
    (set_attr "fp" "yes, *")
    (set_attr "simd" "*, yes")]