// Code generated by 'simdgen -o godefs -goroot $GOROOT -arch amd64 -xedPath $XED_PATH go_amd64.yaml types.yaml categories.yaml'; DO NOT EDIT. //go:build goexperiment.simd package archsimd import "internal/cpu" // AVX2AES returns whether the CPU supports AES operations on 256-bit vectors. // // This corresponds to the AVX2, VAES, and AES CPUID features. // // If it returns true, then the CPU also supports AVX, AVX2, and AVXAES. // // AVX2AES is defined on all GOARCHes, but will only return true on // GOARCH amd64. func (X86Features) AVX2AES() bool { return cpu.X86.HasAVX2 && cpu.X86.HasVAES && cpu.X86.HasAES } // AVX512AES returns whether the CPU supports AES operations on 512-bit vectors. // // This corresponds to the AVX512F, AVX512CD, AVX512BW, AVX512DQ, AVX512VL, VAES, and AES CPUID features. // // If it returns true, then the CPU also supports AVX, AVX2, AVX512, AVXAES, and AVX2AES. // // AVX512AES is defined on all GOARCHes, but will only return true on // GOARCH amd64. func (X86Features) AVX512AES() bool { return cpu.X86.HasAVX512 && cpu.X86.HasVAES && cpu.X86.HasAES } // AVX512GFNI returns whether the CPU supports the AVX512GFNI feature. // // If it returns true, then the CPU also supports AVX, AVX2, and AVX512. // // AVX512GFNI is defined on all GOARCHes, but will only return true on // GOARCH amd64. func (X86Features) AVX512GFNI() bool { return cpu.X86.HasAVX512GFNI } // AVX512VNNI returns whether the CPU supports the AVX512VNNI feature. // // If it returns true, then the CPU also supports AVX, AVX2, and AVX512. // // AVX512VNNI is defined on all GOARCHes, but will only return true on // GOARCH amd64. func (X86Features) AVX512VNNI() bool { return cpu.X86.HasAVX512VNNI } // AVXAES returns whether the CPU supports AES operations on 128-bit vectors. // // This corresponds to the AVX and AES CPUID features. // // If it returns true, then the CPU also supports AVX. // // AVXAES is defined on all GOARCHes, but will only return true on // GOARCH amd64. func (X86Features) AVXAES() bool { return cpu.X86.HasAVX && cpu.X86.HasAES } // AVXVNNI returns whether the CPU supports the AVXVNNI feature. // // If it returns true, then the CPU also supports AVX and AVX2. // // AVXVNNI is defined on all GOARCHes, but will only return true on // GOARCH amd64. func (X86Features) AVXVNNI() bool { return cpu.X86.HasAVXVNNI } // SHA returns whether the CPU supports the SHA feature. // // SHA is defined on all GOARCHes, but will only return true on // GOARCH amd64. func (X86Features) SHA() bool { return cpu.X86.HasSHA }