Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1254024imu; Wed, 28 Nov 2018 06:57:48 -0800 (PST) X-Google-Smtp-Source: AFSGD/Wn8k+GpjQiisn9YYneC8OrVoD/VFCpFMK09rj2FP20YpAhY95zbZI2x2Dp+b4lOHkD+YDI X-Received: by 2002:a17:902:47aa:: with SMTP id r39mr14775113pld.219.1543417068742; Wed, 28 Nov 2018 06:57:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543417068; cv=none; d=google.com; s=arc-20160816; b=XBS9pLJ3y1ageicZrKrTcccL/o2tSb7A7h9c4w6DugFFsWHA67JMlDJlc9t33juPPD DpWLNv7rZ8svZ6uCCGnN550Jx8POqguH32vM7ZwvkTCNUIP4pMy4tubprPQBRcDuPC1C uTTAC9Vwk195PWCAkaYMloLDdNj/Z6ySQZVgujtlkXPiYVOFbfqVPIbohm/ESPO0FCh6 o1tuidQNO7sz8k2O1w+yFcgwJEg5/1XXsbIHG53lGr6yipp2vewkis0qZUe8wI6UiU15 +zhHmn8hZ/SszFCc2Af+wUydGgdgiHQQ1/oVq9omv0bEXhqmwTu7kyQtHFqeUO6lFbv8 Nnng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=BqYwKSq8Ktp6JoUf6WD4NLTREQDC4vb89JEXNRtGWmo=; b=cDIUUEvO8kBFx9a6NUDhfHluW3d+DAC7lU0pZtZ3VeCEnDtA/z3xCDrZugEfwOS2Ic D1GNfEJmqki7jIgiDny98w7WGHlL5QKOygRmbwJGcKCFBfF5llitN7SvCe+tBqYz+lyb fgJevQ8McjKIdmDChpP1WmWdkbwLfy+RDtZF4hAYWtOZDkmYiQqxZT4jvSuvjlSM+gA7 dz5nkoXUiJ6IbNYTCy9LlV1m+ajSduRzFnftftlcY0e3rExwii9/Rwm/p1ivBdI5BMqV 1Nn6kIii3rwC0Fust/CXvLggLtok4t04U/vreRPl03WJpr0zT99LV65Bd6hKJ25fg18r 47tQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZCjqlyZQ; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b4-v6si8126714pla.189.2018.11.28.06.57.31; Wed, 28 Nov 2018 06:57:48 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b=ZCjqlyZQ; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728664AbeK2B5N (ORCPT + 99 others); Wed, 28 Nov 2018 20:57:13 -0500 Received: from mail-io1-f68.google.com ([209.85.166.68]:46418 "EHLO mail-io1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727789AbeK2B5N (ORCPT ); Wed, 28 Nov 2018 20:57:13 -0500 Received: by mail-io1-f68.google.com with SMTP id v10so14539906ios.13 for ; Wed, 28 Nov 2018 06:55:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=BqYwKSq8Ktp6JoUf6WD4NLTREQDC4vb89JEXNRtGWmo=; b=ZCjqlyZQGHzvFP1gQWdttkJYSoRy7kUxnor2ZvaxS5Il26X+tq28oDz2Ckn58g/MEb HU2ROJ0sInT3CQPB4TFAzdUvLw+ZUjdKHIH2s+83J26SigVaHW/TLeaQfMj4CCq0MfEN G4BAbwcAwFKcO10fqSQlbg3NjkAwzCBbrTDjY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=BqYwKSq8Ktp6JoUf6WD4NLTREQDC4vb89JEXNRtGWmo=; b=pWTEiALnB9oYqFhuVgIo3zh3Q4CGnQEjwEPd0V5qTIgYvYLXNqyrgTFo0emMRLk2Vm 3u5OaqG6LOOeOIGE+ufBu8wkZnJEMSxnl/5s3JI3Z3tWaE8M4L5ryjsEB/xCEX/hNxQS pgODepoWfKa+h9QAKErs4aBBsQGgqj0AhEgGjF47+JYaUywEVpsao3Okcbmsy66a70+z 2HpAmrza14IFMuGRy7k7g1yU0TfurWZGnLaYgu8lnhs01oWDxREhabVBe+wf/TvlbdmJ j/QupEdjsKNMWrMw1BszNZVv4e8tDYIKvPS/oL756IUG6NhHh5nsP+NHdIWmjsNKpVcx 1jmA== X-Gm-Message-State: AA+aEWY2umbzcNOayBrgweqs4tgv23jKWDccJ2ajM4roHc3SgYKDZCWl fVNB/dIvKGh6+iwhlYXK5Zeqbdxyvx66W4MSO0OyMw== X-Received: by 2002:a6b:fe13:: with SMTP id x19mr27534227ioh.294.1543416916554; Wed, 28 Nov 2018 06:55:16 -0800 (PST) MIME-Version: 1.0 References: <1542711308-25256-1-git-send-email-vincent.guittot@linaro.org> <1542711308-25256-3-git-send-email-vincent.guittot@linaro.org> <20181128100241.GA2131@hirez.programming.kicks-ass.net> <20181128115336.GB23094@e110439-lin> <20181128144039.GC23094@e110439-lin> In-Reply-To: <20181128144039.GC23094@e110439-lin> From: Vincent Guittot Date: Wed, 28 Nov 2018 15:55:05 +0100 Message-ID: Subject: Re: [PATCH v7 2/2] sched/fair: update scale invariance of PELT To: Patrick Bellasi Cc: Peter Zijlstra , Ingo Molnar , linux-kernel , "Rafael J. Wysocki" , Dietmar Eggemann , Morten Rasmussen , Paul Turner , Ben Segall , Thara Gopinath , pkondeti@codeaurora.org, Quentin Perret , Srinivas Pandruvada Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 28 Nov 2018 at 15:40, Patrick Bellasi wrote: > > On 28-Nov 14:33, Vincent Guittot wrote: > > On Wed, 28 Nov 2018 at 12:53, Patrick Bellasi wrote: > > > > > > On 28-Nov 11:02, Peter Zijlstra wrote: > > > > On Wed, Nov 28, 2018 at 10:54:13AM +0100, Vincent Guittot wrote: > > > > > > > > > Is there anything else that I should do for these patches ? > > > > > > > > IIRC, Morten mention they break util_est; Patrick was going to explain. > > > > > > I guess the problem is that, once we cross the current capacity, > > > strictly speaking util_avg does not represent anymore a utilization. > > > > > > With the new signal this could happen and we end up storing estimated > > > utilization samples which will overestimate the task requirements. > > > > > > We will have a spike in estimated utilization at next wakeup, since we > > > use MAX(util_avg@dequeue_time, ewma). Potentially we also inflate the EWMA in > > > case we collect multiple samples above the current capacity. > > > > TBH I don't see how it's different from current implementation with a > > task that was scheduled on big core and now wakes up on little core. > > The util_est is overestimated as well. > > While running below the capacity of a CPU, either big or LITTLE, we > can still measure the actual used bandwidth as long as we have idle > time. If the task is then moved into a lower capacity core, I think > it's still safe to assume that, likely, it would need more capacity. > > Why do you say it's the same ? In the example of a task that runs 39ms in period of 80ms that we used during previous version, the utilization on the big core will reach 709 so will util_est too When the task migrates on little core (512), util_est is higher than current cpu capacity > > With your new signal instead, once we cross the current capacity, > utilization is just not anymore utilization. Thus, IMHO it make sense > avoid to accumulate a sample for what we call "estimated utilization". > > I would also say that, with the current implementation which caps > utilization to the current capacity, we get better estimation in > general. At least we can say with absolute precision: > > "the task needs _at least_ that amount of capacity". > > Potentially we can also flag the task as being under-provisioned, in > case there was not idle time, and _let a policy_ decide what to do > with it and the granted information we have. > > While, with your new signal, once we are over the current capacity, > the "utilization" is just a sort of "random" number at best useful to > drive some conclusions about how long the task has been delayed. > > IOW, I fear that we are embedding a policy within a signal which is > currently representing something very well defined: how much cpu > bandwidth a task used. While, latency/under-provisioning policies > perhaps should be better placed somewhere else. > > Perhaps I've missed it in some of the previous discussions: > have we have considered/discussed this signal-vs-policy aspect ? > > -- > #include > > Patrick Bellasi