RFR: 8310844: [AArch64] C1 compilation fails because monitor offset in OSR buffer is too large for immediate [v2]
Tobias Hartmann
thartmann at openjdk.org
Thu Jan 4 14:20:41 UTC 2024
On Thu, 4 Jan 2024 14:08:51 GMT, Andrew Haley <aph at openjdk.org> wrote:
>> Tobias Hartmann has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Adjusted according to review
>
> src/hotspot/cpu/aarch64/c1_LIRAssembler_aarch64.cpp line 289:
>
>> 287: __ ldr(r19, Address(OSR_buf, slot_offset + 1*BytesPerWord));
>> 288: __ str(r19, frame_map()->address_for_monitor_object(i));
>> 289: }
>
> The macro assembler automagically fuses `ldr` pairs. It'd be better to fix this with:
>
>
> --- a/src/hotspot/cpu/aarch64/c1_LIRAssembler_aarch64.cpp
> +++ b/src/hotspot/cpu/aarch64/c1_LIRAssembler_aarch64.cpp
> @@ -282,7 +282,8 @@ void LIR_Assembler::osr_entry() {
> __ bind(L);
> }
> #endif
> - __ ldp(r19, r20, Address(OSR_buf, slot_offset));
> + __ ldr(r19, Address(OSR_buf, slot_offset));
> + __ ldr(r20, Address(OSR_buf, slot_offset + BytesPerWord));
> __ str(r19, frame_map()->address_for_monitor_lock(i));
> __ str(r20, frame_map()->address_for_monitor_object(i));
> }
Thanks for the review. I adjusted the fix accordingly.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/17266#discussion_r1441798599
More information about the hotspot-compiler-dev
mailing list