61 #include <include/hpctoolkit-config.h> 118 TMSG(TRACE,
"Tracing is ON");
131 TMSG(TRACE,
"Trace open called");
136 TMSG(TRACE,
"Hit active portion");
150 #ifdef DATACENTRIC_TRACE 159 TMSG(TRACE,
"Trace open done");
177 int ret = gettimeofday(&tv,
NULL);
178 assert(ret == 0 &&
"in trace_append: gettimeofday failed!");
179 uint64_t microtime = ((uint64_t)tv.tv_usec
180 + (((uint64_t)tv.tv_sec) * 1000000));
197 TMSG(TRACE,
"Trace close called");
200 TMSG(TRACE,
"Trace active close code");
203 EMSG(
"unable to flush and close trace file");
211 TMSG(TRACE,
"trace close done");
230 trace_datum.
time = microtime;
231 trace_datum.
cpId = (uint32_t)call_path_id;
233 trace_datum.
metricId = (uint32_t)metric_id;
236 #ifdef DATACENTRIC_TRACE 251 EMSG(
"unable to %s trace file\n", op);
static void hpcrun_trace_append_with_time_real(core_profile_trace_data_t *cptd, unsigned int call_path_id, uint metric_id, uint64_t microtime)
hpcio_outbuf_t trace_outbuf
void hpcrun_trace_open(core_profile_trace_data_t *cptd)
void hpcrun_trace_append(core_profile_trace_data_t *cptd, cct_node_t *node, uint metric_id)
int hpctrace_fmt_datum_outbuf(hpctrace_fmt_datum_t *x, hpctrace_hdr_flags_t flags, hpcio_outbuf_t *outbuf)
#define HPCIO_OUTBUF_UNLOCKED
const hpctrace_hdr_flags_t hpctrace_hdr_flags_NULL
void hpcrun_trace_close(core_profile_trace_data_t *cptd)
uint64_t trace_max_time_us
int hpcrun_sample_prob_active(void)
static const size_t HPCRUN_TraceBufferSz
int hpcrun_trace_isactive()
static void hpcrun_trace_file_validate(int valid, char *op)
int hpcrun_open_trace_file(int thread)
void hpcrun_cct_retain(cct_node_t *x)
int hpcio_outbuf_close(hpcio_outbuf_t *outbuf)
void * hpcrun_malloc(size_t size)
int32_t hpcrun_cct_persistent_id(cct_node_t *x)
int hpcrun_get_rank(void)
hpctrace_hdr_flags_bitfield fields
int hpcio_outbuf_attach(hpcio_outbuf_t *outbuf, int fd, void *buf_start, size_t buf_size, int flags)
void hpcrun_trace_append_with_time(core_profile_trace_data_t *st, unsigned int call_path_id, uint metric_id, uint64_t microtime)
int hpctrace_fmt_hdr_outbuf(hpctrace_hdr_flags_t flags, hpcio_outbuf_t *outbuf)
uint64_t trace_min_time_us
bool hpcrun_get_disabled(void)
int hpcrun_rename_trace_file(int rank, int thread)
void monitor_real_abort(void)
const char * HPCRUN_TRACE