test/lib-test/jdk/test/whitebox/CPUInfoTest.java fails on Intel Alder/Raptor Lake

Kosta Stojiljkovic kostasto at proton.me
Wed Mar 15 08:19:47 UTC 2023


Hi Tobias,

Thank you for the correction and for creating the issue in the bug tracker.

I do intend to work on the fix.

Best,
Kosta

------- Original Message -------
On Wednesday, March 15th, 2023 at 8:49 AM, Tobias Hartmann <tobias.hartmann at oracle.com> wrote:


> Hi Kosta,
> 
> Welcome to OpenJDK and thanks for reporting this issue! I was able to reproduce it and filed:
> https://bugs.openjdk.org/browse/JDK-8304242
> 
> Just a minor correction: Support was not added by JDK-8284161 but JDK-8264543.
> 
> Do you intend to work on the fix?
> 
> Best regards,
> Tobias
> 
> On 14.03.23 16:59, Kosta Stojiljkovic wrote:
> 
> > Dear all,
> > 
> > On a machine with the 13th gen Intel CPU, WhiteBox test in the file CPUInfoTest.java fails.
> > 
> > The test in question checks the features returned from the CPUInfo class against a hardcoded set of
> > well known CPU features inside the test, that looks like this:
> > 
> > wellKnownCPUFeatures = Set.of( "cx8", "cmov", "fxsr", "ht", "mmx", "3dnowpref", "sse", "sse2",
> > "sse3", "ssse3", "sse4a", "sse4.1", "sse4.2", "popcnt", "lzcnt", "tsc", "tscinvbit", "tscinv",
> > "avx", "avx2", "aes", "erms", "clmul", "bmi1", "bmi2", "rtm", "adx", "avx512f", "avx512dq",
> > "avx512pf", "avx512er", "avx512cd", "avx512bw", "avx512vl", "sha", "fma", "vzeroupper",
> > "avx512_vpopcntdq", "avx512_vpclmulqdq", "avx512_vaes", "avx512_vnni", "clflush", "clflushopt",
> > "clwb", "avx512_vbmi2", "avx512_vbmi", "rdtscp", "rdpid", "hv", "fsrm", "avx512_bitalg", "gfni",
> > "f16c", "pku", "ospke", "cet_ibt", "cet_ss", "avx512_ifma");
> > 
> > This set of strings on the other hand does not account for the SERIALIZE instruction, added in the
> > 12th generation of Intel Core processors (codenamed Alder Lake), while the processor inspection
> > implementation in /src/hotspot/cpu/x86/vm_version_x86.cpp picks up the flag for it, thus leading to
> > a discrepancy between the features set in the test and the features string obtained from CPUInfo
> > class, when ran on the 12th gen processors and higher.
> > 
> > The support for this feature seems to have been added to the code base with the following commit:
> > 8284161: Implementation of Virtual Thread
> > https://github.com/openjdk/jdk/commit/9583e3657e43cc1c6f2101a64534564db2a9bd84, but the authors
> > may have missed adding the "serialize" string to the set of well known CPU features in the
> > CPUInfoTest.java file.
> > 
> > I would like to extend the wellKnownCPUFeatures set with the "serialize" keyword, unless there is a
> > reason that this keyword is missing that I do not see?
> > 
> > If that isn't the case, I would appreciate getting some support with creating an issue in JBS, since
> > I am not an author yet :)
> > 
> > I look forward to your feedback!
> > 
> > Best Regards,
> > Kosta Stojiljkovic


More information about the hotspot-compiler-dev mailing list