3 ms·
The wasted space has administrative overhead, and the administrative overhead can partially poison the cache.
by hinkley 2y ago
The wasted space has administrative overhead, and the administrative overhead can partially poison the cache.
- naasking 2y agoDo you mean wasted space inside the pointers, or on the heap?
- hinkley 2y agoIf you malloc or roll your own every allocation has to be big enough to be put back on the free list. And the overhead for combining adjacent segments back together, which will involve additional cache lines at least 12.5% of the time. cache line / pointer size, and anything larger than a pointer has higher probability. If you GC then it’s more pointer chasing during mark. Which will cache thrash at least one CPU, even if it’s not the one where most of the code is running.