Re: [PATCH] x86,sched: Fix sched_smt_power_savings totally broken

From: Vincent Guittot
Date: Tue Jan 10 2012 - 10:32:45 EST


On 10 January 2012 15:32, Arjan van de Ven <arjan@xxxxxxxxxxxxxxx> wrote:
> On 1/10/2012 1:18 AM, Ingo Molnar wrote:
>>
>> * Suresh Siddha <suresh.b.siddha@xxxxxxxxx> wrote:
>>
>>> On Tue, 2012-01-10 at 00:58 -0500, Youquan Song wrote:
>>>> Thanks Peter! Here is the patch.
>>>
>>> Youquan, As far as I know both the
>>> sched_smt_power_savings/sched_mc_power_savings are broken for atleast an
>>> year.
>>
>> We want a single knob, sched_power_savings - with the mc_ and
>> smt_ ones still kept and aliased to sched_power_savings, for
>> compatibility reasons.
>>
>> As Peter said, the other reasonable option is to have no knob at
>> all and restart this code from scratch.
>>
>> The other thing we should do is to add sane defaults: to turn on
>> sched_power_savings *AUTOMATICALLY* when a system is obviously
>> battery driven and turn it off when the system is obviously AC
>> driven. User-space can still implement policy and override the
>> kernel's default, but there's absolutely no excuse to not offer
>> this default ourselves.
>
> a very good default would be to keep all tasks on one package until half
> the cores in the package are busy, and then start spreading out.
>

The choice of spreading or not tasks is clearly architecture or even
platform dependent. Can't we get such optimal threshold information
from architecture code ?

> I suspect that'll be the 90% case coverage.
> --
> 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/
--
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/