RFR: 8350903: Remove explicit libjvm.so dependency for libVThreadEventTest
    Jiangli Zhou 
    jiangli at openjdk.org
       
    Fri Feb 28 01:45:34 UTC 2025
    
    
  
Please review the test fix that removes `libVThreadEventTest` explicit dependency to `libjvm`, by removing the call to `JNI_GetCreatedJavaVMs` in `Agent_OnAttach`. There is a `vm` argument passed via `Agent_OnAttach`. With the change, `libVThreadEventTest` no longer needs to be linked with `libjvm.so` (or `jvm.dll`). `VThreadEventTest.java` now runs on both dynamic and static JDK.
Tested on static JDK locally
GHA: https://github.com/jianglizhou/jdk/actions/runs/13577993687/job/37960245161
-------------
Commit messages:
 - Remove unused `nVMs` variable.
 - Remove JNI_GetCreatedJavaVMs call.
Changes: https://git.openjdk.org/jdk/pull/23835/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=23835&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8350903
  Stats: 10 lines in 2 files changed: 0 ins; 9 del; 1 mod
  Patch: https://git.openjdk.org/jdk/pull/23835.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/23835/head:pull/23835
PR: https://git.openjdk.org/jdk/pull/23835
    
    
More information about the serviceability-dev
mailing list