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

jdk22 java/foreign/critical/TestCritical.java Heap segment not allowed #18939

Closed
pshipton opened this issue Feb 12, 2024 · 8 comments · Fixed by #18930
Closed

jdk22 java/foreign/critical/TestCritical.java Heap segment not allowed #18939

pshipton opened this issue Feb 12, 2024 · 8 comments · Fixed by #18930

Comments

@pshipton
Copy link
Member

pshipton commented Feb 12, 2024

https://openj9-jenkins.osuosl.org/job/Pipeline-Build-Test-JDK22/10/ - all platforms

https://openj9-jenkins.osuosl.org/job/Test_openjdk22_j9_sanity.openjdk_aarch64_linux_Nightly_testList_1/8/
https://openj9-jenkins.osuosl.org/job/Test_openjdk22_j9_sanity.openjdk_aarch64_linux_Nightly_testList_2/8/
jdk_foreign
java/foreign/critical/TestCritical.java

23:18:18  NativeTestHelper::DEFAULT_RANDOM.seed = -654531519
23:18:18  Re-run with '-DNativeTestHelper.DEFAULT_RANDOM.seed=-654531519' to reproduce
23:18:18  test TestCritical.testAllowHeap(TestCritical$AllowHeapCase@8bbe5efa): failure
23:18:18  java.lang.IllegalArgumentException: Heap segment not allowed: MemorySegment{ heapBase: [B@3c73a5d9, address: 0x0, byteSize: 10 }
23:18:18  	at java.base/openj9.internal.foreign.abi.UpcallMHMetaData.validateNativeArgRetSegmentOfPtr(UpcallMHMetaData.java:110)
23:18:18  	at java.base/openj9.internal.foreign.abi.InternalDowncallHandler.memSegmtOfPtrToLongArg(InternalDowncallHandler.java:214)
23:18:18  	at java.base/java.lang.invoke.MethodHandle.invokeWithArguments(MethodHandle.java:733)
23:18:18  	at TestCritical.testAllowHeap(TestCritical.java:119)

@ChengJin01 fyi

@ChengJin01
Copy link

The test failure is expected for JDK22 as the related functionality (passing the heap argument to native) will be covered by #18930.

@keithc-ca
Copy link
Contributor

Perhaps adoptium/aqa-tests#5052 was merged prematurely? Maybe it should have waited until #18930 was merged?

@ChengJin01
Copy link

ChengJin01 commented Feb 12, 2024

Perhaps adoptium/aqa-tests#5052 was merged prematurely? Maybe it should have waited until #18930 was merged?

We need to know how many issues are left to be addressed by enabling all FFI specific test suites in JDK22+ except the functionality specific issue with #18930.

@keithc-ca
Copy link
Contributor

Yes, but that can be done via grinders without sacrificing nightly and other builds.

@ChengJin01
Copy link

Yes, but that can be done via grinders without sacrificing nightly and other builds.

We can disable the failing test suites via https://github.com/adoptium/aqa-tests for the moment and re-enable one by one once we fix them up.

@pshipton, any input on this?

@pshipton
Copy link
Member Author

I agree, we should individually disable all the failing tests until they are fixed. Are you going to create the PR to do that?

@ChengJin01
Copy link

I agree, we should individually disable all the failing tests until they are fixed. Are you going to create the PR to do that?

Yes. Will do that later today.

@ChengJin01 ChengJin01 self-assigned this Feb 12, 2024
@ChengJin01
Copy link

ChengJin01 commented Feb 12, 2024

I just created a PR at adoptium/aqa-tests#5056 to disable all failing FFI test suites detected in JDK22+.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants