Use extent_heap_first for best fit.
extent_heap_any makes the layout less predictable and as a result incurs more fragmentation.
This commit is contained in:
parent
d6feed6e66
commit
282a3faa17
@ -370,7 +370,7 @@ extents_best_fit_locked(tsdn_t *tsdn, arena_t *arena, extents_t *extents,
|
|||||||
(size_t)pind);
|
(size_t)pind);
|
||||||
if (i < NPSIZES+1) {
|
if (i < NPSIZES+1) {
|
||||||
assert(!extent_heap_empty(&extents->heaps[i]));
|
assert(!extent_heap_empty(&extents->heaps[i]));
|
||||||
extent_t *extent = extent_heap_any(&extents->heaps[i]);
|
extent_t *extent = extent_heap_first(&extents->heaps[i]);
|
||||||
assert(extent_size_get(extent) >= size);
|
assert(extent_size_get(extent) >= size);
|
||||||
return extent;
|
return extent;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user