aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author_ov4 <ov4@ov4.org>2026-10-16 17:24:52 +0000
committer_ov4 <ov4@ov4.org>2026-10-16 17:24:52 +0000
commit13c80c288929045875ca2fb5de1d4f5266086209 (patch)
treeac8d33b831ebdb3031920c9757c2cf84b079b35e
parentb0079d19fb3eb77c18eda27e9ca51a110a5a279d (diff)
docs(jit): describe the simplified ORC runtime integration
Drop removed mechanisms (custom SEH keep-alive, hand-written probe, IR personality forwarding) and document the factory, default liveness, stub, and probe binding now used. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
-rw-r--r--AGENTS/ARCH.md17
1 files changed, 11 insertions, 6 deletions
diff --git a/AGENTS/ARCH.md b/AGENTS/ARCH.md
index d557ec0..175a607 100644
--- a/AGENTS/ARCH.md
+++ b/AGENTS/ARCH.md
@@ -115,19 +115,24 @@ Driver behavior (`tools/driver/main.cc`):
- In EMBEDDED mode, `-r` uses LLJIT with JITLink in-process (`tools/driver/EmbeddedRunner.cc`).
The JIT owns a copy of CodeGen's module made with `cloneExternalModuleToContext`
into an independent `ThreadSafeContext`; CodeGen retains its module and context.
- The running copy uses the JIT target triple and DataLayout. Static C++ exception
+ The running copy uses the JIT target triple and DataLayout. The JIT target uses
+ Large code model with PIC. Static C++ exception
ABI symbols are defined with ORC `absoluteSymbols` using the JIT mangling
- (MinGW keeps its `snprintf`/`strtoll` aliases and a no-op `__main`); ordinary
+ (MinGW keeps its `snprintf`/`strtoll` aliases and a no-op `__main`; MinGW
+ x86_64 additionally binds the toolchain-provided `___chkstk_ms`); ordinary
C library symbols resolve through the ORC process-symbol mechanism. Linux uses
the generic LLVM IR platform with EH-frame registration. macOS uses LLJIT's
unwind registration, selecting compact unwind or EH-frame per host capability.
Windows x86_64 keeps the GNU C++ runtime and `__gxx_personality_seh0` with a
small in-process COFF adapter: per-graph `__ImageBase` shared by relocations
- and SEH registration, preserved `.pdata`/`.xdata` with layout/sort/range checks,
- x86_64 pointer/stub helpers for external/personality calls, and
+ and SEH registration, default backend liveness for `.pdata`, JITLink
+ pointer-jump stubs for the `.xdata` personality references, and
`RtlAddFunctionTable`/`RtlDeleteFunctionTable` via JITLink allocation actions
- covering teardown and link-failure cleanup; registration failure blocks entry.
- The JIT explicitly uses `ObjectLinkingLayer` so Windows COFF does not fall back
+ covering teardown and link-failure cleanup, with table validation in the
+ registration callback; registration failure blocks entry.
+ The JIT builds its `ObjectLinkingLayer` through one file-local factory (COFF
+ flags stay format-conditional, SEH plugin installed before LLJIT ownership)
+ so Windows COFF does not fall back
to RuntimeDyld. Initialization runs through the platform support before lookup
of `main`; deinitialization runs while code is still mapped so unwind
deregistration precedes memory release. Execution failures return 1 without