RFR: 8360389: Support printing from C2 compiled code [v12]

Vladimir Kozlov kvn at openjdk.org
Thu Oct 2 15:32:07 UTC 2025


On Thu, 2 Oct 2025 14:46:39 GMT, Benoît Maillard <bmaillard at openjdk.org> wrote:

>> src/hotspot/share/opto/compile.cpp line 5387:
>> 
>>> 5385:       if (in->is_CFG()) {
>>> 5386:         if (in->is_Multi()) {
>>> 5387:           candidates.push(in->as_Multi()->proj_out(TypeFunc::Control));
>> 
>> Why you collect only one control output edge? IfNode has two. May be add comment if it is intentional.
>
> This should not happen because we got here by following data inputs, so typically it cannot be an `IfNode` (I have added a comment). However @TobiHartmann pointed out that if we are trying to print the return value of a java call we should use the fall through projection of the `CatchNode` after the call. I have made the necessary changes.

Then which CFG/Multi nodes you expect here?

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

PR Review Comment: https://git.openjdk.org/jdk/pull/26475#discussion_r2399226614


More information about the hotspot-dev mailing list