← ClaudeAtlas

compilation-and-inlining-logslisted

Reading what the JIT actually did: the columns of -XX:+PrintCompilation and its flag characters, -XX:+PrintInlining and its verdict strings, -XX:+LogCompilation with JITWatch, the -Xlog:jit+compilation and JFR forms, targeted compiler directives, and turning a refusal into a code change. Use when a hot method is suspected of not reaching tier 4, when a call site shows "too big" or another inlining refusal, when a method never appears in the compilation log at all, when someone prescribes -XX:CompileThreshold or -Xlog:jit, when a script greps the compilation log and returns nothing, when a directive added with jcmd changed nothing, when JFR shows no compilation events, or when raising FreqInlineSize globally is proposed to fix one method. Does not cover the tiered pipeline, warm-up and the code cache as concepts (jit-compilation), the design rules about inlining and escape (jit-inlining-and-escape-analysis), recompilation and uncommon traps (deoptimization), or C2's internal representation (c2-sea-of-nodes).
robsonkades/agent-skills · ★ 2 · Code & Development · score 75
Install: claude install-skill robsonkades/agent-skills
# Compilation and Inlining Logs ## Purpose Read the compiler's own output instead of guessing at it. Three diagnoses look alike from the outside and lead to three different flags: the method never became native code at all; a specific call inside a tree that compiled fine was not inlined; or code that was already generated got invalidated afterwards. Confusing them is how a session ends with the wrong flag changed. The failure this prevents is the plausible-looking command that silently answers nothing — a tier filter on the wrong field, `-Xlog:jit` with no sub-tag, a JFR recording whose threshold drops every compilation, a directive that only applies to compilations that have not happened yet — and is then read as "there is nothing to see". ## Workflow 1. **Decide which question you are asking**, because it picks the tool. When and at which tier a method became native code is `PrintCompilation` or `-Xlog:jit+compilation`; which calls inside one compilation tree were inlined is `PrintInlining` or `-Xlog:jit+inlining=debug`; currently listed nmethods and their tier/state are visible through `jcmd <pid> Compiler.codelist`; continuous production monitoring is JFR. A method can execute inlined in several callers without its own listed nmethod. 2. **Record the runtime and compilation mode** before interpreting a tier. On the usual server HotSpot with tiered compilation enabled, levels 1–3 are C1 modes and level 4 is C2. Under `-XX:-TieredCompilation` the