CPUID: Fix TBM detection (ticket #2211)

This commit is contained in:
zzz committed 2018-04-14 12:55:50 +00:00
1 parent abec6ad64c
commit 98aafee53a
2 files changed
+5 -3

No files matched your search

@@ -99,12 +99,13 @@ class CPUIDCPUInfo implements CPUInfo
}
/**
* Trailing Bit Manipulation (AMD feature)
* @return true iff the CPU supports TBM.
* @since 0.9.26
* @since 0.9.26, broken before 0.9.35, fixed in 0.9.35
*/
public boolean hasTBM()
{
return (CPUID.getECXCPUFlags() & (1 << 21)) != 0; //ECX Bit 21
return (CPUID.getExtendedECXCPUFlags() & (1 << 21)) != 0; //Extended ECX Bit 21
}
/**
@@ -109,8 +109,9 @@ public interface CPUInfo
public boolean hasADX();
/**
* Trailing Bit Manipulation (AMD feature)
* @return true iff the CPU supports TBM.
* @since 0.9.26
* @since 0.9.26, broken before 0.9.35, fixed in 0.9.35
*/
public boolean hasTBM();