RFR: 8366357: C2 SuperWord: refactor VTransformNode::apply with VTransformApplyState [v3]

Christian Hagedorn chagedorn at openjdk.org
Thu Aug 28 13:55:01 UTC 2025


On Thu, 28 Aug 2025 13:51:40 GMT, Emanuel Peter <epeter at openjdk.org> wrote:

>> I'm working on **cost-modeling**, and am integrating some smaller changes from this proof-of-concept PR: https://github.com/openjdk/jdk/pull/20964
>> 
>> This is a **pure refactoring** - no change in behaviour. I'm presenting it like this because it will make reviews easier.
>> 
>> The goal here is that `VTransformNode::apply` only needs a single argument. This is important, as we will soon add more components that need to be updated during apply. That way, we can simply add more parts to `VTransformApplyState`, and do not need to add more arguments to VTransformNode::apply.
>> 
>> And yes: I have considering passing the `apply_state` as `const`. While this may be possible with the current code state, the upcoming changes from https://github.com/openjdk/jdk/pull/20964 will require non-const access to the `apply_state` (e.g. for `set_memory_state`).
>> 
>> Also: Christian asked me to squeeze in some other change: `igvn.intcon` -> `phase->intcon`, so that we also set the control to root. It's not been strictly necessary, but probably better to do it.
>
> Emanuel Peter has updated the pull request incrementally with one additional commit since the last revision:
> 
>   For Christian: use phase->intcon instead

Thanks for the update, looks good!

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

Marked as reviewed by chagedorn (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/26987#pullrequestreview-3164958854


More information about the hotspot-compiler-dev mailing list