Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

compiler/rtm/locking/ tests have different include/exclude behaviours on different ppc64le machines #2896

Open
sophia-guo opened this issue Jan 24, 2023 · 8 comments
Assignees

Comments

@sophia-guo
Copy link

sophia-guo commented Jan 24, 2023

Using hotspot_custom target run tests under compiler/rtm/locking/* will get no test selected error on test-osuosl-ubuntu1804-ppc64le-2 and tests selected either pass or fail on test-skytap-ubuntu2004-ppc64le-1.

Those tests required @requires vm.rtm.cpu & vm.rtm.compiler, which can be set by https://github.com/adoptium/jdk19u/blob/master/test/jtreg-ext/requires/VMProps.java. This different behavior can make jvm_compiler target has different testcases number. Running on test-osuosl-ubuntu1804-ppc64le-2 testcase is 1073 and run on test-skytap-ubuntu2004-ppc64le-1 testcase is 1091. Same with jdk11 https://ci.adoptopenjdk.net/job/Test_openjdk11_hs_extended.openjdk_ppc64le_linux_testList_0/78/testReport/
https://ci.adoptopenjdk.net/job/Test_openjdk11_hs_extended.openjdk_ppc64le_linux_testList_1/86/testReport/
and jdk17:
https://ci.adoptopenjdk.net/job/Test_openjdk17_hs_extended.openjdk_ppc64le_linux_testList_1/81/testReport/
https://ci.adoptopenjdk.net/job/Test_openjdk17_hs_extended.openjdk_ppc64le_linux_testList_1/79/testReport/

This might be a infra issue, need infra's invesitigation.

@sophia-guo
Copy link
Author

Trying compiler/allocation/ it works. Needs more investigation, but not related with hotspot_custom target.

@sophia-guo sophia-guo self-assigned this Jan 25, 2023
@sophia-guo sophia-guo changed the title hotspot_custom doesn't work? compiler/rtm/locking/ tests have different include/exclude behaviours on different ppc64le machines Jan 25, 2023
@sophia-guo sophia-guo reopened this Jan 25, 2023
@sophia-guo sophia-guo transferred this issue from adoptium/aqa-tests Jan 26, 2023
@sophia-guo
Copy link
Author

Using openjdk test code got vm properties file.
propertiesOSUOSL.txt
propertiesSkype.txt

with cpu features
[email protected] (OSUOSL) : vm.cpu.features:[ppc64, fsqrt, isel, lxarxeh, cmpb, popcntb, popcntw, fcfids, vand, lqarx, aes, vpmsumb, mfdscr, vsx, ldbrx, stdbrx, sha]
[email protected] (Skytap) : vm.cpu.features:[ppc64, fsqrt, isel, lxarxeh, cmpb, popcntb, popcntw, fcfids, vand, lqarx, aes, vpmsumb, mfdscr, vsx, ldbrx, stdbrx, sha, rtm, darn]

The main difference is skype has rtm and osuosl doesn't.

cat /proc/cpuinfo shows flags missing from /proc/cpuinfo. Other command need root with sudo permission. But I don't think its necessary. It shows clearly that Skytap and OSUOSL has different cpu features. That is test results may be different with different failing or passing test case number. When tests fail may need to rerun or debug on the specific machines with feature enabled. It's not a configuration issue nor test bugs. Close this one.

However if those features could be set as machine labels that would be helpful. May be new features for infra? @sxa

@sophia-guo
Copy link
Author

adoptium/aqa-tests#4290 (comment)

Maybe the [email protected] (Skytap) rtm feature is wrong? cat /proc/cpuinfo shows flags missing from /proc/cpuinfo other command need sudo permission. @sxa could I get the root permission or could you double check if 20.61.136.210 (Skytap) support rtm?

@sxa
Copy link
Member

sxa commented Feb 6, 2023

What are the commands you need the output of? /proc/cpuinfo output should not be different when running as root and non-root. From the earlier comment it looks like you managed to see that the skytap machine had an rtm flag, so can you clarify what's needed please?

@sophia-guo
Copy link
Author

Yes, using the jdk jtreg extension code ( native WB_GetCPUFeatures) can see that skytap machine has a rtm flag. I'd like to get that flags information directly by command to double confirm it is true. But i cannot get that information from /proc/cpuinfo, which has no flags information at all. That is different from other linux platforms.

I'm asking if you could use the root | sudo permission to try other command to get cpu features of skytap as i tried some commands which asks for sudo permission. Or if you could guide me to get cpu features of skytap by command directly?

@zzambers
Copy link

zzambers commented Feb 6, 2023

@sophia-guo I also dug a bit into this and current code in hotspot uses getauxval to detect support for transactional memory (See: [1]).

Btw, on ppc this feature seems to be referred as HTM [2] (Hardware Transactional Memory), while RTM (Restricted Transactional Memory) is Intel terminology [3]. Nevertheless JDK internally refers to both as RTM (which adds some confusion).

[1] https://github.com/openjdk/jdk/blob/05ea083b0563ddacf3e38dc329ba00dc4bac9b29/src/hotspot/cpu/ppc/vm_version_ppc.cpp#L683
[2] https://docs.kernel.org/powerpc/transactional_memory.html
[3] https://www.intel.com/content/www/us/en/develop/documentation/cpp-compiler-developer-guide-and-reference/top/compiler-reference/intrinsics/intrinsics-for-avx2/intrinsics-for-tsx/intrinsics-for-restrict-transactional-mem-ops/restricted-transactional-memory-overview.html

@sxa
Copy link
Member

sxa commented Feb 8, 2023

Yes, using the jdk jtreg extension code ( native WB_GetCPUFeatures) can see that skytap machine has a rtm flag. I'd like to get that flags information directly by command to double confirm it is true. But i cannot get that information from /proc/cpuinfo, which has no flags information at all. That is different from other linux platforms.

I'm asking if you could use the root | sudo permission to try other command to get cpu features of skytap as i tried some commands which asks for sudo permission. Or if you could guide me to get cpu features of skytap by command directly?

Which commands asked for the elevated access? If I know what they are I can run them for you.

@sxa
Copy link
Member

sxa commented Feb 8, 2023

(Also, did you mean to close this issue since it seems like it's still unresolved?)

@sophia-guo sophia-guo reopened this Feb 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Status: Done
Development

No branches or pull requests

3 participants