From: Peter Zijlstra <peterz@infradead.org>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Vishal Chourasia <vishalc@linux.vnet.ibm.com>,
linux-kernel@vger.kernel.org, mingo@redhat.com,
vincent.guittot@linaro.org, vschneid@redhat.com,
srikar@linux.vnet.ibm.com, sshegde@linux.ibm.com,
linuxppc-dev@lists.ozlabs.org, ritesh.list@gmail.com,
aneesh.kumar@linux.ibm.com
Subject: Re: sched/debug: CPU hotplug operation suffers in a large cpu systems
Date: Wed, 26 Oct 2022 11:10:10 +0200 [thread overview]
Message-ID: <Y1j5cqbyZCDlyaTn@hirez.programming.kicks-ass.net> (raw)
In-Reply-To: <Y1jbhCYfktL51zNB@kroah.com>
On Wed, Oct 26, 2022 at 09:02:28AM +0200, Greg Kroah-Hartman wrote:
> On Wed, Oct 26, 2022 at 12:07:01PM +0530, Vishal Chourasia wrote:
> > On Tue, Oct 18, 2022 at 01:04:40PM +0200, Greg Kroah-Hartman wrote:
> >
> > > Why do you need to? What tools require these debugfs files to be
> > > present?
> >
> > We are not entirely sure what applications (if any) might be using this interface.
>
> Then just disable it and see what happens :)
It's mostly a debug interface for developers. A lot of people complained
when I moved things to debugfs, and I told them their program was broken
for a SCHED_DEBUG=n build anyway, but nobody complained about
this particular thing IIRC.
It's mostly affected by things like hotplug and cpusets, you can
discover the resulting topology by looking at these files.
Also; while we generally try and keep SCHED_DEBUG impact low, it is
still measurable; there are a number of people that run SCHED_DEBUG=n
kernels for the extra little gain.
> > > And if you only have 7-8 files per CPU, that does not seem like a lot of
> > > files overall (14000-16000)? If you only offline 1 cpu, how is removing
> > > 7 or 8 files a bottleneck? Do you really offline 1999 cpus for a 2k
> > > system?
> >
> > It's 7-8 files per domain per cpu, so, in a system with approx 2k cpus and five
> > domains, the total file count goes above 70k-80k files. And, when we offline 1
> > CPU, the entire directory is rebuilt, resulting in creation of all the files
> > again.
>
> Perhaps change the logic to not rebuild the whole thing and instead just
> remove the required files?
Unplugging a single cpu can change the topology and the other cpus might
need to be updated too.
Simplest example would be the SMT case, if you reduce from SMT>1 to SMT1
the SMT domain goes away (because a single CPU domain is as pointless as
it sounds) and that affects the CPU that remains.
Tracking all that is a pain. Simply rebuilding the whole thing is by
*far* the simplest option. And given this all is debug code, simple is
good.
> Or as I mentioned before, you can move debugfs to use kernfs, which
> should resolve most of these issues automatically. Why not take the
> time to do that which will solve the problem no matter what gets added
> in the future in other subsystems?
This sounds like a good approach.
next prev parent reply other threads:[~2022-10-26 9:10 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-17 13:10 sched/debug: CPU hotplug operation suffers in a large cpu systems Vishal Chourasia
2022-10-17 14:19 ` Peter Zijlstra
2022-10-17 14:54 ` Greg Kroah-Hartman
2022-10-18 10:37 ` Vishal Chourasia
2022-10-18 11:04 ` Greg Kroah-Hartman
2022-10-26 6:37 ` Vishal Chourasia
2022-10-26 7:02 ` Greg Kroah-Hartman
2022-10-26 9:10 ` Peter Zijlstra [this message]
2022-11-08 10:00 ` Vishal Chourasia
2022-11-08 12:24 ` Greg Kroah-Hartman
2022-11-08 14:51 ` Srikar Dronamraju
2022-11-08 15:38 ` Greg Kroah-Hartman
2022-12-12 19:17 ` Phil Auld
2022-12-13 2:17 ` kernel test robot
2022-12-13 6:23 ` Greg Kroah-Hartman
2022-12-13 13:22 ` Phil Auld
2022-12-13 14:31 ` Greg Kroah-Hartman
2022-12-13 14:45 ` Phil Auld
2023-01-19 15:31 ` Phil Auld
2022-12-13 23:41 ` Michael Ellerman
2022-12-14 2:26 ` Phil Auld
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=Y1j5cqbyZCDlyaTn@hirez.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=aneesh.kumar@linux.ibm.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=mingo@redhat.com \
--cc=ritesh.list@gmail.com \
--cc=srikar@linux.vnet.ibm.com \
--cc=sshegde@linux.ibm.com \
--cc=vincent.guittot@linaro.org \
--cc=vishalc@linux.vnet.ibm.com \
--cc=vschneid@redhat.com \
/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