RFR: 8366905: Store AdapterBlob pointer in AdapterHandlerEntry [v2]

Ashutosh Mehra asmehra at openjdk.org
Fri Sep 19 14:58:02 UTC 2025


On Fri, 19 Sep 2025 14:50:18 GMT, Ashutosh Mehra <asmehra at openjdk.org> wrote:

>> src/hotspot/share/runtime/sharedRuntime.cpp line 2825:
>> 
>>> 2823:   int comp_args_on_stack = SharedRuntime::java_calling_convention(sig_bt, regs, total_args_passed);
>>> 2824:   address entry_address[AdapterBlob::ENTRY_COUNT];
>>> 2825:   assert(AdapterBlob::ENTRY_COUNT == 4, "sanity");
>> 
>> Why you need this assert? Do you use `4` instead of `ENTRY_COUNT` somewhere?
>
> This was just copied from the existing code. I think we don't need it. We should always be using enums.

AdapterBlob constructor was using numeric values to access values in the entry_offset. I update it to use enums.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/27101#discussion_r2363184167


More information about the hotspot-dev mailing list