Received: by 10.192.165.156 with SMTP id m28csp2331052imm; Thu, 12 Apr 2018 12:26:28 -0700 (PDT) X-Google-Smtp-Source: AIpwx4/ddLNuvedphE5dV08uj5dNjmXEAARtW6tDkSCyffJC+ff+NdKgGVtMHEvRi3QFv+zwpYDO X-Received: by 10.98.234.13 with SMTP id t13mr8782379pfh.56.1523561188118; Thu, 12 Apr 2018 12:26:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1523561188; cv=none; d=google.com; s=arc-20160816; b=wEs5aG9PP62crDMxGuOiPKsnSKd13IA5eQqLAovsosY7Lb5wYye9VC2GgLnBuxClOA dxx/hoPvtaf+QfG6b3BBuajlAed+LUopvE75zDvxwI7PhJCK1Xxj/EBiz/EjQXtIk4Uj BTjSUlyfz7JNOxDVL9JbVfTDbwVnszg3ltogsv9W+jRCY5MR0Xkx4w7LC0/ZNUi2I4zP 4WEFEHWhmyfOp44f52FTfkevQUfXD+QXzxPGqjElo9Es1FkXoH8EJ7Pe887VQyXWI4qR xHZ9M5TC72vT8+e9KFx4aBo5aXchXT+bqxBfNljK61VOf1YpAmvhPrATx64v1wnxowg2 C2og== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=SqtPu57Ed2MBcx+aJ581nTJK64gNNPOHS+2wVNDRAIk=; b=wSrGHUCMVAF0TiY+vZtUwKo6GprXK0qT4g5H7NtoSI5x6l22W8ikycElm8PXyB7iRK 1Oln00DEwBjHO/n25Tjy6is2KHFmFgEhxIaI23BE4YiH1Cgf9n3JPgExgq0ZmjtOxSQ8 MdpGGEKPW81NJ+Rwq+D4NGLin6hfnBTRErtAUDOZBlUyLZtiWxdDT4us6kwek0rMNSfa /QNILd6k7jsMvwPbVhsQt7CAUU5V19WyV2Lt06Fw/GOyULiXGpRJLdL0vjV1x0oZJH08 piQvvA4/Ckk964ZM4mD5C4Llhrr9hwvnugxvZQk7vjAdhtl58SIV5TAEQitthugUbS0G Sy7A== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=merlin.20170209 header.b=vinbE4Qh; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d1-v6si69017plr.410.2018.04.12.12.26.14; Thu, 12 Apr 2018 12:26:28 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=merlin.20170209 header.b=vinbE4Qh; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753519AbeDLTNH (ORCPT + 99 others); Thu, 12 Apr 2018 15:13:07 -0400 Received: from merlin.infradead.org ([205.233.59.134]:32768 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753063AbeDLTNF (ORCPT ); Thu, 12 Apr 2018 15:13:05 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=SqtPu57Ed2MBcx+aJ581nTJK64gNNPOHS+2wVNDRAIk=; b=vinbE4QhVyPXlt/JUbqu7cxly HLIfgjv7TG1FfKCbdlIwjrKA/EBUlNJHhdWVzJZ2PVeuzTOpriHfPDVWoy0pqdIVxuyIxjw3hh0JA ck8eetTduO85FFybIJ0tIbEz4z8FC/lHZb4DW6/LXhjvxDh7VAIJxDOBXcDrsPLgbPM42Wp3ffmW5 3HNyP/6doVS2Rsv17Ke8yS8gJKFDpFlbiSDoWMpoQFD5tygFs8zfepz48U5LHa5b7HHhBmQReH+jT gllQPDX4ko+X1hTm2dWxn0JJX3rCXY57G5v3bzcSbLsCNbbvHc3FTNWygK48p0GNHnpuOiqEIL69F l5Q/dUTLQ==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=worktop) by merlin.infradead.org with esmtpsa (Exim 4.90_1 #2 (Red Hat Linux)) id 1f6heL-0005l9-Cj; Thu, 12 Apr 2018 19:12:49 +0000 Received: by worktop (Postfix, from userid 1000) id 0A6E06E079F; Thu, 12 Apr 2018 21:13:19 +0200 (CEST) Date: Thu, 12 Apr 2018 21:13:18 +0200 From: Peter Zijlstra To: Patrick Bellasi Cc: linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, Ingo Molnar , "Rafael J . Wysocki" , Viresh Kumar , Vincent Guittot , Juri Lelli , Joel Fernandes , Steve Muckle , Dietmar Eggemann , Morten Rasmussen , Jonathan Corbet , Paul Turner , linux-doc@vger.kernel.org Subject: Re: [PATCH] sched/fair: add support to tune PELT ramp/decay timings Message-ID: <20180412191318.GA7129@worktop.programming.kicks-ass.net> References: <20180409165134.707-1-patrick.bellasi@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180409165134.707-1-patrick.bellasi@arm.com> User-Agent: Mutt/1.5.22.1 (2013-10-16) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Apr 09, 2018 at 05:51:34PM +0100, Patrick Bellasi wrote: > The PELT half-life is the time [ms] required by the PELT signal to build > up a 50% load/utilization, starting from zero. This time is currently > hardcoded to be 32ms, a value which seems to make sense for most of the > workloads. > > However, 32ms has been verified to be too long for certain classes of > workloads. For example, in the mobile space many tasks affecting the > user-experience run with a 16ms or 8ms cadence, since they need to match > the common 60Hz or 120Hz refresh rate of the graphics pipeline. > This contributed so fare to the idea that "PELT is too slow" to properly > track the utilization of interactive mobile workloads, especially > compared to alternative load tracking solutions which provides a > better representation of tasks demand in the range of 10-20ms. Initially the 32 was chosen to more or less correspond to the effective scheduling period (sysctl_sched_latency based). The thinking was that if you pick a PELT window shorter than the period, the result becomes unstable due to not all tasks getting an equal go at things. (of course, stuffing enough tasks on a rq will break this, but at that point you have worse problems to deal with) Should we retain this? Esp. with the lower end (8ms) I worry we'll see more of those effects. > Fortunately, since the integration of the utilization estimation > support in mainline kernel: > > commit 7f65ea42eb00 ("sched/fair: Add util_est on top of PELT") > > a fast decay time is no longer an issue for tasks utilization estimation. > Although estimated utilization does not slow down the decay of blocked > utilization on idle CPUs, for mobile workloads this seems not to be a > major concern compared to the benefits in interactivity responsiveness. By picking a smaller PELT window, the util_est window shrinks correspondingly; is that intentional or do we want to modify UTIL_EST_WEIGHT_SHIFT to negate the PELT window changes?