From: Christopher Bazley <[email protected]>

Benchmarking has shown some worthwhile improvements as a result of
unrolling small loops (<= 4 instructions) by the smallest possible
unroll factor (2) in the RTL loop unroller pass.  In preparation
for enabling loop unrolling for at least some AArch64 targets, this
commit implements the TARGET_LOOP_UNROLL_ADJUST hook with a similar
structure to the implementation of the equivalent function in other
backends.

Support is also added for an undocumented command line option,
-munroll-only-small-loops, that is already supported by several
other backends.  In the short term, the only effect of this option
on the AArch64 backend will be to suppress loop unrolling: a
max_small_unroll_ninsns member added to the tuning parameters
structure is initialized to zero for every type of CPU, which
means that no loop is considered small enough to unroll.

The combination of -funroll-loops and -munroll-only-small-loops
is now enabled by default at optimization level -O2 and above,
if debugging and optimization for code size are disabled.

Normally, enabling -funroll-loops would implicitly enable
-frename-registers ("perform a register renaming optimization
pass") and -fweb ("construct webs and split unrelated uses of
single variable").  Like the i386 and rs6000 backends, the AArch64
backend now prevents implicit enablement of -frename-registers by
disabling it by default at all optimization levels; unlike i386,
the AArch64 backend does *not* also disable -fweb, which is
therefore now implicitly enabled by default at -O2 and above.
This choice is based on benchmark results on Neoverse V3.

If -funroll-loops or -funroll-all-loops were specified when
invoking GCC (without explicit -munroll-only-small-loops or
-mno-unroll-only-small-loops) then -munroll-only-small-loops is
disabled by aarch64_override_options_after_change_1 (in
TARGET_OPTION_OVERRIDE and many other hooks).  Similarly, if the
user requested unrolling without explicit -frename-registers or
-fno-rename-registers then -frename-registers is automatically
re-enabled.  The intent is to keep GCC's behavior unchanged for
existing users of -funroll-loops and -funroll-all-loops.

These preparatory changes are not expected to cause unexpected
unrolling because no loop of more than zero insns is considered
small enough to unroll.  It is still possible to explicitly request
unrolling by a loop-specific factor at any optimization level, by
putting '#pragma GCC unroll' in the source code.

If loop unrolling is explicitly enabled at a lower optimization level
then it can now be suppressed by invoking GCC with the new
-munroll-only-small-loops option (e.g., -O1 -funroll-loops
-munroll-only-small-loops); however, that combination of options is
not guaranteed to disable loop unrolling in the long term, because it
depends on the tuning parameters for the selected target.

gcc/ChangeLog:

        * common/config/aarch64/aarch64-common.cc:
        Enable -munroll-only-small-loops with -funroll-loops in
        aarch_option_optimization_table to unroll small loops at
        -O2 and above by default, unless debugging or optimization
        for size is enabled.
        Disable -frename-registers by default at all optimization
        levels.
        * config/aarch64/aarch64-json-schema.h:
        Add max_small_unroll_ninsns and max_small_unroll_factor.
        * config/aarch64/aarch64-json-tunings-parser-generated.inc:
        Regenerate.
        * config/aarch64/aarch64-json-tunings-printer-generated.inc:
        Regenerate.
        * config/aarch64/aarch64-protos.h (struct tune_params):
        New members: max_small_unroll_ninsns and
        max_small_unroll_factor to configure which loops are
        considered 'small' and the maximum amount by which to allow
        such loops to be unrolled.
        * config/aarch64/aarch64.cc (aarch64_override_options_after_change_1):
        Disable the restriction whereby only 'small' loops are unrolled
        and enable register renaming if the user explicitly specified
        -funroll-loops or -funroll-all-loops but did not explicitly
        specify the value of dependent options.
        (aarch64_override_options_internal): Pass opts_set through to
        aarch64_override_options_after_change_1 as a new argument.
        (aarch64_override_options_after_change): Pass &global_options_set
        as a new argument to aarch64_override_options_after_change_1.
        (aarch64_loop_unroll_adjust): Implement the target hook
        TARGET_LOOP_UNROLL_ADJUST.
        (TARGET_LOOP_UNROLL_ADJUST): Define macro as
        aarch64_loop_unroll_adjust to enable target hook.
        * config/aarch64/aarch64.opt:
        Add -munroll-only-small-loops as a new undocumented option.
        * config/aarch64/tuning_models/a64fx.h:
        Initialize max_small_unroll_ninsns and
        max_small_unroll_factor to zero so that no loops are
        considered small enough to unroll in this tuning model.
        * config/aarch64/tuning_models/ampere1.h: As above.
        * config/aarch64/tuning_models/ampere1a.h: As above.
        * config/aarch64/tuning_models/ampere1b.h: As above.
        * config/aarch64/tuning_models/cortexa35.h: As above.
        * config/aarch64/tuning_models/cortexa53.h: As above.
        * config/aarch64/tuning_models/cortexa57.h: As above.
        * config/aarch64/tuning_models/cortexa72.h: As above.
        * config/aarch64/tuning_models/cortexa73.h: As above.
        * config/aarch64/tuning_models/cortexx925.h: As above.
        * config/aarch64/tuning_models/emag.h: As above.
        * config/aarch64/tuning_models/exynosm1.h: As above.
        * config/aarch64/tuning_models/fujitsu_monaka.h: As above.
        * config/aarch64/tuning_models/generic.h: As above.
        * config/aarch64/tuning_models/generic_armv8_a.h: As above.
        * config/aarch64/tuning_models/generic_armv9_a.h: As above.
        * config/aarch64/tuning_models/hip12.h: As above.
        * config/aarch64/tuning_models/neoverse512tvb.h: As above.
        * config/aarch64/tuning_models/neoversen1.h: As above.
        * config/aarch64/tuning_models/neoversen2.h: As above.
        * config/aarch64/tuning_models/neoversen3.h: As above.
        * config/aarch64/tuning_models/neoversev1.h: As above.
        * config/aarch64/tuning_models/neoversev2.h: As above.
        * config/aarch64/tuning_models/neoversev3.h: As above.
        * config/aarch64/tuning_models/neoversev3ae.h: As above.
        * config/aarch64/tuning_models/olympus.h: As above.
        * config/aarch64/tuning_models/qdf24xx.h: As above.
        * config/aarch64/tuning_models/saphira.h: As above.
        * config/aarch64/tuning_models/thunderx.h: As above.
        * config/aarch64/tuning_models/thunderx2t99.h: As above.
        * config/aarch64/tuning_models/thunderx3t110.h: As above.
        * config/aarch64/tuning_models/thunderxt88.h: As above.
        * config/aarch64/tuning_models/tsv110.h: As above.
        * config/aarch64/tuning_models/xgene1.h: As above.
---
 gcc/common/config/aarch64/aarch64-common.cc   |  8 ++++
 gcc/config/aarch64/aarch64-json-schema.h      |  2 +
 .../aarch64-json-tunings-parser-generated.inc |  2 +
 ...aarch64-json-tunings-printer-generated.inc |  2 +
 gcc/config/aarch64/aarch64-protos.h           |  7 +++
 gcc/config/aarch64/aarch64.cc                 | 46 +++++++++++++++++--
 gcc/config/aarch64/aarch64.opt                |  4 ++
 gcc/config/aarch64/tuning_models/a64fx.h      |  2 +
 gcc/config/aarch64/tuning_models/ampere1.h    |  2 +
 gcc/config/aarch64/tuning_models/ampere1a.h   |  2 +
 gcc/config/aarch64/tuning_models/ampere1b.h   |  2 +
 gcc/config/aarch64/tuning_models/cortexa35.h  |  2 +
 gcc/config/aarch64/tuning_models/cortexa53.h  |  2 +
 gcc/config/aarch64/tuning_models/cortexa57.h  |  2 +
 gcc/config/aarch64/tuning_models/cortexa72.h  |  2 +
 gcc/config/aarch64/tuning_models/cortexa73.h  |  2 +
 gcc/config/aarch64/tuning_models/cortexx925.h |  2 +
 gcc/config/aarch64/tuning_models/emag.h       |  2 +
 gcc/config/aarch64/tuning_models/exynosm1.h   |  2 +
 .../aarch64/tuning_models/fujitsu_monaka.h    |  2 +
 gcc/config/aarch64/tuning_models/generic.h    |  2 +
 .../aarch64/tuning_models/generic_armv8_a.h   |  2 +
 .../aarch64/tuning_models/generic_armv9_a.h   |  2 +
 gcc/config/aarch64/tuning_models/hip12.h      |  2 +
 .../aarch64/tuning_models/neoverse512tvb.h    |  2 +
 gcc/config/aarch64/tuning_models/neoversen1.h |  2 +
 gcc/config/aarch64/tuning_models/neoversen2.h |  2 +
 gcc/config/aarch64/tuning_models/neoversen3.h |  2 +
 gcc/config/aarch64/tuning_models/neoversev1.h |  2 +
 gcc/config/aarch64/tuning_models/neoversev2.h |  2 +
 gcc/config/aarch64/tuning_models/neoversev3.h |  2 +
 .../aarch64/tuning_models/neoversev3ae.h      |  2 +
 gcc/config/aarch64/tuning_models/olympus.h    |  2 +
 gcc/config/aarch64/tuning_models/qdf24xx.h    |  2 +
 gcc/config/aarch64/tuning_models/saphira.h    |  2 +
 gcc/config/aarch64/tuning_models/thunderx.h   |  2 +
 .../aarch64/tuning_models/thunderx2t99.h      |  2 +
 .../aarch64/tuning_models/thunderx3t110.h     |  2 +
 .../aarch64/tuning_models/thunderxt88.h       |  2 +
 gcc/config/aarch64/tuning_models/tsv110.h     |  2 +
 gcc/config/aarch64/tuning_models/xgene1.h     |  2 +
 41 files changed, 136 insertions(+), 3 deletions(-)

diff --git a/gcc/common/config/aarch64/aarch64-common.cc 
b/gcc/common/config/aarch64/aarch64-common.cc
index ae467f140e3c..83b49933f6af 100644
--- a/gcc/common/config/aarch64/aarch64-common.cc
+++ b/gcc/common/config/aarch64/aarch64-common.cc
@@ -59,6 +59,14 @@ static const struct default_options 
aarch_option_optimization_table[] =
     { OPT_LEVELS_3_PLUS, OPT_fschedule_insns, NULL, 1 },
     /* Enable redundant extension instructions removal at -O2 and higher.  */
     { OPT_LEVELS_2_PLUS, OPT_free, NULL, 1 },
+
+    /* Enable -munroll-only-small-loops with -funroll-loops to unroll small
+       loops at -O2 and above by default.  */
+    { OPT_LEVELS_2_PLUS_SPEED_ONLY, OPT_funroll_loops, NULL, 1 },
+    { OPT_LEVELS_2_PLUS_SPEED_ONLY, OPT_munroll_only_small_loops, NULL, 1 },
+    /* Turns off -frename-registers which is enabled by -funroll-loops.  */
+    { OPT_LEVELS_ALL, OPT_frename_registers, NULL, 0 },
+
     { OPT_LEVELS_2_PLUS, OPT_mearly_ra_, NULL, AARCH64_EARLY_RA_ALL },
 #if (TARGET_DEFAULT_ASYNC_UNWIND_TABLES == 1)
     { OPT_LEVELS_ALL, OPT_fasynchronous_unwind_tables, NULL, 1 },
diff --git a/gcc/config/aarch64/aarch64-json-schema.h 
b/gcc/config/aarch64/aarch64-json-schema.h
index 9b6c5478d158..07f1f7924a31 100644
--- a/gcc/config/aarch64/aarch64-json-schema.h
+++ b/gcc/config/aarch64/aarch64-json-schema.h
@@ -269,6 +269,8 @@ static const char *schema_json = R"json(
     "min_div_recip_mul_sf": "int",
     "min_div_recip_mul_df": "int",
     "max_case_values": "uint",
+    "max_small_unroll_ninsns": "uint",
+    "max_small_unroll_factor": "uint",
     "autoprefetcher_model": "enum",
     "extra_tuning_flags": "uint",
     "prefetch": {
diff --git a/gcc/config/aarch64/aarch64-json-tunings-parser-generated.inc 
b/gcc/config/aarch64/aarch64-json-tunings-parser-generated.inc
index 1a615ac7d203..97546a417f14 100644
--- a/gcc/config/aarch64/aarch64-json-tunings-parser-generated.inc
+++ b/gcc/config/aarch64/aarch64-json-tunings-parser-generated.inc
@@ -368,6 +368,8 @@ parse_tunings (gcc_json_context &ctxt, const json::object 
&jo, T &tunings)
   PARSE_INTEGER_FIELD (ctxt, jo, "min_div_recip_mul_sf", 
tunings.min_div_recip_mul_sf);
   PARSE_INTEGER_FIELD (ctxt, jo, "min_div_recip_mul_df", 
tunings.min_div_recip_mul_df);
   PARSE_UNSIGNED_INTEGER_FIELD (ctxt, jo, "max_case_values", 
tunings.max_case_values);
+  PARSE_UNSIGNED_INTEGER_FIELD (ctxt, jo, "max_small_unroll_ninsns", 
tunings.max_small_unroll_ninsns);
+  PARSE_UNSIGNED_INTEGER_FIELD (ctxt, jo, "max_small_unroll_factor", 
tunings.max_small_unroll_factor);
   PARSE_ENUM_FIELD (ctxt, jo, "autoprefetcher_model", 
tunings.autoprefetcher_model, autoprefetcher_model_mappings);
   PARSE_UNSIGNED_INTEGER_FIELD (ctxt, jo, "extra_tuning_flags", 
tunings.extra_tuning_flags);
   PARSE_OBJECT (ctxt, jo, "prefetch", tunings.prefetch, parse_prefetch);
diff --git a/gcc/config/aarch64/aarch64-json-tunings-printer-generated.inc 
b/gcc/config/aarch64/aarch64-json-tunings-printer-generated.inc
index e619a39749dd..e9b707c84a7c 100644
--- a/gcc/config/aarch64/aarch64-json-tunings-printer-generated.inc
+++ b/gcc/config/aarch64/aarch64-json-tunings-printer-generated.inc
@@ -450,6 +450,8 @@ serialize_tunings (const T &tunings)
   SERIALIZE_INTEGER_FIELD (tunings_obj, "min_div_recip_mul_sf", 
tunings.min_div_recip_mul_sf);
   SERIALIZE_INTEGER_FIELD (tunings_obj, "min_div_recip_mul_df", 
tunings.min_div_recip_mul_df);
   SERIALIZE_UNSIGNED_INTEGER_FIELD (tunings_obj, "max_case_values", 
tunings.max_case_values);
+  SERIALIZE_UNSIGNED_INTEGER_FIELD (tunings_obj, "max_small_unroll_ninsns", 
tunings.max_small_unroll_ninsns);
+  SERIALIZE_UNSIGNED_INTEGER_FIELD (tunings_obj, "max_small_unroll_factor", 
tunings.max_small_unroll_factor);
   SERIALIZE_ENUM_FIELD (tunings_obj, "autoprefetcher_model", 
tunings.autoprefetcher_model, autoprefetcher_model_mappings);
   SERIALIZE_UNSIGNED_INTEGER_FIELD (tunings_obj, "extra_tuning_flags", 
tunings.extra_tuning_flags);
   SERIALIZE_OBJECT (tunings_obj, "prefetch", tunings.prefetch, 
serialize_prefetch);
diff --git a/gcc/config/aarch64/aarch64-protos.h 
b/gcc/config/aarch64/aarch64-protos.h
index 8d201821e934..636a7a1fb72c 100644
--- a/gcc/config/aarch64/aarch64-protos.h
+++ b/gcc/config/aarch64/aarch64-protos.h
@@ -564,6 +564,13 @@ struct tune_params
   int min_div_recip_mul_df;
   /* Value for aarch64_case_values_threshold; or 0 for the default.  */
   unsigned int max_case_values;
+  /* Insn count limit for a loop to be considered small.  When unrolling is
+     restricted to small loops, loops larger than this are not unrolled.  */
+  unsigned int max_small_unroll_ninsns;
+  /* Maximum unroll factor for a small loop.  When unrolling is restricted to
+     small loops, the unroll factor of such a loop is adjusted if necessary to
+     avoid exceeding this value.  */
+  unsigned int max_small_unroll_factor;
 /* An enum specifying how to take into account CPU autoprefetch capabilities
    during instruction scheduling:
    - AUTOPREFETCHER_OFF: Do not take autoprefetch capabilities into account.
diff --git a/gcc/config/aarch64/aarch64.cc b/gcc/config/aarch64/aarch64.cc
index cd5ed154c7ac..e492c6b96759 100644
--- a/gcc/config/aarch64/aarch64.cc
+++ b/gcc/config/aarch64/aarch64.cc
@@ -19549,7 +19549,8 @@ aarch64_adjust_generic_arch_tuning (struct tune_params 
&current_tune)
 }
 
 static void
-aarch64_override_options_after_change_1 (struct gcc_options *opts)
+aarch64_override_options_after_change_1 (struct gcc_options *opts,
+                                        struct gcc_options *opts_set)
 {
   /* PR 70044: We have to be careful about being called multiple times for the
      same function.  This means all changes should be repeatable.  */
@@ -19594,6 +19595,19 @@ aarch64_override_options_after_change_1 (struct 
gcc_options *opts)
      intermediary step for the former.  */
   if (flag_mlow_precision_sqrt)
     flag_mrecip_low_precision_sqrt = true;
+
+  /* Revert to the traditional behavior of -funroll-loops and 
-funroll-all-loops
+     if they were explictly specified by the user and the user did not override
+     the implied defaults.  */
+  if ((opts_set->x_flag_unroll_loops && opts->x_flag_unroll_loops)
+      || (opts_set->x_flag_unroll_all_loops && opts->x_flag_unroll_all_loops))
+    {
+      if (!opts_set->x_unroll_only_small_loops)
+       opts->x_unroll_only_small_loops = 0;
+
+      if (!opts_set->x_flag_rename_registers)
+       opts->x_flag_rename_registers = 1;
+    }
 }
 
 /* 'Unpack' up the internal tuning structs and update the options
@@ -19858,7 +19872,7 @@ aarch64_override_options_internal (struct gcc_options 
*opts,
                         aarch64_autovec_preference,
                         opts->x_autovec_preference);
 
-  aarch64_override_options_after_change_1 (opts);
+  aarch64_override_options_after_change_1 (opts, opts_set);
 }
 
 /* Straight line speculation indicators.  */
@@ -20181,7 +20195,8 @@ aarch64_override_options (void)
 static void
 aarch64_override_options_after_change (void)
 {
-  aarch64_override_options_after_change_1 (&global_options);
+  aarch64_override_options_after_change_1 (&global_options,
+                                          &global_options_set);
 }
 
 /* Implement the TARGET_OFFLOAD_OPTIONS hook.  */
@@ -31803,6 +31818,28 @@ aarch64_indirect_call_asm (rtx addr)
   return "";
 }
 
+/* This function adjusts the unroll factor on a per loop basis.
+   Implements TARGET_LOOP_UNROLL_ADJUST.  */
+
+static unsigned
+aarch64_loop_unroll_adjust (unsigned nunroll, class loop *loop)
+{
+  /* Prevent unrolling of big loops only if configured to do so and if no
+     unroll factor was explicitly specified.  */
+  if (unroll_only_small_loops && !loop->unroll)
+    {
+      /* If the loop is small enough then allow it to be unrolled up to a
+        tunable maximum unroll factor; otherwise, it is too big to unroll.  */
+      if (loop->ninsns <= aarch64_tune_params.max_small_unroll_ninsns)
+       return MIN (nunroll, aarch64_tune_params.max_small_unroll_factor);
+      else
+       return 1; /* Loop is too big to unroll.  */
+    }
+
+  /* Allow the loop to be unrolled without adjustment.  */
+  return nunroll;
+}
+
 /* Generate assembly for AArch64 indirect branch instruction.  ADDR is the
    target address register.  Returns any additional barrier instructions
    needed for SLS (Straight Line Speculation) mitigation.  */
@@ -34139,6 +34176,9 @@ aarch64_libgcc_floating_mode_supported_p
 #undef TARGET_DOCUMENTATION_NAME
 #define TARGET_DOCUMENTATION_NAME "AArch64"
 
+#undef TARGET_LOOP_UNROLL_ADJUST
+#define TARGET_LOOP_UNROLL_ADJUST aarch64_loop_unroll_adjust
+
 struct gcc_target targetm = TARGET_INITIALIZER;
 
 #include "gt-aarch64.h"
diff --git a/gcc/config/aarch64/aarch64.opt b/gcc/config/aarch64/aarch64.opt
index ef0d96e74860..0ba8381d33ef 100644
--- a/gcc/config/aarch64/aarch64.opt
+++ b/gcc/config/aarch64/aarch64.opt
@@ -370,6 +370,10 @@ moutline-atomics
 Target Var(aarch64_flag_outline_atomics) Init(2) Save
 Generate local calls to out-of-line atomic operations.
 
+munroll-only-small-loops
+Target Undocumented Var(unroll_only_small_loops) Init(0) Save
+; Use conservative small loop unrolling.
+
 -param=aarch64-vect-compare-costs=
 Target Joined UInteger Var(aarch64_vect_compare_costs) Init(1) IntegerRange(0, 
1) Param
 When vectorizing, consider using multiple different approaches and use
diff --git a/gcc/config/aarch64/tuning_models/a64fx.h 
b/gcc/config/aarch64/tuning_models/a64fx.h
index c3222960f175..8e5d4077e889 100644
--- a/gcc/config/aarch64/tuning_models/a64fx.h
+++ b/gcc/config/aarch64/tuning_models/a64fx.h
@@ -161,6 +161,8 @@ static const struct tune_params a64fx_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE),   /* tune_flags.  */
   &a64fx_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/ampere1.h 
b/gcc/config/aarch64/tuning_models/ampere1.h
index 53d45761b42f..869544c42573 100644
--- a/gcc/config/aarch64/tuning_models/ampere1.h
+++ b/gcc/config/aarch64/tuning_models/ampere1.h
@@ -100,6 +100,8 @@ static const struct tune_params ampere1_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_AVOID_CROSS_LOOP_FMA
    | AARCH64_EXTRA_TUNE_FULLY_PIPELINED_FMA), /* tune_flags.  */
diff --git a/gcc/config/aarch64/tuning_models/ampere1a.h 
b/gcc/config/aarch64/tuning_models/ampere1a.h
index 0954ac551a0b..d65ac238b0dc 100644
--- a/gcc/config/aarch64/tuning_models/ampere1a.h
+++ b/gcc/config/aarch64/tuning_models/ampere1a.h
@@ -52,6 +52,8 @@ static const struct tune_params ampere1a_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_AVOID_CROSS_LOOP_FMA
    | AARCH64_EXTRA_TUNE_FULLY_PIPELINED_FMA), /* tune_flags.  */
diff --git a/gcc/config/aarch64/tuning_models/ampere1b.h 
b/gcc/config/aarch64/tuning_models/ampere1b.h
index b84713b53668..a378e0a7a6a7 100644
--- a/gcc/config/aarch64/tuning_models/ampere1b.h
+++ b/gcc/config/aarch64/tuning_models/ampere1b.h
@@ -101,6 +101,8 @@ static const struct tune_params ampere1b_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_STRONG,  /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_AVOID_CROSS_LOOP_FMA), /* tune_flags.  */
diff --git a/gcc/config/aarch64/tuning_models/cortexa35.h 
b/gcc/config/aarch64/tuning_models/cortexa35.h
index fd2fc47f5e23..faf667d2de30 100644
--- a/gcc/config/aarch64/tuning_models/cortexa35.h
+++ b/gcc/config/aarch64/tuning_models/cortexa35.h
@@ -52,6 +52,8 @@ static const struct tune_params cortexa35_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE),   /* tune_flags.  */
   &generic_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/cortexa53.h 
b/gcc/config/aarch64/tuning_models/cortexa53.h
index e71cc1b26afb..7ee922cbd0db 100644
--- a/gcc/config/aarch64/tuning_models/cortexa53.h
+++ b/gcc/config/aarch64/tuning_models/cortexa53.h
@@ -61,6 +61,8 @@ static const struct tune_params cortexa53_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE),   /* tune_flags.  */
   &generic_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/cortexa57.h 
b/gcc/config/aarch64/tuning_models/cortexa57.h
index 4f3ec60ba275..1f4ec49e3c96 100644
--- a/gcc/config/aarch64/tuning_models/cortexa57.h
+++ b/gcc/config/aarch64/tuning_models/cortexa57.h
@@ -98,6 +98,8 @@ static const struct tune_params cortexa57_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_RENAME_FMA_REGS),        /* tune_flags.  */
   &generic_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/cortexa72.h 
b/gcc/config/aarch64/tuning_models/cortexa72.h
index df0fcf110867..f4d942fc9f0e 100644
--- a/gcc/config/aarch64/tuning_models/cortexa72.h
+++ b/gcc/config/aarch64/tuning_models/cortexa72.h
@@ -50,6 +50,8 @@ static const struct tune_params cortexa72_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE),   /* tune_flags.  */
   &generic_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/cortexa73.h 
b/gcc/config/aarch64/tuning_models/cortexa73.h
index c871b454d40f..ceeeb46645e9 100644
--- a/gcc/config/aarch64/tuning_models/cortexa73.h
+++ b/gcc/config/aarch64/tuning_models/cortexa73.h
@@ -51,6 +51,8 @@ static const struct tune_params cortexa73_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE),   /* tune_flags.  */
   &generic_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/cortexx925.h 
b/gcc/config/aarch64/tuning_models/cortexx925.h
index 2a73b3697065..1aa361d27b92 100644
--- a/gcc/config/aarch64/tuning_models/cortexx925.h
+++ b/gcc/config/aarch64/tuning_models/cortexx925.h
@@ -218,6 +218,8 @@ static const struct tune_params cortexx925_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_CSE_SVE_VL_CONSTANTS
diff --git a/gcc/config/aarch64/tuning_models/emag.h 
b/gcc/config/aarch64/tuning_models/emag.h
index 82bbc554f41b..dabedacfe385 100644
--- a/gcc/config/aarch64/tuning_models/emag.h
+++ b/gcc/config/aarch64/tuning_models/emag.h
@@ -50,6 +50,8 @@ static const struct tune_params emag_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   17,  /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_OFF,     /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE),   /* tune_flags.  */
   &xgene1_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/exynosm1.h 
b/gcc/config/aarch64/tuning_models/exynosm1.h
index a561ccf6fa71..85bed640275c 100644
--- a/gcc/config/aarch64/tuning_models/exynosm1.h
+++ b/gcc/config/aarch64/tuning_models/exynosm1.h
@@ -134,6 +134,8 @@ static const struct tune_params exynosm1_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   48,  /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK, /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE), /* tune_flags.  */
   &exynosm1_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/fujitsu_monaka.h 
b/gcc/config/aarch64/tuning_models/fujitsu_monaka.h
index 71549bd0ea70..4a8ec6deafff 100644
--- a/gcc/config/aarch64/tuning_models/fujitsu_monaka.h
+++ b/gcc/config/aarch64/tuning_models/fujitsu_monaka.h
@@ -53,6 +53,8 @@ static const struct tune_params fujitsu_monaka_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_MATCHED_VECTOR_THROUGHPUT),    /* tune_flags.  */
diff --git a/gcc/config/aarch64/tuning_models/generic.h 
b/gcc/config/aarch64/tuning_models/generic.h
index af013e478d45..a49076cf4623 100644
--- a/gcc/config/aarch64/tuning_models/generic.h
+++ b/gcc/config/aarch64/tuning_models/generic.h
@@ -180,6 +180,8 @@ static const struct tune_params generic_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   /* Enabling AARCH64_EXTRA_TUNE_CSE_SVE_VL_CONSTANTS significantly benefits
      Neoverse V1.  It does not have a noticeable effect on A64FX and should
diff --git a/gcc/config/aarch64/tuning_models/generic_armv8_a.h 
b/gcc/config/aarch64/tuning_models/generic_armv8_a.h
index 29cf3a5a7c7a..0b23140e932e 100644
--- a/gcc/config/aarch64/tuning_models/generic_armv8_a.h
+++ b/gcc/config/aarch64/tuning_models/generic_armv8_a.h
@@ -173,6 +173,8 @@ static const struct tune_params generic_armv8_a_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_CSE_SVE_VL_CONSTANTS
diff --git a/gcc/config/aarch64/tuning_models/generic_armv9_a.h 
b/gcc/config/aarch64/tuning_models/generic_armv9_a.h
index 05e777d20efb..bc3ba9647a9f 100644
--- a/gcc/config/aarch64/tuning_models/generic_armv9_a.h
+++ b/gcc/config/aarch64/tuning_models/generic_armv9_a.h
@@ -249,6 +249,8 @@ static const struct tune_params generic_armv9_a_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_MATCHED_VECTOR_THROUGHPUT),    /* tune_flags.  */
diff --git a/gcc/config/aarch64/tuning_models/hip12.h 
b/gcc/config/aarch64/tuning_models/hip12.h
index cfb204b2e533..4dcd9aa4a986 100644
--- a/gcc/config/aarch64/tuning_models/hip12.h
+++ b/gcc/config/aarch64/tuning_models/hip12.h
@@ -215,6 +215,8 @@ static const struct tune_params hip12_tunings =
   2,    /* min_div_recip_mul_sf.  */
   2,    /* min_div_recip_mul_df.  */
   0,    /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_MATCHED_VECTOR_THROUGHPUT),    /* tune_flags.  */
diff --git a/gcc/config/aarch64/tuning_models/neoverse512tvb.h 
b/gcc/config/aarch64/tuning_models/neoverse512tvb.h
index d6e2c2e8120d..af9fa5beb7f8 100644
--- a/gcc/config/aarch64/tuning_models/neoverse512tvb.h
+++ b/gcc/config/aarch64/tuning_models/neoverse512tvb.h
@@ -154,6 +154,8 @@ static const struct tune_params neoverse512tvb_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_CSE_SVE_VL_CONSTANTS
diff --git a/gcc/config/aarch64/tuning_models/neoversen1.h 
b/gcc/config/aarch64/tuning_models/neoversen1.h
index 87c7fbcb7f22..7790221abebe 100644
--- a/gcc/config/aarch64/tuning_models/neoversen1.h
+++ b/gcc/config/aarch64/tuning_models/neoversen1.h
@@ -50,6 +50,8 @@ static const struct tune_params neoversen1_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE),   /* tune_flags.  */
   &generic_armv9a_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/neoversen2.h 
b/gcc/config/aarch64/tuning_models/neoversen2.h
index 21597e6b50f8..4a1105e2ba1f 100644
--- a/gcc/config/aarch64/tuning_models/neoversen2.h
+++ b/gcc/config/aarch64/tuning_models/neoversen2.h
@@ -216,6 +216,8 @@ static const struct tune_params neoversen2_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_CSE_SVE_VL_CONSTANTS
diff --git a/gcc/config/aarch64/tuning_models/neoversen3.h 
b/gcc/config/aarch64/tuning_models/neoversen3.h
index 37f9819148f6..23d0da4e12c3 100644
--- a/gcc/config/aarch64/tuning_models/neoversen3.h
+++ b/gcc/config/aarch64/tuning_models/neoversen3.h
@@ -216,6 +216,8 @@ static const struct tune_params neoversen3_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_CSE_SVE_VL_CONSTANTS
diff --git a/gcc/config/aarch64/tuning_models/neoversev1.h 
b/gcc/config/aarch64/tuning_models/neoversev1.h
index 253f11e87a68..beea9d9cb9bb 100644
--- a/gcc/config/aarch64/tuning_models/neoversev1.h
+++ b/gcc/config/aarch64/tuning_models/neoversev1.h
@@ -225,6 +225,8 @@ static const struct tune_params neoversev1_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_CSE_SVE_VL_CONSTANTS
diff --git a/gcc/config/aarch64/tuning_models/neoversev2.h 
b/gcc/config/aarch64/tuning_models/neoversev2.h
index 061fa6b8445c..af4581a4a59d 100644
--- a/gcc/config/aarch64/tuning_models/neoversev2.h
+++ b/gcc/config/aarch64/tuning_models/neoversev2.h
@@ -354,6 +354,8 @@ static const struct tune_params neoversev2_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_CSE_SVE_VL_CONSTANTS
diff --git a/gcc/config/aarch64/tuning_models/neoversev3.h 
b/gcc/config/aarch64/tuning_models/neoversev3.h
index 7e0144032dc6..2aaa2afd6e47 100644
--- a/gcc/config/aarch64/tuning_models/neoversev3.h
+++ b/gcc/config/aarch64/tuning_models/neoversev3.h
@@ -216,6 +216,8 @@ static const struct tune_params neoversev3_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_CSE_SVE_VL_CONSTANTS
diff --git a/gcc/config/aarch64/tuning_models/neoversev3ae.h 
b/gcc/config/aarch64/tuning_models/neoversev3ae.h
index bbe4dc547015..4081da45fa71 100644
--- a/gcc/config/aarch64/tuning_models/neoversev3ae.h
+++ b/gcc/config/aarch64/tuning_models/neoversev3ae.h
@@ -216,6 +216,8 @@ static const struct tune_params neoversev3ae_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_CSE_SVE_VL_CONSTANTS
diff --git a/gcc/config/aarch64/tuning_models/olympus.h 
b/gcc/config/aarch64/tuning_models/olympus.h
index c83e35adc2b9..bbdc65c5a6b6 100644
--- a/gcc/config/aarch64/tuning_models/olympus.h
+++ b/gcc/config/aarch64/tuning_models/olympus.h
@@ -555,6 +555,8 @@ static struct tune_params olympus_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_BASE
    | AARCH64_EXTRA_TUNE_CSE_SVE_VL_CONSTANTS
diff --git a/gcc/config/aarch64/tuning_models/qdf24xx.h 
b/gcc/config/aarch64/tuning_models/qdf24xx.h
index a15a4fc56897..bb770179ceeb 100644
--- a/gcc/config/aarch64/tuning_models/qdf24xx.h
+++ b/gcc/config/aarch64/tuning_models/qdf24xx.h
@@ -126,6 +126,8 @@ static const struct tune_params qdf24xx_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE), /* tune_flags.  */
   &qdf24xx_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/saphira.h 
b/gcc/config/aarch64/tuning_models/saphira.h
index 369d3618f7f1..6805eeda7734 100644
--- a/gcc/config/aarch64/tuning_models/saphira.h
+++ b/gcc/config/aarch64/tuning_models/saphira.h
@@ -52,6 +52,8 @@ static const struct tune_params saphira_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE),           /* tune_flags.  */
   &generic_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/thunderx.h 
b/gcc/config/aarch64/tuning_models/thunderx.h
index ed8de307276a..caaea2fe6487 100644
--- a/gcc/config/aarch64/tuning_models/thunderx.h
+++ b/gcc/config/aarch64/tuning_models/thunderx.h
@@ -107,6 +107,8 @@ static const struct tune_params thunderx_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_OFF,     /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_CHEAP_SHIFT_EXTEND),     /* tune_flags.  */
   &thunderx_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/thunderx2t99.h 
b/gcc/config/aarch64/tuning_models/thunderx2t99.h
index f6be657ac9c3..e3ccd67089e0 100644
--- a/gcc/config/aarch64/tuning_models/thunderx2t99.h
+++ b/gcc/config/aarch64/tuning_models/thunderx2t99.h
@@ -127,6 +127,8 @@ static const struct tune_params thunderx2t99_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE),   /* tune_flags.  */
   &thunderx2t99_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/thunderx3t110.h 
b/gcc/config/aarch64/tuning_models/thunderx3t110.h
index cdcbec680945..8cf2f403b584 100644
--- a/gcc/config/aarch64/tuning_models/thunderx3t110.h
+++ b/gcc/config/aarch64/tuning_models/thunderx3t110.h
@@ -126,6 +126,8 @@ static const struct tune_params thunderx3t110_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,    /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE),   /* tune_flags.  */
   &thunderx3t110_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/thunderxt88.h 
b/gcc/config/aarch64/tuning_models/thunderxt88.h
index 44a1eac59a96..d592282d0cb0 100644
--- a/gcc/config/aarch64/tuning_models/thunderxt88.h
+++ b/gcc/config/aarch64/tuning_models/thunderxt88.h
@@ -62,6 +62,8 @@ static const struct tune_params thunderxt88_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   0,   /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_OFF,     /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE),   /* tune_flags.  */
   &thunderxt88_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/tsv110.h 
b/gcc/config/aarch64/tuning_models/tsv110.h
index 366f2b3e2323..c59fe5b15e12 100644
--- a/gcc/config/aarch64/tuning_models/tsv110.h
+++ b/gcc/config/aarch64/tuning_models/tsv110.h
@@ -127,6 +127,8 @@ static const struct tune_params tsv110_tunings =
   2,    /* min_div_recip_mul_sf.  */
   2,    /* min_div_recip_mul_df.  */
   0,    /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_WEAK,     /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE),     /* tune_flags.  */
   &tsv110_prefetch_tune,
diff --git a/gcc/config/aarch64/tuning_models/xgene1.h 
b/gcc/config/aarch64/tuning_models/xgene1.h
index 0d4aaf80b61a..229139332f9a 100644
--- a/gcc/config/aarch64/tuning_models/xgene1.h
+++ b/gcc/config/aarch64/tuning_models/xgene1.h
@@ -135,6 +135,8 @@ static const struct tune_params xgene1_tunings =
   2,   /* min_div_recip_mul_sf.  */
   2,   /* min_div_recip_mul_df.  */
   17,  /* max_case_values.  */
+  0,   /* max_small_unroll_ninsns.  */
+  0,   /* max_small_unroll_factor.  */
   tune_params::AUTOPREFETCHER_OFF,     /* autoprefetcher_model.  */
   (AARCH64_EXTRA_TUNE_NONE),   /* tune_flags.  */
   &xgene1_prefetch_tune,
-- 
2.54.0


Reply via email to