mirror of
https://github.com/jemalloc/jemalloc.git
synced 2026-08-25 16:43:33 +03:00
Add a per-arena oversize_threshold.
This can let manual arenas trade off memory and CPU the way auto arenas do.
This commit is contained in:
parent
4ca3d91e96
commit
cf2549a149
10 changed files with 194 additions and 12 deletions
|
|
@ -63,9 +63,11 @@ test_data_t *init_test_data(ssize_t dirty_decay_ms, ssize_t muzzy_decay_ms) {
|
|||
nstime_t time;
|
||||
nstime_init(&time, 0);
|
||||
|
||||
const size_t oversize_threshold = 8 * 1024 * 1024;
|
||||
err = pa_shard_init(TSDN_NULL, &test_data->shard, &test_data->emap,
|
||||
test_data->base, /* ind */ 1, &test_data->stats,
|
||||
&test_data->stats_mtx, &time, dirty_decay_ms, muzzy_decay_ms);
|
||||
&test_data->stats_mtx, &time, oversize_threshold, dirty_decay_ms,
|
||||
muzzy_decay_ms);
|
||||
assert_false(err, "");
|
||||
|
||||
return test_data;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue