[jdk25u-dev] RFR: 8373945: Use WB.fullGC() in ClassUnloader.unloadClass to force GC for vmTestbase tests

SendaoYan syan at openjdk.org
Thu Jan 29 07:47:35 UTC 2026


Hi all,

This backport PR contains JDK-8373945 and JDK-8375485. These two PR try to use WB.fullGC() in ClassUnloader.unloadClass to force GC for vmTestbase tests, which will make test more robustness and run more quickly. Some of the tests touched by '8260555: Change the default TIMEOUT_FACTOR from 4 to 1' make this backport uncleanly, and only below 5 files backported uncleanly because of the diffrent copyright year. All other parts are cleanly.

Change has been verifed locally on linux-x64 by run all the releated tests. Test-fix only, no risk.

test/hotspot/jtreg/vmTestbase/gc/gctests/LargeObjects/large001/large001.java
test/hotspot/jtreg/vmTestbase/gc/gctests/LargeObjects/large002/TestDescription.java
test/hotspot/jtreg/vmTestbase/gc/gctests/LargeObjects/large003/TestDescription.java
test/hotspot/jtreg/vmTestbase/gc/gctests/LargeObjects/large004/TestDescription.java
test/hotspot/jtreg/vmTestbase/gc/gctests/LargeObjects/large005/TestDescription.java

Related tests list:

[199.log](https://github.com/user-attachments/files/24930289/199.log)

-------------

Commit messages:
 - 8375485: Tests in vmTestbase/nsk are failing due to missing class unloading after 8373945
 - Backport ce5e0d8a48296b51c9c2eff4867e2a9a70194091

Changes: https://git.openjdk.org/jdk25u-dev/pull/199/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk25u-dev&pr=199&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8373945
  Stats: 457 lines in 63 files changed: 236 ins; 101 del; 120 mod
  Patch: https://git.openjdk.org/jdk25u-dev/pull/199.diff
  Fetch: git fetch https://git.openjdk.org/jdk25u-dev.git pull/199/head:pull/199

PR: https://git.openjdk.org/jdk25u-dev/pull/199


More information about the jdk-updates-dev mailing list