From: Dietmar Eggemann <dietmar.eggemann@arm.com>
To: Qais Yousef <qyousef@layalina.io>,
Peter Zijlstra <peterz@infradead.org>,
Ingo Molnar <mingo@kernel.org>,
Juri Lelli <juri.lelli@redhat.com>,
Waiman Long <longman@redhat.com>
Cc: Steven Rostedt <rostedt@goodmis.org>,
tj@kernel.org, linux-kernel@vger.kernel.org,
luca.abeni@santannapisa.it, claudio@evidence.eu.com,
tommaso.cucinotta@santannapisa.it, bristot@redhat.com,
mathieu.poirier@linaro.org, cgroups@vger.kernel.org,
Vincent Guittot <vincent.guittot@linaro.org>,
Wei Wang <wvw@google.com>, Rick Yiu <rickyiu@google.com>,
Quentin Perret <qperret@google.com>,
Heiko Carstens <hca@linux.ibm.com>,
Vasily Gorbik <gor@linux.ibm.com>,
Alexander Gordeev <agordeev@linux.ibm.com>,
Sudeep Holla <sudeep.holla@arm.com>,
Zefan Li <lizefan.x@bytedance.com>,
linux-s390@vger.kernel.org, x86@kernel.org
Subject: Re: [PATCH v3] sched: cpuset: Don't rebuild root domains on suspend-resume
Date: Fri, 24 Feb 2023 16:14:51 +0100 [thread overview]
Message-ID: <5f087dd8-3e39-ce83-fe24-afa5179c05d9@arm.com> (raw)
In-Reply-To: <20230223153859.37tqoqk33oc6tv7o@airbuntu>
On 23/02/2023 16:38, Qais Yousef wrote:
IMHO the patch title is misleading since what you want to avoid in
certain cases is that the RD DL accounting is updated.
> On 02/06/23 22:14, Qais Yousef wrote:
>> Commit f9a25f776d78 ("cpusets: Rebuild root domain deadline accounting information")
>> enabled rebuilding root domain on cpuset and hotplug operations to
>> correct deadline accounting.
>>
>> Rebuilding root domain is a slow operation and we see 10+ of ms delays
>> on suspend-resume because of that (worst case captures 20ms which
>> happens often).
>>
>> Since nothing is expected to change on suspend-resume operation; skip
>> rebuilding the root domains to regain the some of the time lost.
>>
>> Achieve this by refactoring the code to pass whether dl accoutning needs
>> an update to rebuild_sched_domains(). And while at it, rename
>> rebuild_root_domains() to update_dl_rd_accounting() which I believe is
>> a more representative name since we are not really rebuilding the root
>> domains, but rather updating dl accounting at the root domain.
>>
>> Some users of rebuild_sched_domains() will skip dl accounting update
>> now:
>>
>> * Update sched domains when relaxing the domain level in cpuset
>> which only impacts searching level in load balance
This one is cpuset related. (1)
>> * update sched domains when cpufreq governor changes and we need
>> to create the perf domains
This one is drivers/base/arch_topology.c [arm/arm64/...] related. (2)
There are several levels of passing this `update_dl_accounting`
information through. I guess it looks like this:
update_dl_accounting
arm/arm64/riscv/parisc specific:
update_topology_flags_workfn() true
rebuild_sched_domains_energy() false (2)
cpuset_hotplug_workfn() cpus_updated ||
force_rebuild == CPUSET_FORCE_REBUILD_PRS_ERROR
->rebuild_sched_domains(update_dl_accounting)
update_cpumasks_hier() true
update_relax_domain_level() false (1)
update_flag() true
update_prstate() true
->rebuild_sched_domains_locked(update_dl_accounting)
->partition_and_rebuild_sched_domains(..., update_dl_accounting)
if (update_dl_accounting)
update_dl_rd_accounting()
There is already a somehow hidden interface for `sd/rd rebuild`
int __weak arch_update_cpu_topology(void)
which lets partition_sched_domains_locked() figure out whether sched
domains have to be rebuild..
But in your case it is more on the interface `cpuset/hotplug -> sd/rd
rebuild` and not only `arch -> `sd/rd rebuild``.
IMHO, it would be still nice to have only one way to tell `sd/rd
rebuild` what to do and what not to do during sd/rd/(pd) rebuild.
[...]
next prev parent reply other threads:[~2023-02-24 15:15 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-06 22:14 [PATCH v3] sched: cpuset: Don't rebuild root domains on suspend-resume Qais Yousef
2023-02-23 15:38 ` Qais Yousef
2023-02-24 15:14 ` Dietmar Eggemann [this message]
2023-02-27 20:57 ` Qais Yousef
2023-02-28 14:09 ` Dietmar Eggemann
2023-02-28 17:46 ` Qais Yousef
2023-03-01 7:31 ` Juri Lelli
2023-03-01 12:28 ` Qais Yousef
2023-03-01 14:26 ` Juri Lelli
2023-03-01 17:03 ` Qais Yousef
2023-03-08 10:19 ` Juri Lelli
2023-03-08 18:01 ` Hao Luo
2023-03-09 6:55 ` Juri Lelli
2023-03-09 22:23 ` Hao Luo
2023-03-11 18:51 ` Qais Yousef
2023-03-13 16:37 ` Juri Lelli
2023-03-13 17:10 ` Dietmar Eggemann
2023-03-14 11:41 ` Dietmar Eggemann
2023-03-08 19:21 ` Waiman Long
2023-03-13 12:37 ` Dietmar Eggemann
2023-03-07 19:56 ` Hao Luo
2023-03-07 20:08 ` Waiman Long
2023-03-07 21:06 ` Hao Luo
2023-03-07 21:13 ` Waiman Long
2023-03-07 22:17 ` Hao Luo
2023-03-08 2:29 ` Waiman Long
2023-03-08 18:11 ` Hao Luo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5f087dd8-3e39-ce83-fe24-afa5179c05d9@arm.com \
--to=dietmar.eggemann@arm.com \
--cc=agordeev@linux.ibm.com \
--cc=bristot@redhat.com \
--cc=cgroups@vger.kernel.org \
--cc=claudio@evidence.eu.com \
--cc=gor@linux.ibm.com \
--cc=hca@linux.ibm.com \
--cc=juri.lelli@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-s390@vger.kernel.org \
--cc=lizefan.x@bytedance.com \
--cc=longman@redhat.com \
--cc=luca.abeni@santannapisa.it \
--cc=mathieu.poirier@linaro.org \
--cc=mingo@kernel.org \
--cc=peterz@infradead.org \
--cc=qperret@google.com \
--cc=qyousef@layalina.io \
--cc=rickyiu@google.com \
--cc=rostedt@goodmis.org \
--cc=sudeep.holla@arm.com \
--cc=tj@kernel.org \
--cc=tommaso.cucinotta@santannapisa.it \
--cc=vincent.guittot@linaro.org \
--cc=wvw@google.com \
--cc=x86@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox