doc: implement REUSE with SPDX identifiers
[lttng-ust.git] / doc / man / lttng-ust-dl.3.txt
CommitLineData
53f7d0d7
MJ
1// SPDX-FileCopyrightText: 2016 Philippe Proulx <pproulx@efficios.com>
2// SPDX-License-Identifier: CC-BY-4.0
3//
4ddbd0b7
PP
4lttng-ust-dl(3)
5===============
6:object-type: library
7
8
9NAME
10----
11lttng-ust-dl - Dynamic linker tracing (LTTng-UST helper)
12
13
14SYNOPSIS
15--------
16Launch your application by preloading `liblttng-ust-dl.so`:
17
18[role="term"]
19[verse]
636cf2a0 20$ *LD_PRELOAD=liblttng-ust-dl.so* my-app
4ddbd0b7
PP
21
22
23DESCRIPTION
24-----------
25When the `liblttng-ust-dl.so` library is preloaded before a given
26application starts, it causes all calls to man:dlopen(3) and
27man:dlclose(3) in said application to be traced with LTTng-UST (see
28man:lttng-ust(3)).
29
30See man:lttng(1) to learn more about how to control LTTng tracing
31sessions.
32
d1194248
PP
33IMPORTANT: This LTTng-UST helper can also emit _shared library
34load/unload_ events (see _Shared library load/unload tracking_ in
35man:lttng-ust(3)). You should :not: use the event records generated by
36this LTTng-UST helper (prefixed with `lttng_ust_dl:`) to track the
37loading and unloading of shared libraries, especially in situations
38where a dynamically loaded library loads its own dependencies. Instead,
39do preload `liblttng-ust-dl.so`, but use the shared library load/unload
40event records, which are more reliable, for your tracking analysis.
41
42The following LTTng-UST events are available when using this library.
43
4ddbd0b7
PP
44
45`lttng_ust_dl:dlopen`::
46 Emitted when man:dlopen(3) is called.
47+
48Fields:
49+
50[options="header"]
8902dadc
PP
51|===
52|Field name |Description
53
54|`baddr`
d01f365a 55|Base address of loaded library.
8902dadc
PP
56
57|`memsz`
d01f365a 58|Size of loaded library in memory.
8902dadc 59
3faa376c
PP
60|`flags`
61|Flags passed to man:dlopen(3).
62
63|`path`
64|Path to loaded library file.
65
66|`has_build_id`
67|Whether or not the loaded library has a build ID. If this field is 1,
68you can expect that an `lttng_ust_dl:build_id` event record
69follows this one (not necessarily immediately after).
70
71|`has_debug_link`
72|Whether or not the loaded library has debug link information. If this
73field is 1, you can expect that an `lttng_ust_dl:debug_link` event
74record follows this one (not necessarily immediately after).
75|===
76
77`lttng_ust_dl:dlmopen`::
78 Emitted when man:dlmopen(3) is called.
79+
80Fields:
81+
82[options="header"]
83|===
84|Field name |Description
85
86|`baddr`
87|Base address of loaded library.
88
89|`memsz`
90|Size of loaded library in memory.
91
92|`nsid`
93|ID of the namespace in which the library is loaded (as passed
94to man:dlmopen(3)).
95
96|`flags`
97|Flags passed to man:dlmopen(3).
98
8902dadc 99|`path`
d01f365a 100|Path to loaded library file.
3faa376c
PP
101
102|`has_build_id`
103|Whether or not the loaded library has a build ID. If this field is 1,
104you can expect that an `lttng_ust_dl:build_id` event record
105follows this one (not necessarily immediately after).
106
107|`has_debug_link`
108|Whether or not the loaded library has debug link information. If this
109field is 1, you can expect that an `lttng_ust_dl:debug_link` event
110record follows this one (not necessarily immediately after).
8902dadc 111|===
4ddbd0b7
PP
112
113`lttng_ust_dl:dlclose`::
114 Emitted when man:dlclose(3) is called.
115+
116Fields:
117+
118[options="header"]
8902dadc
PP
119|===
120|Field name |Description
121
122|`baddr`
d01f365a 123|Base address of loaded library.
8902dadc 124|===
4ddbd0b7
PP
125
126`lttng_ust_dl:debug_link`::
127 Emitted when debug link information is found when loading a library
128 with man:dlopen(3). See
129 https://sourceware.org/gdb/onlinedocs/gdb/Separate-Debug-Files.html[Debugging Information in Separate Files]
130 for more information about debug links.
131+
132Fields:
133+
134[options="header"]
8902dadc
PP
135|===
136|Field name |Description
137
138|`baddr`
d01f365a 139|Base address of loaded library.
8902dadc
PP
140
141|`filename`
d01f365a 142|Debug link file name.
8902dadc
PP
143
144|`crc`
d01f365a 145|Debug link file's CRC.
8902dadc 146|===
4ddbd0b7
PP
147
148`lttng_ust_dl:build_id`::
149 Emitted when a build ID is found when loading a library
150 with man:dlopen(3). See
151 https://sourceware.org/gdb/onlinedocs/gdb/Separate-Debug-Files.html[Debugging Information in Separate Files]
152 for more information about build IDs.
153+
154Fields:
155+
156[options="header"]
8902dadc
PP
157|===
158|Field name |Description
159
160|`baddr`
d01f365a 161|Base address of loaded library.
8902dadc
PP
162
163|`build_id`
d01f365a 164|Build ID.
8902dadc 165|===
4ddbd0b7
PP
166
167
168include::common-footer.txt[]
169
170include::common-copyrights.txt[]
171
172include::common-authors.txt[]
173
174
175SEE ALSO
176--------
177man:lttng-ust(3),
178man:dlopen(3),
179man:lttng(1)
This page took 0.035054 seconds and 4 git commands to generate.