A trace (oski_trace_t) is a list of trace records (oski_tracerec_t), where each record stores the frequency and observed execution time for a particular kernel call with a specific argument list.
Each trace record contains a void pointer to a kernel-specific data structure that stores the argument list. Each kernel must define this data structure (see Kernel Implementations).
In addition, callers of the trace routines may provide an optional comparison function (of type oski_traceargscmp_funcpt) that takes two kernel-specific argument lists and returns 1 if they match, or 0 otherwise. This function provides a general mechanism for implementing queries on a trace, and is used by the heuristic module (see Tuning Module). If not specified, the default comparison compares the argument list pointers byte-by-byte.
Files | |
file | trace.h |
Implements a database for keeping track of kernel calls. | |
file | trace_query.c |
Implements a database system for tracking kernel calls. |