From 01d75ac4b535682a4d531ebd916ee93ff0a69839 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn-Egil=20Dahlberg?= Date: Thu, 12 May 2016 18:10:59 +0200 Subject: runtime_tools: Fix tags of LTTng User's Guide --- lib/runtime_tools/doc/src/LTTng.xml | 78 ++++++++++++++++++------------------- 1 file changed, 38 insertions(+), 40 deletions(-) (limited to 'lib/runtime_tools/doc') diff --git a/lib/runtime_tools/doc/src/LTTng.xml b/lib/runtime_tools/doc/src/LTTng.xml index 4a87133c57..06152c66d6 100644 --- a/lib/runtime_tools/doc/src/LTTng.xml +++ b/lib/runtime_tools/doc/src/LTTng.xml @@ -76,7 +76,7 @@ $ make entry : string :: Code Location. Ex. "lists:sort/1"

Example:

-

process_spawn: { cpu_id = 3 }, { pid = "<0.131.0>", parent = "<0.130.0>", entry = "erlang:apply/2" }

+ process_spawn: { cpu_id = 3 }, { pid = "<0.131.0>", parent = "<0.130.0>", entry = "erlang:apply/2" }

process_link

@@ -85,7 +85,7 @@ $ make type : string :: "link" | "unlink"

Example:

-

process_link: { cpu_id = 3 }, { from = "<0.130.0>", to = "<0.131.0>", type = "link" }

+ process_link: { cpu_id = 3 }, { from = "<0.130.0>", to = "<0.131.0>", type = "link" }

process_exit

@@ -94,7 +94,7 @@ $ make reason : string :: Exit reason. Ex. "normal"

Example:

-

process_exit: { cpu_id = 3 }, { pid = "<0.130.0>", reason = "normal" }

+ process_exit: { cpu_id = 3 }, { pid = "<0.130.0>", reason = "normal" }

process_register

@@ -103,7 +103,7 @@ $ make type : string :: "register" | "unregister"

Example:

-

process_register: { cpu_id = 0 }, { pid = "<0.128.0>", name = "dyntrace_lttng_SUITE" type = "register" }

+ process_register: { cpu_id = 0 }, { pid = "<0.128.0>", name = "dyntrace_lttng_SUITE" type = "register" }

process_scheduled

@@ -113,7 +113,7 @@ $ make

Example:

-

process_scheduled: { cpu_id = 0 }, { pid = "<0.136.0>", entry = "erlang:apply/2", type = "in" }

+ process_scheduled: { cpu_id = 0 }, { pid = "<0.136.0>", entry = "erlang:apply/2", type = "in" }

port_open

@@ -124,7 +124,7 @@ $ make

Example:

-

port_open: { cpu_id = 5 }, { pid = "<0.131.0>", driver = "'/bin/sh -s unix:cmd'", port = "#Port<0.1887>" }

+ port_open: { cpu_id = 5 }, { pid = "<0.131.0>", driver = "'/bin/sh -s unix:cmd'", port = "#Port<0.1887>" }

port_exit

@@ -132,7 +132,7 @@ $ make reason : string :: Exit reason. Ex. "normal"

Example:

-

port_exit: { cpu_id = 5 }, { port = "#Port<0.1887>", reason = "normal" }

+ port_exit: { cpu_id = 5 }, { port = "#Port<0.1887>", reason = "normal" }

port_link

@@ -141,7 +141,7 @@ $ make type : string :: "link" | "unlink"

Example:

-

port_link: { cpu_id = 5 }, { from = "#Port<0.1887>", to = "<0.131.0>", type = "unlink" }

+ port_link: { cpu_id = 5 }, { from = "#Port<0.1887>", to = "<0.131.0>", type = "unlink" }

port_scheduled

@@ -151,7 +151,7 @@ $ make

Example:

-

port_scheduled: { cpu_id = 5 }, { pid = "#Port<0.1905>", entry = "close", type = "out" }

+ port_scheduled: { cpu_id = 5 }, { pid = "#Port<0.1905>", entry = "close", type = "out" }

function_call

@@ -160,7 +160,7 @@ $ make depth : integer :: Stack depth. Ex. 0

Example:

-

function_call: { cpu_id = 5 }, { pid = "<0.145.0>", entry = "dyntrace_lttng_SUITE:'-t_call/1-fun-1-'/0", depth = 0 }

+ function_call: { cpu_id = 5 }, { pid = "<0.145.0>", entry = "dyntrace_lttng_SUITE:'-t_call/1-fun-1-'/0", depth = 0 }

function_return

@@ -169,7 +169,7 @@ $ make depth : integer :: Stack depth. Ex. 0

Example:

-

function_return: { cpu_id = 5 }, { pid = "<0.145.0>", entry = "dyntrace_lttng_SUITE:waiter/0", depth = 0 }

+ function_return: { cpu_id = 5 }, { pid = "<0.145.0>", entry = "dyntrace_lttng_SUITE:waiter/0", depth = 0 }

function_exception

@@ -178,7 +178,7 @@ $ make class : string :: Error reason. Ex. "error"

Example:

-

function_exception: { cpu_id = 5 }, { pid = "<0.144.0>", entry = "t:call_exc/1", class = "error" }

+ function_exception: { cpu_id = 5 }, { pid = "<0.144.0>", entry = "t:call_exc/1", class = "error" }

message_send

@@ -187,7 +187,7 @@ $ make message : string :: Message sent. Ex. "{<0.162.0>,ok}"

Example:

-

message_send: { cpu_id = 3 }, { from = "#Port<0.1938>", to = "<0.160.0>", message = "{#Port<0.1938>,eof}" }

+ message_send: { cpu_id = 3 }, { from = "#Port<0.1938>", to = "<0.160.0>", message = "{#Port<0.1938>,eof}" }

message_receive

@@ -195,7 +195,7 @@ $ make message : string :: Message received. Ex. "{<0.162.0>,ok}"

Example:

-

message_receive: { cpu_id = 7 }, { to = "<0.167.0>", message = "{<0.165.0>,ok}" }

+ message_receive: { cpu_id = 7 }, { to = "<0.167.0>", message = "{<0.165.0>,ok}" }

gc_minor_start

@@ -205,7 +205,7 @@ $ make old_heap : integer :: Old heap word size. Ex. 233

Example:

-

gc_minor_start: { cpu_id = 0 }, { pid = "<0.172.0>", need = 0, heap = 610, old_heap = 0 }

+ gc_minor_start: { cpu_id = 0 }, { pid = "<0.172.0>", need = 0, heap = 610, old_heap = 0 }

gc_minor_end

@@ -215,7 +215,7 @@ $ make old_heap : integer :: Old heap word size. Ex. 233

Example:

-

gc_minor_end: { cpu_id = 0 }, { pid = "<0.172.0>", reclaimed = 120, heap = 1598, old_heap = 1598 }

+ gc_minor_end: { cpu_id = 0 }, { pid = "<0.172.0>", reclaimed = 120, heap = 1598, old_heap = 1598 }

gc_major_start

@@ -225,7 +225,7 @@ $ make old_heap : integer :: Old heap word size. Ex. 233

Example:

-

gc_major_start: { cpu_id = 0 }, { pid = "<0.172.0>", need = 8, heap = 2586, old_heap = 1598 }

+ gc_major_start: { cpu_id = 0 }, { pid = "<0.172.0>", need = 8, heap = 2586, old_heap = 1598 }

gc_major_end

@@ -235,7 +235,7 @@ $ make old_heap : integer :: Old heap word size. Ex. 233

Example:

-

gc_major_end: { cpu_id = 0 }, { pid = "<0.172.0>", reclaimed = 240, heap = 4185, old_heap = 0 }

+ gc_major_end: { cpu_id = 0 }, { pid = "<0.172.0>", reclaimed = 240, heap = 4185, old_heap = 0 } @@ -250,7 +250,7 @@ $ make runnable : integer :: Runnable. Ex. 1

Example:

-

scheduler_poll: { cpu_id = 4 }, { scheduler = 1, runnable = 1 }

+ scheduler_poll: { cpu_id = 4 }, { scheduler = 1, runnable = 1 }

driver_init

@@ -260,7 +260,7 @@ $ make flags : integer :: Flags. Ex. 1

Example:

-

driver_init: { cpu_id = 2 }, { driver = "caller_drv", major = 3, minor = 3, flags = 1 }

+ driver_init: { cpu_id = 2 }, { driver = "caller_drv", major = 3, minor = 3, flags = 1 }

driver_start

@@ -269,7 +269,7 @@ $ make port : string :: Port ID. Ex. "#Port<0.1031>"

Example:

-

driver_start: { cpu_id = 2 }, { pid = "<0.198.0>", driver = "caller_drv", port = "#Port<0.3676>" }

+ driver_start: { cpu_id = 2 }, { pid = "<0.198.0>", driver = "caller_drv", port = "#Port<0.3676>" }

driver_output

@@ -279,7 +279,7 @@ $ make bytes : integer :: Size of data returned. Ex. 82

Example:

-

driver_output: { cpu_id = 2 }, { pid = "<0.198.0>", port = "#Port<0.3677>", driver = "/bin/sh -s unix:cmd", bytes = 36 }

+ driver_output: { cpu_id = 2 }, { pid = "<0.198.0>", port = "#Port<0.3677>", driver = "/bin/sh -s unix:cmd", bytes = 36 }

driver_outputv

@@ -289,7 +289,7 @@ $ make bytes : integer :: Size of data returned. Ex. 82

Example:

-

driver_outputv: { cpu_id = 5 }, { pid = "<0.194.0>", port = "#Port<0.3663>", driver = "tcp_inet", bytes = 3 }

+ driver_outputv: { cpu_id = 5 }, { pid = "<0.194.0>", port = "#Port<0.3663>", driver = "tcp_inet", bytes = 3 }

driver_ready_input

@@ -298,7 +298,7 @@ $ make driver : string :: Driver name. Ex. "efile"

Example:

-

driver_ready_input: { cpu_id = 5 }, { pid = "<0.189.0>", port = "#Port<0.3637>", driver = "inet_gethost 4 " }

+ driver_ready_input: { cpu_id = 5 }, { pid = "<0.189.0>", port = "#Port<0.3637>", driver = "inet_gethost 4 " }

driver_ready_output

@@ -307,7 +307,7 @@ $ make driver : string :: Driver name. Ex. "efile"

Example:

-

driver_ready_output: { cpu_id = 5 }, { pid = "<0.194.0>", port = "#Port<0.3663>", driver = "tcp_inet" }

+ driver_ready_output: { cpu_id = 5 }, { pid = "<0.194.0>", port = "#Port<0.3663>", driver = "tcp_inet" }

driver_timeout

@@ -316,14 +316,14 @@ $ make driver : string :: Driver name. Ex. "efile"

Example:

-

driver_timeout: { cpu_id = 5 }, { pid = "<0.196.0>", port = "#Port<0.3664>", driver = "tcp_inet" }

+ driver_timeout: { cpu_id = 5 }, { pid = "<0.196.0>", port = "#Port<0.3664>", driver = "tcp_inet" }

driver_stop_select

driver : string :: Driver name. Ex. "efile"

Example:

-

driver_stop_select: { cpu_id = 5 }, { driver = "unknown" }

+ driver_stop_select: { cpu_id = 5 }, { driver = "unknown" }

driver_flush

@@ -332,7 +332,7 @@ $ make driver : string :: Driver name. Ex. "efile"

Example:

-

driver_flush: { cpu_id = 7 }, { pid = "<0.204.0>", port = "#Port<0.3686>", driver = "tcp_inet" }

+ driver_flush: { cpu_id = 7 }, { pid = "<0.204.0>", port = "#Port<0.3686>", driver = "tcp_inet" }

driver_stop

@@ -341,7 +341,7 @@ $ make driver : string :: Driver name. Ex. "efile"

Example:

-

driver_stop: { cpu_id = 5 }, { pid = "[]", port = "#Port<0.3673>", driver = "efile" }

+ driver_stop: { cpu_id = 5 }, { pid = "[]", port = "#Port<0.3673>", driver = "efile" }

driver_process_exit

@@ -357,7 +357,7 @@ $ make driver : string :: Driver name. Ex. "efile"

Example:

-

driver_ready_async: { cpu_id = 3 }, { pid = "<0.181.0>", port = "#Port<0.3622>", driver = "efile" }

+ driver_ready_async: { cpu_id = 3 }, { pid = "<0.181.0>", port = "#Port<0.3622>", driver = "efile" }

driver_call

@@ -368,7 +368,7 @@ $ make bytes : integer :: Size of data returned. Ex. 82

Example:

-

driver_call: { cpu_id = 2 }, { pid = "<0.202.0>", port = "#Port<0.3676>", driver = "caller_drv", command = 0, bytes = 2 }

+ driver_call: { cpu_id = 2 }, { pid = "<0.202.0>", port = "#Port<0.3676>", driver = "caller_drv", command = 0, bytes = 2 }

driver_control

@@ -379,7 +379,7 @@ $ make bytes : integer :: Size of data returned. Ex. 82

Example:

-

driver_control: { cpu_id = 3 }, { pid = "<0.32767.8191>", port = "#Port<0.0>", driver = "forker", command = 83, bytes = 32 }

+ driver_control: { cpu_id = 3 }, { pid = "<0.32767.8191>", port = "#Port<0.0>", driver = "forker", command = 83, bytes = 32 }

aio_pool_get

@@ -387,7 +387,7 @@ $ make length : integer :: Async queue length. Ex. 0

Example:

-

aio_pool_get: { cpu_id = 4 }, { port = "#Port<0.3614>", length = 0 }

+ aio_pool_get: { cpu_id = 4 }, { port = "#Port<0.3614>", length = 0 }

aio_pool_put

@@ -396,7 +396,7 @@ $ make

Async queue length is not defined for put operations.

Example:

-

aio_pool_put: { cpu_id = 3 }, { port = "#Port<0.3614>", length = -1 }

+ aio_pool_put: { cpu_id = 3 }, { port = "#Port<0.3614>", length = -1 }

carrier_create

@@ -414,7 +414,7 @@ $ make

Example:

-

carrier_create: { cpu_id = 2 }, { type = "ets_alloc", instance = 7, size = 2097152, mbc_carriers = 4, mbc_carriers_size = 3440640, mbc_blocks = 526, mbc_blocks_size = 1278576, sbc_carriers = 0, sbc_carriers_size = 0, sbc_blocks = 0, sbc_blocks_size = 0 }

+ carrier_create: { cpu_id = 2 }, { type = "ets_alloc", instance = 7, size = 2097152, mbc_carriers = 4, mbc_carriers_size = 3440640, mbc_blocks = 526, mbc_blocks_size = 1278576, sbc_carriers = 0, sbc_carriers_size = 0, sbc_blocks = 0, sbc_blocks_size = 0 }

carrier_destroy

@@ -432,7 +432,7 @@ $ make

Example:

-

carrier_destroy: { cpu_id = 6 }, { type = "ets_alloc", instance = 7, size = 262144, mbc_carriers = 3, mbc_carriers_size = 3178496, mbc_blocks = 925, mbc_blocks_size = 2305336, sbc_carriers = 0, sbc_carriers_size = 0, sbc_blocks = 0, sbc_blocks_size = 0 }

+ carrier_destroy: { cpu_id = 6 }, { type = "ets_alloc", instance = 7, size = 262144, mbc_carriers = 3, mbc_carriers_size = 3178496, mbc_blocks = 925, mbc_blocks_size = 2305336, sbc_carriers = 0, sbc_carriers_size = 0, sbc_blocks = 0, sbc_blocks_size = 0 }

carrier_pool_put

@@ -441,7 +441,7 @@ $ make size : integer :: Carrier size. Ex. 262144

Example:

-

carrier_pool_put: { cpu_id = 3 }, { type = "ets_alloc", instance = 5, size = 1048576 }

+ carrier_pool_put: { cpu_id = 3 }, { type = "ets_alloc", instance = 5, size = 1048576 }

carrier_pool_get

@@ -450,11 +450,9 @@ $ make size : integer :: Carrier size. Ex. 262144

Example:

-

carrier_pool_get: { cpu_id = 7 }, { type = "ets_alloc", instance = 4, size = 3208 }

- + carrier_pool_get: { cpu_id = 7 }, { type = "ets_alloc", instance = 4, size = 3208 } -
Examples
-- cgit v1.2.3 From 7467d2de71b4664b3d1c735990182f5ce309c6a2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn-Egil=20Dahlberg?= Date: Thu, 12 May 2016 18:41:19 +0200 Subject: runtime_tools: Fix tags of dbg reference manual --- lib/runtime_tools/doc/src/dbg.xml | 155 ++++++++++++++++++++------------------ 1 file changed, 82 insertions(+), 73 deletions(-) (limited to 'lib/runtime_tools/doc') diff --git a/lib/runtime_tools/doc/src/dbg.xml b/lib/runtime_tools/doc/src/dbg.xml index 0128e23a47..103b8b52e9 100644 --- a/lib/runtime_tools/doc/src/dbg.xml +++ b/lib/runtime_tools/doc/src/dbg.xml @@ -36,8 +36,8 @@ The Text Based Trace Facility

This module implements a text based interface to the - trace/3 and the - trace_pattern/2 BIFs. It makes it + trace/3 and the + trace_pattern/2 BIFs. It makes it possible to trace functions, processes, ports and messages.

@@ -185,7 +185,7 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ The corresponding process or port is traced. The process or port may be a remote process or port (on another Erlang node). The node must be in the list of traced nodes (see n/1 - and tracer/3). + and tracer/3). all All processes and ports in the system as well as all processes and ports created hereafter are to be traced. @@ -208,22 +208,23 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ atom() The process or port with the corresponding registered name is traced. The process or port may be a remote process (on another Erlang node). The node must be - added with the n/1 or - tracer/3 function. + added with the n/1 or + tracer/3 function. integer() The process ]]> is traced. {X, Y, Z} The process ]]> is traced. - string() - If the Item is a string "]]> - as returned from pid_to_list/1, the process - ]]> is traced. - + string() + If the Item is a string "]]> + as returned from pid_to_list/1, + the process ]]> is traced. + +

When enabling an Item that represents a group of processes, the Item is enabled on all nodes added with the - n/1 or - tracer/3 function.

+ n/1 or + tracer/3 function.

Flags can be a single atom, or a list of flags. The available flags are: @@ -275,7 +276,7 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\

This is the same as sol, but only for the first call to - link/1 by the traced process.

+ link/1 by the traced process.

all @@ -288,7 +289,7 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\

The list can also include any of the flags allowed in - erlang:trace/3

+ erlang:trace/3

The function returns either an error tuple or a tuple {ok, List}. The List consists of specifications of how many processes and ports that matched (in the @@ -368,11 +369,11 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ please turn to the User's guide part of the online documentation for the runtime system (erts). The - chapter Match Specifications in Erlang + chapter Match Specifications in Erlang explains the general match specification "language". The most common generic match specifications used can be found as Built-inAlias', see - ltp/0 below for details. + ltp/0 below for details.

The Module, Function and/or Arity parts of the tuple may be specified as the atom '_' which is a "wild-card" @@ -380,21 +381,21 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ Module is specified as '_', the Function and Arity parts have to be specified as '_' too. The same holds for the Functions relation to the Arity.

-

All nodes added with n/1 or - tracer/3 will +

All nodes added with n/1 or + tracer/3 will be affected by this call, and if Module is not '_' the module will be loaded on all nodes.

The function returns either an error tuple or a tuple {ok, List}. The List consists of specifications of how many functions that matched, in the same way as the processes and ports - are presented in the return value of p/2.

+ are presented in the return value of p/2.

There may be a tuple {saved, N} in the return value, if the MatchSpec is other than []. The integer N may then be used in subsequent calls to this function and will stand as an "alias" for the given expression. There are also a couple of - built-in aliases for common expressions, see - ltp/0 below for details.

+ built-in aliases for common expressions, see + ltp/0 below for details.

If an error is returned, it can be due to errors in compilation of the match specification. Such errors are presented as a list of tuples {error, string()} where @@ -433,7 +434,7 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ tpl({Module, Function, Arity}, MatchSpec) -> {ok, MatchDesc} | {error, term()} Set pattern for traced local (as well as global) function calls -

This function works as tp/2, but enables +

This function works as tp/2, but enables tracing for local calls (and local functions) as well as for global calls (and functions).

@@ -480,10 +481,10 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\

This function disables call tracing on the specified functions. The semantics of the parameter is the same as for the corresponding function specification in - tp/2 or tpl/2. Both local and global call trace + tp/2 or tpl/2. Both local and global call trace is disabled.

The return value reflects how many functions that matched, - and is constructed as described in tp/2. No tuple + and is constructed as described in tp/2. No tuple {saved, N} is however ever returned (for obvious reasons).

@@ -519,8 +520,9 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ ctpl({Module, Function, Arity}) -> {ok, MatchDesc} | {error, term()} Clear call trace pattern for the specified functions -

This function works as ctp/1, but only disables - tracing set up with tpl/2 (not with tp/2).

+

This function works as ctp/1, but only disables + tracing set up with tpl/2 + (not with tp/2).

@@ -555,8 +557,9 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ ctpg({Module, Function, Arity}) -> {ok, MatchDesc} | {error, term()} Clear call trace pattern for the specified functions -

This function works as ctp/1, but only disables - tracing set up with tp/2 (not with tpl/2).

+

This function works as ctp/1, but only disables + tracing set up with tp/2 + (not with tpl/2).

@@ -565,13 +568,14 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\

Use this function to recall all match specifications previously used in the session (i. e. previously saved during calls - to tp/2, and built-in match specifications. + to tp/2, and built-in match specifications. This is very useful, as a complicated match_spec can be quite awkward to write. Note that the - match specifications are lost if stop/0 is called.

+ match specifications are lost if stop/0 is called.

Match specifications used can be saved in a file (if a read-write file system is present) for use in later - debugging sessions, see wtp/1 and rtp/1

+ debugging sessions, see wtp/1 + and rtp/1

There are three built-in trace patterns: exception_trace, caller_trace and caller_exception_trace (or x, c and @@ -594,10 +598,10 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ Delete all saved match specifications.

Use this function to "forget" all match specifications - saved during calls to tp/2. - This is useful when one wants to restore other match - specifications from a file with rtp/1. Use - dtp/1 to delete specific saved match specifications.

+ saved during calls to tp/2. + This is useful when one wants to restore other match + specifications from a file with rtp/1. Use + dtp/1 to delete specific saved match specifications.

@@ -608,7 +612,7 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\

Use this function to "forget" a specific match specification - saved during calls to tp/2.

+ saved during calls to tp/2.

@@ -620,12 +624,12 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\

This function will save all match specifications saved - during the session (during calls to tp/2) + during the session (during calls to tp/2) and built-in match specifications in a text file with the name designated by Name. The format of the file is textual, why it can be edited with an ordinary text editor, and then restored with - rtp/1.

+ rtp/1.

Each match spec in the file ends with a full stop (.) and new (syntactically correct) match specifications can be added to the file manually.

@@ -643,7 +647,8 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\

This function reads match specifications from a file - (possibly) generated by the wtp/1 function. It checks + (possibly) generated by the wtp/1 + function. It checks the syntax of all match specifications and verifies that they are correct. The error handling principle is "all or nothing", i. e. if some of the match specifications are @@ -651,7 +656,8 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ saved match specifications for the running system.

The match specifications in the file are merged with the current match specifications, so that no duplicates - are generated. Use ltp/0 to see what numbers were + are generated. Use ltp/0 + to see what numbers were assigned to the specifications from the file.

The function will return an error, either due to I/O problems (like a non existing or non readable file) or due @@ -670,9 +676,9 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\

The dbg server keeps a list of nodes where tracing - should be performed. Whenever a tp/2 call or a - p/2 call is made, it is executed for all nodes in this - list including the local node (except for p/2 with a + should be performed. Whenever a tp/2 call or a + p/2 call is made, it is executed for all nodes in this + list including the local node (except for p/2 with a specific pid() or port() as first argument, in which case the command is executed only on the node where the designated process or port resides). @@ -684,7 +690,7 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ distribution). If no tracer process is running on the local node, the error reason no_local_tracer is returned. The tracer process on the local node must be started with the - tracer/0/2 function. + tracer/0/2 function.

If Nodename is the local node, the error reason cant_add_local_node is returned. @@ -694,7 +700,7 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ a tracer process. The error reason cant_trace_remote_pid_to_local_port is returned. A trace port can however be started on the remote node with the - tracer/3 function. + tracer/3 function.

The function will also return an error if the node Nodename is not reachable.

@@ -708,9 +714,10 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\

Clears a node from the list of traced nodes. Subsequent - calls to tp/2 and p/2 will not consider that - node, but tracing already activated on the node will continue - to be in effect.

+ calls to tp/2 and + p/2 will not consider that + node, but tracing already activated on the node will continue + to be in effect.

Returns ok, cannot fail.

@@ -727,14 +734,14 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\

This function starts a server on the local node that will be the recipient of all trace messages. All subsequent calls - to p/2 will result in messages sent to the newly + to p/2 will result in messages sent to the newly started trace server.

A trace server started in this way will simply display the trace messages in a formatted way in the Erlang shell - (i. e. use io:format). See tracer/2 for a description - of how the trace message handler can be customized. + (i. e. use io:format). See tracer/2 + for a description of how the trace message handler can be customized.

-

To start a similar tracer on a remote node, use n/1.

+

To start a similar tracer on a remote node, use n/1.

@@ -758,9 +765,9 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ by a receiving process (process), by a tracer port (port) or by a tracer module (module). For a description about tracer ports see - trace_port/2 + trace_port/2 and for a tracer modules see - erl_tracer. + erl_tracer.

If Type is process, a message handler function can be specified (HandlerSpec). The handler function, which @@ -776,10 +783,10 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\

If Type is port, then the second parameter should be a fun which takes no arguments and returns a newly opened trace port when called. Such a fun is - preferably generated by calling trace_port/2. + preferably generated by calling trace_port/2.

if Type is module, then the second parameter should - be either a tuple describing the erl_tracer + be either a tuple describing the erl_tracer module to be used for tracing and the state to be used for that tracer module or a fun returning the same tuple.

If an error is returned, it can either be due to a tracer @@ -787,7 +794,7 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ due to the HandlerFun throwing an exception.

To start a similar tracer on a remote node, use - tracer/3. + tracer/3.

@@ -798,19 +805,19 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ Nodename = atom() -

This function is equivalent to tracer/2, but acts on +

This function is equivalent to tracer/2, but acts on the given node. A tracer is started on the node (Nodename) and the node is added to the list of traced nodes.

-

This function is not equivalent to n/1. While - n/1 starts a process tracer which redirects all trace +

This function is not equivalent to n/1. While + n/1 starts a process tracer which redirects all trace information to a process tracer on the local node (i.e. the - trace control node), tracer/3 starts a tracer of any + trace control node), tracer/3 starts a tracer of any type which is independent of the tracer on the trace control node.

-

For details, see tracer/2.

+

For details, see tracer/2.

@@ -842,9 +849,9 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ file and the ip trace drivers. The file driver sends all trace messages into one or several binary files, from where they later can be fetched and processed with the - trace_client/2 function. The ip driver opens a TCP/IP + trace_client/2 function. The ip driver opens a TCP/IP port where it listens for connections. When a client - (preferably started by calling trace_client/2 on + (preferably started by calling trace_client/2 on another Erlang node) connects, all trace messages are sent over the IP network for further processing by the remote client.

@@ -883,7 +890,8 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\ as fast as they are produced by the runtime system, a special message is sent, which indicates how many messages that are dropped. That message will arrive at the handler function - specified in trace_client/3 as the tuple {drop, N} where N is the number of consecutive messages + specified in trace_client/3 + as the tuple {drop, N} where N is the number of consecutive messages dropped. In case of heavy tracing, drop's are likely to occur, and they surely occur if no client is reading the trace messages.

@@ -960,8 +968,8 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\

This function starts a trace client that reads the output created by a trace port driver and handles it in mostly the - same way as a tracer process created by the tracer/0 - function.

+ same way as a tracer process created by the + tracer/0 function.

If Type is file, the client reads all trace messages stored in the file named Filename or specified by WrapFilesSpec (must be the same as used @@ -972,7 +980,7 @@ Error: fun containing local erlang function calls ('is_atomm' called in guard)\

If Type is follow_file, the client behaves as in the file case, but keeps trying to read (and process) more data - from the file until stopped by stop_trace_client/1. + from the file until stopped by stop_trace_client/1. WrapFilesSpec is not allowed as second argument for this Type.

If Type is ip, the client connects to the @@ -1028,10 +1036,10 @@ hello InitialData = term() -

This function works exactly as trace_client/2, but - allows you to write your own handler function. The handler +

This function works exactly as trace_client/2, + but allows you to write your own handler function. The handler function works mostly as the one described in - tracer/2, but will also have to be prepared to handle + tracer/2, but will also have to be prepared to handle trace messages of the form {drop, N}, where N is the number of dropped messages. This pseudo trace message will only occur if the ip trace driver is used.

@@ -1050,7 +1058,8 @@ hello

This function shuts down a previously started trace client. The Pid argument is the process id returned - from the trace_client/2 or trace_client/3 call.

+ from the trace_client/2 + or trace_client/3 call.

@@ -1203,7 +1212,7 @@ SeqTrace [0]: (<0.30.0>) <0.25.0> ! {dbg,{ok,<0.31.0>}} [Serial: {4,5}] of causing a deadlock. This will happen if a group leader process generates a trace message and the tracer process, by calling the trace handler function, sends an IO request to the same group leader. The problem can only occur if the trace handler - prints to tty using an io function such as format/2. + prints to tty using an io function such as format/2. Note that when dbg:p(all,call) is called, IO processes are also traced. Here's an example:

-- cgit v1.2.3