Bug 10787

Summary: Probe exported functions only
Product: systemtap Reporter: Mark Wielaard <mark>
Component: translatorAssignee: Unassigned <systemtap>
Status: RESOLVED FIXED    
Severity: normal CC: scox
Priority: P2    
Version: unspecified   
Target Milestone: ---   
Host: Target:
Build: Last reconfirmed:

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