The Creek has long been one of the bigger warts in Elfmalloc's design. Allocating a massive region of memory can be a dubious maneuver, in that it inadvertently forced us to rely on certain Linux-specific conventions. This refactor allows us to acquire memory through mmap in a piecemeal fashion. It also allows us to waste less virtual memory in small object sizes, paving the way for better Windows support.
This refactor also uncovered some bugs in how we handle TLS; this PR includes fixes for those.
One thing missing here are updated benchmark numbers. Those should be added soon.
The Creek has long been one of the bigger warts in Elfmalloc's design. Allocating a massive region of memory can be a dubious maneuver, in that it inadvertently forced us to rely on certain Linux-specific conventions. This refactor allows us to acquire memory through mmap in a piecemeal fashion. It also allows us to waste less virtual memory in small object sizes, paving the way for better Windows support.
This refactor also uncovered some bugs in how we handle TLS; this PR includes fixes for those.
One thing missing here are updated benchmark numbers. Those should be added soon.