RFR: 8370220: C2: rename methods and improve documentation around get_ctrl and idom lazy updating/forwarding of ctrl and idom via dead ctrl nodes [v5]
Emanuel Peter
epeter at openjdk.org
Tue Oct 21 07:47:07 UTC 2025
On Mon, 20 Oct 2025 13:50:08 GMT, Christian Hagedorn <chagedorn at openjdk.org> wrote:
>> Emanuel Peter has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Apply suggestions from code review
>>
>> Co-authored-by: Christian Hagedorn <christian.hagedorn at oracle.com>
>
> src/hotspot/share/opto/loopnode.hpp line 1262:
>
>> 1260: // forwarding installed, using "install_lazy_ctrl_and_idom_forwarding".
>> 1261: // We now have to jump from the old (dead) ctrl node to the new (live)
>> 1262: // ctrl/idom node, in possibly multiple ctrl/idom forwarding steps.
>
> Maybe for clarification since it's somehow surprising at first that we reuse `_loop_or_ctrl`:
> Suggestion:
>
> // idom node, in possibly multiple idom forwarding steps.
> // Note that we piggy back on `_loop_or_ctrl` do the the forwarding.
Applied with even more information.
> src/hotspot/share/opto/loopnode.hpp line 1274:
>
>> 1272: }
>> 1273:
>> 1274: Node* idom(uint didx) const {
>
> While at it: Maybe also name this `node_index`?
I chose to replace it with `node_idx`, since it comes from `n->_idx`.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/27892#discussion_r2447068474
PR Review Comment: https://git.openjdk.org/jdk/pull/27892#discussion_r2447075460
More information about the shenandoah-dev
mailing list