public inbox for linux-kernel@vger.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 <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 3/3] tracing/function-return-tracer: add the overrun field
Date: Tue, 18 Nov 2008 09:47:55 +0100	[thread overview]
Message-ID: <20081118084755.GK17838@elte.hu> (raw)
In-Reply-To: <4921BA25.3090704@gmail.com>


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

> Ingo Molnar a écrit :
> > * Frederic Weisbecker <fweisbec@gmail.com> wrote:
> > 
> >> Impact: help to find the better depth of trace
> >>
> >> We decided to arbitrary define the depth of function return trace as 
> >> "20". Perhaps this is not enough. To help finding an optimal depth, 
> >> we measure now the overrun: the number of functions that have been 
> >> missed for the current thread. By default this is not displayed, we 
> >> have to do set a particular flag on the return tracer: echo overrun 
> >>> /debug/tracing/trace_options And the overrun will be printed on 
> >> the right.
> >>
> >> As the trace shows below, the current 20 depth is not enough.
> >>
> >> update_wall_time+0x37f/0x8c0 -> update_xtime_cache (345 ns) (Overruns: 2838)
> >> update_wall_time+0x384/0x8c0 -> clocksource_get_next (1141 ns) (Overruns: 2838)
> >> do_timer+0x23/0x100 -> update_wall_time (3882 ns) (Overruns: 2838)
> > 
> > hm, interesting. Have you tried to figure out what a practical depth 
> > limit would be?
> > 
> > With lockdep we made the experience that function call stacks can be 
> > very deep - if we count IRQ contexts too it can be up to 100 in the 
> > extreme cases. (but at that stage kernel stack limits start hitting 
> > us)
> > 
> > I'd say 50 would be needed.
> > 
> > 	Ingo
> 
> 
> Ok I will try with 50. If there are still a lot and often missing 
> traces with this depth, perhaps should we consider a hybrid solution 
> between ret stack and trampolines? We could use the normal ret stack 
> on struct info for most common cases and the trampoline when we are 
> exceeding the depth....

dunno, trampolines make me feel uneasy.

Could you set it to some really large value (200) and add a "max depth 
seen" variable perhaps, and see the maximum depth?

	Ingo

  reply	other threads:[~2008-11-18  8:48 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-17  2:22 [PATCH 3/3] tracing/function-return-tracer: add the overrun field Frederic Weisbecker
2008-11-17  8:49 ` Ingo Molnar
2008-11-17 18:38   ` Frederic Weisbecker
2008-11-18  8:47     ` Ingo Molnar [this message]
2008-11-18 14:23       ` Steven Rostedt
2008-11-18 14:51         ` Ingo Molnar
2008-11-18 15:06           ` Steven Rostedt
2008-11-18 15:13             ` Ingo Molnar
2008-11-18 15:22               ` Steven Rostedt
2008-11-18 15:50                 ` Ingo Molnar
2008-11-18 16:31                   ` Frédéric Weisbecker
2008-11-18 16:40                     ` Ingo Molnar
2008-11-18 16:47                       ` Frédéric Weisbecker
2008-11-18 16:53                         ` Steven Rostedt
2008-11-18 16:58                           ` Frédéric Weisbecker
2008-11-18 17:00                             ` Frédéric Weisbecker
2008-11-18 21:01                               ` Ingo Molnar
2008-11-18 21:03                         ` Ingo Molnar
2008-11-19  7:35                           ` Frédéric Weisbecker
2008-11-21 19:39                           ` Frédéric Weisbecker
2008-11-21 19:48                             ` Ingo Molnar
2008-11-21 20:07                               ` Frédéric Weisbecker
2008-11-23 13:18                                 ` Ingo Molnar
2008-11-18 16:43                     ` Steven Rostedt
2008-11-18 14:21   ` Steven Rostedt
2008-11-18 14:48     ` Ingo Molnar
2008-11-18 14:58       ` Steven Rostedt
2008-11-18 15:02         ` Ingo Molnar
2008-11-18 15:11           ` Steven Rostedt

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=20081118084755.GK17838@elte.hu \
    --to=mingo@elte.hu \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox