RFR: 8310268: RISC-V: misaligned memory access in String.Compare intrinsic [v3]

Vladimir Kempik vkempik at openjdk.org
Mon Jul 24 13:51:42 UTC 2023


On Mon, 24 Jul 2023 05:50:19 GMT, Fei Yang <fyang at openjdk.org> wrote:

>> Vladimir Kempik has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Simplify case for long LU UL compares
>
> src/hotspot/cpu/riscv/stubGenerator_riscv.cpp line 2540:
> 
>> 2538:       __ ld(tmp2, Address(str2));
>> 2539:       __ addi(str2, str2, 8);
>> 2540:       __ beqz(cnt2, LAST_CHECK_AND_LENGTH_DIFF);
> 
> I wonder when this branch instruction will taken?

yeah, cnt2 possible values before beqz is [1..7], branch will never be taken

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

PR Review Comment: https://git.openjdk.org/jdk/pull/14534#discussion_r1272292454


More information about the hotspot-dev mailing list