On Mon, 22 Dec 2025 03:10:42 GMT, Chris Plummer <[email protected]> wrote:
>> It seems that, the references is non null at the first time. So it will not >> unload the classes actually, > > I understand that difference. What I meant is before it used to use > eatMemory() above to attempt to force class unloading (and you are correct, > there should be none) and then below it was using unloadClass(), which > essentially was the same as eatMemory(). I'm not sure why two different APIs > where use. I'm wondering if we should change the test to just always use > WB.fullGC() both here and below where the unloadClass() call. is being made. I have changed the test always use WhiteBox.fullGC() instead of call unloadClass(). This test has been verified locally, ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/28891#discussion_r2645091951
