mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
[dev.simd] internal/goexperiment: add SIMD goexperiment
We'll use it to guard the simd package, and the compiler's handling of SIMD types and intrinsics. Change-Id: I0356368eea0a98a5016baaaf7acb7da8b6305429 Reviewed-on: https://go-review.googlesource.com/c/go/+/675536 Reviewed-by: David Chase <drchase@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
This commit is contained in:
parent
3ac5f2f962
commit
4d2c71ebf9
3 changed files with 20 additions and 0 deletions
8
src/internal/goexperiment/exp_simd_off.go
Normal file
8
src/internal/goexperiment/exp_simd_off.go
Normal file
|
|
@ -0,0 +1,8 @@
|
||||||
|
// Code generated by mkconsts.go. DO NOT EDIT.
|
||||||
|
|
||||||
|
//go:build !goexperiment.simd
|
||||||
|
|
||||||
|
package goexperiment
|
||||||
|
|
||||||
|
const SIMD = false
|
||||||
|
const SIMDInt = 0
|
||||||
8
src/internal/goexperiment/exp_simd_on.go
Normal file
8
src/internal/goexperiment/exp_simd_on.go
Normal file
|
|
@ -0,0 +1,8 @@
|
||||||
|
// Code generated by mkconsts.go. DO NOT EDIT.
|
||||||
|
|
||||||
|
//go:build goexperiment.simd
|
||||||
|
|
||||||
|
package goexperiment
|
||||||
|
|
||||||
|
const SIMD = true
|
||||||
|
const SIMDInt = 1
|
||||||
|
|
@ -129,4 +129,8 @@ type Flags struct {
|
||||||
|
|
||||||
// GreenTeaGC enables the Green Tea GC implementation.
|
// GreenTeaGC enables the Green Tea GC implementation.
|
||||||
GreenTeaGC bool
|
GreenTeaGC bool
|
||||||
|
|
||||||
|
// SIMD enables the simd package and the compiler's handling
|
||||||
|
// of SIMD intrinsics.
|
||||||
|
SIMD bool
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue