Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp519804imu; Tue, 20 Nov 2018 02:57:39 -0800 (PST) X-Google-Smtp-Source: AFSGD/UnHYGVsZfq5sBXzLRJ/4HxANWDYVq+gMWnsrTMZ0rOFnVram5SvXhSf9RWPDyFp1b4w1LA X-Received: by 2002:a17:902:bc4c:: with SMTP id t12mr1657526plz.45.1542711458972; Tue, 20 Nov 2018 02:57:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542711458; cv=none; d=google.com; s=arc-20160816; b=OSu9DX4Xj4LVjRH2peihWzizbcf3SMHtapXgWyTBqoXsoyrFZlAHGr/muuz/eJozU+ 3eEQQE0qJ3NK8lKmgxoLVVh9UuItIvn85hEDRvqJesiSs132+nEDo8mYveIK15OLAQ9p +8SFlQnXvFO98LZsvzt7GQiQcWntDjFvq0qi0o8y5773ZkEaVfHnRtDo1lP2+PA6C05M izmxmihjboz2aLCyoDP6EeBu6oasiq+BVNbwELO4FbWXrQGh6kZZYNC3m5oVClkGyDCO DRo1FvjDxKDtNVkZZWO86DItiydeTLAE3l+eNUlL4Sh2KiEmuM7ttvMwF1NzsbaWXbhx yrWw== 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=Awk9OeOCPWoy9xhc10bEldU/6swpjap+mlgEmdjB+l8=; b=W/bu3hZZ1r0ZkGvPQ09UN7bC73KXRUi1SfJNDIYRX5XEvws49g3nZ9KPrO/ge9puWu nxsgPstAL6Z3X9h2OPmVM0eKP4/tHC6XOcwU0SrpIGC/7aGdtJLevk4i47JdIPVACg8l hw7x3AR5yo/SI7qm0vW9lYOuP02anXdMfGPQoMbHG1GuilutuvJr9EmlJMriy+gBMNbo 5D+5RICqc4Ss7N3D4t2504LEyKKhAUfI5vQ1w6wHlGadX/pgqEZ2IddGv92HfwCHHMqZ BJ7u5C/msAGOxNaKt/+LafMT3Z1P27F6BPFKpI0XEJtaQvjhGgju9peAv3iq3J7l1dHK ubyA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=SP9PgvIs; 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 a185si39749509pge.404.2018.11.20.02.57.24; Tue, 20 Nov 2018 02:57:38 -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=SP9PgvIs; 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 S1728778AbeKTVXv (ORCPT + 99 others); Tue, 20 Nov 2018 16:23:51 -0500 Received: from mail-wm1-f67.google.com ([209.85.128.67]:36180 "EHLO mail-wm1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727791AbeKTVXv (ORCPT ); Tue, 20 Nov 2018 16:23:51 -0500 Received: by mail-wm1-f67.google.com with SMTP id s11so1727108wmh.1 for ; Tue, 20 Nov 2018 02:55:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=Awk9OeOCPWoy9xhc10bEldU/6swpjap+mlgEmdjB+l8=; b=SP9PgvIsJ69Mfqp4OLZLecWO8R84PkDHghLJuMRFX2Hkvwvu9Ya7jIOXqcvUOmzXHJ ASBRQOAkYXIOX2B3UaQdceRCK7hBqGDw/kAvmaY4Ii1K2rCtrx3deJbaT9yFdy9PLgDc vpOh5EJYquo8+nYab5Mw7IdrWmlcI8SHyTSJw= 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=Awk9OeOCPWoy9xhc10bEldU/6swpjap+mlgEmdjB+l8=; b=jOI+HjpSjBjsC0kDdKyWHI18Na29Q/u+/F7KraIpdM3+tv5uDcJ7glu0NDgspmYqGa 4BElVl8WHzv1w3fDudvzPQqsQu9Fm6vto0cR+yPYC0r9pPIRkxzxQkLGSIJ+GIOWdZuG A/HLwoaPr0wt5gATKbgd8btfmDEaHfLBJ4blU365WK5g++ocMw0ROQyiHRkKOwolZ9Dw 3phcJeoefu91B0m9795irVdN9aeCXGDyuWaEYt7zvNcwxMEFFcVuzd539lcTEfRgnZiL VeZLDguB6w05xRQvKhTTXTSZUfqLKQMrPfSo2vXm0Ly5dMJetFkkL1SMwywd/nc7/aVI GiRg== X-Gm-Message-State: AGRZ1gLp9xuwoohmoZ91H4iE8Xj9xe4OUN2+flwYM8yH6BYOfmbEd32V +a3YmaD5Q/jZ+LPuxs8CrIJmrg== X-Received: by 2002:a1c:930d:: with SMTP id v13-v6mr1769676wmd.26.1542711317617; Tue, 20 Nov 2018 02:55:17 -0800 (PST) Received: from localhost.localdomain ([2a01:e0a:f:6020:c511:7193:974b:48e6]) by smtp.gmail.com with ESMTPSA id f192sm12170831wmd.12.2018.11.20.02.55.16 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 20 Nov 2018 02:55:16 -0800 (PST) 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, quentin.perret@arm.com, srinivas.pandruvada@linux.intel.com, Vincent Guittot Subject: [PATCH v7 0/2] sched/fair: update scale invariance of PELT Date: Tue, 20 Nov 2018 11:55:06 +0100 Message-Id: <1542711308-25256-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 ensures 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 v5: - Fix niptick raised by Dietmar - Upodated some comments - Remove some unused variables - No functional change Vincent Guittot (2): sched/fair: move rq_of helper function sched/fair: update scale invariance of PELT include/linux/sched.h | 23 +++------- kernel/sched/core.c | 1 + kernel/sched/deadline.c | 6 +-- kernel/sched/fair.c | 58 +++++++++++-------------- kernel/sched/pelt.c | 45 +++++++++++--------- kernel/sched/pelt.h | 111 ++++++++++++++++++++++++++++++++++++++++++++++-- kernel/sched/rt.c | 6 +-- kernel/sched/sched.h | 21 ++++++++- 8 files changed, 190 insertions(+), 81 deletions(-) -- 2.7.4