instrumenting-linux-kernel-itself: document LTTNG_TRACEPOINT_EVENT_CODE()
[lttng-docs.git] / contents / using-lttng / instrumenting / instrumenting-linux-kernel / instrumenting-linux-kernel-itself / lttng-adaptation-layer.md
index 1595cf2a7ce795f8489de35553b4b1f1d9be2edb..5adc088b37c5e745ef41d9e51ca04b26c9933cec 100644 (file)
@@ -71,6 +71,11 @@ Some possible entries for `TP_STRUCT__entry()` and `TP_fast_assign()`,
 in the case of LTTng-modules, are shown in the
 [LTTng-modules reference](#doc-lttng-modules-ref) section.
 
+You may also be interested in using the
+[`LTTNG_TRACEPOINT_EVENT_CODE()` macro](#doc-lttng-tracepoint-event-code),
+instead of using `LTTNG_TRACEPOINT_EVENT()`, which allows custom local
+variables and C code to be executed before the event fields are recorded.
+
 The best way to learn how to use the above macros is to inspect
 existing LTTng tracepoint definitions in `instrumentation/events/lttng-module`
 header files. Compare them with the Linux kernel mainline versions
This page took 0.022625 seconds and 4 git commands to generate.