diff options
author | David Goldblatt <davidgoldblatt@fb.com> | 2017-05-30 17:45:37 (GMT) |
---|---|---|
committer | David Goldblatt <davidtgoldblatt@gmail.com> | 2017-05-31 20:08:45 (GMT) |
commit | 8261e581be517f4fe193ead2c9b662717d9ca5e0 (patch) | |
tree | 4dbd5e4a2f434e23d29494c6f7821eedd44b3b78 /src/tcache.c | |
parent | 041e041e1f23a03d1019330c8401a01285feb44f (diff) | |
download | jemalloc-8261e581be517f4fe193ead2c9b662717d9ca5e0.zip jemalloc-8261e581be517f4fe193ead2c9b662717d9ca5e0.tar.gz jemalloc-8261e581be517f4fe193ead2c9b662717d9ca5e0.tar.bz2 |
Header refactoring: Pull size helpers out of jemalloc module.
Diffstat (limited to 'src/tcache.c')
-rw-r--r-- | src/tcache.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/tcache.c b/src/tcache.c index 96ebe67..6355805 100644 --- a/src/tcache.c +++ b/src/tcache.c @@ -383,7 +383,7 @@ tsd_tcache_data_init(tsd_t *tsd) { assert(tcache_small_bin_get(tcache, 0)->avail == NULL); size_t size = stack_nelms * sizeof(void *); /* Avoid false cacheline sharing. */ - size = sa2u(size, CACHELINE); + size = sz_sa2u(size, CACHELINE); void *avail_array = ipallocztm(tsd_tsdn(tsd), size, CACHELINE, true, NULL, true, arena_get(TSDN_NULL, 0, true)); @@ -430,7 +430,7 @@ tcache_create_explicit(tsd_t *tsd) { stack_offset = size; size += stack_nelms * sizeof(void *); /* Avoid false cacheline sharing. */ - size = sa2u(size, CACHELINE); + size = sz_sa2u(size, CACHELINE); tcache = ipallocztm(tsd_tsdn(tsd), size, CACHELINE, true, NULL, true, arena_get(TSDN_NULL, 0, true)); @@ -655,7 +655,7 @@ tcache_boot(tsdn_t *tsdn) { return true; } - nhbins = size2index(tcache_maxclass) + 1; + nhbins = sz_size2index(tcache_maxclass) + 1; /* Initialize tcache_bin_info. */ tcache_bin_info = (tcache_bin_info_t *)base_alloc(tsdn, b0get(), nhbins |