RFR: 8350864: C2: verify structural invariants of the Ideal graph [v7]
Manuel Hässig
mhaessig at openjdk.org
Tue Sep 30 13:08:52 UTC 2025
On Mon, 29 Sep 2025 06:48:36 GMT, Marc Chevalier <mchevalier at openjdk.org> wrote:
>> src/hotspot/share/opto/graphInvariants.cpp line 275:
>>
>>> 273:
>>> 274: private:
>>> 275: static void print_node_list(const Node_List& ctrl_succ, stringStream& ss) {
>>
>> Perhaps this would be a good addition to `Node_List` as an analog to `Node::dump(suffix, mark, ss, dc)` instead of a private method of some verification class.
>
> There is already a `Node_List::dump` and `Node_List::dump_simple`, but they are a bit ugly for my usage here in my opinion: `dump_simple` just dump the node index, and `dump` prefix each line with `%5d--> ` where %d is the rank in the list (which I don't need to display here, and I found a bit confusing).
>
> But they are more than enough for debugging. So, I'm not sure we need a relatively light variation of `dump` in there.
Fair enough. Reusing the static method you have now defined is good enough.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/26362#discussion_r2391381116
More information about the hotspot-compiler-dev
mailing list