YAC 3.21.0
Yet Another Coupler
Loading...
Searching...
No Matches
yac_pak_instrument.c File Reference
#include "yac_pak_instrument.h"
#include "instrument.h"
#include "yac_pak.h"
#include "utils_common.h"
Include dependency graph for yac_pak_instrument.c:

Go to the source code of this file.

Functions

static void pak_instrument_start_cb (int id, void *region_handle, int depth, void *user_data)
 
static void pak_instrument_stop_cb (int id, void *region_handle, int depth, void *user_data)
 
void yac_pak_instrument_begin (struct yac_pak *pak, yac_pak_trace_level_t level, char const *component, char const *grid)
 Begin a tracing window: record instrumented core regions until the matching yac_pak_instrument_end as YAC_PAK_EVENT_TYPE_REGION events on pak.
 
void yac_pak_instrument_end (void)
 End the window opened by yac_pak_instrument_begin (clears the callbacks). Safe to call unconditionally: no-op if begin did not register anything.
 

Variables

static struct yac_pak * window_pak = NULL
 
static yac_pak_trace_level_t window_level = YAC_PAK_TRACE_LEVEL_OFF
 
static char const * window_component = NULL
 
static char const * window_grid = NULL
 
static int window_active = 0
 
static int window_handles [YAC_INSTR_REGION_COUNT]
 

Function Documentation

◆ pak_instrument_start_cb()

static void pak_instrument_start_cb ( int id,
void * region_handle,
int depth,
void * user_data )
static

Definition at line 30 of file yac_pak_instrument.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ pak_instrument_stop_cb()

static void pak_instrument_stop_cb ( int id,
void * region_handle,
int depth,
void * user_data )
static

Definition at line 48 of file yac_pak_instrument.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ yac_pak_instrument_begin()

void yac_pak_instrument_begin ( struct yac_pak * pak,
yac_pak_trace_level_t level,
char const * component,
char const * grid )

Begin a tracing window: record instrumented core regions until the matching yac_pak_instrument_end as YAC_PAK_EVENT_TYPE_REGION events on pak.

No-op unless region tracing at level is enabled (see yac_pak_region_trace_is_enabled). Must be paired with yac_pak_instrument_end. component and grid are not copied and must stay valid until then.

Parameters
[in]pakTarget YAC PAK instance (may be NULL).
[in]levelEvent category for the region events. Callers pass YAC_PAK_TRACE_LEVEL_REGIONS. Any extra phase condition (e.g. YAC_PAK_TRACE_SETUP) is applied by the caller.
[in]componentComponent context (may be NULL).
[in]gridGrid context (may be NULL).

Definition at line 63 of file yac_pak_instrument.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ yac_pak_instrument_end()

void yac_pak_instrument_end ( void )

End the window opened by yac_pak_instrument_begin (clears the callbacks). Safe to call unconditionally: no-op if begin did not register anything.

Definition at line 83 of file yac_pak_instrument.c.

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ window_active

int window_active = 0
static

Definition at line 22 of file yac_pak_instrument.c.

◆ window_component

char const* window_component = NULL
static

Definition at line 20 of file yac_pak_instrument.c.

◆ window_grid

char const* window_grid = NULL
static

Definition at line 21 of file yac_pak_instrument.c.

◆ window_handles

int window_handles[YAC_INSTR_REGION_COUNT]
static

Definition at line 28 of file yac_pak_instrument.c.

◆ window_level

Definition at line 19 of file yac_pak_instrument.c.

◆ window_pak

struct yac_pak* window_pak = NULL
static

Definition at line 18 of file yac_pak_instrument.c.