#allocation

Articles tagged “allocation”

3 articles

The 30% is 46%, and it stops dead at 80 bytes

Go 1.27's size-specialised allocation is worth up to 46% on the pointer-containing path, not the 30% announced — and from 96 bytes up it is worth nothing.

Performance and measurement

sync.Pool survives one GC, not two

A pool holding 100 objects lost none across one collection and all 100 across two. Here is the victim cache, and what it costs at 122,000 ops per millisecond.

Runtime internals

Escape analysis is not a rule of thumb

The compiler said "does not escape" and the benchmark reported 104 KiB per operation. Both were right. What -gcflags=-m actually tells you.

Performance and measurement

Arrow keys to move, Enter to open.