This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
[Bug translator/10995] on-the-fly enabled/disabled probes
- From: "jlebon at redhat dot com" <sourceware-bugzilla at sourceware dot org>
- To: systemtap at sourceware dot org
- Date: Thu, 12 Jun 2014 19:27:03 +0000
- Subject: [Bug translator/10995] on-the-fly enabled/disabled probes
- Auto-submitted: auto-generated
- References: <bug-10995-6586 at http dot sourceware dot org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=10995
Jonathan Lebon <jlebon at redhat dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jlebon at redhat dot com
--- Comment #3 from Jonathan Lebon <jlebon at redhat dot com> ---
I've been working on this feature for a while. I've just pushed to the
jlebon/onthefly branch preliminary work to support this. Currently supported
are hrtimer probes and kprobes.
You can use the -DDEBUG_STP_ON_THE_FLY directive to see it in action during
runtime (outputs to dmesg). Here's a sample (with relevant dmesg output
interspersed):
$ stap -DDEBUG_STP_ON_THE_FLY -e '
global enabled = 0
probe timer.s(1) if (enabled) {
println("enabled!")
}
probe timer.s(5) {
println("toggling enable")
enabled = !enabled
}'
***** DMESG *****
[ 1490.643619] stap_9ea625b9fc91177d0b2a6490acd27b5_20639: systemtap:
2.6/0.158, base: ffffffffa0295000, memory: 31data/24text/1ctx/2058net/17alloc
kb, probes: 2
[ 1490.643625] systemtap_module_init:470 not starting (hrtimer) pidx 0
[ 1490.644421] systemtap_module_init:486 started (hrtimer) pidx 1
*****************
toggling enable
***** DMESG *****
[ 1495.644483] _stp_hrtimer_notify_function:298 scheduling work
[ 1495.645261] module_refresher:68 calling systemtap_module_refresh()
[ 1495.645474] systemtap_module_refresh:538 enabling (hrtimer) pidx 0
*****************
enabled!
enabled!
enabled!
enabled!
toggling enable
***** DMESG *****
[ 1500.644483] _stp_hrtimer_notify_function:298 scheduling work
[ 1500.645275] module_refresher:68 calling systemtap_module_refresh()
[ 1500.646036] systemtap_module_refresh:541 disabling (hrtimer) pidx 0
*****************
toggling enable
***** DMESG *****
[ 1505.644484] _stp_hrtimer_notify_function:298 scheduling work
[ 1505.645287] module_refresher:68 calling systemtap_module_refresh()
[ 1505.646069] systemtap_module_refresh:538 enabling (hrtimer) pidx 0
*****************
--
You are receiving this mail because:
You are the assignee for the bug.