Message ID | CAOvf_xxUaOkzzyVZp1nzq8Uw63tfuTyneSzhkoLwanzVw32_4g@mail.gmail.com |
---|---|
State | New |
Headers | show |
On Fri, Nov 21, 2014 at 11:46 AM, Evgeny Stupachenko <evstupac@gmail.com> wrote: > PING. > "200" currently looks optimal for x86. > Let's commit the following: > > 2014-11-21 Evgeny Stupachenko <evstupac@gmail.com> > * config/i386/i386.c (ix86_option_override_internal): Increase > PARAM_MAX_COMPLETELY_PEELED_INSNS. OK. Looks like a good performance vs. codesize tradeoff. Uros.
> OK. Looks like a good performance vs. codesize tradeoff.
Yes, but IMO this should be done in the generic code, unrolling small loops is
profitable on most architectures.
On Sat, Nov 22, 2014 at 10:49 AM, Eric Botcazou <ebotcazou@adacore.com> wrote: >> OK. Looks like a good performance vs. codesize tradeoff. > > Yes, but IMO this should be done in the generic code, unrolling small loops is > profitable on most architectures. Yeah, but after a couple of pings for a generic change, we went the target way. Uros.
> Yeah, but after a couple of pings for a generic change, we went the target > way. That's a bit of a shame, the 400 -> 100 change was very likely tested only on x86-64 and nevetheless applied to the generic code, so the fix repairing the damages should also be applied to the generic code.
On November 22, 2014 12:24:22 PM CET, Eric Botcazou <ebotcazou@adacore.com> wrote: >> Yeah, but after a couple of pings for a generic change, we went the >target >> way. > >That's a bit of a shame, the 400 -> 100 change was very likely tested >only on >x86-64 and nevetheless applied to the generic code, so the fix >repairing the >damages should also be applied to the generic code. A patch to bump the generic limit is OK. Targets that dont want it can reduce it in target specific code. Richard.
diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c index 6337aa5..5ac10eb 100644 --- a/gcc/config/i386/i386.c +++ b/gcc/config/i386/i386.c @@ -4081,6 +4081,12 @@ ix86_option_override_internal (bool main_args_p, opts->x_param_values, opts_set->x_param_values); + /* Extend full peel max insns parameter for x86. */ + maybe_set_param_value (PARAM_MAX_COMPLETELY_PEELED_INSNS, + 200, + opts->x_param_values, + opts_set->x_param_values); + /* Enable sw prefetching at -O3 for CPUS that prefetching is helpful. */ if (opts->x_flag_prefetch_loop_arrays < 0