RFR: 8350471: Unhandled compilation bailout in GraphKit::builtin_throw

Manuel Hässig duke at openjdk.org
Thu Mar 27 10:38:11 UTC 2025


On Thu, 27 Mar 2025 07:59:10 GMT, Manuel Hässig <duke at openjdk.org> wrote:

> So where failed state come from?

Maybe in a bit more detail: The failing test ran with `-XX:+StressBailout`, which makes "stress decisions" to exercise the `failing()` calls throughout C2. In our case, the removed line in `GraphKit::builtin_throw()` was randomly selected to bail out for testing purposes _without_ a failing state. Concretely, in the `Compile::failing()` code path, the execution entered `Compile::fail_randomly()` due to `StressBailout == true`:

https://github.com/openjdk/jdk/blob/4100dc9d4cdd5f0c202b2b2a32554e3aa4f15025/src/hotspot/share/opto/compile.hpp#L811-L822

In `fail_randomly()` the random number generator doomed the execution to fail:

https://github.com/openjdk/jdk/blob/4100dc9d4cdd5f0c202b2b2a32554e3aa4f15025/src/hotspot/share/opto/compile.cpp#L4998-L5004

We know that it was a stress bailout from the logs:

Pending compilation failure details for thread 0x00007f2638217ad0:
  Time: 138.483687 seconds (0d 0h 2m 18s) Compile id: 24732
  Reason: 'StressBailout' 


Knowing this and finding that there cannot be a failure state from the execution in `GraphKit::builtin_throw()`, I concluded that this test failure is a false positive.

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

PR Comment: https://git.openjdk.org/jdk/pull/24243#issuecomment-2757546229


More information about the hotspot-compiler-dev mailing list