Skip to content

(v0.51.0) Support JEP491 in VM code path #21308

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

Merged
merged 4 commits into from
Mar 11, 2025

Conversation

fengxue-IS
Copy link
Contributor

pack port of #21273 and #21292

fengxue-IS and others added 4 commits March 7, 2025 13:38
Update Continuation.Pinned enum
Add field refs in vmconstantpool.xml
add helper to update monitor info
add enterObjectMonitor intercept
Add support for Object.wait/notify()
Add reverse link between J9VMContinuation and vthread & remove Object ref in J9ObjectMonitor
Move JVM_TakeVirtualThreadListToUnblock code into helper
Rename XX:YieldPinnedContinuation to XX:YieldPinnedVirtualThreads

Co-authored-by: Jack Lu <[email protected]>
Co-authored-by: Babneet Singh <[email protected]>
Co-authored-by: Keith W. Campbell <[email protected]>
Move enter/exitVThreadTransitionCritical to ContinuationHelpers.hpp
Enter critical before yielding a pinned vthread
Exit critical after vthread re-entry from a pinned state (not vthread.yield)

Co-authored-by: Babneet Singh <[email protected]>
Co-authored-by: Jack Lu <[email protected]>
Correctly handle the waiting object during detach/attach.
Use vthread.notified field to indicate status.
Prevent vthreads in transition to be returned as unblocked.

Co-authored-by: Babneet Singh <[email protected]>
Signed-off-by: Jack Lu <[email protected]>
Update isPinnedImpl to ignore ownedMonitorCount when trying to yield.
Handle the detach/attach when yielding vthread holds monitors.

Signed-off-by: Jack Lu <[email protected]>
@babsingh
Copy link
Contributor

#21292 was merged yesterday. We should wait for tonight's nightly builds to pass before backporting these changes to the 0.51 release. If any issues arise, we will need to revert changes in two places.

@babsingh babsingh marked this pull request as ready for review March 11, 2025 18:58
@babsingh babsingh merged commit 1e89c7e into eclipse-openj9:v0.51.0-release Mar 11, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants