From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dietmar Eggemann Subject: Re: [PATCH v5 09/14] sched: Add over-utilization/tipping point indicator Date: Mon, 6 Aug 2018 15:20:27 +0200 Message-ID: <454ee0da-9c6c-6944-25e5-0fbbf89bc3b6@arm.com> References: <20180802153035.vjtmqwdwujvt7ojs@queper01-lin> <20180802160009.uhwwj3tqrqmv7q5a@queper01-lin> <20180802161027.v2ctgscuc4uxbb7u@queper01-lin> <20180802165924.7ywgoxj2jwftxycz@queper01-lin> <20180803081850.hj7bp5ognuywapmd@queper01-lin> <20180803155547.sxlhxpmhwcoappit@queper01-lin> <68689fcb-3cb8-4685-58ef-0bec84be2047@arm.com> <1cac0d16-9f50-ed30-2460-340b077faa57@arm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: Content-Language: en-GB Sender: linux-kernel-owner@vger.kernel.org To: Vincent Guittot Cc: Quentin Perret , Peter Zijlstra , "Rafael J. Wysocki" , linux-kernel , "open list:THERMAL" , "gregkh@linuxfoundation.org" , Ingo Molnar , Morten Rasmussen , Chris Redpath , Patrick Bellasi , Valentin Schneider , Thara Gopinath , viresh kumar , Todd Kjos , Joel Fernandes , "Cc: Steve Muckle" , adharmap@quicinc.com, "Kannan, Saravana" , pkondeti@codeaurora.org List-Id: linux-pm@vger.kernel.org On 08/06/2018 02:37 PM, Vincent Guittot wrote: > On Mon, 6 Aug 2018 at 14:29, Dietmar Eggemann wrote: >> >> On 08/06/2018 12:33 PM, Vincent Guittot wrote: >>> On Mon, 6 Aug 2018 at 12:08, Dietmar Eggemann wrote: >>>> >>>> On 08/06/2018 10:40 AM, Vincent Guittot wrote: >>>>> On Fri, 3 Aug 2018 at 17:55, Quentin Perret wrote: >>>>>> >>>>>> On Friday 03 Aug 2018 at 15:49:24 (+0200), Vincent Guittot wrote: >>>>>>> On Fri, 3 Aug 2018 at 10:18, Quentin Perret wrote: >>>>>>>> >>>>>>>> On Friday 03 Aug 2018 at 09:48:47 (+0200), Vincent Guittot wrote: >>>>>>>>> On Thu, 2 Aug 2018 at 18:59, Quentin Perret wrote: >>>> >>>> [...] >>>> >>>>>> I think we're discussing two different things right now: >>>>>> 1. Should forkees go in find_energy_efficient_cpu() ? >>>>>> 2. Should forkees have 0 of initial util_avg when EAS is enabled ? >>>>> >>>>> It's the same topic: How EAS should consider a newly created task ? >>>>> >>>>> For now, we let the "performance" mode selects a CPU. This CPU will >>>>> most probably be worst CPU from a EAS pov because it's the idlest CPU >>>>> in the idlest group which is the opposite of what EAS tries to do >>>>> >>>>> The current behavior is : >>>>> For every new task, the cpu selection is done assuming it's a heavy >>>>> task with the max possible load_avg, and it looks for the idlest cpu. >>>>> This means that if the system is lightly loaded, scheduler will select >>>>> most probably a idle big core. >>>> >>>> AFAICS, task load doesn't seem to be used for find_idlest_cpu() ( >>>> find_idlest_group() and find_idlest_group_cpu()). So the forkee >>>> (SD_BALANCE_FORK) is placed independently of his task load. >>> >>> hmm ... so what is used if load or runnable load are not used ? >>> find_idlest_group() uses load and runnable load but skip spare >>> capacity in case of fork >> >> Yes, runnable load and load are used, but from the cpus, not from the task. > > yes that's right, I have skipped the "task" word when reading. > So scheduler looks for the idlest CPU taking into account only CPU > loads. Then the task load starts to highest value until it get a > chance to reduce and stabilize to its final value This could potentially allow us to find a better init value for sa->[runnable]_load_avg. At least we could use the information of the initial task rq. > >> >> [...]