RFR: 8370077: C2: make Compile::_major_progress a boolean
Emanuel Peter
epeter at openjdk.org
Tue Oct 21 16:34:06 UTC 2025
On Tue, 21 Oct 2025 11:58:22 GMT, Marc Chevalier <mchevalier at openjdk.org> wrote:
>> src/hotspot/share/opto/compile.hpp line 325:
>>
>>> 323: bool _allow_macro_nodes; // True if we allow creation of macro nodes.
>>> 324:
>>> 325: bool _major_progress; // Count of something big happening
>>
>> Perhaps the comment should be updated too?
>
> That makes sense. A suggestion? Maybe "Whether something big happened"?
It is kind of scary that there is basically no documentation on this. But it is quite important actually. The current comment is really not very helpful.
My understanding is that the flag is set if the loop-opts data-structures are invalid (or at least there is no guarantee that they are valid). So we need to re-build the loop tree.
If we ever set the flag, we don't continue with more loop-opts, but spin back to IGVN, clean the graph, and maybe come back to a new loop-opts round.
There may be others who have a better understanding / definition though.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/27912#discussion_r2448970079
More information about the hotspot-compiler-dev
mailing list