public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
From: "fche at redhat dot com" <sourceware-bugzilla@sourceware.org>
To: systemtap@sources.redhat.com
Subject: [Bug translator/6921] New: tracepoint support
Date: Mon, 29 Sep 2008 20:12:00 -0000	[thread overview]
Message-ID: <20080929201133.6921.fche@redhat.com> (raw)

2.6.26+ have something called tracepoints.  See include/linux/tracepoint.h,
DEFINE_TRACE() macro.  It's desirable to let systemtap hook up to these things
directly, without marker intermediaries.  Thanks to a tip from roland, here's
how it might be done ...

 so ... we have DEFINE_TRACE declaring the static inline fn that should have the
same prototype as the final tracepoint callback function
 so we could do a dwarf search on the putative tracepoint name "foo" to find a
inline function "trace_foo"
 and/or use the tracepoint string section table to validate the "foo" name
 then look up its formal parameters in dwarf
 then save any particular inlined instance pc for later $param resolution
 then emit a tracepoint callback api thing with the same signature

$param resolution is tricky, since we wouldn't be using dwarf location list
data in a real tracepoint callback function.  we'd emit the callback function.
So for mapping $expr->field1->field2, we may *validate* the expression using
dwarf type data (including "alternatives" listing), but we'd just emit C code
that transcribes $expr->field1->field2 to "expr->field1->field2". ... Except
for pointer value checking .. so we may need to expand it to kread() chains
as for dwarf/pt_regs based probes.

The end result would be a generic tracepoint attachment mechanism that gives
good performance and good access to parameters.

-- 
           Summary: tracepoint support
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: translator
        AssignedTo: systemtap at sources dot redhat dot com
        ReportedBy: fche at redhat dot com


http://sourceware.org/bugzilla/show_bug.cgi?id=6921

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

             reply	other threads:[~2008-09-29 20:12 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-09-29 20:12 fche at redhat dot com [this message]
2008-09-29 23:36 ` [Bug translator/6921] " fche at redhat dot com
2009-01-05 15:43 ` tytso at mit dot edu
2009-02-21 14:48 ` jistone at redhat dot com
2009-02-21 16:09 ` fche at redhat dot com

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=20080929201133.6921.fche@redhat.com \
    --to=sourceware-bugzilla@sourceware.org \
    --cc=systemtap@sources.redhat.com \
    /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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).