From: Frederic Weisbecker <fweisbec@gmail.com>
To: Ingo Molnar <mingo@elte.hu>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
Steven Rostedt <rostedt@goodmis.org>,
Thomas Gleixner <tglx@linutronix.de>,
linux-kernel@vger.kernel.org, "H. Peter Anvin" <hpa@zytor.com>,
Borislav Petkov <borislav.petkov@amd.com>,
Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [GIT PULL] x86/cpu changes for v2.6.34
Date: Mon, 1 Mar 2010 14:17:05 +0100 [thread overview]
Message-ID: <20100301131701.GA5562@nowhere> (raw)
In-Reply-To: <20100301080058.GA8049@elte.hu>
On Mon, Mar 01, 2010 at 09:00:58AM +0100, Ingo Molnar wrote:
> Weird. It seems to be around multiples of .8: 0.8, 1.6, 2.4, with some extra
> overhead.
>
> Almost as if some calibration routine or some other busy-loop misses the train
> occasionally.
>
> The way i'd go about debugging this is to narrow down the approximate place
> the slowdown happens, then enable CONFIG_FUNCTION_TRACER (and disable
> CONFIG_DYNAMIC_FTRACE=y, to not have to deal with the dynamic patching
> aspects), and do a single-shot tracing session of only that section, on only
> one CPU:
>
> if (smp_processor_id() == 7)
> ftrace_enabled = 1;
>
> ... bootup sequence ...
>
> if (smp_processor_id() == 7)
> ftrace_enabled = 0;
>
> And recover the resulting trace from /debug/tracing/trace - it should have the reason
> in it plain and simple.
>
> ( Unfortunately i'm not 100% sure that setting ftrace_enabled to 1 is enough.
> I asked for a simple ad-hoc enable/disable function tracing mechanism _ages_
> ago - Steve, Frederic, what happened to that? ftrace_start()/stop() does not
> seem to allow that. )
I don't remember such request. But that would be useful indeed.
We could simply pair the setting of an early tracer with tracing
disabled and then manually delimit the places to trace with
tracing_on/tracing_off().
Whatever.
For now what you can do is setting the function_graph tracer
on bootup:
ftrace=function_graph
and call ftrace_graph_stop() in the place you want the trace
to finish (you could use ftrace_graph_filter= to delimit
the function tracing window, but that won't work without
dynamic tracing, neither with __init functions).
So, after the boot you can look at /debug/tracing/per_cpu/cpu7/trace
and the end of the trace should contain what you want.
next prev parent reply other threads:[~2010-03-01 13:17 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-27 15:09 [GIT PULL] x86/cpu changes for v2.6.34 Ingo Molnar
2010-02-27 17:10 ` Arjan van de Ven
2010-02-27 20:03 ` H. Peter Anvin
2010-02-28 20:09 ` Linus Torvalds
2010-02-28 20:45 ` Linus Torvalds
2010-03-01 8:00 ` Ingo Molnar
2010-03-01 13:17 ` Frederic Weisbecker [this message]
2010-03-01 16:47 ` Linus Torvalds
2010-03-01 19:42 ` Steven Rostedt
2010-03-01 22:23 ` Steven Rostedt
2010-03-01 22:24 ` H. Peter Anvin
2010-03-01 19:29 ` 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=20100301131701.GA5562@nowhere \
--to=fweisbec@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=borislav.petkov@amd.com \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=rostedt@goodmis.org \
--cc=tglx@linutronix.de \
--cc=torvalds@linux-foundation.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