Kernel: Oops, fix bad sort order of available VM ranges

This made the allocator perform worse, so here's another second off of
the Kernel/Process.cpp compile time from a simple bugfix! (31s to 30s)
This commit is contained in:
Andreas Kling 2020-01-19 15:53:43 +01:00
parent 167b57a6b7
commit 05836757c6
Notes: sideshowbarker 2024-07-19 09:57:25 +09:00

View file

@ -170,7 +170,7 @@ void RangeAllocator::deallocate(Range range)
inserted_index = nearby_index;
} else {
m_available_ranges.insert_before_matching(Range(range), [&](auto& entry) {
return entry.base() < range.end();
return entry.base() >= range.end();
}, nearby_index, &inserted_index);
}