summaryrefslogtreecommitdiff
path: root/lib/trace.h
diff options
context:
space:
mode:
authorQuentin Young <qlyoung@nvidia.com>2020-09-14 18:05:47 -0400
committerQuentin Young <qlyoung@nvidia.com>2020-10-23 15:13:51 -0400
commit1bd1ebaa08e9ca2e120f31fb9db3bd6be8111989 (patch)
tree514d607e86217ee2799578498e3522d2ca49a46a /lib/trace.h
parentabf96a87f3f2f9527885ee78930787ecb4068530 (diff)
lib: generate trace events for log messages
LTTng supports tracef() and tracelog() macros, which work like printf, and are used to ease transition between logging and tracing. Messages printed using these macros end up as trace events. For our uses we are not interested in dropping logging, but it is nice to get log messages in trace output, so I've added a call to tracelog() in zlog that dumps our zlog messages as trace events. Signed-off-by: Quentin Young <qlyoung@nvidia.com>
Diffstat (limited to 'lib/trace.h')
-rw-r--r--lib/trace.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/trace.h b/lib/trace.h
index dd6fb73ae4..d605cad0c4 100644
--- a/lib/trace.h
+++ b/lib/trace.h
@@ -107,6 +107,7 @@ THREAD_OPERATION_TRACEPOINT_INSTANCE(thread_call)
/* clang-format on */
#include <lttng/tracepoint-event.h>
+#include <lttng/tracelog.h>
#else /* HAVE_LTTNG */