aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex Shi <alex.shi@intel.com>2012-06-06 02:52:51 -0400
committerIngo Molnar <mingo@kernel.org>2012-06-06 10:52:25 -0400
commit10717dcde10d09f9fcee53a12a4236af1a82b484 (patch)
treeef7fa575d2bec5631201cd72c5764f042650e382
parentceb1cbac8eda66cf0f889def226b4e82f8ff857b (diff)
sched/numa: Load balance between remote nodes
Commit cb83b629b ("sched/numa: Rewrite the CONFIG_NUMA sched domain support") removed the NODE sched domain and started checking if the node distance in SLIT table is farther than REMOTE_DISTANCE, if so, it will lose the load balance chance at exec/fork/wake_affine points. But actually, even the node distance is farther than REMOTE_DISTANCE. Modern CPUs also has QPI like connections, which ensures that memory access is not too slow between nodes. So the above change in behavior on NUMA machine causes a performance regression on various benchmarks: hackbench, tbench, netperf, oltp, etc. This patch will recover the scheduler behavior to old mode on all my Intel platforms: NHM EP/EX, WSM EP, SNB EP/EP4S, and thus fixes the perfromance regressions. (all of them just have 2 kinds distance, 10, 21) Signed-off-by: Alex Shi <alex.shi@intel.com> Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1338965571-9812-1-git-send-email-alex.shi@intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org>
-rw-r--r--kernel/sched/core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index c46958e26121..6546083af3e0 100644
--- a/kernel/sched/core.c
+++ b/kernel/sched/core.c
@@ -6321,7 +6321,7 @@ static int sched_domains_curr_level;
6321 6321
6322static inline int sd_local_flags(int level) 6322static inline int sd_local_flags(int level)
6323{ 6323{
6324 if (sched_domains_numa_distance[level] > REMOTE_DISTANCE) 6324 if (sched_domains_numa_distance[level] > RECLAIM_DISTANCE)
6325 return 0; 6325 return 0;
6326 6326
6327 return SD_BALANCE_EXEC | SD_BALANCE_FORK | SD_WAKE_AFFINE; 6327 return SD_BALANCE_EXEC | SD_BALANCE_FORK | SD_WAKE_AFFINE;