Skip to content
Commit 16bbb8ef authored by Torbjörn Leksell's avatar Torbjörn Leksell Committed by Anas Nashif
Browse files

Tracing: Trace hook support macros



Adds generic trace hook macros for inserting trace hook for
function entry, exit, blocking, and object initialization
with a variable number of arguments (objects, return values,
etc.). Utilizing macro concatenation these macros produce
trace hooks of a similar format to the old trace system
with SYS_TRACING_OBJ_FUNC(k_thread, switched_in) being
turned into sys_trace_k_thread_switched_in() by the
preprocessor. Although these macros still rely on the manual
definition of each unique trace hook in tracing.h, the benefit
of not directly calling those is that we can enable/disable
trace hooks based on object type (k_thread, k_sem, etc.)
through the preprocessor while providing the ability of adding
type specific runtime trace processing similar to
SYS_TRACING_OBJ_INIT.

Signed-off-by: default avatarTorbjörn Leksell <torbjorn.leksell@percepio.com>
Signed-off-by: default avatarAnas Nashif <anas.nashif@intel.com>
parent 2f01479b
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment