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

Chad Rakoczy duke at openjdk.org
Fri Apr 25 00:14:51 UTC 2025


On Thu, 24 Apr 2025 23:47:32 GMT, Dean Long <dlong at openjdk.org> wrote:

>> Chad Rakoczy has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Fix branch range check
>
> src/hotspot/cpu/aarch64/relocInfo_aarch64.cpp line 86:
> 
>> 84:     if (!Assembler::reachable_from_branch_at(addr(), x, true)) {
>> 85:       address trampoline = call->get_trampoline();
>> 86:       assert(trampoline != nullptr, "branch is too large with no available trampoline");
> 
> Doesn't this mean any nmethod relocation can cause the JVM to crash if there is no trampoline?  Or are you creating new trampoline stubs in the relocated destination as needed (and deleting trampoline stubs that are no longer needed)?

>From what I saw calls are _usually_ accompanied by a corresponding trampoline. I'll look deeper to see if _usually_ is _always_

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

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


More information about the hotspot-compiler-dev mailing list