int VM_Version::get_current_sve_vector_length() {
assert(VM_Version::supports_sve(), "should not call this");
return prctl(PR_SVE_GET_VL);
}
This seems to be unintended, because the caller checks whether the call fails, and automatically disables SVE use, i.e.
if (UseSVE > 0) {
int vl = get_current_sve_vector_length(); // Fails here.
if (vl < 0) { // Checks here.
warning("Unable to get SVE vector length on this system. "
"Disabling SVE. Specify -XX:UseSVE=0 to shun this warning.");
FLAG_SET_DEFAULT(UseSVE, 0);
If the assert() were intentional, the whole check after the call would not make sense.
Can be reproduced using a VM emulating Apple processors.
May either be a wrong assert, or wrong detection of SVE(2).
- caused by
-
JDK-8284563 AArch64: bitperm feature detection for SVE2 on Linux
-
- Resolved
-