Skip to content

Tag

#Go runtime 3 posts

Go · Concepts

Why Go's append Changes the OriginalInside Slices, Maps, and Strings

The Go bugs I keep hitting come from holding something different from what I think I'm holding. A slice is a window, not data. A map doesn't guarantee addresses. A string isn't a character array. This post opens up the layout of all three.

Go · Concepts

The Go Interface nil TrapWhy err != nil Is True

You return a nil pointer and err != nil comes out true, because an interface value has two slots: a type and the data. From that two-slot layout to method sets, where interfaces should live, and the cost of dynamic dispatch.

Go · Concepts

How Static Typing and Compilation Affect Runtime Performance (Through Go)

Following how compiled, statically typed code turns into runtime wins, using Go: memory layout, compiler optimizations, escape analysis, the GC, and the scheduler, each checked with tools.

esc

Recent posts

↑↓ move↵ openOpen search page ›