Re: [RFC] sched: unused cpu in affine workload

From: Peter Zijlstra
Date: Mon Apr 04 2016 - 17:34:58 EST


On Mon, Apr 04, 2016 at 03:45:16PM -0400, Rik van Riel wrote:
> An optimal solution is NP hard.
>
> Heuristics that "move tasks with pressure" may be
> much more doable, and lead to perfectly satisfactory
> results, especially if most migrations happen within
> a socket (and the same shared L3 cache).

Right; trick will be finding something that mostly works without making
the regular balance paths increase in complexity.

As per the argument in kernel/sched/fair.c:5694 the current
load-balancing averages out to O(n), and I would very much like to keep
it that way.