capture: add counter define/set collectors

This commit is contained in:
Christian Hergert
2020-08-19 13:43:13 -07:00
parent c7e0e11fc2
commit b913de8882
2 changed files with 121 additions and 31 deletions

View File

@ -64,43 +64,50 @@
SYSPROF_BEGIN_DECLS
SYSPROF_AVAILABLE_IN_3_36
void sysprof_collector_init (void);
void sysprof_collector_init (void);
SYSPROF_AVAILABLE_IN_3_36
void sysprof_collector_allocate (SysprofCaptureAddress alloc_addr,
int64_t alloc_size,
SysprofBacktraceFunc backtrace_func,
void *backtrace_data);
void sysprof_collector_allocate (SysprofCaptureAddress alloc_addr,
int64_t alloc_size,
SysprofBacktraceFunc backtrace_func,
void *backtrace_data);
SYSPROF_AVAILABLE_IN_3_36
void sysprof_collector_sample (SysprofBacktraceFunc backtrace_func,
void *backtrace_data);
void sysprof_collector_sample (SysprofBacktraceFunc backtrace_func,
void *backtrace_data);
SYSPROF_AVAILABLE_IN_3_36
void sysprof_collector_mark (int64_t time,
int64_t duration,
const char *group,
const char *mark,
const char *message);
void sysprof_collector_mark (int64_t time,
int64_t duration,
const char *group,
const char *mark,
const char *message);
SYSPROF_AVAILABLE_IN_3_38
void sysprof_collector_mark_printf (int64_t time,
int64_t duration,
const char *group,
const char *mark,
const char *message_format,
...) SYSPROF_PRINTF(5, 6);
void sysprof_collector_mark_printf (int64_t time,
int64_t duration,
const char *group,
const char *mark,
const char *message_format,
...) SYSPROF_PRINTF(5, 6);
SYSPROF_AVAILABLE_IN_3_38
void sysprof_collector_mark_vprintf (int64_t time,
int64_t duration,
const char *group,
const char *mark,
const char *message_format,
va_list args) SYSPROF_PRINTF(5, 0);
void sysprof_collector_mark_vprintf (int64_t time,
int64_t duration,
const char *group,
const char *mark,
const char *message_format,
va_list args) SYSPROF_PRINTF(5, 0);
SYSPROF_AVAILABLE_IN_3_36
void sysprof_collector_log (int severity,
const char *domain,
const char *message);
void sysprof_collector_log (int severity,
const char *domain,
const char *message);
SYSPROF_AVAILABLE_IN_3_38
void sysprof_collector_log_printf (int severity,
const char *domain,
const char *format,
...) SYSPROF_PRINTF (3, 4);
void sysprof_collector_log_printf (int severity,
const char *domain,
const char *format,
...) SYSPROF_PRINTF (3, 4);
SYSPROF_AVAILABLE_IN_3_38
void sysprof_collector_define_counters (const SysprofCaptureCounter *counters,
unsigned int n_counters);
SYSPROF_AVAILABLE_IN_3_38
void sysprof_collector_set_counters (const unsigned int *counters_ids,
const SysprofCaptureCounterValue *values,
unsigned int n_counters);
SYSPROF_END_DECLS