mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Steven Rostedt <srostedt@redhat.com>
To: Arjan van de Ven <arjan@infradead.org>
Cc: linux-kernel@vger.kernel.org,
	Steven Rostedt <rostedt@goodmis.org>,
	Frederic Weisbecker <fweisbec@gmail.com>
Subject: Re: dynamic function tracing
Date: Sun, 30 Nov 2008 20:58:50 -0500	[thread overview]
Message-ID: <1228096730.4886.3.camel@localhost.localdomain> (raw)
In-Reply-To: <20081128101922.451e254a@infradead.org>


On Fri, 2008-11-28 at 10:19 -0800, Arjan van de Ven wrote:
> Hi,
> 
> I like the new function trace format with the {}'s a lot.. but I would
> like to use it in a way I don't think would work with dynamic tracing.
> 
> What I would like to do (read: usecase) is mark a function as
> interesting (because it has some performance issue or whatever),
> and then I want to get all functions it calls (recursive) traced
> automatically for the duration of that function.
> 
> This might be implementable by, on hitting the function to trace,
> patching all trace points with a function that checks if it's this
> thread (eg this "current"), and if so, traces the call. 
> I realize it's not going to be super cheap, so it needs to be one-shot,
> but it'll form a really strong usecase in practice...

It would not be wise to enable the function pointer at that moment. But
what we could do is have a function trace enabled that will flag when a
function is hit. Then it could start tracing all functions until it
returns. This would be possible.

What we need is a better way to attach the function tracer with the
function graph.

-- Steve



      parent reply	other threads:[~2008-12-01  1:59 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-28 18:19 Arjan van de Ven
2008-11-28 19:50 ` Frank Ch. Eigler
2008-12-01  1:58 ` Steven Rostedt [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=1228096730.4886.3.camel@localhost.localdomain \
    --to=srostedt@redhat.com \
    --cc=arjan@infradead.org \
    --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

Powered by JetHome