mirror of
https://github.com/microsoft/mimalloc.git
synced 2025-07-06 19:38:41 +03:00
small fixes; max object size 1/8th of a pages
This commit is contained in:
parent
9a4c264e76
commit
3746bf79ed
6 changed files with 21 additions and 17 deletions
|
@ -313,7 +313,7 @@ static bool mi_arena_reserve(size_t req_size, bool allow_large, mi_arena_id_t re
|
|||
|
||||
if (arena_count >= 1 && arena_count <= 128) {
|
||||
// scale up the arena sizes exponentially every 4 entries
|
||||
const size_t multiplier = (size_t)1 << _mi_clamp(arena_count/4, 0, 16);
|
||||
const size_t multiplier = (size_t)1 << _mi_clamp(arena_count/2, 0, 16);
|
||||
size_t reserve = 0;
|
||||
if (!mi_mul_overflow(multiplier, arena_reserve, &reserve)) {
|
||||
arena_reserve = reserve;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue