Intel AMX and feature detection
Robert Muir
rcmuir at gmail.com
Wed Jun 26 01:51:41 UTC 2024
On Tue, Jun 25, 2024 at 7:07 PM Daniel Lemire <daniel at lemire.me> wrote:
>
> If the CPU has AVX-512 VBMI2, then it is Ice Lake or better, or AMD Zen 4 or better, and then the downclocking should not be a concern.
>
> I would suggest you verify that the issues that have been reported still applies to a CPU with VBMI2.
There unfortunately isn't any way to detect VBMI2 from java though. It
is basically the problem of this thread.
Java VM knows the cpu flags and cpu family, but won't give up the
goods to users like us :)
In some cases java gives a "tell" by setting some default values
differently based upon cpu/family, and we currently infer such things
heuristically from that. Requires hunting through code such as
https://github.com/openjdk/jdk/blob/c66f785fb685d5c378fb4c4cdebdef29c01d321b/src/hotspot/cpu/x86/vm_version_x86.cpp#L1622-L1655
and figuring out what java flags might imply it. But I don't see any
jvm flags to check that imply VBMI2 at a glance.
Currently in lucene, we just avoid 512-bit integer multiply on x86
completely to prevent the issue.
More information about the panama-dev
mailing list