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

Andrew Haley aph at openjdk.org
Tue Jul 1 08:34:48 UTC 2025


On Tue, 1 Jul 2025 08:28:00 GMT, Andrew Haley <aph at openjdk.org> wrote:

>> @theRealAph When we don't need a trampoline (a call site is a direct call), we update the trampoline to have the same destination as the call site. I have not found places in Hotspot relying on this. 
>> Do you remember why we are doing this? Is it Ok not to update trampolines in the case of reachable destinations?
>
>> @theRealAph When we don't need a trampoline (a call site is a direct call), we update the trampoline to have the same destination as the call site.
> 
> Yes, that's fundamental to the design.
> 
>> I have not found places in Hotspot relying on this. Do you remember why we are doing this? Is it Ok not to update trampolines in the case of reachable destinations?
> 
> No. We always keep the trampoline up to date so that we don't have to deal with a race condition when patching trampoline calls.

Please read the comments which begin:

`AArch64 OpenJDK uses four different types of calls:`

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

PR Review Comment: https://git.openjdk.org/jdk/pull/23573#discussion_r2176825935


More information about the hotspot-compiler-dev mailing list