Make edata pointer on prof recent record an atomic fence

This commit is contained in:
Yinan Zhang
2020-04-10 16:26:55 -07:00
parent b8bdea6b26
commit 857ebd3daf
4 changed files with 42 additions and 19 deletions

View File

@@ -9,6 +9,7 @@ void edata_prof_recent_alloc_init(edata_t *edata);
#ifdef JEMALLOC_JET
typedef ql_head(prof_recent_t) prof_recent_list_t;
extern prof_recent_list_t prof_recent_alloc_list;
edata_t *prof_recent_alloc_edata_get_no_lock(const prof_recent_t *node);
prof_recent_t *edata_prof_recent_alloc_get_no_lock(const edata_t *edata);
#endif

View File

@@ -205,8 +205,8 @@ struct prof_recent_s {
ql_elm(prof_recent_t) link;
size_t size;
atomic_p_t alloc_edata; /* NULL means allocation has been freed. */
prof_tctx_t *alloc_tctx;
edata_t *alloc_edata; /* NULL means allocation has been freed. */
prof_tctx_t *dalloc_tctx;
};