Skip to content

Commit

Permalink
remove hasAMX flag
Browse files Browse the repository at this point in the history
  • Loading branch information
anton-kuklin committed Aug 10, 2023
1 parent 7ee8ef4 commit a243dce
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
1 change: 0 additions & 1 deletion cpu/cpu.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ var X86 struct {
HasAVX512VBMI2 bool // Advanced vector extension 512 Vector Byte Manipulation Instructions 2
HasAVX512BITALG bool // Advanced vector extension 512 Bit Algorithms
HasAVX512BF16 bool // Advanced vector extension 512 BFloat16 Instructions
HasAMX bool // Advanced Matrix Extension
HasAMXTile bool // Advanced Matrix Extension Tile instructions
HasAMXInt8 bool // Advanced Matrix Extension Int8 instructions
HasAMXBF16 bool // Advanced Matrix Extension BFloat16 instructions
Expand Down
9 changes: 3 additions & 6 deletions cpu/cpu_x86.go
Original file line number Diff line number Diff line change
Expand Up @@ -143,12 +143,9 @@ func archInit() {
X86.HasAVX512BF16 = isSet(5, eax71)
}

X86.HasAMX = isSet(24, edx7)
if X86.HasAMX {
X86.HasAMXTile = true
X86.HasAMXInt8 = isSet(25, edx7)
X86.HasAMXBF16 = isSet(22, edx7)
}
X86.HasAMXTile = isSet(24, edx7)
X86.HasAMXInt8 = isSet(25, edx7)
X86.HasAMXBF16 = isSet(22, edx7)
}

func isSet(bitpos uint, value uint32) bool {
Expand Down

0 comments on commit a243dce

Please sign in to comment.