summaryrefslogtreecommitdiffstats
path: root/include/jemalloc/internal
diff options
context:
space:
mode:
authorQi Wang <interwq@gwu.edu>2017-08-30 23:17:04 (GMT)
committerQi Wang <interwq@gmail.com>2017-08-31 18:03:34 (GMT)
commita315688be0f38188f16fe89ee1657c7f596f8cbb (patch)
tree8ef41b30e33326d91b67078a7fb3a0c3b9671c49 /include/jemalloc/internal
parente55c3ca26758bcb7f6f1621fd690caa245f16942 (diff)
downloadjemalloc-a315688be0f38188f16fe89ee1657c7f596f8cbb.zip
jemalloc-a315688be0f38188f16fe89ee1657c7f596f8cbb.tar.gz
jemalloc-a315688be0f38188f16fe89ee1657c7f596f8cbb.tar.bz2
Relax constraints on reentrancy for extent hooks.
If we guarantee no malloc activity in extent hooks, it's possible to make customized hooks working on arena 0. Remove the non-a0 assertion to enable such use cases.
Diffstat (limited to 'include/jemalloc/internal')
-rw-r--r--include/jemalloc/internal/jemalloc_internal_inlines_a.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/jemalloc/internal/jemalloc_internal_inlines_a.h b/include/jemalloc/internal/jemalloc_internal_inlines_a.h
index 5ec35db..c6a1f7e 100644
--- a/include/jemalloc/internal/jemalloc_internal_inlines_a.h
+++ b/include/jemalloc/internal/jemalloc_internal_inlines_a.h
@@ -151,6 +151,7 @@ pre_reentrancy(tsd_t *tsd, arena_t *arena) {
assert(arena != arena_get(tsd_tsdn(tsd), 0, false));
bool fast = tsd_fast(tsd);
+ assert(tsd_reentrancy_level_get(tsd) < INT8_MAX);
++*tsd_reentrancy_levelp_get(tsd);
if (fast) {
/* Prepare slow path for reentrancy. */