Add high-level API

This commit is contained in:
Patrick Lipka 2025-08-07 15:41:31 +02:00
parent 29b2322284
commit 877841db24
1 changed files with 28 additions and 0 deletions

28
rvprof.h Normal file
View File

@ -0,0 +1,28 @@
#ifndef RVPROF_H
#define RVPROF_H
#include <stdint.h>
#ifdef __cplusplus
extern "C"{
#endif
// not called by instrumented code directly anymore
void rvprof_init(const char* output_file);
// not called by instrumented code directly anymore
void rvprof_set_program_name(const char* name);
// begin profiling a named region
void rvprof_region_begin(const char* name);
// end profiling of a named region
void rvprof_region_end(const char* name);
// not called by instrumented code direclty anymore
void rvprof_finalize();
#ifdef __cplusplus
extern }
#endif
#endif