From: Dimitri Sivanich <sivanich@sgi.com>
To: Tejun Heo <tj@kernel.org>
Cc: linux-kernel@vger.kernel.org,
Rusty Russell <rusty@rustcorp.com.au>,
Linus Torvalds <torvalds@linux-foundation.org>,
Heiko Carstens <heiko.carstens@de.ibm.com>
Subject: Re: [PATCH] improve stop_machine performance
Date: Fri, 5 Mar 2010 08:11:43 -0600 [thread overview]
Message-ID: <20100305141143.GA17417@sgi.com> (raw)
In-Reply-To: <4B904EA8.3050709@kernel.org>
On Fri, Mar 05, 2010 at 09:22:00AM +0900, Tejun Heo wrote:
> Hello,
>
> On 03/05/2010 06:20 AM, Dimitri Sivanich wrote:
> > On systems with large cpu counts, we've been seeing long bootup times
> > associated with stop_machine operations. I've noticed that by simply
> > removing the creation of the workqueue and associated percpu variables
> > in subsequent stop_machine calls, we can reduce boot times on a
> > 1024 processor SGI UV system from 25-30 (or more) minutes down to 12
> > minutes.
> >
> > The attached patch does this in a simple way by removing the
> > stop_machine_destroy interface, thereby by leaving the workqueues and
> > percpu variables for later use once they are created.
> >
> > If people are against having these areas around after boot, maybe there
> > are some alternatives that will still allow for this optimization:
> >
> > - Set a timer to go off after a configurable number of minutes, at
> > which point the workqueue areas will be deleted.
> >
> > - Keep the stop_machine_destroy function, but somehow run it at the tail
> > end of boot (after modules have loaded), rather than running it at
> > every stop_machine call.
>
> Yeah, I can indeed imagine that creating and destroying all those
> workers on every module load during boot would be very costly if there
> are lots of CPUs. How about sharing the migration thread so that it
> serves as one-per-cpu uninterruptible RT simple thread pool? It's not
> like these things can run taking their turns anyway. I'll go ahead
> and make something up.
>
It seems reasonable as long as setup is fast enough. Will that thread indeed become fully uninterruptible (not affected by anything including scheduler decisions like sched_rt_period_us/sched_rt_runtime_us, etc..)?
next prev parent reply other threads:[~2010-03-05 14:11 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-04 21:20 [PATCH] improve stop_machine performance Dimitri Sivanich
2010-03-05 0:22 ` Tejun Heo
2010-03-05 14:11 ` Dimitri Sivanich [this message]
2010-03-05 14:17 ` Tejun Heo
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=20100305141143.GA17417@sgi.com \
--to=sivanich@sgi.com \
--cc=heiko.carstens@de.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=rusty@rustcorp.com.au \
--cc=tj@kernel.org \
--cc=torvalds@linux-foundation.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