upvote
Agreed mostly. Going from standard library to something like jemalloc or tcmalloc will give you around 5-10% wins which can be significant, but the difference between those generic allocators seem small. I just made a slab allocator recently for a custom data type and got speedups of 100% over malloc.
reply
You are not wrong and this is indeed what zig is trying to push by making all std functions that allocate take a allocator parameter.
reply