Re: [PATCH V3 2/2] sched: idle: IRQ based next prediction for idle period

From: Rafael J. Wysocki
Date: Thu Feb 18 2016 - 14:57:23 EST


On Thu, Feb 18, 2016 at 11:25 AM, Daniel Lezcano
<daniel.lezcano@xxxxxxxxxx> wrote:
> On 02/17/2016 11:21 PM, Rafael J. Wysocki wrote:
>
> [ ... ]
>
>>>> Reviewed-by: Nicolas Pitre <nico@xxxxxxxxxx>
>>>
>>>
>>> Well, I'm likely overlooking something, but how is this going to be
>>> hooked up to the code in idle.c?
>>
>>
>> My somewhat educated guess is that sched_idle() in your patch is
>> intended to replace cpuidle_idle_call(), right?
>
>
> Well, no. I was planning to first have it to use a different code path as
> experimental code in order to focus improving the accuracy of the prediction
> and then merge or replace cpuidle_idle_call() with sched_idle().

In that case, what about making it a proper cpuidle governor that
people can test and play with in a usual way? Then it may potentially
benefit everybody and not just your experimental setup and you may get
coverage on systems you have no access to normally.

There is some boilerplate code to add for this purpose, but that's not
that bad IMO.

>
>> If so, why do you want to replace it?
>>

So I'm still unsure why you want to replace cpuidle_idle_call() with
sched_idle(). Is there anything wrong with it that it needs to be
replaced?

Thanks,
Rafael