small fixes; max object size 1/8th of a pages

This commit is contained in:
daanx 2024-12-19 21:30:03 -08:00
parent 9a4c264e76
commit 3746bf79ed
6 changed files with 21 additions and 17 deletions

View file

@ -870,7 +870,7 @@ void* _mi_malloc_generic(mi_heap_t* heap, size_t size, bool zero, size_t huge_al
if mi_unlikely(!mi_heap_is_initialized(heap)) { return NULL; }
}
mi_assert_internal(mi_heap_is_initialized(heap));
// collect every N generic mallocs
if (heap->generic_count++ > 10000) {
heap->generic_count = 0;