Bug 10787 - Probe exported functions only
Summary: Probe exported functions only
Status: RESOLVED FIXED
Alias: None
Product: systemtap
Classification: Unclassified
Component: translator (show other bugs)
Version: unspecified
: P2 normal
Target Milestone: ---
Assignee: Unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-10-16 12:22 UTC by Mark Wielaard
Modified: 2011-12-09 23:01 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mark Wielaard 2009-10-16 12:22:26 UTC
When probing functions of a shared library, say glibc, it is often nice to just
probe the exported (non-inlined, non-internal) functions of that library that
are called by the process.

Maybe we could add a qualifier after .function(), a sibling to .call, like
.exported?
Comment 1 Stan Cox 2011-12-02 22:14:47 UTC
The .library qualifier now comes close to providing this:

 stap -p2 -c plt.x  -e 'probe process("/plt.x").library("*libc*").function("*").call {printf("%s\n",pp())}'
yields:
 process("/lib64/libc-2.14.so").function("_dl_start@../sysdeps/unix/sysv/linux/init-first.c:110").call
 process("/lib64/libc-2.14.so").function("_init@../sysdeps/unix/sysv/linux/init-first.c:51").call
 ...

Just need to add .export to complement .call and .import so one could say:
process("/plt.x").library("*libc*").function("*").export
Comment 2 Stan Cox 2011-12-09 23:01:11 UTC
commit: 4bda987e1
Adds .exported