summaryrefslogtreecommitdiffstats
path: root/src/tcache.c
diff options
context:
space:
mode:
authorJason Evans <jasone@canonware.com>2015-05-20 00:40:37 (GMT)
committerJason Evans <jasone@canonware.com>2015-05-20 00:40:37 (GMT)
commit5aa50a2834fb09c5338f0e7b9db49cc0edd1a38a (patch)
tree0a7e95ea08cd79242e7c3156f23eae1260693111 /src/tcache.c
parentfd5f9e43c35b39740e218fececbb70d929546bb0 (diff)
downloadjemalloc-5aa50a2834fb09c5338f0e7b9db49cc0edd1a38a.zip
jemalloc-5aa50a2834fb09c5338f0e7b9db49cc0edd1a38a.tar.gz
jemalloc-5aa50a2834fb09c5338f0e7b9db49cc0edd1a38a.tar.bz2
Fix nhbins calculation.
This regression was introduced by 155bfa7da18cab0d21d87aa2dce4554166836f5d (Normalize size classes.).
Diffstat (limited to 'src/tcache.c')
-rw-r--r--src/tcache.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tcache.c b/src/tcache.c
index 8d0a6fa..83e7e36 100644
--- a/src/tcache.c
+++ b/src/tcache.c
@@ -506,7 +506,7 @@ tcache_boot(void)
else
tcache_maxclass = (1U << opt_lg_tcache_max);
- nhbins = NBINS + (tcache_maxclass >> LG_PAGE);
+ nhbins = size2index(tcache_maxclass) + 1;
/* Initialize tcache_bin_info. */
tcache_bin_info = (tcache_bin_info_t *)base_alloc(nhbins *