
ZII and Arena Allocators in C++: Zero Is Initialization, Benchmarked
ZII designs every type so all-zero bytes is a valid default, and pairs it with arenas that free a whole group at once. RAII ties cleanup to each object. Here is how the two differ, where ZII falls short, a 20-line arena, and a nanobench run of 1000 allocations per frame: arena, std::pmr, malloc, calloc and new, with a live Godbolt session. Plus a struct-of-arrays layout, a Cortex-A78AE run, and the Jetson Orin GPU, then one CPU+GPU frame that uses all of it: 3.3x faster per frame.