← All releases

go1.5.0

Major

August 19, 2015

Go 1.5 is a major implementation overhaul: the compiler and runtime are now written in Go instead of C, GC pauses are drastically shorter via a new concurrent collector, and GOMAXPROCS defaults to all CPU cores instead of 1. Language compatibility is preserved, but scheduling-order and multicore-default changes can affect existing programs, and builds are about 2x slower.

highlights
  • Compiler, linker, and assembler are now written in Go (not C); tools renamed to go tool compile/asm/link and old 6g/8g-style binaries and .6/.8 object suffixes are gone (now .o)

  • New concurrent garbage collector dramatically cuts pause times, with stop-the-world pauses almost always under 10ms

  • GOMAXPROCS now defaults to the number of available CPU cores instead of 1, which can change behavior of programs assuming single-threaded execution

  • Goroutine scheduling order has changed; code that implicitly depended on the old order may break

  • Internal package rules (directories named internal) now apply to all repositories, not just the Go core

  • Experimental vendoring support added to the go command for managing external dependencies

  • New go tool trace command for execution tracing, and a new go doc command for command-line-friendly documentation lookup

  • Language tweak: map literals can now elide the element type, matching existing slice literal behavior

  • New math/big.Float type provides arbitrary-precision floating-point arithmetic with IEEE-754-compatible rounding

  • Native Go DNS resolver now used by default on most Unix systems, avoiding cgo and reducing per-lookup OS thread usage (netgo/netcgo tags still available)

  • Reduced official binary downloads (e.g. darwin/386 and dragonfly/386 dropped) but new ports added: darwin/arm, darwin/arm64, linux/arm64, and experimental ppc64/ppc64le

  • Full builds are roughly 2x slower than Go 1.4 due to the C-to-Go translated compiler/linker code, pending further optimization