Received: by 2002:a25:f815:0:0:0:0:0 with SMTP id u21csp3658668ybd; Fri, 28 Jun 2019 12:36:50 -0700 (PDT) X-Google-Smtp-Source: APXvYqz9aFZL6SmqqOJPG1D/5pRcvpvdu5o+5EcXwgi8676PncIqVAdKHe71iTyM1qJXYDdHcDo5 X-Received: by 2002:a17:90a:db42:: with SMTP id u2mr15300638pjx.48.1561750610818; Fri, 28 Jun 2019 12:36:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1561750610; cv=none; d=google.com; s=arc-20160816; b=D2aM8JRbs/zmHHXzDH3wNPOpPutL3cpc7xPcyHAdCw7E0jFy0E2uDoFDUbBqYbCUQJ Dy25QwOD4NMnWFcfzOih+iZqcLrCyYgzDHmE79dwnxKJ+kE40klm3rvwyqjE8DWCRnkJ xmYnXL20IZfnKcTfnRZQGsH1WvR9i9RL8LtHH7/bO2RL+OCXLayjThqRcr1rIahHwq3W tmiA0CTfjZQfxCYfn1NseQp4UmQ8fsAg36vEdXc7dQcmrZAlzgn9cCfkuEMCV3RLBA1B pujO8H6jSRXoo0nbjmg5y4CglOi7GFFm3a0DBHtXyfZKFupd6Aty7wTQKTza1fr5yvUx SfXA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:date:cc:to:from:subject:message-id; bh=vRi5Zgx8ZXE5ypt3TsUl+QYxGNsY7SJLUVpC4SEHxKY=; b=QhyVTPVTCxSgViIjCoN4ZVfSUFTAdnONTwAG3lF/grPLR4GFzFqVHFkGyvmkgrweZ9 waVkFU+sEkf88BEwcTR8hnTlVRDkCC0jg3OucgHHghaKrJIRgYnCXlCjJ0CtwFCdIFTD pcLn/6J1+yQEcOc+CJUVs2GN/miVyhPQL/ySKfM1a0gCVBdfmaF7qQmrd3hCx/CSjVUG aZKpzv7P/00T8hZbDVSMwOjUce9qEYV0FVT+Tw2pGAyVAYa28Fq/xecag13MCO5oSch5 PUmUT3id+eNA8bQD4F8tBoN4DFjQuFb/7cXAZHiJoNcvzi1clfC+mHu8Tsax0PFaEXmF TDHQ== ARC-Authentication-Results: i=1; mx.google.com; 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 i11si2989771plb.20.2019.06.28.12.36.34; Fri, 28 Jun 2019 12:36:50 -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; 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 S1726996AbfF1TgZ (ORCPT + 99 others); Fri, 28 Jun 2019 15:36:25 -0400 Received: from shelob.surriel.com ([96.67.55.147]:38268 "EHLO shelob.surriel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726695AbfF1TgZ (ORCPT ); Fri, 28 Jun 2019 15:36:25 -0400 Received: from imladris.surriel.com ([96.67.55.152]) by shelob.surriel.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.92) (envelope-from ) id 1hgwfQ-0008Qs-D3; Fri, 28 Jun 2019 15:36:16 -0400 Message-ID: <27e1ce40c50a1b575527531bfc8dd562843b8ad5.camel@surriel.com> Subject: Re: [PATCH 8/8] sched,fair: flatten hierarchical runqueues From: Rik van Riel To: Dietmar Eggemann , peterz@infradead.org Cc: mingo@redhat.com, linux-kernel@vger.kernel.org, kernel-team@fb.com, morten.rasmussen@arm.com, tglx@linutronix.de, mgorman@techsingularity.com, vincent.guittot@linaro.org Date: Fri, 28 Jun 2019 15:36:15 -0400 In-Reply-To: <1146bbfd-ae1e-27d8-6b62-d68392d8130f@arm.com> References: <20190612193227.993-1-riel@surriel.com> <20190612193227.993-9-riel@surriel.com> <1146bbfd-ae1e-27d8-6b62-d68392d8130f@arm.com> Content-Type: multipart/signed; micalg="pgp-sha256"; protocol="application/pgp-signature"; boundary="=-6PyMai3QXP/n3170GSeT" User-Agent: Evolution 3.30.5 (3.30.5-1.fc29) MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --=-6PyMai3QXP/n3170GSeT Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Fri, 2019-06-28 at 12:26 +0200, Dietmar Eggemann wrote: > On 6/12/19 9:32 PM, Rik van Riel wrote: > > Flatten the hierarchical runqueues into just the per CPU rq.cfs > > runqueue. > >=20 > > Iteration of the sched_entity hierarchy is rate limited to once per > > jiffy > > per sched_entity, which is a smaller change than it seems, because > > load > > average adjustments were already rate limited to once per jiffy > > before this > > patch series. > >=20 > > This patch breaks CONFIG_CFS_BANDWIDTH. The plan for that is to > > park tasks > > from throttled cgroups onto their cgroup runqueues, and slowly > > (using the > > GENTLE_FAIR_SLEEPERS) wake them back up, in vruntime order, once > > the cgroup > > gets unthrottled, to prevent thundering herd issues. > >=20 > > Signed-off-by: Rik van Riel > > --- > > include/linux/sched.h | 2 + > > kernel/sched/fair.c | 478 +++++++++++++++++--------------------- > > ---- > > kernel/sched/pelt.c | 6 +- > > kernel/sched/pelt.h | 2 +- > > kernel/sched/sched.h | 2 +- > > 5 files changed, 194 insertions(+), 296 deletions(-) > >=20 >=20 > [...] >=20 > > diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c >=20 > [...] >=20 > > @@ -3491,7 +3544,7 @@ static inline bool update_load_avg(struct > > cfs_rq *cfs_rq, struct sched_entity *s > > * track group sched_entity load average for task_h_load calc > > in migration > > */ > > if (se->avg.last_update_time && !(flags & SKIP_AGE_LOAD)) > > - updated =3D __update_load_avg_se(now, cfs_rq, se); > > + updated =3D __update_load_avg_se(now, cfs_rq, se, curr, > > curr); >=20 > I wonder if task migration is still working correctly. >=20 > migrate_task_rq_fair(p, ...) -> remove_entity_load_avg(&p->se) would > use > cfs_rq =3D se->cfs_rq (i.e. root cfs_rq). So load (and util) will not > propagate through the taskgroup hierarchy. >=20 > [...] Good point. This should be the group cfs_rq, and then on the next tick the load change will be=20 propagated up. Let me add that change in for v2 as well. --=20 All Rights Reversed. --=-6PyMai3QXP/n3170GSeT Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- iQEzBAABCAAdFiEEKR73pCCtJ5Xj3yADznnekoTE3oMFAl0WbDAACgkQznnekoTE 3oP9oQf/aeOsTlZQXSP/CpQs/0riPf9KL0PUIZ0PUsITghfB7jyFNBJKqdUldRVy wrc6gwPv9TVow+zP9oFuOKIfF2hqHIyxHoKhrFkG4jAclR9fq4rqfDvI5AE/Kw7q PT8iVWvsi90cF0SfmlaACPJ06hIj+48sehY0UdHY3j8CIWhqJgknLur3f14RKhU1 s7X+cefjXrPOXjqcIlRpMnAl3wg2Mz66rSJk1cLjDDtIMDds72LxGkc6ee822ei/ TyOj4zmHEdW3HwkQntg6yYi9hf07mekMhvmuvzkEucK5cWCODyEiWWoBuEPneEDp xngncEsP0B5VKUyDX/MtTVXwSvX4Bg== =wXrm -----END PGP SIGNATURE----- --=-6PyMai3QXP/n3170GSeT--