diff options
author | Jason Evans <je@fb.com> | 2012-10-11 20:53:15 (GMT) |
---|---|---|
committer | Jason Evans <je@fb.com> | 2012-10-13 01:26:16 (GMT) |
commit | 609ae595f0358157b19311b0f9f9591db7cee705 (patch) | |
tree | 2a51758c6218f26167eb8ad2155ccc925c898c3b /include/jemalloc/internal/chunk.h | |
parent | d0ffd8ed4f6aa4cf7248028eddfcb35f93247fe4 (diff) | |
download | jemalloc-609ae595f0358157b19311b0f9f9591db7cee705.zip jemalloc-609ae595f0358157b19311b0f9f9591db7cee705.tar.gz jemalloc-609ae595f0358157b19311b0f9f9591db7cee705.tar.bz2 |
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 'include/jemalloc/internal/chunk.h')
-rw-r--r-- | include/jemalloc/internal/chunk.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/include/jemalloc/internal/chunk.h b/include/jemalloc/internal/chunk.h index c3c3e9c..87d8700 100644 --- a/include/jemalloc/internal/chunk.h +++ b/include/jemalloc/internal/chunk.h @@ -28,6 +28,7 @@ #ifdef JEMALLOC_H_EXTERNS extern size_t opt_lg_chunk; +extern const char *opt_dss; /* Protects stats_chunks; currently not used for any other purpose. */ extern malloc_mutex_t chunks_mtx; @@ -42,7 +43,9 @@ extern size_t chunk_npages; extern size_t map_bias; /* Number of arena chunk header pages. */ extern size_t arena_maxclass; /* Max size class for arenas. */ -void *chunk_alloc(size_t size, size_t alignment, bool base, bool *zero); +void *chunk_alloc(size_t size, size_t alignment, bool base, bool *zero, + dss_prec_t dss_prec); +void chunk_unmap(void *chunk, size_t size); void chunk_dealloc(void *chunk, size_t size, bool unmap); bool chunk_boot(void); void chunk_prefork(void); |