RFR: 8316694: Implement relocation of nmethod within CodeCache [v42]

Vladimir Kozlov kvn at openjdk.org
Thu Aug 21 17:13:06 UTC 2025


On Thu, 21 Aug 2025 15:54:48 GMT, Erik Österlund <eosterlund at openjdk.org> wrote:

> So what is the driver for this relocation in the JVM, which makes sure hot nmethods get moved together?

@fisk, next RFE  [JDK-8326205](https://bugs.openjdk.org/browse/JDK-8326205) will "drive" nmethod relocation based on their hotness. It is similar AFAIK to what you implemented back in Leyden repo to create list of hot nmethods to cache.


We can a sampling thread which uses the thread-local handshake framework. An example of such a thread is the Sweeper: https://github.com/openjdk/jdk17u/blob/master/src/hotspot/share/runtime/sweeper.hpp which was used to detect active nmethods.

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

PR Comment: https://git.openjdk.org/jdk/pull/23573#issuecomment-3211445467


More information about the hotspot-compiler-dev mailing list