Go 1.20 Released With Preview PGO Support, CPU Architecture Feature Build Flags
Google has released a new version of the Go programming language that with today's v1.20 release come a number of notable additions as well as gutting out support for older versions of Microsoft Windows and Apple macOS. Two features alone have me excited about Go 1.20: initial work on CPU architecture feature build flags like for x86_64 micro-architecture feature level handling and initial support for Profile Guided Optimizations (PGO) builds.
In addition to some subtle changes and additions to the Go programming language, some of the other platform and tooling work with Go 1.20 includes:
- Go 1.20 is the last release supporting Microsoft Windows 7 / 8 / Server 200 8 / Server 2012. With Go 1.21, Windows 10 or Windows Server 2016 is the new minimum baseline.
- Go 1.20 is also dropping support for macOS 10.13 and 10.14 series.
- Experimental support for FreeBSD on RISC-V is introduced.
- The $GOROOT/pkg directory no longer stores pre-compiled package archives for the standard archive in order to reduce the size of the Go distribution.
- The go command now defines architecture feature build flags, like amd64.V2, to allow selecting a package implementation file based on the presence or absence of particular CPU architecture features. This is great news for the x86_64 micro-architecture feature level work.
- The go build and go install and other build-related commands now supports a "-cover" flag for enabling a build with code coverage instrumentation.
- Memory overhead reduction and CPU performance improvements by up to 2% thanks to work on the garbage collector.
- Preview support for Profile Guided Optimizations (PGO).
- On Linux the linker now selects the dynamic interpreter for glibc or musl at link-time.
- A new crypto/ecdh package to provide explicit support for Elliptic Curve Diffie-Hellman key exchanges over NIST curves and Curve25519.
Downloads and more details on the Go 1.20 release via go.dev.
In addition to some subtle changes and additions to the Go programming language, some of the other platform and tooling work with Go 1.20 includes:
- Go 1.20 is the last release supporting Microsoft Windows 7 / 8 / Server 200 8 / Server 2012. With Go 1.21, Windows 10 or Windows Server 2016 is the new minimum baseline.
- Go 1.20 is also dropping support for macOS 10.13 and 10.14 series.
- Experimental support for FreeBSD on RISC-V is introduced.
- The $GOROOT/pkg directory no longer stores pre-compiled package archives for the standard archive in order to reduce the size of the Go distribution.
- The go command now defines architecture feature build flags, like amd64.V2, to allow selecting a package implementation file based on the presence or absence of particular CPU architecture features. This is great news for the x86_64 micro-architecture feature level work.
- The go build and go install and other build-related commands now supports a "-cover" flag for enabling a build with code coverage instrumentation.
- Memory overhead reduction and CPU performance improvements by up to 2% thanks to work on the garbage collector.
- Preview support for Profile Guided Optimizations (PGO).
- On Linux the linker now selects the dynamic interpreter for glibc or musl at link-time.
- A new crypto/ecdh package to provide explicit support for Elliptic Curve Diffie-Hellman key exchanges over NIST curves and Curve25519.
Downloads and more details on the Go 1.20 release via go.dev.
1 Comment