RFR: 8337666: AArch64: SHA3 GPR intrinsic [v2]

Dmitry Chuyko dchuyko at openjdk.org
Fri May 30 18:21:40 UTC 2025


On Fri, 25 Apr 2025 09:51:19 GMT, Andrew Haley <aph at openjdk.org> wrote:

>> Dmitry Chuyko has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains five commits:
>> 
>>  - Copyright year
>>  - Review suggestions
>>  - Merge master
>>  - Delete empty line
>>  - SHA3 GPR intrinsic & tests
>
> src/hotspot/cpu/aarch64/stubGenerator_aarch64.cpp line 4462:
> 
>> 4460:              a7 = r7,
>> 4461:              a8 = r8,
>> 4462:              a9 = r9,
> 
> Suggestion:
> 
>              a8 = rscratch1,
>              a9 = rscratch2,
> 
> 
> Aliasing these registers is dangerous.

Changed as proposed.

> src/hotspot/cpu/aarch64/stubGenerator_aarch64.cpp line 4488:
> 
>> 4486:     can_use_r18 = true;
>> 4487: #endif
>> 4488:     bool can_use_fp = !PreserveFramePointer;
> 
> Can's we always use fp in a leaf function?

I'm still not sure about external tools compatibility, like perf which was the cause of the entire +PreserveFP story.

> src/hotspot/cpu/aarch64/stubGenerator_aarch64.cpp line 4662:
> 
>> 4660:     }
>> 4661: 
>> 4662:     __ ror(tmp1, a10, 64 - 3);
> 
> Suggestion:
> 
>     __ rol(tmp1, a10, 3);

rol was added in MacroAssembler.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/24260#discussion_r2116377293
PR Review Comment: https://git.openjdk.org/jdk/pull/24260#discussion_r2116379048
PR Review Comment: https://git.openjdk.org/jdk/pull/24260#discussion_r2116376614


More information about the hotspot-dev mailing list