← All releases

go1.3.0

Major

June 19, 2014

Go 1.3 adds no language changes but delivers major implementation work: precise stack garbage collection, contiguous goroutine stacks, a refactored compiler/linker for faster builds, broad performance gains, new experimental OS/arch support, and a couple of behavior-breaking fixes (crypto/tls verification, cgo struct pointers, map iteration order).

highlights
  • No language changes; this release is entirely about runtime, compiler, and toolchain work.

  • Goroutine stacks switched from segmented to contiguous, removing the old stack-split performance hot spot.

  • Garbage collection is now precise on stack values (not just heap); misusing unsafe.Pointer to store integers as pointers is now illegal and can crash at runtime.

  • GC pause times cut roughly 50-70% via a concurrent sweep algorithm, better parallelization, and larger pages.

  • New experimental platform support: DragonFly BSD, Solaris (illumos/Solaris 11+), Plan 9, and revived Native Client (NaCl); Windows 2000 support dropped.

  • Minimum OS version bumps: FreeBSD now needs kernel COMPAT_FREEBSD32 and effectively FreeBSD 10 on ARM, NetBSD 6.0+, OpenBSD 5.5+.

  • Small map iteration order is randomized again, breaking Go 1.1/1.2 code that accidentally relied on a fixed order for maps with 8 or fewer entries.

  • Compiler and linker refactored with a new shared liblink component, moving instruction selection into the compiler for notably faster builds on large projects.

  • crypto/tls now requires ServerName or InsecureSkipVerify to be set and enforces ServerName, closing a bug that could silently skip certificate verification.

  • New sync.Pool type added for building caches whose contents can be reclaimed automatically by the GC.

  • go command changes: go test always builds a package even with no test files, go build gains -i to install dependencies, go run/go test gain -exec, and cgo cross-compiling is now supported.

  • cgo now gives distinct named Go types to different incomplete C struct types, fixing a bug but breaking code that passed opaque C pointers (e.g. *C.FILE) across package boundaries; SWIG 3.0 is now required.