server-skynet-source-3rd-je.../include/jemalloc/internal/prof_data.h

31 lines
1.1 KiB
C
Raw Normal View History

2020-04-01 00:42:11 +08:00
#ifndef JEMALLOC_INTERNAL_PROF_DATA_H
#define JEMALLOC_INTERNAL_PROF_DATA_H
2019-12-19 07:15:31 +08:00
#include "jemalloc/internal/mutex.h"
extern malloc_mutex_t *gctx_locks;
extern malloc_mutex_t *tdata_locks;
void prof_bt_hash(const void *key, size_t r_hash[2]);
bool prof_bt_keycomp(const void *k1, const void *k2);
bool prof_data_init(tsd_t *tsd);
bool prof_dump(tsd_t *tsd, bool propagate_err, const char *filename,
bool leakcheck);
prof_tdata_t * prof_tdata_init_impl(tsd_t *tsd, uint64_t thr_uid,
uint64_t thr_discrim, char *thread_name, bool active);
2019-12-19 07:15:31 +08:00
void prof_tdata_detach(tsd_t *tsd, prof_tdata_t *tdata);
void bt_init(prof_bt_t *bt, void **vec);
void prof_backtrace(tsd_t *tsd, prof_bt_t *bt);
void prof_tctx_try_destroy(tsd_t *tsd, prof_tctx_t *tctx);
/* Used in unit tests. */
size_t prof_tdata_count(void);
size_t prof_bt_count(void);
typedef void (prof_dump_header_t)(tsdn_t *, const prof_cnt_t *);
extern prof_dump_header_t *JET_MUTABLE prof_dump_header;
void prof_cnt_all(uint64_t *curobjs, uint64_t *curbytes, uint64_t *accumobjs,
uint64_t *accumbytes);
2020-04-01 00:42:11 +08:00
#endif /* JEMALLOC_INTERNAL_PROF_DATA_H */