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

OpenJDK java/lang/ref/PhantomReferentClearing - P2 not notified by O2 deletion #18340

Open
pshipton opened this issue Oct 24, 2023 · 5 comments

Comments

@pshipton
Copy link
Member

https://openj9-jenkins.osuosl.org/job/Test_openjdk21_j9_sanity.openjdk_s390x_linux_Nightly_testList_0/82/
jdk_lang_0
java/lang/ref/PhantomReferentClearing.java

18:53:52  java.lang.RuntimeException: P2 not notified by O2 deletion
18:53:52  	at PhantomReferentClearing.main(PhantomReferentClearing.java:98)
18:53:52  	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
18:53:52  	at java.base/java.lang.reflect.Method.invoke(Method.java:580)
18:53:52  	at com.sun.javatest.regtest.agent.MainWrapper$MainTask.run(MainWrapper.java:138)
18:53:52  	at java.base/java.lang.Thread.run(Thread.java:1595)
@pshipton
Copy link
Member Author

@dmitripivkine fyi

@pshipton pshipton changed the title OpenJDK java/lang/ref/PhantomReferentClearing OpenJDK java/lang/ref/PhantomReferentClearing - P2 not notified by O2 deletion Oct 24, 2023
@dmitripivkine
Copy link
Contributor

Looking to the test source code I guess 1s timeout has not been long enough to execute Finalization (and this is s390, it is not a first time). If it is reproducible and somebody helps me to generate system core for this exception we can figure out exact reason.
https://programtalk.com/vs/?source=openjdk/jdk/test/java/lang/ref/PhantomReferentClearing.java

@dmitripivkine
Copy link
Contributor

Hm, #18044 introduced implicit "Run Finalization" to System GC call. So, it should work, probably not a timeout issue.

@dmitripivkine
Copy link
Contributor

Another theoretical possibility is reference to O2 might be stored in O-slot for higher level of hotness for JITed method. It keep O2 alive even after O2 = null;.

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

No branches or pull requests

2 participants