From patchwork Fri Oct 26 16:11:41 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vincent Guittot X-Patchwork-Id: 149598 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp959327ljp; Fri, 26 Oct 2018 09:11:52 -0700 (PDT) X-Google-Smtp-Source: AJdET5exgg2Opu9kw+tIKti7oocJnHX4EowK3YE5TAX2JIOamlJIuTZnqPIDwPNTqT37P7xeQKPf X-Received: by 2002:a63:ac02:: with SMTP id v2-v6mr4059391pge.414.1540570312436; Fri, 26 Oct 2018 09:11:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1540570312; cv=none; d=google.com; s=arc-20160816; b=nYeTYIJg4eUMXl5EGM+MbVwYle2Lmgvff25H8aAeLSWERvdVJtfNai7UY1qA6Qete6 KmKHKrWtIZQOFFUgiHFixt8m1qq4FClWTS7idjWT4LDhxpinG1mscLmP2aplL5RJwyD/ Zm2/uqNzB7U3B5oOoRb6mE4WnWZyqvzUKlE0tfLhGehHHSh+114VNnhX2CqRTrs08P6x NSgzP8DL5Iry5qohZLWYOBzJq48r74JehDJ6lmRNzgSO09vMYhLu3lztJszmLaji2nMX lS3CUe5yrZ35MZ7CzfM/8FQWkaNrBtKJsSg7n+TQ0+j/aTig/lQhPx6X+FA0xUIOfaR+ P1lQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature; bh=xZLGzItrNY60hRMRPsxMSW2P9j1uarxjBp9l3h8QUOc=; b=CJeQX5thhr1pWU1chGiX0C5FwIfo45TEqdB+ddQgF5KcjiWEiSwoaGLoc+3KHVlE+X xoXNxeK7PNec5vuZCmSAXNs/aVbya4UaOBnKavFpJmbfUpGleTC4oXnWA04Mov+gN61C DBAURZCu/LTdNTred4/56yfxW/Pg3pN1cmWR00KKQqlydsJrmBDNhAPFfA6T8wIyyMDb KzwyL4OAV4i7PsL4e0C1AHDrKC4zEM1hMw4S0pxnRgQsBmLunK+0ia5EBn6rh1l/tfHx EbG+sYvoGdoeNjM8LB0W8exHitWnqoui7acs2YHLJlOulXItPYYIeHxjw54oKHUlYSuX PNvw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="a/X9RT3J"; 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 s22-v6si16029337pfs.13.2018.10.26.09.11.51; Fri, 26 Oct 2018 09:11:52 -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=pass header.i=@linaro.org header.s=google header.b="a/X9RT3J"; 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 S1727615AbeJ0At1 (ORCPT + 32 others); Fri, 26 Oct 2018 20:49:27 -0400 Received: from mail-wr1-f66.google.com ([209.85.221.66]:45298 "EHLO mail-wr1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727491AbeJ0At0 (ORCPT ); Fri, 26 Oct 2018 20:49:26 -0400 Received: by mail-wr1-f66.google.com with SMTP id n5-v6so1892488wrw.12 for ; Fri, 26 Oct 2018 09:11:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=xZLGzItrNY60hRMRPsxMSW2P9j1uarxjBp9l3h8QUOc=; b=a/X9RT3J1PQGNgGNpx3ULDGjLpR9uvVqsMWOxIGl286KTq68eN+CExiIvIwsJnT7D8 ZnWMJpbEuA6k220KyKoztV2+Vd3eHPlzay353xPmUng1LIx/uD/WewLJTwB0Ze6VKN6C YgumiXhEtzNIJAi02akhFhD9E/GnWjwnwdcMU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=xZLGzItrNY60hRMRPsxMSW2P9j1uarxjBp9l3h8QUOc=; b=Hip7fzMWN3ltLkIOOaUW9UWVhZEbuo6g0rGQc8I24cWQg7tIp7p0I/zCGjzqiwT+ze JHb2277OnE8i7lznzhJvvn8hCqtasYYdoKuLiE+xeHceNLJ4U5/tmjig86MaotWj+LMK YCLBET+oSP08WGr8zbo/GXEAvJ0GRPeMT46ZIj0vSarovoaR9Wlil+ktxd2JBC8uyzM2 8tDwCy9pGmWRn1reFwWl/0vttKWp0MiO0x8+Ybre0j3gOA5SlZedyBEdSqlDQLQFlioZ TXl7lxz6AcyDRzVCM5dfAn9+PHHUjY4t+jHdkSv7Kr9b/GmFTQnSIzjkhU8MLQluGiz1 o/hw== X-Gm-Message-State: AGRZ1gLzNEt+yjZ2gFv2PoC6aNc/ceTjwzAIKS94onWmqL4lZJbdE9Rx Y6PwFEWyW2wxZRYT+ZGTIGWoDg== X-Received: by 2002:adf:c650:: with SMTP id u16-v6mr6790713wrg.177.1540570307221; Fri, 26 Oct 2018 09:11:47 -0700 (PDT) Received: from localhost.localdomain ([2a01:e0a:f:6020:d30:71a0:24b4:1c25]) by smtp.gmail.com with ESMTPSA id y16-v6sm11807209wru.18.2018.10.26.09.11.46 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 26 Oct 2018 09:11:46 -0700 (PDT) From: Vincent Guittot To: peterz@infradead.org, mingo@kernel.org, linux-kernel@vger.kernel.org Cc: rjw@rjwysocki.net, dietmar.eggemann@arm.com, Morten.Rasmussen@arm.com, patrick.bellasi@arm.com, pjt@google.com, bsegall@google.com, thara.gopinath@linaro.org, pkondeti@codeaurora.org, Vincent Guittot Subject: [PATCH v5 0/2] sched/fair: update scale invariance of PELT Date: Fri, 26 Oct 2018 18:11:41 +0200 Message-Id: <1540570303-6097-1-git-send-email-vincent.guittot@linaro.org> X-Mailer: git-send-email 2.7.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This new version of the scale invariance patchset adds an important change compare to v3 and before. It still scales the time to reflect the amount of work that has been done during the elapsed running time but this is now done at rq level instead of per entity and rt/dl/cfs_rq. The main advantage is that it is done once per clock update and we don't need to maintain per sched_avg's stolen_idle_time anymore. This also ensure that all pelt signals will be always synced for a rq. The 1st patch makes available rq_of() helper function for pelt.c file and the 2nd patch implements the new scaling algorithm Changes since v4: - Fix compile issue for !SMP raised by kbuild test robot - Fix lost_idle_time update raised by Pavan Vincent Guittot (2): sched/fair: move rq_of helper function sched/fair: update scale invariance of PELT kernel/sched/core.c | 1 + kernel/sched/deadline.c | 6 +-- kernel/sched/fair.c | 38 +++++++---------- kernel/sched/pelt.c | 23 +++++----- kernel/sched/pelt.h | 109 ++++++++++++++++++++++++++++++++++++++++++++++++ kernel/sched/rt.c | 6 +-- kernel/sched/sched.h | 21 +++++++++- 7 files changed, 164 insertions(+), 40 deletions(-) -- 2.7.4