Commit | Line | Data |
---|---|---|
5e0cbfb0 PP |
1 | --- |
2 | id: lttng-ust | |
3 | --- | |
4 | ||
5 | The user space tracing part of LTTng is possible thanks to the user | |
6 | space tracing library, `liblttng-ust`, which is part of the LTTng-UST | |
7 | package. | |
8 | ||
9 | `liblttng-ust` provides header files containing macros used to define | |
10 | tracepoints and create tracepoint providers, as well as a shared object | |
11 | that must be linked to individual applications to connect to and | |
12 | communicate with a session daemon and a consumer daemon as soon as the | |
13 | application starts. | |
14 | ||
15 | The exact mechanism by which an application is registered to the | |
16 | session daemon is beyond the scope of this documentation. The only thing | |
17 | you need to know is that, since the library constructor does this job | |
18 | automatically, tracepoints may be safely inserted anywhere in the source | |
19 | code without prior manual initialization of `liblttng-ust`. | |
20 | ||
21 | The `liblttng-ust`-session daemon collaboration also provides an | |
22 | interesting feature: user space events may be enabled _before_ | |
23 | applications actually start. By doing this and starting tracing before | |
24 | launching the instrumented application, you make sure that even the | |
25 | earliest occurring events can be recorded. | |
26 | ||
27 | The [C application](#doc-c-application) instrumenting guide of the | |
28 | [Using LTTng](#doc-using-lttng) chapter focuses on using `liblttng-ust`: | |
29 | instrumenting, building/linking and running a user application. |