Get the latest tech news
I was surprised by how simple an allocator is
ble of Contents Introduction Recently I was looking at an issue on mimalloc, a "state-of-the-art" memory allocator developed by Microsoft. The issue was quite simple, developers wanted a way to preallocate a piece of memory and use it as mimalloc's heap.
The issue was quite simple, developers wanted a way to preallocate a piece of memory and use it as mimalloc's heap. It is widely used in the industry, and it is the one used by the Linux kernel to handle page allocations ( albeit a modified version). The disadvantage of this technique is that it has internal fragmentation since the returned chunk can be smaller than the requested size and so the unused memory is wasted.
Or read this on Hacker News