RFR: 8347901: C2 should remove unused leaf / pure runtime calls [v2]

Emanuel Peter epeter at openjdk.org
Fri Jun 20 15:57:38 UTC 2025


On Fri, 20 Jun 2025 15:50:46 GMT, Emanuel Peter <epeter at openjdk.org> wrote:

>> Marc Chevalier has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Mostly comments
>
> src/hotspot/share/opto/divnode.cpp line 1522:
> 
>> 1520:   if (!can_reshape) {
>> 1521:     return nullptr;
>> 1522:   }
> 
> Would this prevent us from doing the `make_tuple_of_input_state_and_top_return_values` trick? Because it seems to me that we do not need to reshape the node for that, right? Maybe you  should reorder things for that?

Also, you should probably call `CallLeafPureNode::Ideal` instead of duplicating its logic here and in other subclasses.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/25760#discussion_r2159293669


More information about the graal-dev mailing list