![]() |
LTTng control library C API
|
Context field descriptor. More...
#include <event.h>

Data Fields | |
| enum lttng_event_context_type | ctx |
| Context field type. | |
| union lttng_event_context_u | u |
| perf counter or application-specific context field descriptor. | |
Context field descriptor.
Such a structure describes a context field to be recorded within all the event records of a given event record channel (see lttng_add_context()).
You must initialize such a structure to zeros before setting its members and using it, for example:
| enum lttng_event_context_type lttng_event_context::ctx |
Context field type.
Some types have a tracing domain constraint.
If this member has the value LTTNG_EVENT_CONTEXT_PERF_CPU_COUNTER or LTTNG_EVENT_CONTEXT_PERF_THREAD_COUNTER, then you must also set the lttng_event_context_u::perf_counter member of lttng_event_context::u.
If this member has the value LTTNG_EVENT_CONTEXT_APP_CONTEXT, then you must also set the lttng_event_context_u::app_ctx member of lttng_event_context::u.