@@ -73,6 +73,7 @@ const (
7373 AVX512BW // AVX-512 Byte and Word Instructions
7474 AVX512VL // AVX-512 Vector Length Extensions
7575 AVX512VBMI // AVX-512 Vector Bit Manipulation Instructions
76+ AVX512VNNI // AVX-512 Vector Neural Network Instructions
7677 MPX // Intel MPX (Memory Protection Extensions)
7778 ERMS // Enhanced REP MOVSB/STOSB
7879 RDTSCP // RDTSCP Instruction
@@ -131,6 +132,7 @@ var flagNames = map[Flags]string{
131132 AVX512BW : "AVX512BW" , // AVX-512 Byte and Word Instructions
132133 AVX512VL : "AVX512VL" , // AVX-512 Vector Length Extensions
133134 AVX512VBMI : "AVX512VBMI" , // AVX-512 Vector Bit Manipulation Instructions
135+ AVX512VNNI : "AVX512VNNI" , // AVX-512 Vector Neural Network Instructions
134136 MPX : "MPX" , // Intel MPX (Memory Protection Extensions)
135137 ERMS : "ERMS" , // Enhanced REP MOVSB/STOSB
136138 RDTSCP : "RDTSCP" , // RDTSCP Instruction
@@ -440,6 +442,11 @@ func (c CPUInfo) AVX512VBMI() bool {
440442 return c .Features & AVX512VBMI != 0
441443}
442444
445+ // AVX512VNNI indicates support of AVX-512 Vector Neural Network Instructions
446+ func (c CPUInfo ) AVX512VNNI () bool {
447+ return c .Features & AVX512VNNI != 0
448+ }
449+
443450// MPX indicates support of Intel MPX (Memory Protection Extensions)
444451func (c CPUInfo ) MPX () bool {
445452 return c .Features & MPX != 0
@@ -955,6 +962,9 @@ func support() Flags {
955962 if ecx & (1 << 1 ) != 0 {
956963 rval |= AVX512VBMI
957964 }
965+ if ecx & (1 << 11 ) != 0 {
966+ rval |= AVX512VNNI
967+ }
958968 }
959969 }
960970 }
0 commit comments