lkml.org 
[lkml]   [2018]   [Sep]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 4/4] sched/numa: Do not move imbalanced load purely on the basis of an idle CPU
* Peter Zijlstra <peterz@infradead.org> [2018-09-12 11:36:21]:

> On Wed, Sep 12, 2018 at 12:24:10PM +0530, Srikar Dronamraju wrote:
>
> > Kernel A = 4.18+ 13 sched patches part of v4.19-rc1.
> > Kernel B = Kernel A + 6 patches (http://lore.kernel.org/lkml/1533276841-16341-1-git-send-email-srikar@linux.vnet.ibm.com)
> > Kernel C = Kernel B - (Avoid task migration for small numa improvement) i.e
> > http://lore.kernel.org/lkml/1533276841-16341-4-git-send-email-srikar@linux.vnet.ibm.com
> > + 2 patches from Mel
> > (Do not move imbalanced load purely)
> > http://lore.kernel.org/lkml/20180907101139.20760-5-mgorman@techsingularity.net
> > (Stop comparing tasks for NUMA placement)
> > http://lore.kernel.org/lkml/20180907101139.20760-4-mgorman@techsingularity.net
>
> But that's not a fair comparison :/ You've complicated things by adding
> that second patch from Mel.
>

One patch does choose a idle thread over a possible swap. This is the one
that conflicts with "Avoid task migration for small numa improvement".

The other one detects if we have already found an idle thread and stops
iterating. So if we have already chosen a idle CPU, then dont iterate. So
this patch should ideally help the above patch.

My take on both the patches:
If there is a possible swap candidate (i.e if choosing a thread over idle is
better from a NUMA score improvement perspective), then it means the swap
candidate will benefit from movement. It means the swap candidate is not
running on its preferred node at this moment. If we don't do it, the swap
candidate will later on try migrating to its preferred node. We could avoid
that if we choose swap candidate over idle thread. Please note if the idle
and swap candidates yield the same NUMA score, then we still choose the idle
thread and not the swap candidate.

> Now you cannot (unambiguously) tell what the cause for the performance
> difference is.
>

The difference as I listed above is should we choose a swap candidate with
more NUMA score compared to idle thread.

My patch would hurt if there was an idle thread and we still iterate for
possible swap candidates and we dont find any. But that we cant speculate.

\
 
 \ /
  Last update: 2018-09-12 12:45    [W:0.069 / U:0.152 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site