Switch from opt.lg_tcache_max to opt.tcache_max

Though for convenience, keep parsing lg_tcache_max.
This commit is contained in:
Qi Wang
2020-10-19 22:48:26 -07:00
committed by Qi Wang
parent 5ba861715a
commit c8209150f9
7 changed files with 47 additions and 32 deletions

View File

@@ -179,7 +179,7 @@ TEST_BEGIN(test_mallctl_opt) {
TEST_MALLCTL_OPT(bool, xmalloc, xmalloc);
TEST_MALLCTL_OPT(bool, tcache, always);
TEST_MALLCTL_OPT(size_t, lg_extent_max_active_fit, always);
TEST_MALLCTL_OPT(size_t, lg_tcache_max, always);
TEST_MALLCTL_OPT(size_t, tcache_max, always);
TEST_MALLCTL_OPT(const char *, thp, always);
TEST_MALLCTL_OPT(const char *, zero_realloc, always);
TEST_MALLCTL_OPT(bool, prof, prof);

View File

@@ -393,7 +393,7 @@ test_tcache_bytes_for_usize(size_t usize) {
TEST_BEGIN(test_stats_tcache_bytes_small) {
test_skip_if(!config_stats);
test_skip_if(!opt_tcache);
test_skip_if((ZU(1) << opt_lg_tcache_max) < SC_SMALL_MAXCLASS);
test_skip_if(opt_tcache_max < SC_SMALL_MAXCLASS);
test_tcache_bytes_for_usize(SC_SMALL_MAXCLASS);
}
@@ -402,7 +402,7 @@ TEST_END
TEST_BEGIN(test_stats_tcache_bytes_large) {
test_skip_if(!config_stats);
test_skip_if(!opt_tcache);
test_skip_if((ZU(1) << opt_lg_tcache_max) < SC_LARGE_MINCLASS);
test_skip_if(opt_tcache_max < SC_LARGE_MINCLASS);
test_tcache_bytes_for_usize(SC_LARGE_MINCLASS);
}