@@ -1478,20 +1478,29 @@ artifacts:
14781478 silently-wrong source lines after host-link. The v0.12.0 TAG is HELD for
14791479 step 5c (advisor-confirmed: PR B in main is default-off + frozen-safe, so
14801480 it banks the work at zero risk; the tag waits for relocations).
1481- - step (5c) RELOCATIONS — PR C, REQUIRED before the v0.12.0 tag:
1482- C1 = generalize elf_builder's `.rel.text`-ONLY relocation machinery to
1483- PER-SECTION relocations, **REL form (not RELA)** — synth/ARM32 uses REL
1484- with the addend stored in-place (`.rel.debug_*`, matching the existing
1485- `.rel.text` convention); frozen-safe, gated on the existing `.rel.text`
1486- fixtures (cabi_arena_realloc_linkability_418) staying byte-identical.
1487- C2 = emit DWARF addresses via gimli `Address::Symbol{text_sym, addend}`,
1488- extract the relocations, emit `.rel.debug_line` / `.rel.debug_info`
1489- against the `.text` symbol. The C2 ORACLE must APPLY the relocations at a
1490- NONZERO `.text` base and verify the address resolves to the CORRECT
1491- source line (not merely that a reloc record exists). Advisor caution:
1492- "do NOT rush the addend math into a debug-info path — careful (even next
1493- session) beats fast."
1494- status : approved
1481+ - step (5c) RELOCATIONS LANDED (PR C #430, merged 9a34c8d; SHIPS in
1482+ v0.12.0): C1 generalized elf_builder's `.rel.text`-ONLY machinery to
1483+ PER-SECTION REL tables (`extra_relocations` + `add_section_relocations`;
1484+ `.rel.debug_*`, REL in-place addend); byte-identical when off — the
1485+ frozen gust whole-`.o` no-op oracle is the end-to-end proof, and
1486+ cabi_arena_realloc_linkability_418 `.rel.text` stays byte-identical.
1487+ C2: a custom gimli `write::Writer` (`RelocWriter`) overrides ONLY
1488+ `write_address`, so just the two `.text` references (line program
1489+ `DW_LNE_set_address` + CU `DW_AT_low_pc`) become `R_ARM_ABS32` against a
1490+ global `__synth_text_base` (st_shndx=.text, value 0); internal DWARF
1491+ cross-refs stay concrete (do NOT use gimli's blanket `RelocateWriter`).
1492+ Addend 0 ⇒ `.debug_*` bytes byte-identical to PR B. Oracle
1493+ `rel_debug_relocations_shift_addresses_to_correct_line_394` applies the
1494+ reloc at a NONZERO base and asserts every row shifts by exactly the base
1495+ with its source line preserved; CONFIRMED end-to-end with a real
1496+ `arm-none-eabi-ld -Ttext=0x08000000` link (readelf decodedline → correct
1497+ lines). FAST-FOLLOW: `__synth_text_base` is global ⇒ linking >1
1498+ `--debug-line` object collides (fails LOUD); local-STT_SECTION fix is
1499+ blocked by the hardcoded `.symtab` sh_info=1 — jumps priority iff a
1500+ consumer links multiple synth objects. GOTCHA recorded: dependabot #436
1501+ (gimli 0.31→0.33, `LineProgram::new` 5→6 args) broke main after PR C
1502+ merged textually-clean on a stale base; fixed in #439.
1503+ status : implemented
14951504 tags : [toolchain, dwarf, debuggability, elf, meld-coordination, feature-loop, release-v0.12.0, synth-394]
14961505 links :
14971506 - type : derives-from
0 commit comments