RFR: 8362482: [TESTBUG] serviceability/HeapDump/UnmountedVThreadNativeMethodAtTop.java: System.gc() does not provide full GC
Richard Reingruber
rrich at openjdk.org
Thu Jul 24 07:28:40 UTC 2025
On Thu, 17 Jul 2025 11:48:15 GMT, SendaoYan <syan at openjdk.org> wrote:
>> Call WhiteBox.fullGC() instead of System.gc() for a guaranteed full GC.
>> It is assumed that one full GC is sufficient for these tests.
>>
>> Testing was done with fastdebug and release builds on the main platforms and also on Linux/PPC64le and AIX.
>
> test/hotspot/jtreg/serviceability/HeapDump/UnmountedVThreadNativeMethodAtTop.java line 32:
>
>> 30: * @build jdk.test.whitebox.WhiteBox
>> 31: * @run driver jdk.test.lib.helpers.ClassFileInstaller jdk.test.whitebox.WhiteBox
>> 32: * @run junit/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI --enable-native-access=ALL-UNNAMED UnmountedVThreadNativeMethodAtTop
>
> Maybe use '@run junit/othervm/native' more better.
I guess that's better. Thanks for the hint. I wasn't aware of the `/native` option.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/26363#discussion_r2213422135
More information about the serviceability-dev
mailing list