lkml.org 
[lkml]   [2013]   [Jan]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] sched: Get rid of unnecessary checks from select_idle_sibling
Date
On Wed, 09 Jan 2013 16:34:39 +0800, Alex Shi wrote:
> On 01/09/2013 03:54 PM, Namhyung Kim wrote:
>> Hi Alex,
>>
>> On Wed, 09 Jan 2013 15:33:40 +0800, Alex Shi wrote:
>>> On 01/09/2013 02:50 PM, Namhyung Kim wrote:
>>>> From: Namhyung Kim <namhyung.kim@lge.com>
>>>>
>>>> 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]
>>> Uh, we don't know if the target is this_cpu or previous cpu, If we just
>>> check the target idle status, we may miss another idle cpu. So this
>>> patch change the logical in this function.
>>
>> select_idle_sibling() is called only in select_task_rq_fair() if it
>> found a suitable affine_sd. The default target is the 'prev_cpu' of the
>> task but if wake_affine() returns true it'd be (this) 'cpu'.
>>
>> I cannot see where the prev_cpu or the cpu is set to another one before
>> calling select_idle_sibling.
>
> The old logical will return directly whenever prev_cpu or this cpu idle,
> but your new logical just has one chance.

Sorry, I can't get your point. Could you elaborate on it a bit more?

Thanks,
Namhyung


\
 
 \ /
  Last update: 2013-01-10 07:21    [W:0.132 / U:0.292 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site