Files
abra/vendor/github.com/pjbgf/sha1cd/internal/cpu/cpu.go
T
renovate-bot 3819ee38f5
continuous-integration/drone/pr Build is passing
continuous-integration/drone/push Build is passing
chore(deps): update module github.com/go-git/go-git/v5 to v5.19.3
2026-10-04 15:02:06 +00:00

29 lines
854 B
Go
Generated

// Package cpu detects the CPU features that sha1cd dispatches on.
//
// It covers only what the assembly implementations need, which keeps
// start up cheap and avoids an external dependency. Every flag is false
// where a feature cannot be detected safely, which selects the generic
// implementation.
package cpu
// X86 holds the features of the current amd64 CPU. All flags are false on
// other architectures.
var X86 struct {
// HasAVX and HasAVX2 are set only when the OS also preserves the YMM
// state, and HasAVX512F only when it preserves the ZMM and opmask state.
HasAVX bool
HasAVX2 bool
HasAVX512F bool
HasBMI1 bool
HasBMI2 bool
HasSHA bool
HasSSSE3 bool
HasSSE41 bool
}
// ARM64 holds the features of the current arm64 CPU. All flags are false on
// other architectures.
var ARM64 struct {
HasSHA1 bool
}