8360679: Shenandoah: AOT saved adapter calls into broken GC barrier stub

Reviewed-by: kvn
Backport-of: 8477630970b61e3178abd7ac812ed97e181e2684
This commit is contained in:
Aleksey Shipilev 2025-07-25 08:09:02 +00:00
parent 1867effcc0
commit 033a121c96

View File

@ -292,7 +292,8 @@ void ShenandoahBarrierSetAssembler::load_reference_barrier(MacroAssembler* masm,
} else {
assert(is_phantom, "only remaining strength");
assert(!is_narrow, "phantom access cannot be narrow");
__ mov(lr, CAST_FROM_FN_PTR(address, ShenandoahRuntime::load_reference_barrier_phantom));
// AOT saved adapters need relocation for this call.
__ lea(lr, RuntimeAddress(CAST_FROM_FN_PTR(address, ShenandoahRuntime::load_reference_barrier_phantom)));
}
__ blr(lr);
__ mov(rscratch1, r0);