]> git.baikalelectronics.ru Git - kernel.git/commit
sched/numa: Apply imbalance limitations consistently
authorMel Gorman <mgorman@techsingularity.net>
Fri, 20 May 2022 10:35:18 +0000 (11:35 +0100)
committerPeter Zijlstra <peterz@infradead.org>
Mon, 13 Jun 2022 08:29:59 +0000 (10:29 +0200)
commite2a38c621f517af06c7cc8904d103edd49c1647e
tree947d47688097dfa46b9956fb84442630b1f53f13
parent0594dcbf755a66377e5643dbacd224f07e5145c0
sched/numa: Apply imbalance limitations consistently

The imbalance limitations are applied inconsistently at fork time
and at runtime. At fork, a new task can remain local until there are
too many running tasks even if the degree of imbalance is larger than
NUMA_IMBALANCE_MIN which is different to runtime. Secondly, the imbalance
figure used during load balancing is different to the one used at NUMA
placement. Load balancing uses the number of tasks that must move to
restore imbalance where as NUMA balancing uses the total imbalance.

In combination, it is possible for a parallel workload that uses a small
number of CPUs without applying scheduler policies to have very variable
run-to-run performance.

[lkp@intel.com: Fix build breakage for arc-allyesconfig]

Signed-off-by: Mel Gorman <mgorman@techsingularity.net>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Tested-by: K Prateek Nayak <kprateek.nayak@amd.com>
Link: https://lore.kernel.org/r/20220520103519.1863-4-mgorman@techsingularity.net
kernel/sched/fair.c