RFR: 8369219: JNI::RegisterNatives can cause a memory leak in CodeCache [v3]

Andrei Pangin apangin at openjdk.org
Sat Oct 11 17:22:06 UTC 2025


On Sat, 11 Oct 2025 15:42:55 GMT, Francesco Andreuzzi <fandreuzzi at openjdk.org> wrote:

>> I propose to amend the check in `nmethod::is_cold` to allow not-entrant native `nmethod` instances to be collected during GC.
>> 
>> Passes tier1 and tier2 (fastdebug).
>
> Francesco Andreuzzi has updated the pull request incrementally with one additional commit since the last revision:
> 
>   fix summary

test/hotspot/jtreg/gc/NativeWrapperCollection/TestNativeWrapperCollection.java line 84:

> 82:                 continue;
> 83:             }
> 84:             if (foundOne) {

Where is `foundOne` updated?

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

PR Review Comment: https://git.openjdk.org/jdk/pull/27742#discussion_r2423055494


More information about the hotspot-dev mailing list