Re: [PATCH] sched, fair: Allow a small degree of load imbalance between SD_NUMA domains

Valentin Schneider
2019-12-19T14:23:38Z

On 19/12/2019 11:46, Valentin Schneider wrote:
> As for picking values, right now we have
>
> 125 (default) / 117 (LLC domain) / 110 (SMT domain)
>
> We could have
>
> >> 2 (25%), >> 3 (12.5%), >> 4 (6.25%).
>

Hmph, I see that task_numa_migrate() starts with a slightly different value
(112), and does the same halving pattern as wake_affine_weight():

x = 100 + (sd->imbalance_pct - 100) / 2;

The 112 could use >> 3 (12.5%); the halving is just an extra shift with the
suggested changes.

> It's not strictly equivalent but IMO the whole imbalance_pct thing isn't
> very precise anyway; just needs to be good enough on a sufficient number of
> topologies.
>
>
>
>>> + env->imbalance = 0;
>>> +
>>> return;
>>> }
>>>