ELSEIF
Your brief EB
195 stories from 105 feeds 335 clusters Refreshed 10 minutes ago next pull 22:52

PERFORMANCE Signal 427

Go 1.27 uses dedicated allocation functions for small objects under 80 bytes, nearly doubling speed

Go 1.27 replaces the generic heap allocation function with dedicated functions for objects under 80 bytes, yielding a 1.8x speedup on some small allocation benchmarks.

WHY IT MATTERS

Programs that heavily allocate small objects on the heap, such as those maintaining dynamic trees or linked lists, could see significant performance gains. The optimization does not help code that rarely allocates on the heap or allocates larger objects.

Written by elseif from the cluster below · every claim links back to a source

The three things worth knowing

01

Go 1.27 introduces dedicated allocation functions for heap objects under 80 bytes instead of routing through a single generic function.

02

Benchmarking shows a 1.8x speedup for 16-byte allocations with pointers, dropping from 9.5 ns to 5.5 ns per allocation.

03

The improvement only benefits components performing many small heap allocations and will not affect all Go software.

THE CLUSTER

Same story, 1 feed.

ORDERED BY FIRST SEEN
Daniel Lemire's blog Go 1.27 will make some allocations cheaper Open ↗