Merge branch 'github/fork/emersion/tracing' into 'master'

Add kernel tracing instrumentation

See merge request wlroots/wlroots!2791
This commit is contained in:
Simon Ser 2026-01-08 09:52:31 +00:00
commit fe99c730c8
5 changed files with 93 additions and 1 deletions

17
include/util/trace.h Normal file
View file

@ -0,0 +1,17 @@
#ifndef UTIL_TRACE_H
#define UTIL_TRACE_H
#include <stdint.h>
#include <wlr/util/log.h>
void wlr_trace(const char *format, ...) _WLR_ATTRIB_PRINTF(1, 2);
void wlr_vtrace(const char *format, va_list args) _WLR_ATTRIB_PRINTF(1, 0);
struct wlr_trace_ctx {
uint32_t seq;
};
void wlr_trace_begin_ctx(struct wlr_trace_ctx *ctx, const char *format, ...) _WLR_ATTRIB_PRINTF(2, 3);
void wlr_trace_end_ctx(struct wlr_trace_ctx *ctx, const char *format, ...) _WLR_ATTRIB_PRINTF(2, 3);
#endif