Skip to content
go.dev·

💡Go 1.26 and 1.27 Add Experimental SIMD APIs

Go now has native SIMD support for faster data crunching

TL;DR

Go 1.26 and 1.27 introduce experimental SIMD APIs, enabling faster data processing and computation. This is a big deal for developers working on computationally-intensive tasks like cryptography and AI.

Go 1.26 and 1.27 introduce experimental SIMD APIs, allowing developers to leverage the native SIMD capabilities of modern CPUs for faster data processing and computation. This is a big deal for anyone working on computationally-intensive tasks like cryptography, data processing, and AI. The new APIs support various platforms including amd64, arm64, and wasm, with specific instruction sets like AVX, AVX2, and NEON. The APIs aim to provide a consistent interface across platforms, hiding differences in vector sizes and instruction sets.

Key Points

1

Go 1.26 and 1.27 introduce experimental SIMD APIs for amd64, arm64, and wasm platforms.

2

The APIs support AVX, AVX2, and AVX512 on amd64, NEON on arm64, and wasm's SIMD instructions.

3

Go's new SIMD package supports vectors of 128, 256, and 512 bits on amd64, and 128 and 256 bits on loong64.

4

The package supports masked loads and stores on AVX, AVX2, AVX512, NEON, and wasm.

5

The package includes arithmetic operations, vector masking, loading and storing vectors, and reducing vectors.

Why It Matters

If you're working on computationally-intensive tasks like cryptography or AI in Go, the new SIMD APIs can significantly speed up your code. For example, a Go crypto library using SIMD can see up to 37% faster performance. However, the APIs are experimental, so stability and full platform support are still evolving.

simdperformancegodata-processingai

Comments

Subscribe to join the conversation...

Be the first to comment

Enjoyed this article?

Get it daily. 7am. Free. Reads in 5 minutes.

Join 3,507 builders reading daily.

Also get