All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@elte.hu>
To: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Steven Rostedt <rostedt@goodmis.org>,
	linux-kernel@vger.kernel.org,
	Arnaldo Carvalho de Melo <acme@ghostprotocols.net>
Subject: Re: [PATCH 1/2 v2] tracing/core: use appropriate waiting on trace_pipe
Date: Wed, 18 Feb 2009 01:40:47 +0100	[thread overview]
Message-ID: <20090218004047.GF25856@elte.hu> (raw)
In-Reply-To: <20090217225538.GD5194@nowhere>


* Frederic Weisbecker <fweisbec@gmail.com> wrote:

> On Wed, Feb 11, 2009 at 02:25:00AM +0100, Frederic Weisbecker wrote:
> > Impact: api and pipe waiting change
> > 
> > Currently, the waiting used in tracing_read_pipe() is done through a
> > 100 msecs schedule_timeout() loop which periodically check if there
> > are traces on the buffer.
> > 
> > This can cause small latencies for programs which are reading the incoming
> > events.
> > 
> > This patch makes the reader waiting for the trace_wait waitqueue except
> > for few tracers such as the sched and functions tracers which might be
> > already hold the runqueue lock while waking up the reader.
> > 
> > This is performed through a new callback wait_pipe() on struct tracer.
> > If none is implemented on a specific tracer, the default waiting for
> > trace_wait queue is attached.
> > 
> > Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
> > ---
> >  kernel/trace/trace.c                 |   62 ++++++++++++++++++++++-----------
> >  kernel/trace/trace.h                 |   25 ++++++++++++--
> >  kernel/trace/trace_functions.c       |    1 +
> >  kernel/trace/trace_functions_graph.c |    1 +
> >  kernel/trace/trace_sched_switch.c    |    1 +
> >  kernel/trace/trace_sched_wakeup.c    |    1 +
> >  6 files changed, 67 insertions(+), 24 deletions(-)
> 
> 
> Steven, Ingo, do you agree this one?
> 
> Thanks.

yeah - this version is much cleaner. I've applied it to 
tip:tracing/ftrace, thanks Frederic!

	Ingo

      reply	other threads:[~2009-02-18  0:41 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-02-11  1:25 [PATCH 1/2 v2] tracing/core: use appropriate waiting on trace_pipe Frederic Weisbecker
2009-02-17 22:55 ` Frederic Weisbecker
2009-02-18  0:40   ` Ingo Molnar [this message]

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=20090218004047.GF25856@elte.hu \
    --to=mingo@elte.hu \
    --cc=acme@ghostprotocols.net \
    --cc=fweisbec@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rostedt@goodmis.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.