mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-02-16 04:35:58 +00:00
By default malloc manages memory internally in larger blocks. When one of those blocks is added we initialize a free list by touching each of the new block's pages, thereby committing all that memory upfront. This changes malloc to build the free list on demand which as a bonus also distributes the latency hit for new blocks more evenly because the page faults for the zero pages now don't happen all at once.
2.1 KiB
2.1 KiB