oracle/graal · info · RetryableBailoutException

OSR entry point wasn't parsed

Error message

OSR entry point wasn't parsed

What it means

Thrown at the end of graph building when the graph is an OSR compilation but no OSR EntryMarkerNode was created while parsing. OSR entry creation depends on profile data pointing at the loop back edge; if the profile is inconsistent with the bytecode actually parsed, the entry never materializes and this RetryableBailoutException lets HotSpot retry the compilation (usually with corrected/fresh profile info).

Source

Thrown at compiler/src/jdk.graal.compiler/src/jdk/graal/compiler/java/BytecodeParser.java:1268

                assert param.inputs().isEmpty();
                param.safeDelete();
            }
        }

        // Remove redundant begin nodes.
        for (BeginNode beginNode : graph.getNodes(BeginNode.TYPE)) {
            Node predecessor = beginNode.predecessor();
            if (predecessor instanceof ControlSplitNode) {
                // The begin node is necessary.
            } else if (!beginNode.hasUsages()) {
                GraphUtil.unlinkFixedNode(beginNode);
                beginNode.safeDelete();
            }
        }
        if (graph.isOSR() && getParent() == null && graph.getNodes(EntryMarkerNode.TYPE).isEmpty()) {
            // This should generally be a transient condition because of inconsistent profile
            // information.
            throw new RetryableBailoutException("OSR entry point wasn't parsed");
        }
    }

    /**
     * Creates the frame state after the start node of a graph for an {@link IntrinsicContext
     * intrinsic} that is the parse root (either for root compiling or for post-parse inlining).
     */
    private FrameState createStateAfterStartOfReplacementGraph() {
        assert parent == null;
        assert frameState.getMethod().equals(intrinsicContext.getIntrinsicMethod());
        assert bci() == 0 : bci();
        assert frameState.stackSize() == 0 : Assertions.errorMessage(frameState, frameState.stackSize());
        FrameState stateAfterStart;
        if (intrinsicContext.isPostParseInlined()) {
            stateAfterStart = graph.add(new FrameState(BytecodeFrame.BEFORE_BCI));
        } else {
            stateAfterStart = frameState.createInitialIntrinsicFrameState(intrinsicContext.getOriginalMethod());
        }

View on GitHub (pinned to a66e9ccd1d)

Solutions

  1. Usually no action needed: it is a RetryableBailoutException and HotSpot re-attempts OSR compilation automatically.
  2. If it recurs in a loop, warm up the application (run the hot loop a few more iterations) so OSR profiles stabilize.
  3. For deterministic reproduction, disable/refresh profiles (-XX:-UseProfileData or clear the code cache profile) and retry.
Defensive patterns

Strategy: retry

Try / catch

// RetryableBailoutException: the JVM re-attempts OSR compilation automatically.
// No application catch needed; if it flaps, warm up the loop so profiles stabilize.

Prevention

When it happens

Trigger: graph.isOSR() && getParent() == null && graph.getNodes(EntryMarkerNode.TYPE).isEmpty() after all blocks are processed — i.e. an OSR compilation (compiling at a specific back-edge BCI) where the loop's OSR entry block was pruned as unreachable because profile information (e.g. which branch is hot at the OSR bci) disagreed with the code path actually parsed.

Common situations: First OSR compilation of a method right after startup with cold/incomplete profiles; after deoptimization storms where profiles are in flux; flaky/rare in steady state because the exception is retryable — HotSpot re-enqueues the OSR compilation and the second attempt with updated profiles usually succeeds.

Related errors


AI-assisted analysis of oracle/graal@a66e9ccd1d (2026-08-14). Data as JSON: /api/errors/852cd513ad57d877. Report an issue: GitHub.