RFR: 8173709: Fix VerifyLoopOptimizations - step 1

Christian Hagedorn chagedorn at openjdk.org
Wed Mar 29 10:36:09 UTC 2023


On Wed, 29 Mar 2023 09:54:25 GMT, Christian Hagedorn <chagedorn at openjdk.org> wrote:

>> src/hotspot/share/opto/loopnode.cpp line 4805:
>> 
>>> 4803: // within the loop tree can be reordered. We attempt to deal with that by
>>> 4804: // reordering the verify's loop tree if possible.
>>> 4805: void IdealLoopTree::verify_tree(IdealLoopTree* loop, const IdealLoopTree* parent) const {
>> 
>> Should we rename `loop` to `loop_verify` similar to `verify_node()` code?
>
> I agree with Vladimir but then it's a little bit confusing that `loop_verify` is used for `IdealLoopTree` and `PhaseIdealLoop`. Maybe the variable name for the latter could be renamed into something like `phase_verify` to follow the naming convention used at other places (`loop` for `IdealLoopTree` and `phase` for `PhaseIdealLoop`)?

Would it make sense to also have a `fail` counter in this method, similar to `verify_nodes()`, to print multiple failures on the go (from this pass and also accumulated from the loop siblings and children)?

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

PR Review Comment: https://git.openjdk.org/jdk/pull/13207#discussion_r1151701084


More information about the hotspot-compiler-dev mailing list