Skip to content
Opensource internals
  • Posts

Go

How Go's select Picks a Random Ready Case (and Why the Order Is Random)

Oct 21, 2026 18 min read Jay Hubbert

Go’s select randomises the order it polls cases in, takes the first ready one, and only then falls back to parking on every channel at once.

GoInternalsConcurrencySelect

Read more →

How Go's Unicode Tables Are Generated and Why the Runtime Doesn't Use Them

Oct 21, 2026 25 min read Jay Hubbert

Go’s Unicode tables are generated range tables with stride compression, a 256-entry Latin-1 byte table for the fast path, and an accept-ranges decoder for UTF-8; the runtime …

GoInternalsUnicodeUtf 8Stdlib

Read more →

range over func: The Compiler Turns a Loop Into a Coroutine

Oct 21, 2026 20 min read Jay Hubbert

The compiler rewrites a range-over-func loop into a yield callback, tracks iterator misbehaviour with a state machine, and hands coroutine switching to iter.Pull.

GoInternalsIteratorsCompilerRuntime

Read more →

runtime.AddCleanup: How Go Replaced Finalizers With a Queue of Specials

Oct 21, 2026 19 min read Jay Hubbert

runtime.AddCleanup replaces SetFinalizer with span specials, a lock-free block queue and a pool of cleanup goroutines, so cleanups run promptly and in parallel instead of one at a …

GoInternalsGarbage collectionFinalizersRuntime

Read more →

sync.Map: Two Maps, A Miss Counter and Why Read-Mostly Wins

Oct 21, 2026 16 min read Jay Hubbert

sync.Map’s old read/dirty/misses design is gone: the type is now a wrapper around a 16-way hash trie whose reads take no locks at all, and whose doc still tells you to use it only …

GoInternalsSyncConcurrencyPerformance

Read more →

← Newer Page 11 of 12 Older →

© 2026 Jay Hubbert · Built with Hugo 0.168.0

RSS ·