From: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: Dave Jones <davej@redhat.com>,
Linux Kernel <linux-kernel@vger.kernel.org>,
gregkh@linuxfoundation.org, peter@hurleysoftware.com
Subject: Re: tty^Wrcu/perf lockdep trace.
Date: Sat, 5 Oct 2013 09:28:02 -0700 [thread overview]
Message-ID: <20131005162802.GP5790@linux.vnet.ibm.com> (raw)
In-Reply-To: <20131005160511.GV3081@twins.programming.kicks-ass.net>
On Sat, Oct 05, 2013 at 06:05:11PM +0200, Peter Zijlstra wrote:
> On Fri, Oct 04, 2013 at 02:25:06PM -0700, Paul E. McKenney wrote:
> > > Why
> > > do we still have a per-cpu kthread in nocb mode? The idea is that we do
> > > not disturb the cpu, right? So I suppose these kthreads get to run on
> > > another cpu.
> >
> > Yep, the idea is that usermode figures out where to run them. Even if
> > usermode doesn't do that, this has the effect of getting them to be
> > more out of the way of real-time tasks.
> >
> > > Since its running on another cpu; we get into atomic and memory barriers
> > > anyway; so why not keep the logic the same as no-nocb but have another
> > > cpu check our nocb cpu's state.
> >
> > You can do that today by setting rcu_nocb_poll, but that results in
> > frequent polling wakeups even when the system is completely idle, which
> > is out of the question for the battery-powered embedded guys.
>
> So its this polling I don't get.. why is the different behaviour
> required? And why would you continue polling if the cpus were actually
> idle.
The idea is to offload the overhead of doing the wakeup from (say)
a real-time thread/CPU onto some housekeeping CPU.
> Is there some confusion between the nr_running==1 extended quiescent
> state and the nr_running==0 extended quiescent state?
This is independent of the nr_running=1 extended quiescent state. The
wakeups only happen when runnning in the kernel. That said, a real-time
thread might want both rcu_nocb_poll=y and CONFIG_NO_HZ_FULL=y.
> Now, none of this solves the issue at hand because event the 'regular'
> no-nocb rcu mode has this issue of needing to wake kthreads, but I'd
> like to get a better understanding of why nocb mode is as it is.
>
>
> I've seen you've since send a few more emails; I might find some of the
> answers in there. Let me go read the :-)
I -think- I have solved it, but much testing and review will of course
be required. And fixing last night's test failures...
Thanx, Paul
next prev parent reply other threads:[~2013-10-05 16:28 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-03 19:08 tty/perf lockdep trace Dave Jones
2013-10-03 19:42 ` tty^Wrcu/perf " Peter Zijlstra
2013-10-03 19:58 ` Paul E. McKenney
2013-10-04 6:58 ` Peter Zijlstra
2013-10-04 16:03 ` Paul E. McKenney
2013-10-04 16:15 ` Paul E. McKenney
2013-10-04 16:50 ` Peter Zijlstra
2013-10-04 17:09 ` Paul E. McKenney
2013-10-04 18:52 ` Peter Zijlstra
2013-10-04 21:25 ` Paul E. McKenney
2013-10-04 22:02 ` Paul E. McKenney
2013-10-05 0:23 ` Paul E. McKenney
2013-10-07 11:24 ` Peter Zijlstra
2013-10-07 12:59 ` Paul E. McKenney
2013-10-05 16:05 ` Peter Zijlstra
2013-10-05 16:28 ` Paul E. McKenney [this message]
2013-10-05 19:59 ` Peter Zijlstra
2013-10-05 22:03 ` Paul E. McKenney
2013-10-07 8:42 ` Peter Zijlstra
2013-10-07 13:11 ` Paul E. McKenney
2013-10-07 17:35 ` Paul E. McKenney
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=20131005162802.GP5790@linux.vnet.ibm.com \
--to=paulmck@linux.vnet.ibm.com \
--cc=davej@redhat.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=peter@hurleysoftware.com \
--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;
as well as URLs for NNTP newsgroup(s).