aboutsummaryrefslogtreecommitdiffstats
path: root/lib/runtime_tools/src
diff options
context:
space:
mode:
authorBjörn-Egil Dahlberg <[email protected]>2016-03-17 18:21:09 +0100
committerBjörn-Egil Dahlberg <[email protected]>2016-04-29 18:31:35 +0200
commit262d3d9291d5dcd2530d5a0d3170e9dc0345a002 (patch)
tree82d111e2457979f5ea061e6c96f9d4a6d7d9ad8e /lib/runtime_tools/src
parenta4811133b70370e54162d256d61ef4c084e1f4fe (diff)
downloadotp-262d3d9291d5dcd2530d5a0d3170e9dc0345a002.tar.gz
otp-262d3d9291d5dcd2530d5a0d3170e9dc0345a002.tar.bz2
otp-262d3d9291d5dcd2530d5a0d3170e9dc0345a002.zip
runtime_tools: Extend 'enabled' tracer callbacks
Adds the following capabilities to dyntrace * enabled_procs/3 * enabled_ports/3 * enabled_running/3 * enabled_call/3 * enabled_send/3 * enabled_receive/3 * enabled_garbage_collection/3
Diffstat (limited to 'lib/runtime_tools/src')
-rw-r--r--lib/runtime_tools/src/dyntrace.erl43
1 files changed, 36 insertions, 7 deletions
diff --git a/lib/runtime_tools/src/dyntrace.erl b/lib/runtime_tools/src/dyntrace.erl
index f776b601cb..8a449e5749 100644
--- a/lib/runtime_tools/src/dyntrace.erl
+++ b/lib/runtime_tools/src/dyntrace.erl
@@ -41,8 +41,7 @@
pn/1, pn/2, pn/3, pn/4, pn/5, pn/6, pn/7, pn/8, pn/9]).
-export([put_tag/1, get_tag/0, get_tag_data/0, spread_tag/1, restore_tag/1]).
--export([enabled/3,
- trace/5,
+-export([trace/5,
trace/6,
trace_procs/6,
trace_ports/6,
@@ -50,8 +49,17 @@
trace_call/6,
trace_send/6,
trace_receive/6,
- trace_garbage_collection/6
- ]).
+ trace_garbage_collection/6]).
+
+-export([enabled_procs/3,
+ enabled_ports/3,
+ enabled_running/3,
+ enabled_call/3,
+ enabled_send/3,
+ enabled_receive/3,
+ enabled_garbage_collection/3,
+ enabled/3]).
+
-export([user_trace_i4s4/9]). % Know what you're doing!
-on_load(on_load/0).
@@ -137,9 +145,6 @@ user_trace_i4s4(_, _, _, _, _, _, _, _, _) ->
user_trace_n(_, _, _, _, _, _, _, _, _, _) ->
erlang:nif_error(nif_not_loaded).
-enabled(_TraceTag, _TracerState, _Tracee) ->
- erlang:nif_error(nif_not_loaded).
-
trace(_TracerState, _Label, _SeqTraceInfo, _, _Opts) ->
erlang:nif_error(nif_not_loaded).
@@ -167,6 +172,30 @@ trace_receive(_TraceTag, _TracerState, _Tracee, _FirstTraceTerm, _SecondTraceTer
trace_garbage_collection(_TraceTag, _TracerState, _Tracee, _FirstTraceTerm, _SecondTraceTerm, _Opts) ->
erlang:nif_error(nif_not_loaded).
+enabled(_TraceTag, _TracerState, _Tracee) ->
+ erlang:nif_error(nif_not_loaded).
+
+enabled_procs(_TraceTag, _TracerState, _Tracee) ->
+ erlang:nif_error(nif_not_loaded).
+
+enabled_ports(_TraceTag, _TracerState, _Tracee) ->
+ erlang:nif_error(nif_not_loaded).
+
+enabled_running(_TraceTag, _TracerState, _Tracee) ->
+ erlang:nif_error(nif_not_loaded).
+
+enabled_call(_TraceTag, _TracerState, _Tracee) ->
+ erlang:nif_error(nif_not_loaded).
+
+enabled_send(_TraceTag, _TracerState, _Tracee) ->
+ erlang:nif_error(nif_not_loaded).
+
+enabled_receive(_TraceTag, _TracerState, _Tracee) ->
+ erlang:nif_error(nif_not_loaded).
+
+enabled_garbage_collection(_TraceTag, _TracerState, _Tracee) ->
+ erlang:nif_error(nif_not_loaded).
+
%%%
%%% Erlang support functions
%%%