public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
From: Nick Piggin <nickpiggin@yahoo.com.au>
To: stephane eranian <eranian@googlemail.com>
Cc: Peter Zijlstra <peterz@infradead.org>,
	linux-kernel@vger.kernel.org, ia64 <linux-ia64@vger.kernel.org>,
	Stephane Eranian <eranian@gmail.com>,
	Corey J Ashford <cjashfor@us.ibm.com>,
	Ingo Molnar <mingo@elte.hu>
Subject: Re: runqueue locks in schedule()
Date: Fri, 18 Jan 2008 08:28:42 +0000	[thread overview]
Message-ID: <200801181928.43249.nickpiggin@yahoo.com.au> (raw)
In-Reply-To: <7c86c4470801172233s333b5993q8b10e37f8ad151d@mail.gmail.com>

On Friday 18 January 2008 17:33, stephane eranian wrote:
> Nick,

> > It is arch specific. If an architecture wants interrupts on during
> > context switch, or runqueue unlocked, then they set it (btw
> > INTERRUPTS_ON_CTXSW also implies UNLOCKED_CTXSW).
>
> Yes , I noticed that. I am only interested in UNLOCKED_CTXSW.
> But it appears that the approach suggested my Peter does work. We are
> running some tests.

OK, that might be OK.


> > Although, eg on x86, you would hold off interrupts and runqueue lock for
> > slightly less time if you defined those, it results in _slightly_ more
> > complicated context switching... although I did once find a workload
> > where the reduced runqueue contention improved throughput a bit, it is
> > not much problem in general to hold the lock.
>
> By complicated you mean that now you'd have to make sure you don't
> need to access runqueue data?

Well, not speaking about the arch-specific code (which may involve
more complexities), but the core scheduler needs the
task_struct->oncpu variable wheras that isn't required if the
runqueue is locked while switching tasks.

  reply	other threads:[~2008-01-18  8:28 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-17  0:29 runqueue locks in schedule() stephane eranian
2008-01-17 13:24 ` Peter Zijlstra
2008-01-18  2:07   ` Nick Piggin
2008-01-18  6:33     ` stephane eranian
2008-01-18  8:28       ` Nick Piggin [this message]
2008-02-23 14:50   ` stephane eranian
2008-02-23 20:40     ` Peter Zijlstra

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=200801181928.43249.nickpiggin@yahoo.com.au \
    --to=nickpiggin@yahoo.com.au \
    --cc=cjashfor@us.ibm.com \
    --cc=eranian@gmail.com \
    --cc=eranian@googlemail.com \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=peterz@infradead.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