RFR: 8359386: Fix incorrect value for max_size of C2CodeStub when APX is used [v2]

Srinivas Vamsi Parasa sparasa at openjdk.org
Mon Jun 16 19:42:55 UTC 2025


On Fri, 13 Jun 2025 09:44:14 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:

>> Srinivas Vamsi Parasa has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   update max_size computation to be explicit
>
> src/hotspot/cpu/x86/c2_MacroAssembler_x86.cpp line 4691:
> 
>> 4689: 
>> 4690:   // Using the APX extended general purpose registers increases the instruction encoding size by 4 bytes.
>> 4691:   int max_size = dst->encoding() <= 15 ? 23 : 27;
> 
> Do you want to write it in a more explicit way then?
> 
> 
> int max_size = 23 + (UseAPX ? 4 : 0);

Thank you for the suggestion! Please see suggested change incorporated in the updated code.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/25787#discussion_r2150729597


More information about the hotspot-compiler-dev mailing list