← Back to Pull requests

jitlayers: Handle objects without linker info in the debuginfo plugin #63486

Closed
unknown closed this pull request without merging on Oct 01, 2026 04:29 UTC
View on GitHub
unknown unknown commented on Sep 29, 2026 09:05 UTC
Author

With the GDB JIT listener enabled (ENABLE_GDBLISTENER=1, or by default in debug builds), Julia crashes as soon as it materializes code that was added to its JIT from outside of codegen. LLVM.jl does exactly that, through JLJITAddLLVMIRModule and JLJITAddObjectFile, and so do packages built on it like Enzyme:

$ ENABLE_GDBLISTENER=1 julia repro.jl
Fault at memory address: 0x50
notifyMaterializingWithInfo at src/jitlayers.cpp:815:5
notifyMaterializing at src/jitlayers.cpp:859:32
llvm::orc::LinkGraphLinkingLayer::emit(...)
[...]
JLJITJDLookup_impl at src/llvm_api.cpp:96:75

For code that Julia generates itself, linkOutput attaches linker info to each object, which the debuginfo plugin uses when registering the object. Code added through the C API never goes through linkOutput. When the GDB listener is enabled, the plugin still registers such code, just without linker info. Most of the plugin already handles that case, but the coverage counter support added in #62724 assumed that every object has linker info and dereferenced a null pointer.

Code without linker info has no coverage counters to relocate either, so the fix is to skip that step for it. With this change, the reproducer from #63485 works with the GDB listener enabled, and so do LLVM.jl's tests for Julia's JIT.

This PR doesn't add a test: triggering the bug requires adding code to the JIT through the C API, which Julia's own test suite doesn't do.

Fixes #63485

Diff: 182 lines (+136 / -46) across 2 files Reviewer: maleadt Review duration: 2604m
All Vouch review confidence checks passed
Residual risk 0.13 = Change Risk (0.36) × (1 − Review Confidence (0.64)). Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.36 · 182 lines diff across 2 files
0.36
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
0.17
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 70%
64%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size diff_size
0.312
Shallow Review Depth shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #63486"
general weight: 0.35
Reviewers
Assignees
Unassigned
Labels
risk: low confidence: 64% reviewed
Vouch Risk Breakdown
AI-powered review risk analysis
Change Risk
Change Risk · Model 1 (XGBoost)
Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
Score: 35.6% (MEDIUM) · Higher = larger blast radius
35.6%
Review Confidence
Review Confidence · Models 2 & 3
Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
Score: 64% · Lower = rushed or shallow review
64%
Residual Risk
Residual Risk · Core Equation
Residual = Change × (1 − Confidence)
Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
Score: 12.8% · Safe to merge
12.8%