@@ -774,7 +774,8 @@ public:
{
function_instance instance ("svneg", functions::svneg,
shapes::unary, MODE_none,
- f.type_suffix_ids, GROUP_none, f.pred);
+ f.type_suffix_ids, GROUP_none, f.pred,
+ FPM_unused);
gcall *call = f.redirect_call (instance);
unsigned offset_index = 0;
if (f.pred == PRED_m)
@@ -802,7 +803,8 @@ public:
{
function_instance instance ("svlsr", functions::svlsr,
shapes::binary_uint_opt_n, MODE_n,
- f.type_suffix_ids, GROUP_none, f.pred);
+ f.type_suffix_ids, GROUP_none, f.pred,
+ FPM_unused);
call = f.redirect_call (instance);
tree d = INTEGRAL_TYPE_P (TREE_TYPE (op2)) ? op2 : op2_cst;
new_divisor = wide_int_to_tree (TREE_TYPE (d), tree_log2 (d));
@@ -815,7 +817,8 @@ public:
function_instance instance ("svasrd", functions::svasrd,
shapes::shift_right_imm, MODE_n,
- f.type_suffix_ids, GROUP_none, f.pred);
+ f.type_suffix_ids, GROUP_none, f.pred,
+ FPM_unused);
call = f.redirect_call (instance);
new_divisor = wide_int_to_tree (scalar_types[VECTOR_TYPE_svuint64_t],
tree_log2 (op2_cst));
@@ -2092,7 +2095,8 @@ public:
{
function_instance instance ("svneg", functions::svneg,
shapes::unary, MODE_none,
- f.type_suffix_ids, GROUP_none, f.pred);
+ f.type_suffix_ids, GROUP_none, f.pred,
+ FPM_unused);
gcall *call = f.redirect_call (instance);
unsigned offset_index = 0;
if (f.pred == PRED_m)
@@ -2133,7 +2137,8 @@ public:
tree_log2 (shift_op2));
function_instance instance ("svlsl", functions::svlsl,
shapes::binary_uint_opt_n, MODE_n,
- f.type_suffix_ids, GROUP_none, f.pred);
+ f.type_suffix_ids, GROUP_none, f.pred,
+ FPM_unused);
gcall *call = f.redirect_call (instance);
gimple_call_set_arg (call, 1, shift_op1);
gimple_call_set_arg (call, 2, shift_op2);
@@ -200,7 +200,7 @@ DEF_SVE_FUNCTION (svrbit, unary, all_integer, mxz)
DEF_SVE_FUNCTION (svrecpe, unary, all_float, none)
DEF_SVE_FUNCTION (svrecps, binary, all_float, none)
DEF_SVE_FUNCTION (svrecpx, unary, all_float, mxz)
-DEF_SVE_FUNCTION_GS (svreinterpret, reinterpret, reinterpret, x1234, none)
+DEF_SVE_FUNCTION_GS (svreinterpret, reinterpret, reinterpret, x1234, none, unused)
DEF_SVE_FUNCTION (svreinterpret, reinterpret, reinterpret_b, none)
DEF_SVE_FUNCTION (svrev, unary, all_data, none)
DEF_SVE_FUNCTION (svrev, unary_pred, all_pred, none)
@@ -350,7 +350,8 @@ build_one (function_builder &b, const char *signature,
auto_vec<tree, 16> argument_types;
function_instance instance (group.base_name, *group.base, *group.shape,
mode_suffix_id, group.types[ti],
- group.groups[gi], group.preds[pi]);
+ group.groups[gi], group.preds[pi],
+ group.fpm_mode);
tree return_type = parse_signature (instance, signature, argument_types);
apply_predication (instance, return_type, argument_types);
b.add_unique_function (instance, return_type, argument_types,
@@ -19,17 +19,17 @@
#ifndef DEF_SME_FUNCTION
#define DEF_SME_FUNCTION(NAME, SHAPE, TYPES, PREDS) \
- DEF_SME_FUNCTION_GS (NAME, SHAPE, TYPES, none, PREDS)
+ DEF_SME_FUNCTION_GS (NAME, SHAPE, TYPES, none, PREDS, unused)
#endif
#ifndef DEF_SME_ZA_FUNCTION_GS
-#define DEF_SME_ZA_FUNCTION_GS(NAME, SHAPE, TYPES, GROUP, PREDS) \
- DEF_SME_FUNCTION_GS (NAME, SHAPE, TYPES, GROUP, PREDS)
+#define DEF_SME_ZA_FUNCTION_GS(NAME, SHAPE, TYPES, GROUP, PREDS, FPM_MODE) \
+ DEF_SME_FUNCTION_GS (NAME, SHAPE, TYPES, GROUP, PREDS, FPM_MODE)
#endif
#ifndef DEF_SME_ZA_FUNCTION
#define DEF_SME_ZA_FUNCTION(NAME, SHAPE, TYPES, PREDS) \
- DEF_SME_ZA_FUNCTION_GS (NAME, SHAPE, TYPES, none, PREDS)
+ DEF_SME_ZA_FUNCTION_GS (NAME, SHAPE, TYPES, none, PREDS, unused)
#endif
#define REQUIRED_EXTENSIONS 0
@@ -101,117 +101,127 @@ DEF_SME_FUNCTION (svzero_zt, inherent_zt, none, none)
floating-point function. They are needed because the integer and
floating-point functions have different architecture requirements. */
#define REQUIRED_EXTENSIONS AARCH64_FL_SME | AARCH64_FL_SME2 | AARCH64_FL_SM_ON
-DEF_SME_ZA_FUNCTION_GS (svadd, unary_za_slice, za_s_data, vg1x24, none)
-DEF_SME_ZA_FUNCTION_GS (svadd, unary_za_slice, d_za, vg1x24, none)
+DEF_SME_ZA_FUNCTION_GS (svadd, unary_za_slice, za_s_data, vg1x24, none, unused)
+DEF_SME_ZA_FUNCTION_GS (svadd, unary_za_slice, d_za, vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svadd_write, binary_za_slice_opt_single, za_s_integer,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION (svbmopa, binary_za_m, za_s_unsigned, za_m)
DEF_SME_ZA_FUNCTION (svbmops, binary_za_m, za_s_unsigned, za_m)
DEF_SME_ZA_FUNCTION_GS (svdot, binary_za_slice_opt_single, za_s_h_data,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svdot, binary_za_slice_opt_single, za_s_b_integer,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svdot_lane, dot_za_slice_lane, za_s_h_data,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svdot_lane, dot_za_slice_lane, za_s_b_integer,
- vg1x24, none)
-DEF_SME_FUNCTION_GS (svluti2_lane_zt, luti2_lane_zt, bhs_data, x124, none)
-DEF_SME_FUNCTION_GS (svluti4_lane_zt, luti4_lane_zt, bhs_data, x12, none)
-DEF_SME_FUNCTION_GS (svluti4_lane_zt, luti4_lane_zt, hs_data, x4, none)
+ vg1x24, none, unused)
+DEF_SME_FUNCTION_GS (svluti2_lane_zt, luti2_lane_zt, bhs_data, x124, none,
+ unused)
+DEF_SME_FUNCTION_GS (svluti4_lane_zt, luti4_lane_zt, bhs_data, x12, none,
+ unused)
+DEF_SME_FUNCTION_GS (svluti4_lane_zt, luti4_lane_zt, hs_data, x4, none,
+ unused)
DEF_SME_ZA_FUNCTION_GS (svmla, binary_za_slice_opt_single, za_s_float,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmla, binary_za_slice_opt_single, za_s_h_data,
- vg2, none)
+ vg2, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmla, binary_za_slice_opt_single, za_s_b_integer,
- vg4, none)
+ vg4, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmla_lane, binary_za_slice_lane, za_s_float,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmla_lane, binary_za_slice_lane, za_s_h_data,
- vg2, none)
+ vg2, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmla_lane, binary_za_slice_lane, za_s_b_integer,
- vg4, none)
+ vg4, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmls, binary_za_slice_opt_single, za_s_float,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmls, binary_za_slice_opt_single, za_s_h_data,
- vg2, none)
+ vg2, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmls, binary_za_slice_opt_single, za_s_b_integer,
- vg4, none)
+ vg4, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmls_lane, binary_za_slice_lane, za_s_float,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmls_lane, binary_za_slice_lane, za_s_h_data,
- vg2, none)
+ vg2, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmls_lane, binary_za_slice_lane, za_s_b_integer,
- vg4, none)
+ vg4, none, unused)
DEF_SME_ZA_FUNCTION (svmopa, binary_za_m, za_s_h_integer, za_m)
DEF_SME_ZA_FUNCTION (svmops, binary_za_m, za_s_h_integer, za_m)
-DEF_SME_ZA_FUNCTION_GS (svread, read_za_slice, za_bhsd_data, vg1x24, none)
-DEF_SME_ZA_FUNCTION_GS (svread_hor, read_za, za_bhsd_data, vg24, none)
-DEF_SME_ZA_FUNCTION_GS (svread_ver, read_za, za_bhsd_data, vg24, none)
-DEF_SME_ZA_FUNCTION_GS (svsub, unary_za_slice, za_s_data, vg1x24, none)
-DEF_SME_ZA_FUNCTION_GS (svsub, unary_za_slice, d_za, vg1x24, none)
+DEF_SME_ZA_FUNCTION_GS (svread, read_za_slice, za_bhsd_data, vg1x24, none, unused)
+DEF_SME_ZA_FUNCTION_GS (svread_hor, read_za, za_bhsd_data, vg24, none, unused)
+DEF_SME_ZA_FUNCTION_GS (svread_ver, read_za, za_bhsd_data, vg24, none, unused)
+DEF_SME_ZA_FUNCTION_GS (svsub, unary_za_slice, za_s_data, vg1x24, none, unused)
+DEF_SME_ZA_FUNCTION_GS (svsub, unary_za_slice, d_za, vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svsub_write, binary_za_slice_opt_single, za_s_integer,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svsudot, binary_za_slice_uint_opt_single,
- za_s_b_signed, vg1x24, none)
+ za_s_b_signed, vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svsudot_lane, dot_za_slice_uint_lane,
- za_s_b_signed, vg1x24, none)
+ za_s_b_signed, vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svsuvdot_lane, dot_za_slice_uint_lane,
- za_s_b_signed, vg1x4, none)
+ za_s_b_signed, vg1x4, none, unused)
DEF_SME_ZA_FUNCTION_GS (svusdot, binary_za_slice_int_opt_single,
- za_s_b_unsigned, vg1x24, none)
+ za_s_b_unsigned, vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svusdot_lane, dot_za_slice_int_lane,
- za_s_b_unsigned, vg1x24, none)
+ za_s_b_unsigned, vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svusvdot_lane, dot_za_slice_int_lane,
- za_s_b_unsigned, vg1x4, none)
+ za_s_b_unsigned, vg1x4, none, unused)
DEF_SME_ZA_FUNCTION_GS (svvdot_lane, dot_za_slice_lane, za_s_h_data,
- vg1x2, none)
+ vg1x2, none, unused)
DEF_SME_ZA_FUNCTION_GS (svvdot_lane, dot_za_slice_lane, za_s_b_integer,
- vg1x4, none)
-DEF_SME_ZA_FUNCTION_GS (svwrite, write_za_slice, za_bhsd_data, vg1x24, none)
-DEF_SME_ZA_FUNCTION_GS (svwrite_hor, write_za, za_bhsd_data, vg24, none)
-DEF_SME_ZA_FUNCTION_GS (svwrite_ver, write_za, za_bhsd_data, vg24, none)
+ vg1x4, none, unused)
+DEF_SME_ZA_FUNCTION_GS (svwrite, write_za_slice, za_bhsd_data, vg1x24, none,
+ unused)
+DEF_SME_ZA_FUNCTION_GS (svwrite_hor, write_za, za_bhsd_data, vg24, none,
+ unused)
+DEF_SME_ZA_FUNCTION_GS (svwrite_ver, write_za, za_bhsd_data, vg24, none,
+ unused)
#undef REQUIRED_EXTENSIONS
#define REQUIRED_EXTENSIONS (AARCH64_FL_SME \
| AARCH64_FL_SME2 \
| AARCH64_FL_SME_I16I64 \
| AARCH64_FL_SM_ON)
-DEF_SME_ZA_FUNCTION_GS (svadd, unary_za_slice, za_d_integer, vg1x24, none)
+DEF_SME_ZA_FUNCTION_GS (svadd, unary_za_slice, za_d_integer, vg1x24, none,
+ unused)
DEF_SME_ZA_FUNCTION_GS (svadd_write, binary_za_slice_opt_single, za_d_integer,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svdot, binary_za_slice_opt_single, za_d_h_integer,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svdot_lane, dot_za_slice_lane, za_d_h_integer,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmla, binary_za_slice_opt_single, za_d_h_integer,
- vg4, none)
+ vg4, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmla_lane, binary_za_slice_lane, za_d_h_integer,
- vg4, none)
+ vg4, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmls, binary_za_slice_opt_single, za_d_h_integer,
- vg4, none)
+ vg4, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmls_lane, binary_za_slice_lane, za_d_h_integer,
- vg4, none)
-DEF_SME_ZA_FUNCTION_GS (svsub, unary_za_slice, za_d_integer, vg1x24, none)
+ vg4, none, unused)
+DEF_SME_ZA_FUNCTION_GS (svsub, unary_za_slice, za_d_integer, vg1x24, none,
+ unused)
DEF_SME_ZA_FUNCTION_GS (svsub_write, binary_za_slice_opt_single, za_d_integer,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svvdot_lane, dot_za_slice_lane, za_d_h_integer,
- vg1x4, none)
+ vg1x4, none, unused)
#undef REQUIRED_EXTENSIONS
#define REQUIRED_EXTENSIONS (AARCH64_FL_SME \
| AARCH64_FL_SME2 \
| AARCH64_FL_SME_F64F64 \
| AARCH64_FL_SM_ON)
-DEF_SME_ZA_FUNCTION_GS (svadd, unary_za_slice, za_d_float, vg1x24, none)
+DEF_SME_ZA_FUNCTION_GS (svadd, unary_za_slice, za_d_float, vg1x24, none,
+ unused)
DEF_SME_ZA_FUNCTION_GS (svmla, binary_za_slice_opt_single, za_d_float,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmla_lane, binary_za_slice_lane, za_d_float,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmls, binary_za_slice_opt_single, za_d_float,
- vg1x24, none)
+ vg1x24, none, unused)
DEF_SME_ZA_FUNCTION_GS (svmls_lane, binary_za_slice_lane, za_d_float,
- vg1x24, none)
-DEF_SME_ZA_FUNCTION_GS (svsub, unary_za_slice, za_d_float, vg1x24, none)
+ vg1x24, none, unused)
+DEF_SME_ZA_FUNCTION_GS (svsub, unary_za_slice, za_d_float, vg1x24, none,
+ unused)
#undef REQUIRED_EXTENSIONS
#undef DEF_SME_ZA_FUNCTION
@@ -90,7 +90,8 @@ public:
return NULL;
function_instance instance ("svabd", functions::svabd,
shapes::binary_opt_n, f.mode_suffix_id,
- f.type_suffix_ids, GROUP_none, PRED_x);
+ f.type_suffix_ids, GROUP_none, PRED_x,
+ FPM_unused);
gcall *call = f.redirect_call (instance);
/* Add a ptrue as predicate, because unlike svaba, svabd is
predicated. */
@@ -322,7 +323,8 @@ public:
that we can use for sensible shift amounts. */
function_instance instance ("svqshl", functions::svqshl,
shapes::binary_int_opt_n, MODE_n,
- f.type_suffix_ids, GROUP_none, f.pred);
+ f.type_suffix_ids, GROUP_none, f.pred,
+ FPM_unused);
return f.redirect_call (instance);
}
else
@@ -332,7 +334,7 @@ public:
function_instance instance ("svrshl", functions::svrshl,
shapes::binary_int_opt_single_n,
MODE_n, f.type_suffix_ids, GROUP_none,
- f.pred);
+ f.pred, FPM_unused);
return f.redirect_call (instance);
}
}
@@ -361,7 +363,8 @@ public:
-wi::to_wide (amount));
function_instance instance ("svasr", functions::svasr,
shapes::binary_uint_opt_n, MODE_n,
- f.type_suffix_ids, GROUP_none, f.pred);
+ f.type_suffix_ids, GROUP_none, f.pred,
+ FPM_unused);
if (f.type_suffix (0).unsigned_p)
{
instance.base_name = "svlsr";
@@ -396,7 +399,8 @@ public:
that we can use for sensible shift amounts. */
function_instance instance ("svlsl", functions::svlsl,
shapes::binary_uint_opt_n, MODE_n,
- f.type_suffix_ids, GROUP_none, f.pred);
+ f.type_suffix_ids, GROUP_none, f.pred,
+ FPM_unused);
gcall *call = f.redirect_call (instance);
gimple_call_set_arg (call, 2, amount);
return call;
@@ -409,7 +413,8 @@ public:
-wi::to_wide (amount));
function_instance instance ("svrshr", functions::svrshr,
shapes::shift_right_imm, MODE_n,
- f.type_suffix_ids, GROUP_none, f.pred);
+ f.type_suffix_ids, GROUP_none, f.pred,
+ FPM_unused);
gcall *call = f.redirect_call (instance);
gimple_call_set_arg (call, 2, amount);
return call;
@@ -445,7 +450,8 @@ public:
return NULL;
function_instance instance ("svlsr", functions::svlsr,
shapes::binary_uint_opt_n, MODE_n,
- f.type_suffix_ids, GROUP_none, PRED_x);
+ f.type_suffix_ids, GROUP_none, PRED_x,
+ FPM_unused);
if (!f.type_suffix (0).unsigned_p)
{
instance.base_name = "svasr";
@@ -244,59 +244,71 @@ DEF_SVE_FUNCTION (svrevd, unary, all_data, mxz)
| AARCH64_FL_SME \
| AARCH64_FL_SME2 \
| AARCH64_FL_SM_ON)
-DEF_SVE_FUNCTION_GS (svadd, binary_single, all_integer, x24, none)
+DEF_SVE_FUNCTION_GS (svadd, binary_single, all_integer, x24, none, unused)
DEF_SVE_FUNCTION (svbfmlslb, ternary_bfloat_opt_n, s_float, none)
DEF_SVE_FUNCTION (svbfmlslb_lane, ternary_bfloat_lane, s_float, none)
DEF_SVE_FUNCTION (svbfmlslt, ternary_bfloat_opt_n, s_float, none)
DEF_SVE_FUNCTION (svbfmlslt_lane, ternary_bfloat_lane, s_float, none)
DEF_SVE_FUNCTION (svclamp, clamp, all_float, none)
-DEF_SVE_FUNCTION_GS (svclamp, clamp, all_arith, x24, none)
+DEF_SVE_FUNCTION_GS (svclamp, clamp, all_arith, x24, none, unused)
DEF_SVE_FUNCTION (svcntp, count_pred_c, all_count, none)
-DEF_SVE_FUNCTION_GS (svcvt, unary_convertxn, cvt_h_s_float, x2, none)
-DEF_SVE_FUNCTION_GS (svcvt, unary_convertxn, cvt_s_s, x24, none)
-DEF_SVE_FUNCTION_GS (svcvtn, unary_convertxn, cvt_h_s_float, x2, none)
+DEF_SVE_FUNCTION_GS (svcvt, unary_convertxn, cvt_h_s_float, x2, none, unused)
+DEF_SVE_FUNCTION_GS (svcvt, unary_convertxn, cvt_s_s, x24, none, unused)
+DEF_SVE_FUNCTION_GS (svcvtn, unary_convertxn, cvt_h_s_float, x2, none, unused)
DEF_SVE_FUNCTION (svdot, ternary_qq_opt_n_or_011, s_narrow_fsu, none)
DEF_SVE_FUNCTION (svdot_lane, ternary_qq_or_011_lane, s_narrow_fsu, none)
-DEF_SVE_FUNCTION_GS (svld1, load, all_data, x24, implicit)
-DEF_SVE_FUNCTION_GS (svldnt1, load, all_data, x24, implicit)
-DEF_SVE_FUNCTION_GS (svmax, binary_opt_single_n, all_arith, x24, none)
-DEF_SVE_FUNCTION_GS (svmaxnm, binary_opt_single_n, all_float, x24, none)
-DEF_SVE_FUNCTION_GS (svmin, binary_opt_single_n, all_arith, x24, none)
-DEF_SVE_FUNCTION_GS (svminnm, binary_opt_single_n, all_float, x24, none)
-DEF_SVE_FUNCTION_GS (svpext_lane, extract_pred, all_count, x12, none)
+DEF_SVE_FUNCTION_GS (svld1, load, all_data, x24, implicit, unused)
+DEF_SVE_FUNCTION_GS (svldnt1, load, all_data, x24, implicit, unused)
+DEF_SVE_FUNCTION_GS (svmax, binary_opt_single_n, all_arith, x24, none, unused)
+DEF_SVE_FUNCTION_GS (svmaxnm, binary_opt_single_n, all_float, x24, none,
+ unused)
+DEF_SVE_FUNCTION_GS (svmin, binary_opt_single_n, all_arith, x24, none, unused)
+DEF_SVE_FUNCTION_GS (svminnm, binary_opt_single_n, all_float, x24, none,
+ unused)
+DEF_SVE_FUNCTION_GS (svpext_lane, extract_pred, all_count, x12, none, unused)
DEF_SVE_FUNCTION (svptrue, inherent, all_count, none)
-DEF_SVE_FUNCTION_GS (svqcvt, unary_convertxn, qcvt_x2, x2, none)
-DEF_SVE_FUNCTION_GS (svqcvt, unary_convertxn, qcvt_x4, x4, none)
-DEF_SVE_FUNCTION_GS (svqcvtn, unary_convertxn, qcvt_x2, x2, none)
-DEF_SVE_FUNCTION_GS (svqcvtn, unary_convertxn, qcvt_x4, x4, none)
-DEF_SVE_FUNCTION_GS (svqdmulh, binary_opt_single_n, all_signed, x24, none)
-DEF_SVE_FUNCTION_GS (svqrshr, shift_right_imm_narrowxn, qrshr_x2, x2, none)
-DEF_SVE_FUNCTION_GS (svqrshr, shift_right_imm_narrowxn, qrshr_x4, x4, none)
-DEF_SVE_FUNCTION_GS (svqrshrn, shift_right_imm_narrowxn, qrshr_x2, x2, none)
-DEF_SVE_FUNCTION_GS (svqrshrn, shift_right_imm_narrowxn, qrshr_x4, x4, none)
-DEF_SVE_FUNCTION_GS (svqrshru, shift_right_imm_narrowxn, qrshru_x2, x2, none)
-DEF_SVE_FUNCTION_GS (svqrshru, shift_right_imm_narrowxn, qrshru_x4, x4, none)
-DEF_SVE_FUNCTION_GS (svqrshrun, shift_right_imm_narrowxn, qrshru_x2, x2, none)
-DEF_SVE_FUNCTION_GS (svqrshrun, shift_right_imm_narrowxn, qrshru_x4, x4, none)
-DEF_SVE_FUNCTION_GS (svrinta, unaryxn, s_float, x24, none)
-DEF_SVE_FUNCTION_GS (svrintm, unaryxn, s_float, x24, none)
-DEF_SVE_FUNCTION_GS (svrintn, unaryxn, s_float, x24, none)
-DEF_SVE_FUNCTION_GS (svrintp, unaryxn, s_float, x24, none)
-DEF_SVE_FUNCTION_GS (svrshl, binary_int_opt_single_n, all_integer, x24, none)
-DEF_SVE_FUNCTION_GS (svsel, binaryxn, all_data, x24, implicit)
-DEF_SVE_FUNCTION_GS (svst1, storexn, all_data, x24, implicit)
-DEF_SVE_FUNCTION_GS (svstnt1, storexn, all_data, x24, implicit)
-DEF_SVE_FUNCTION_GS (svunpk, unary_convertxn, bhs_widen, x24, none)
-DEF_SVE_FUNCTION_GS (svuzp, unaryxn, all_data, x24, none)
-DEF_SVE_FUNCTION_GS (svuzpq, unaryxn, all_data, x24, none)
-DEF_SVE_FUNCTION_GS (svwhilege, compare_scalar, while_x, x2, none)
+DEF_SVE_FUNCTION_GS (svqcvt, unary_convertxn, qcvt_x2, x2, none, unused)
+DEF_SVE_FUNCTION_GS (svqcvt, unary_convertxn, qcvt_x4, x4, none, unused)
+DEF_SVE_FUNCTION_GS (svqcvtn, unary_convertxn, qcvt_x2, x2, none, unused)
+DEF_SVE_FUNCTION_GS (svqcvtn, unary_convertxn, qcvt_x4, x4, none, unused)
+DEF_SVE_FUNCTION_GS (svqdmulh, binary_opt_single_n, all_signed, x24, none,
+ unused)
+DEF_SVE_FUNCTION_GS (svqrshr, shift_right_imm_narrowxn, qrshr_x2, x2, none,
+ unused)
+DEF_SVE_FUNCTION_GS (svqrshr, shift_right_imm_narrowxn, qrshr_x4, x4, none,
+ unused)
+DEF_SVE_FUNCTION_GS (svqrshrn, shift_right_imm_narrowxn, qrshr_x2, x2, none,
+ unused)
+DEF_SVE_FUNCTION_GS (svqrshrn, shift_right_imm_narrowxn, qrshr_x4, x4, none,
+ unused)
+DEF_SVE_FUNCTION_GS (svqrshru, shift_right_imm_narrowxn, qrshru_x2, x2, none,
+ unused)
+DEF_SVE_FUNCTION_GS (svqrshru, shift_right_imm_narrowxn, qrshru_x4, x4, none,
+ unused)
+DEF_SVE_FUNCTION_GS (svqrshrun, shift_right_imm_narrowxn, qrshru_x2, x2, none,
+ unused)
+DEF_SVE_FUNCTION_GS (svqrshrun, shift_right_imm_narrowxn, qrshru_x4, x4, none,
+ unused)
+DEF_SVE_FUNCTION_GS (svrinta, unaryxn, s_float, x24, none, unused)
+DEF_SVE_FUNCTION_GS (svrintm, unaryxn, s_float, x24, none, unused)
+DEF_SVE_FUNCTION_GS (svrintn, unaryxn, s_float, x24, none, unused)
+DEF_SVE_FUNCTION_GS (svrintp, unaryxn, s_float, x24, none, unused)
+DEF_SVE_FUNCTION_GS (svrshl, binary_int_opt_single_n, all_integer, x24, none,
+ unused)
+DEF_SVE_FUNCTION_GS (svsel, binaryxn, all_data, x24, implicit, unused)
+DEF_SVE_FUNCTION_GS (svst1, storexn, all_data, x24, implicit, unused)
+DEF_SVE_FUNCTION_GS (svstnt1, storexn, all_data, x24, implicit, unused)
+DEF_SVE_FUNCTION_GS (svunpk, unary_convertxn, bhs_widen, x24, none, unused)
+DEF_SVE_FUNCTION_GS (svuzp, unaryxn, all_data, x24, none, unused)
+DEF_SVE_FUNCTION_GS (svuzpq, unaryxn, all_data, x24, none, unused)
+DEF_SVE_FUNCTION_GS (svwhilege, compare_scalar, while_x, x2, none, unused)
DEF_SVE_FUNCTION (svwhilege, compare_scalar_count, while_x_c, none)
-DEF_SVE_FUNCTION_GS (svwhilegt, compare_scalar, while_x, x2, none)
+DEF_SVE_FUNCTION_GS (svwhilegt, compare_scalar, while_x, x2, none, unused)
DEF_SVE_FUNCTION (svwhilegt, compare_scalar_count, while_x_c, none)
-DEF_SVE_FUNCTION_GS (svwhilele, compare_scalar, while_x, x2, none)
+DEF_SVE_FUNCTION_GS (svwhilele, compare_scalar, while_x, x2, none, unused)
DEF_SVE_FUNCTION (svwhilele, compare_scalar_count, while_x_c, none)
-DEF_SVE_FUNCTION_GS (svwhilelt, compare_scalar, while_x, x2, none)
+DEF_SVE_FUNCTION_GS (svwhilelt, compare_scalar, while_x, x2, none, unused)
DEF_SVE_FUNCTION (svwhilelt, compare_scalar_count, while_x_c, none)
-DEF_SVE_FUNCTION_GS (svzip, unaryxn, all_data, x24, none)
-DEF_SVE_FUNCTION_GS (svzipq, unaryxn, all_data, x24, none)
+DEF_SVE_FUNCTION_GS (svzip, unaryxn, all_data, x24, none, unused)
+DEF_SVE_FUNCTION_GS (svzipq, unaryxn, all_data, x24, none, unused)
#undef REQUIRED_EXTENSIONS
@@ -887,9 +887,9 @@ static const predication_index preds_za_m[] = { PRED_za_m, NUM_PREDS };
/* A list of all arm_sve.h functions. */
static CONSTEXPR const function_group_info function_groups[] = {
-#define DEF_SVE_FUNCTION_GS(NAME, SHAPE, TYPES, GROUPS, PREDS) \
+#define DEF_SVE_FUNCTION_GS(NAME, SHAPE, TYPES, GROUPS, PREDS, FPM_MODE) \
{ #NAME, &functions::NAME, &shapes::SHAPE, types_##TYPES, groups_##GROUPS, \
- preds_##PREDS, REQUIRED_EXTENSIONS },
+ preds_##PREDS, REQUIRED_EXTENSIONS, FPM_##FPM_MODE },
#include "aarch64-sve-builtins.def"
};
@@ -897,18 +897,19 @@ static CONSTEXPR const function_group_info function_groups[] = {
static CONSTEXPR const function_group_info neon_sve_function_groups[] = {
#define DEF_NEON_SVE_FUNCTION(NAME, SHAPE, TYPES, GROUPS, PREDS) \
{ #NAME, &neon_sve_bridge_functions::NAME, &shapes::SHAPE, types_##TYPES, \
- groups_##GROUPS, preds_##PREDS, 0 },
+ groups_##GROUPS, preds_##PREDS, 0, FPM_unused },
#include "aarch64-neon-sve-bridge-builtins.def"
};
/* A list of all arm_sme.h functions. */
static CONSTEXPR const function_group_info sme_function_groups[] = {
-#define DEF_SME_FUNCTION_GS(NAME, SHAPE, TYPES, GROUPS, PREDS) \
+#define DEF_SME_FUNCTION_GS(NAME, SHAPE, TYPES, GROUPS, PREDS, FPM_MODE1) \
{ #NAME, &functions::NAME, &shapes::SHAPE, types_##TYPES, groups_##GROUPS, \
- preds_##PREDS, REQUIRED_EXTENSIONS },
-#define DEF_SME_ZA_FUNCTION_GS(NAME, SHAPE, TYPES, GROUPS, PREDS) \
+ preds_##PREDS, REQUIRED_EXTENSIONS, FPM_##FPM_MODE1 },
+#define DEF_SME_ZA_FUNCTION_GS(NAME, SHAPE, TYPES, GROUPS, PREDS, FPM_MODE2) \
{ #NAME, &functions::NAME##_za, &shapes::SHAPE, types_##TYPES, \
- groups_##GROUPS, preds_##PREDS, (REQUIRED_EXTENSIONS | AARCH64_FL_ZA_ON) },
+ groups_##GROUPS, preds_##PREDS, (REQUIRED_EXTENSIONS | AARCH64_FL_ZA_ON), \
+ FPM_##FPM_MODE2 },
#include "aarch64-sve-builtins-sme.def"
};
@@ -1175,6 +1176,7 @@ function_instance::hash () const
h.add_int (type_suffix_ids[1]);
h.add_int (group_suffix_id);
h.add_int (pred);
+ h.add_int (fpm_mode);
return h.end ();
}
@@ -1595,7 +1597,8 @@ function_builder::add_overloaded_functions (const function_group_info &group,
{
function_instance instance (group.base_name, *group.base,
*group.shape, mode, types,
- group_suffix_id, group.preds[pi]);
+ group_suffix_id, group.preds[pi],
+ group.fpm_mode);
add_overloaded_function (instance, group.required_extensions);
};
@@ -1773,7 +1776,7 @@ function_resolver::lookup_form (mode_suffix_index mode,
{
type_suffix_pair types = { type0, type1 };
function_instance instance (base_name, base, shape, mode, types,
- group, pred);
+ group, pred, fpm_mode);
registered_function *rfn
= function_table->find_with_hash (instance, instance.hash ());
return rfn ? rfn->decl : NULL_TREE;
@@ -38,7 +38,7 @@
#endif
#ifndef DEF_SVE_FUNCTION_GS
-#define DEF_SVE_FUNCTION_GS(A, B, C, D, E)
+#define DEF_SVE_FUNCTION_GS(A, B, C, D, E, F)
#endif
#ifndef DEF_SVE_NEON_TYPE_SUFFIX
@@ -48,7 +48,7 @@
#ifndef DEF_SVE_FUNCTION
#define DEF_SVE_FUNCTION(NAME, SHAPE, TYPES, PREDS) \
- DEF_SVE_FUNCTION_GS (NAME, SHAPE, TYPES, none, PREDS)
+ DEF_SVE_FUNCTION_GS (NAME, SHAPE, TYPES, none, PREDS, unused)
#endif
DEF_SVE_MODE (n, none, none, none)
@@ -28,6 +28,7 @@
- the "mode" suffix ("_n", "_index", etc.)
- the type suffixes ("_s32", "_b8", etc.)
- the predication suffix ("_x", "_z", etc.)
+ - the "_fpm" suffix when the floating point mode register is set
Each piece of information is individually useful, so we retain this
classification throughout:
@@ -42,6 +43,8 @@
- prediction_index extends the predication suffix with an additional
alternative: PRED_implicit for implicitly-predicated operations
+ - fpm_mode represents whether the fpm register is set or not
+
In addition to its unique full name, a function may have a shorter
overloaded alias. This alias removes pieces of the suffixes that
can be inferred from the arguments, such as by shortening the mode
@@ -164,6 +167,14 @@ enum predication_index
NUM_PREDS
};
+/* Classifies intrinsics on whether they set the FPM register */
+enum fpm_mode_index
+{
+ FPM_unused,
+ FPM_set,
+ NUM_FPM_MODES
+};
+
/* Classifies element types, based on type suffixes with the bit count
removed. "count" isn't really an element type, but we pretend it is
for consistency. */
@@ -367,6 +378,9 @@ struct function_group_info
/* The architecture extensions that the functions require, as a set of
AARCH64_FL_* flags. */
aarch64_feature_flags required_extensions;
+
+ /* Whether the floating point register is set */
+ fpm_mode_index fpm_mode;
};
/* Describes a single fully-resolved function (i.e. one that has a
@@ -377,7 +391,7 @@ public:
function_instance (const char *, const function_base *,
const function_shape *, mode_suffix_index,
const type_suffix_pair &, group_suffix_index,
- predication_index);
+ predication_index, fpm_mode_index);
bool operator== (const function_instance &) const;
bool operator!= (const function_instance &) const;
@@ -421,6 +435,7 @@ public:
type_suffix_pair type_suffix_ids;
group_suffix_index group_suffix_id;
predication_index pred;
+ fpm_mode_index fpm_mode;
};
class registered_function;
@@ -879,10 +894,11 @@ function_instance (const char *base_name_in,
mode_suffix_index mode_suffix_id_in,
const type_suffix_pair &type_suffix_ids_in,
group_suffix_index group_suffix_id_in,
- predication_index pred_in)
+ predication_index pred_in,
+ fpm_mode_index fpm_mode_in)
: base_name (base_name_in), base (base_in), shape (shape_in),
mode_suffix_id (mode_suffix_id_in), group_suffix_id (group_suffix_id_in),
- pred (pred_in)
+ pred (pred_in), fpm_mode(fpm_mode_in)
{
memcpy (type_suffix_ids, type_suffix_ids_in, sizeof (type_suffix_ids));
}
@@ -896,7 +912,8 @@ function_instance::operator== (const function_instance &other) const
&& type_suffix_ids[0] == other.type_suffix_ids[0]
&& type_suffix_ids[1] == other.type_suffix_ids[1]
&& group_suffix_id == other.group_suffix_id
- && pred == other.pred);
+ && pred == other.pred
+ && fpm_mode == other.fpm_mode);
}
inline bool