Re: [PATCH] sched: Get rid of unnecessary checks from select_idle_sibling

From: Namhyung Kim
Date: Thu Jan 10 2013 - 00:48:52 EST


Hi Preeti,

On Wed, 09 Jan 2013 13:51:00 +0530, Preeti U. Murthy wrote:
> On 01/09/2013 12:20 PM, Namhyung Kim wrote:
>> From: Namhyung Kim <namhyung.kim@xxxxxxx>
>>
>> AFAICS @target cpu of select_idle_sibling() is always either prev_cpu
>> or this_cpu. So no need to check it again and the conditionals can be
>> consolidated.
[snip]
> If NUMA_TTWU_BIAS or NUMA_TTWU_TO is true(it is false by

I can't find those bits in the code. I've checked v3.8-rc2,
next-20130110, tip/master and tip/numa/core but there's nothing like
above. Which tree are you saying?


> default),cpu/prev_cpu can be changed to be a random node_cpu(the node
> that 'this_cpu' is on). In which case even if the node cpu is idle,it
> would not be a viable target,looks like.Maybe that is why
> select_idle_sibling() makes the check if the target is prev_cpu/this cpu.

Looking into tip/numa/core, I can see that there's a code added for
CONFIG_NUMA_BALANCING. But still, it seems nothing changed on a path
from select_task_rq_fair() to select_idle_sibling() - i.e. if the
select_idle_sibling called, the target would be either prev_cpu or this
cpu. Am I missing something?

Thanks,
Namhyung
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/