-
Notifications
You must be signed in to change notification settings - Fork 721
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
Retain Continuation.vthread until the J9VMContinuation is freed #18251
Merged
tajila
merged 1 commit into
eclipse-openj9:master
from
babsingh:fix_getthreadobjectforcontinuation
Oct 13, 2023
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Retain Continuation.vthread until the J9VMContinuation is freed
This PR is needed to enable the Skynet benchmark. The changes in #18180 pass threadObject to walkContinuationStackFrames. The GC can walk the continuations until the associated native J9VMContinuation structure is freed. Since we rely on Continuation.vthread in walkContinuationStackFrames, Continuation.vthread can only be unset once the native continuation structure is freed. Now, we set Continuation.vthread to NULL after the continuation is freed. This will prevent a segfault which can occur due to #18180. Continuation.vthread is also used in JVMTI to not suspend virtual threads once they enter the last unmount phase. This won't work anymore because Continuation.vthread is no longer set to NULL at the start of the last unmount phase. To address this issue, another continuation state has been added to indicate that a virtual thread's continuation has entered the last unmount phase. Signed-off-by: Babneet Singh <sbabneet@ca.ibm.com>
- Loading branch information
commit e64ca0005793b25306bc9f7437b91a54f9d487fa
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@fengxue-IS This source code is in C; we can't invoke C++ code from
ContinuationHelpers.hpp
here; so, I have employed a workaround.