Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755328AbcC1UFP (ORCPT ); Mon, 28 Mar 2016 16:05:15 -0400 Received: from mail-am1on0095.outbound.protection.outlook.com ([157.56.112.95]:25846 "EHLO emea01-am1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752879AbcC1UFK (ORCPT ); Mon, 28 Mar 2016 16:05:10 -0400 X-Greylist: delayed 26983 seconds by postgrey-1.27 at vger.kernel.org; Mon, 28 Mar 2016 16:05:09 EDT Authentication-Results: spf=pass (sender IP is 217.140.96.140) smtp.mailfrom=arm.com; redhat.com; dkim=none (message not signed) header.d=none;redhat.com; dmarc=bestguesspass action=none header.from=arm.com; Subject: Re: [PATCH 1/2] sched/fair: move cpufreq hook to update_cfs_rq_load_avg() To: Steve Muckle , Peter Zijlstra , Ingo Molnar References: <1458606068-7476-1-git-send-email-smuckle@linaro.org> <56F91D56.4020007@arm.com> <56F95D10.4070400@linaro.org> CC: , , "Rafael J. Wysocki" , Vincent Guittot , Morten Rasmussen , Juri Lelli , Patrick Bellasi , Michael Turquette From: Dietmar Eggemann Message-ID: <56F97856.4040804@arm.com> Date: Mon, 28 Mar 2016 20:30:46 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 MIME-Version: 1.0 In-Reply-To: <56F95D10.4070400@linaro.org> Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit X-EOPAttributedMessage: 0 X-Matching-Connectors: 131036634505620880;(7f4fb8e1-17aa-4746-8602-08d27e8c8cd0);() X-Forefront-Antispam-Report: CIP:217.140.96.140;IPV:NLI;CTRY:GB;EFV:NLI;SFV:NSPM;SFS:(10009020)(6009001)(2980300002)(438002)(24454002)(199003)(377454003)(189002)(4001350100001)(5001770100001)(23746002)(77096005)(92566002)(65956001)(65806001)(47776003)(64126003)(59896002)(50466002)(2950100001)(106466001)(230700001)(11100500001)(50986999)(54356999)(83506001)(86362001)(15650500001)(36756003)(6806005)(104016004)(586003)(87936001)(5008740100001)(1096002)(1220700001)(76176999)(33656002)(189998001)(2906002)(87266999);DIR:OUT;SFP:1101;SCL:1;SRVR:AM2PR07MB0930;H:nebula.arm.com;FPR:;SPF:Pass;MLV:sfv;A:1;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics: 1;DB3FFO11FD025;1:WLHRRIb1Z0rowFvkRMtwkV/mVdXxSkjWU/bIF58F/v4p5W4pGZGBwisy301hnOzRm7LzCLsK0RUrIvJP/42HwgiGpmAE7CwLd2uCLrP/qOUCsKJf82YjU275nvPQPoVFJL6kS2/bnh5nW9fOjI+3ziWAVDobfoNXFZzJEcRast5RRCzZAs9N6gNDBY4Fcm+2G08tkBWOU2opHfE1rm7pEHd9EocONCb9i7nGBt1GcJF2qvNB6C7SxNTgV6T7OsSZCe2wzmOBXZl4pEkgF0tulxdTgj3snKPScROGne91WFzeG4bhe2NtPfcQYmuGp1Hthpu720GXpTbO62RtZgRtXiCp1hCswDuGFuC99mu+SvvI+a/P+T5UiGFbLrdYkRe3tQq26BXDPhU+/wvmAOVys3uztsuQM/RANQ5bAqcwoB3+wDDZeM8c50aVZiJAvQac7LiW2Tt4oLQ0nwkjgvFCVbkW7vTq0YjcoCE85wHMQtB14UyxOnB9kavZO7nxHIbMYJKfgoVGaSqqKIXzLyM8Fth2fTV7LaBJeCkOE9UH+Tk= X-MS-Office365-Filtering-Correlation-Id: bea8ba54-f602-4f02-096d-08d3573716b5 X-Microsoft-Exchange-Diagnostics: 1;AM2PR07MB0930;2:b9vtzblSkY8I9qnLYycKgekdsUaFUxxSasLYKm89fYaNmtK0McIFBY/23+woKGa6/J0ItD7j/sG+OwmImLsnTOTYM1VvJem4yTK1NfFNfjoW6QY3UmzjPlpxcPpk1DpS/S5KIHjp0cZUiLafK3XIy/e5HypTuMNl7/ShmxVemOvjTRGg2vbhA32unlnnJroB;3:vMBop+Ai17T+mOS/Uy2B6wnLD+QzzqQRVA6iCAVRJNkWxqlcxc5qM/gd7Kn4CwH57Wk8lD7PiQ+YDR/j4u5HXZTUUWuay2vDhw8W45bgjklFxpsumaDHlRPPkBBvAJCpXEKy+y91PNqA2FH/XYSTpJH3uTp/e1J6hiDoN3GpBlgCmYhdhgs/xl/bWxhXvImfC8L1lhYP/p/1eK8tqZuYGDNC97ba4xkykJty4gELsZB76pfeLZrs3XxgGNjwPI8VMmuJbQWa2Midt8MVVHdtKg== X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(8251501002);SRVR:AM2PR07MB0930; X-Microsoft-Exchange-Diagnostics: 1;AM2PR07MB0930;25:uBd2Yik/vNRfufFl80uRdm5vDXkgQd4qB5EtCypzBJXiJZoQo2M1cTDxzJryEcQNTwOoBXJPagU0Ee88PgDHcZr7wFtGEzrXqn8//e3EfWW6eFvTMJdSOQRMHXGwsKsoD1I+V0SuW2L8Alnf3sbxbT+lS1K0NsmN8D2s5yoTg4647oTNZUjNoqMaG78ZddoFhA9u7x8jO2wYlg3L3qc5Br9BOWjE6tUBAIr5R0rDKpX6/Al5AG6uag7Yu+GeeG2wzINca/NREn3MToAAlNNe4bCR3YZtZeLDV9ZA/w3RRWeKfcwOU3QrluFOybzWYgukXVUi/Fk+8BRx0D4W1XHt947r7OJIdp4aEu9RMC+TLnTUk4YOMy5bSqEPhP+uEf7Ws9BxsxEyAle3yYWgHLfg65mFxzHGGhYKuZKGaP3sKv+GfTl1b85wnhjMOWqVRs6CTpaMTCuYlF/gRY7iIBwFa1osEx9qnjFlKOC0gmv5xmVxC7CD8QJJ05Oj3fyPXJgcT3dcWKUG7+Q3swg1wpYZM5/9mD1g6/PgAPcFJmveV59O/0unBEkBKdN9YN4/DKZmMTLXeVTAA/1Uzznw4G7EpA== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(601004)(2401047)(5005006)(13018025)(13023025)(13016025)(8121501046)(13024025)(10201501046)(3002001);SRVR:AM2PR07MB0930;BCL:0;PCL:0;RULEID:(400006);SRVR:AM2PR07MB0930; X-Microsoft-Exchange-Diagnostics: 1;AM2PR07MB0930;4:snPs0mqCSyl8WXmu5/8ROV9TpfncK3+XzjhA1KylCXurbbdYQcvHl12wN0q/DukKclzdV5IULQG+N0a1KwWW2rCslhOwvDTQBV/YMU+lCjwEviCYs0rD/pI1586GSQl5wBP7Elrlm0HBQVavHRIJ2gLqzFVRpbUioNiZ+HPT6wEg5LZNlb+JQMdvKskVJkHf1l8RTzbR5QidLwm64MFGK+JtyooauazaT08s5pq9mFgbQ/asWihcBIydwF0AzPQIcEihh9ILeSXsKJkUXojAxKVkwGQyiVRPSbPR11L48PZVZ427fkal7JDyD9RqWNgsIGuTapoDHHpQHw3GeWXTv8/vqqjXMlphY8305oNeb3vOHxwfnzeFMrIBi2PTCTwPdl+PXsgRENmfC41iOJ7pbXLMbx8KpM7Bf+53v4AJeRc1ii7o7QU6DNhnacbetYnq X-Forefront-PRVS: 0895DF8FFD X-Microsoft-Exchange-Diagnostics: =?Windows-1252?Q?1;AM2PR07MB0930;23:we4S8eh+1NLtZZhZBYcLhqxTgbGLfDH2+nxo5?= =?Windows-1252?Q?EwaKlVFgtBeHNYuQoCeLyhC5e4EF+x4AKeqqEFsjY8UQIUMFLYDWElnJ?= =?Windows-1252?Q?EhMcz0TJYuTUrblpHC84Yves9/wjieTlCsUSah3h95HQN0GmYZTW3EuE?= =?Windows-1252?Q?CvmHmXih4xNeaGlb1cG3JeJl+VNdp4laJStSws6SGN3/6W+Ts/WjWNmS?= =?Windows-1252?Q?gaADCyC85YjO+5sph94vVo6ySkgpHBWym0SWWGW1PAHziF7afjXm2+tm?= =?Windows-1252?Q?0hpSZCMORkl9l8P/E38jihy6tkX902zYmzKoesPEIvfkPD1Ma4n/eRfO?= =?Windows-1252?Q?3HxpKNKqQkgiaWRX52LaCIKV0DGWs6rVeiKRJJZY8Pd1pq/BFI6ghgps?= =?Windows-1252?Q?ngl6hfiatdCyd/kKGPDeMQkW2U9RrwW/0JV6EyP3Lvg+2bJ0N+EWD1R9?= =?Windows-1252?Q?xK0psNUvaTyxBMTlXJm6fyIAFoUmnZxsATSHdG2n1Fk5BFOeCyqn9Pdx?= =?Windows-1252?Q?O8Hgo+keibHvpBGX6lwAaTAuWvMj07F0iDBvJ76YXMWV6pRg1NdH2Twq?= =?Windows-1252?Q?nKI1vo6yItGycR/4KbvKrf5igpd1FNRkzrvqHc06hZfedQOrRZqEdkfb?= =?Windows-1252?Q?F+yc1AdHSkmL3GkTYofsax+XjD+dmvhpRlkA05WFWmWNQEmGsRE1pY0z?= =?Windows-1252?Q?VWXc3qE6URiercWxc4jarplGz0dz1WhowK5/I6FV/8sME0hrW/+gqcDo?= =?Windows-1252?Q?4VXGG4PibAjor0wudYTPHzDingyMVXJzck/pIN7Um4egwYJcIyOcmaNG?= =?Windows-1252?Q?Uhij2ZKhgKKxep8GlVmqHzd8fFBNzVOHkFVxaGK/PGnYiC91BWea8w75?= =?Windows-1252?Q?kBXMDAnV5cLgmH3N+O9i2dF1TLVAKcVr73cKRIiqK/7O59T79NHF9M4e?= =?Windows-1252?Q?nSWfjNgo1MENoF32t1F7Dz12VjPW4tT0JKfWzlryIyxdTRjs9x2IegX2?= =?Windows-1252?Q?qIolkpUCVdcdqUhYmz7tPhnZhAxVUkjkvR/tvevUqrKNmfrD7XpjoGjQ?= =?Windows-1252?Q?JsN3FG9GzCWH6gKi6RemPgnij6RfHLP/g6HZ0NjOinogHhY/eiA6QWXB?= =?Windows-1252?Q?n1DSoROeJpWIRGfGgNQUCw=3D?= X-Microsoft-Exchange-Diagnostics: 1;AM2PR07MB0930;5:ngHzioXR5P/qsB60rcyc08uCzCsCEjQXYSFioFAI5JZlEVgsjFI8ZAsjVGmn/hLdvKv7NCmBGr+Ky8Z/+RXMgH9fz6ziWpmRa+6Zpjiax5Pl9cShA8eK3KoWjJGK9UwjEeH0Udu3GNDsZSIfNX3NFZL4oWgrf/LO1JZ25XjPm6o=;24:WDX/Gy4y2Des4pMgrHMFPLyZX/e26aTEYT+MWooNRM+tSObJHo5PEvgg8j3DLUYeFU/dnQjnZMGOxVSWBOazMDgboJWpsiQutGPLGOSIWuQ= SpamDiagnosticOutput: 1:23 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 28 Mar 2016 18:30:50.2812 (UTC) X-MS-Exchange-CrossTenant-Id: 5afe0b00-7697-4969-b663-5eab37d5f47e X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5afe0b00-7697-4969-b663-5eab37d5f47e;Ip=[217.140.96.140];Helo=[nebula.arm.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM2PR07MB0930 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1666 Lines: 42 On 03/28/2016 06:34 PM, Steve Muckle wrote: > Hi Dietmar, > > On 03/28/2016 05:02 AM, Dietmar Eggemann wrote: >> Hi Steve, >> >> these patches fall into the bucket of 'optimization of updating the >> value only if the root cfs_rq util has changed' as discussed in '[PATCH >> 5/8] sched/cpufreq: pass sched class into cpufreq_update_util' of Mike >> T's current series '[PATCH 0/8] schedutil enhancements', right? > > I would say just the second patch is an optimization. The first and > third patches cover additional paths in CFS where the hook should be > called but currently is not, which I think is a correctness issue. Not disagreeing here but I don't know if this level of accuracy is really needed. I mean we currently miss updates in enqueue_task_fair()->enqueue_entity()->enqueue_entity_load_avg() and idle_balance()/rebalance_domains()->update_blocked_averages() but there are plenty of call sides of update_load_avg(se, ...) with '&rq_of(cfs_rq_of(se))->cfs == cfs_rq_of(se)'. The question for me is does schedutil work better with this new, more accurate signal? IMO, not receiving a bunch of consecutive cpufreq_update_util's w/ the same 'util' value is probably a good thing, unless we see the interaction with RT/DL class as mentioned by Sai. Here an agreement on the design for the 'capacity vote aggregation from CFS/RT/DL' would help to clarify. >> I wonder if it makes sense to apply them before a proper 'capacity vote >> aggregation from CFS/RT/DL' has been agreed upon? > > Getting the right call sites for the hook in CFS should be orthogonal to > the sched class vote aggregation IMO. Hopefully :-) [...] Cheers, -- Dietmar