Skip to content

(0.44) Refactor virtual thread inspector access #19229

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 1 commit into from
Mar 26, 2024

Conversation

fengxue-IS
Copy link
Contributor

  • Fix getVMThread API to account for suspended virtual thread under transition
  • Refactor acquire/releaseVThreadInspector to handle suspended transition cases
  • Add wait loop in exitTransition, link J9VMThread to vthread object during transition
  • Introduce constant flags and common helper API
  • Convert jvmti API c file to cpp jvmtiForceEarlyReturn.c -> .cpp jvmtiLocalVariable.c -> .cpp jvmtiStackFrame.c -> .cpp

back port of #19076

- Fix getVMThread API to account for suspended virtual thread
  under transition
- Refactor acquire/releaseVThreadInspector to handle
  suspended transition cases
- Add wait loop in exitTransition, link J9VMThread to vthread object
  during transition
- Introduce constant flags and common helper API
- Convert jvmti API c file to cpp
    jvmtiForceEarlyReturn.c -> .cpp
    jvmtiLocalVariable.c -> .cpp
    jvmtiStackFrame.c -> .cpp

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

Note #19186 in not included in this backport as #18989 have only been added to JDK22+
Personal build in progress
FYI @babsingh @pshipton

@babsingh
Copy link
Contributor

babsingh commented Mar 26, 2024

Note #19186 in not included in this backport as #18989 have only been added to JDK22+

#19186 needs to be included in this backport. #19186 has #if JAVA_SPEC_VERSION >= 19 around the changes. The virtual thread interrupt functionality is implemented for JDK19+. Only the VirtualThread interrupt test (GetThreadStateMountedTest) was added in JDK22+. A JDK21 user will experience similar issues reported in #19203.

@pshipton
Copy link
Member

Babneet will create another PR for #18989 and #19186

@pshipton pshipton merged commit afb3132 into eclipse-openj9:v0.44.0-release Mar 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants