lkml.org 
[lkml]   [2018]   [Apr]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH tip/core/rcu 01/22] sched: Make non-production PREEMPT cond_resched() help Tasks RCU
On Mon, 23 Apr 2018 05:40:00 -0700
"Paul E. McKenney" <paulmck@linux.vnet.ibm.com> wrote:

> > I'm confused.. why is having this conditional on TRACEPOINT_BENCHMARK a
> > sane idea?
>
> Because the TRACEPOINT_BENCHMARK tests are insane, so a similar
> level of insanity is required to make things work. Plus having this
> be unconditional would not be good for performance, as 0day has been
> telling me frequently over the past couple of years.

Just for some context. The tracepoint benchmark (which should never be
enabled in any production machine), will start a thread when the
benchmark trace event is enabled. This thread will never exit (until
the trace event is disabled), and does a benchmark loop and constantly
calls "cond_resched()" to allow other tasks to run. The point is, this
thread will never have a quiescent state for task_rcu, unless we tell
rcu that cond_resched() is a quiescent state. But this is only required
because the tracepoint benchmark has this nasty thread, that is only
used for debugging and benchmarking the tracepoint (during development).

I also suggested having a direct call into RCU from the thread to tell
RCU that it entered a quiescent state, but Paul didn't like that idea
as it caused the tracepoint benchmark to call too deep into RCU
internals.

http://lkml.kernel.org/r/20180227153646.GD3777@linux.vnet.ibm.com


-- Steve

\
 
 \ /
  Last update: 2018-04-23 15:48    [W:0.117 / U:0.236 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site