aboutsummaryrefslogtreecommitdiff
path: root/src/tcache.c
diff options
context:
space:
mode:
authorJason Evans <je@fb.com>2012-10-11 13:53:15 -0700
committerJason Evans <je@fb.com>2012-10-12 18:26:16 -0700
commit609ae595f0358157b19311b0f9f9591db7cee705 (patch)
tree2a51758c6218f26167eb8ad2155ccc925c898c3b /src/tcache.c
parentd0ffd8ed4f6aa4cf7248028eddfcb35f93247fe4 (diff)
downloadjemalloc-609ae595f0358157b19311b0f9f9591db7cee705.tar.gz
Add arena-specific and selective dss allocation.
Add the "arenas.extend" mallctl, so that it is possible to create new arenas that are outside the set that jemalloc automatically multiplexes threads onto. Add the ALLOCM_ARENA() flag for {,r,d}allocm(), so that it is possible to explicitly allocate from a particular arena. Add the "opt.dss" mallctl, which controls the default precedence of dss allocation relative to mmap allocation. Add the "arena.<i>.dss" mallctl, which makes it possible to set the default dss precedence on a per arena or global basis. Add the "arena.<i>.purge" mallctl, which obsoletes "arenas.purge". Add the "stats.arenas.<i>.dss" mallctl.
Diffstat (limited to 'src/tcache.c')
-rw-r--r--src/tcache.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/tcache.c b/src/tcache.c
index 60244c4..47e14f3 100644
--- a/src/tcache.c
+++ b/src/tcache.c
@@ -288,7 +288,7 @@ tcache_create(arena_t *arena)
else if (size <= tcache_maxclass)
tcache = (tcache_t *)arena_malloc_large(arena, size, true);
else
- tcache = (tcache_t *)icalloc(size);
+ tcache = (tcache_t *)icallocx(size, false, arena);
if (tcache == NULL)
return (NULL);
@@ -364,7 +364,7 @@ tcache_destroy(tcache_t *tcache)
arena_dalloc_large(arena, chunk, tcache);
} else
- idalloc(tcache);
+ idallocx(tcache, false);
}
void