16 fprintf(stderr,
"WARNING: node: %ld: %s:%i: ",
g_tw_mynode, __FILE__, __LINE__);
17 fprintf(stderr,
"The g_st_model_types has not been defined! No model level data will be collected\n");
34 fprintf(stderr,
"WARNING: node: %ld: %s:%i: ",
g_tw_mynode, __FILE__, __LINE__);
35 fprintf(stderr,
"The struct st_model_types has not been defined for at least 1 LP type! No model level data will be collected for LP types without a valid st_model_types struct defined.\n");
61 for (lpid = 0; lpid <
g_tw_nlp; lpid++)
72 model_md.
kpid = (
unsigned int) clp->
kp->
id;
73 model_md.
lpid = (
unsigned int) clp->
gid;
75 total_sz =
sizeof(sample_md) +
sizeof(model_md) + model_md.
model_sz;
76 char buffer[total_sz];
77 memcpy(&buffer[0], &sample_md,
sizeof(sample_md));
78 index +=
sizeof(sample_md);
79 memcpy(&buffer[index], &model_md,
sizeof(model_md));
80 index +=
sizeof(model_md);
tw_synch g_tw_synchronization_protocol
model_stat_f model_stat_fn
function pointer to collect model level data for RT and GVT-based instrumentation ...
st_model_types * g_st_model_types
static int model_type_warned
tw_statistics stats
per PE counters
void st_model_setup_types(tw_lp *lp)
void st_buffer_push(int type, char *data, int size)
size_t mstat_sz
size of data collected from model at sampling points
static tw_clock tw_clock_read(void)
void st_collect_model_data(tw_pe *pe, double current_rt, int stats_type)
Holds the entire PE state.
tw_kp * kp
kp – Kernel process that we belong to (must match pe).
static tw_stime tw_now(tw_lp const *lp)
void st_model_settype(tw_lpid i, st_model_types *model_types)
tw_typemap_f g_tw_lp_typemap
struct st_model_types * model_types
tw_stime GVT
Global Virtual Time.
tw_kpid id
ID number, otherwise its not available to the app.
void * cur_state
Current application LP data.
st_model_types model_types[]