Event tracing

Cross-platform event tracing subsystem.
Supports DTrace or SystemTap USDT and ETW (Event Tracing for Windows)

TODO: Type translation

Functions

etrc_provider_init

public

static void etrc_provider_init(etrc_provider_t* provider) 

etrc_provider_destroy

public

static void etrc_provider_destroy(etrc_provider_t* provider) 

etrc_probe_n

public

TSDOC_HIDDEN static ULONG etrc_probe_n(etrc_provider_t* provider, const EVENT_DESCRIPTOR* event, int numargs,void* arg1, size_t size1, void* arg2, size_t size2, void* arg3, size_t size3, void* arg4, size_t size4,void* arg5, size_t size5, void* arg6, size_t size6) 

ETRC_DEFINE_PROVIDER, ETRC_DEFINE_EVENT


Define profiler and events.

NOTES
you need manually assign event id's

#define ETRC_DEFINE_PROVIDER(provider, guid)
#define ETRC_DEFINE_EVENT(provider, event, id)

etrc_provider_destroy, etrc_provider_init


Initialize/destroy provider object

#define etrc_provider_init(provider)
#define etrc_provider_destroy(provider)

ETRC_PROBE4, ETRC_PROBE5, ETRC_PROBE0, ETRC_PROBE1, ETRC_PROBE2, ETRC_PROBE3


Probe functions

#define ETRC_PROBE0(provider, name)
#define ETRC_PROBE1(provider, name, type1, arg1)
#define ETRC_PROBE2(provider, name, type1, arg1, type2, arg2)
#define ETRC_PROBE3(provider, name, type1, arg1, type2, arg2, type3, arg3)
#define ETRC_PROBE4(provider, name, type1, arg1, type2, arg2, type3, arg3,  type4, arg4)
#define ETRC_PROBE5(provider, name, type1, arg1, type2, arg2, type3, arg3,  type4, arg4, type5, arg5)

Types

etrc_provider_t

typedef struct {
    REGHANDLE etp_reghandle;
    GUID      etp_guid;
} etrc_provider_t;