Commit Graph

1933 Commits

Author SHA1 Message Date
Drew T 6e9cd5e449 feat(decomp): t6-recover gate — +1 fns x0 propagated (fleet None%) 2026-07-30 17:24:43 -06:00
Drew T 9713f1ede0 feat(decomp): t6-recover gate — +1 fns x0 propagated (fleet None%) 2026-07-30 17:23:54 -06:00
Drew T 11da706745 feat(decomp): t6-recover gate — +1 fns x0 propagated (fleet None%) 2026-07-30 17:22:36 -06:00
Drew T 9398f3b5cf feat(decomp): t6-recover gate — +1 fns x0 propagated (fleet None%) 2026-07-30 17:21:47 -06:00
Drew T e277701267 feat(decomp): t6-recover gate — +1 fns x0 propagated (fleet None%) 2026-07-30 17:20:17 -06:00
Drew T a74e21631d feat(decomp): t6-recover gate — +2 fns x0 propagated (fleet None%) 2026-07-30 17:16:21 -06:00
Drew T ab467e2196 feat(decomp): t6-recover gate — +1 fns x0 propagated (fleet None%) 2026-07-30 17:15:24 -06:00
Drew T b4b298278e feat(decomp): t6-recover gate — +2 fns x0 propagated (fleet None%) 2026-07-30 17:12:31 -06:00
Drew T cb0d3c185b feat(decomp): t6-recover gate — +1 fns x0 propagated (fleet None%) 2026-07-30 17:10:09 -06:00
Drew T 41a19efc00 docs(phase-30): T2 finding 2 (fleet is jr-carved; -O0 range inside _jr_80135D20 — carve-within-a-carve arc scoped) + in-flight session checkpoint 2026-07-30 17:09:06 -06:00
Drew T fe8095a24d feat(phase-30): T2 — rollout_o0.py (generalized o0b driver) + x1 probe verdict: append route REFUTED for the remaining cluster (R14 correction)
o0b-bearing != o0b-adjacent: T85's 0x801457A4 banked by append only because it abuts the o0b
object's END; the 0x8013Bxxx-0x8013Cxxx families mis-place by construction (probe 1/1 gate-reject)
and per-fn isolation IS the Arm-A re-carve. Frontier report corrected; T2 pivots to the Arm-A
+0x20 defect itself (symbol-pin hypothesis first). Driver stands as the post-fix sweep harness.
2026-07-30 17:05:50 -06:00
Drew T e02fd38358 feat(phase-30): T0.5 — DefineFunctions completion pass wired into the batch (define missing stubs from splat truth, re-decompile)
Probe: main +476/477, fresh-import ov_SC03_001 +238/238, ov_SC02_011 +227/228. Raw-blob
auto-analysis finds only the reachable subset (Phase-10 finding, now automated per program).
2026-07-30 17:01:53 -06:00
Drew T bd76f2373c fix(phase-30): T0.5 — import trigger matches Ghidra's actual 'not found' phrase (probe caught +0/371 silent no-fire); probe findings logged 2026-07-30 16:52:05 -06:00
Drew T 19766a6dc3 feat(phase-30): T0.5 — prefetch_fleet.py, the fleet Ghidra-C batch orchestrator (+ SETUP row, R21; fuel manifest ride-along)
One representative per remaining h_seq distinct class + all main/resident stubs -> .run/ghidra_c/.
Resumable (skips cached); serial on the exclusive project lock; auto-stops a serving MCP (R23);
imports missing overlay programs on demand via ghidra_import_raw.sh (blob derived via
family_remap.img_path, vram from the splat yaml — R33, never guessed); R32 per-program outcome
report, continues past failures. Dry-run: 126 programs / 7,966 uncached representatives.
2026-07-30 16:49:08 -06:00
Drew T 93d2851ab2 feat(phase-30): T0e2+T0f — autopsy refreshed (108 stranded MATCHes); frontier regenerated; the three populations PINNED (docs/frontier-p30.md)
- Autopsy 1,349 rows: 1,178 near / 63 nobuild / 108 match_one-MATCH (T1 fuel, 3x the S16 sample);
  0 classifier errors; second-oracle agree.
- THE -O0 PIN: 18 fam / 2,192 open members = 2,131 o0b-route-eligible + 61 SC07-only; 15/18
  exemplar-matched. The 'WALLED ~1,287' framing dissolves — T2 generalizes rollout_801457a4_o0.py
  (proven 130/130); jr+o0 composites (0x8013c414, 0x8013c0f8) probe x1 first.
- Zero-crack: 114 fam / 3,166 members / ~204k w-ins (28 substantial). Concentration top-20 24.0% /
  top-100 44.8%. Worklist fresh: 101 live / 261,789 gain-ins (stale 160/583k gone).
- T0 COMPLETE (a-f) — report point #1 = docs/frontier-p30.md
2026-07-30 16:45:09 -06:00
Drew T 407ff8f85c fix(phase-30): T0e-1 — the 21-file absolute-include portability defect: /home/musashi paths -> ../shared/ relative (R22 140/140) 2026-07-30 16:42:03 -06:00
Drew T e03494dc1f feat(phase-30): T0d — backlog _open_stubs derives from corpus.stubs (STUB_RE deleted, R33); ledger verified already-clean
- Filter + prune existed since 07-24; jsonl already compacted (the tree's uncommitted edit was
  S25's un-committed prune output; prune today 1350->1350/0 dropped). Stale rows were worklist.md's.
- Oracle agreement: 0 divergence across 131 ledger binaries (my first probe compared names vs int
  addrs — R35 on my own instrument). Hex-case canonicalized in the membership test (R32).
- Parity proven post-change: load_best 1350 == 1350. §83 doctrinal caveat stands.
2026-07-30 16:39:05 -06:00
Drew T de7b347f6f feat(phase-30): T0c — the family_hseq/progress 'gap' was a cross-date+scope misread; digests now self-stamp (scope+HEAD+oracle)
Same-tree regen: family_hseq(overlays) 27,248 == progress 28,296-1,034(main)-14(resident) EXACT.
The 07-29 map was SESSION-25's open snapshot; 29,961-27,248 = 2,713 = the session's banked total.
Zero definitional gap — both tools already derive from corpus.stubs (Phase 26-A). family-hseq.md
header now stamps 'OVERLAYS only' + generation HEAD + compare-at-same-HEAD. Roadmap D-bucket
corrected. Fresh readings: 478 substantial fam / 678,404 templ ins / 28 zero-crack (S25 ate 33).
2026-07-30 16:35:59 -06:00
Drew T 53b30962ee feat(phase-30): T0b — rtu_match FAIL verdicts surface the real cc1 error (filtered, first-15) instead of a warning tail
The SESSION-25 recipe (grep -v warnings from --stderr-out) applied in-tool across all 4 stages;
gcc-2.7.2 hard errors have no 'error:' prefix so the old tail-truncation drowned them (cost 3
probes). Raw-tail fallback if the filter empties. Verified on a real deliberate CC1 failure.
2026-07-30 16:32:37 -06:00
Drew T b5a28edae8 feat(phase-30): T0a — gate_stage stage-0 raw gate + fix_arity_callers per-edit journal undo (§122)
- STAGE 0: gate the RAW drafts before any transform (GATE_NO_STAGE0 escape) — the carried
  'ladder destroys good drafts' defect (SESSION-22 reproduction: _o0 pair + func_80138C60,
  ladder-FAILED/bare-VERIFIED) is impossible by construction; ladder+arity now touch only
  stage-0 failures. TU-blind-transform root-cause hypothesis recorded in-code, open.
- fix_arity_callers --journal/--undo-journal --keep: exact per-edit undo in the WRITER,
  shared by ladder AND bare workflows (the 17-TU residue class); replaces the two-special-case
  file snapshot; undo moved after stage 2 (closes the stage-2 arity parity gap); stale-journal
  guard. Negative-control: apply->undo byte-identical; --keep exact.
- Flow test .run/t0a_flowtest/driver.py 7/7 PASS. Cookbook §122. CURRENT_PHASE T0(a) logged.
2026-07-30 16:31:01 -06:00
Drew T 0acd4cc5d4 (Phase 29 landed as 552 commits commit:0661..commit:1212 + this PhaseEnd. Fleet 68.9 -> 87.5% instr / 49.5 -> 78.0% distinct / 83.94 -> 92.00% fn-count; 140/140 byte-identical throughout; 0 NON_MATCHING. The granular trail -> logs/Phase29.md.)
feat(phase-29): the family campaign — +18.6pp instr in 25 sessions; engine spent on evidence; roadmap v2 (v1.28.0)

- T1 diff_regions.py RESOLVED the swing number: (a) TOOLING — the "~3% h_seq ceiling" was an -O0
  compile-flag artifact (REGALLOC 0/106); the third structural wall to resolve to our own tooling.
- The campaign: crack waves + propagate-behind-each-crack + the §20 broad type-lift (154 types) +
  the jtbl carve waves + the SC07-region sweeps. SESSION-25 alone: 2,713 members, +100,572 ins,
  +1,620 unique fns, every named blocker closed — NOT ONE a compiler wall.
- Doctrine shifts (decision-log): fresh cracks are the only lever that moves distinct-code; the
  propagation cap gates de-duplication, not coverage; the wave bottleneck is INTEGRATION (~92%
  byte-correct, ~27% bank) -> the tiered T0/T1 blast-radius recovery driver (14/36 = 39% measured);
  gate_stage call-site-casts are the integration spine (bulk header edits BREAK builds).
- T98 characterised the residue: 80 families / 960 members / 173 distinct (29 all-STRUCT by-design
  + 51 gate-failing, 3 sweeps at 0) -> T99 burn-down (derived from digest git history, R33):
  final-four-day decay +2.7 -> +0.3pp/day. Closed on the measurement, gate-2 confirmed.
- roadmap-to-100 v2: P30 Recovery & Concentration -> P31 Scope-Complete + Main & Resident ->
  P32 Behemoths+Walls -> P33 Verify+Flip. member_adapt + family-adapt fine-tune VACATED.
- Honesty ledger: 7 recorded errors + the month-old shared byte-gate default defect (found+fixed);
  the -O0 Arm-A splat wall named and carried as P30 T2 instrument work, never force-banked.
- cookbook §54-§121 (68 sections); ~15 decision-log entries; calibration re-measured; R37 proposed.
2026-07-30 16:14:22 -06:00
Drew T 8c73950270 docs(phase-29): roadmap-to-100 v2 — the owed re-baseline; P30-P33 rechartered on 2026-07-30 measured reality
- §1 contract numbers corrected: 140 onboarded + 39 type-1 pending; metrics contract marked
  IMPLEMENTED (main in denominators since 07-22); main second-oracle gap named as P31 item
- §2 rebuilt: 87.5/78.0/92.00 baseline; buckets W1-W5/M/R/T/B/D with dated sources; the
  measured lever order (recover -> fix -O0 instrument -> concentration head -> scope -> flag-plants)
- §3 rechartered: P30 Recovery & Concentration -> P31 Scope-Complete + Main & Resident ->
  P32 Behemoths+Walls -> P33 Verify+Flip; honest scale estimates from measured velocity
- §4 tooling: member_adapt + family-adapt fine-tune VACATED (dissolved premise); burn-down
  DERIVED not built (R33); new T0 defect fixes named; diff_regions BUILT
- §7 records the v1->v2 supersession (v1 in git history at commit:1210)
2026-07-30 16:06:08 -06:00
Drew T f382a8180a docs(phase-29): T99/Task-7 — burn-down derived from digest history; ROI close recommended; frontier → roadmap v2 2026-07-30 16:01:10 -06:00
Drew T 0e5d649568 docs(phase-29): SESSION-25 final checkpoint v9 — residue characterised, ROI decision surfaced 2026-07-30 14:22:56 -06:00
Drew T 4115279990 docs(phase-29): T98 — residue characterised: 29 all-STRUCT (refused by design) + 51 gate-failing families
- Re-ranked after T97: 80 families / 960 members / 173 new distinct, top family worth 20.
- Probed the top (0x8017d840): stages 0 drafts, skipped {'member class STRUCT': 21} — every member
  is register-drift class, refused by remap_hseq for a REAL structural reason. First still-zero
  family this session whose blocker is not our own tooling.
- Clean split measured: 29 all-STRUCT families (86 members, refused by design, per-member drafting
  only) vs 51 no-STRUCT families (874 members, ~150 distinct, stage fine but fail the gate) — no
  mixed families at all.
- HONEST ROI: the 51 are ~51 independent diagnoses at ~3 distinct each, and the last THREE blast
  sweeps over them returned 0 with every lever this phase built applied. Residue total is 173
  distinct vs 2,713 members banked today. The mechanical family engine is SPENT — this is the ROI
  conversation SESSION-24 deferred, now supported by data (Drew's gate-2 call).
- No banks; tree clean; src/ untouched.
2026-07-30 14:22:23 -06:00
Drew T 7460a80d6f docs(phase-29): SESSION-25 final checkpoint v8 — 2,713 banked, 92.00% fn-count, every named blocker closed 2026-07-30 13:44:58 -06:00
Drew T ceae8bb4cd feat(phase-29): T97 — func_80151944 138/138; the "three-edit job" was ONE edit
- The last big NAMED blocker, costed across four checkpoints as §112 header + §20 call-site cast +
  a scripted §99 pass over 2,022 overlay-local decls. Probing first showed two of the three were
  unnecessary: the conflict is entirely between DEFINE_func_80151924()'s own forward-decl
  (extern s32 func_80151944(void)) and the byte-true definition (void f(void *a0)), four lines
  apart in the assembled TU. The 2,022 decls live in OTHER TUs and never entered it.
- ONE 4-line edit in engine_core.h: decl -> byte-true, call site -> ((s32 (*)(void))f)() so the
  caller's codegen is unchanged. rtu_match: conflicting types -> MATCH (15 ins). Sweep 138/138.
- Family 0x80131eec fully closed: 149 (T87) + 138 (T97) + 1 immediate-refusal = all 288 members.
- SHARED-HEADER RISK VERIFIED, NOT ARGUED: engine_core.h is included by all 138 overlays, so §20
  cast-folding is a hypothesis. Per-binary gates 138/138 are necessary but not sufficient; the
  fleet check is the one that counts. R22 clean-fleet 140/140 + tools-health RC=0 (corpus 0
  PHANTOM/0 TRUNCATED, cdecl, audit-binaries, dedup 1886/0, C1 239604/239604).
- METRICS: fn-count 91.96 -> 92.00% (+138, exact) · instr 87.4 -> 87.5% (+2,070) · distinct +72.
- COSTING LESSON: the estimate came from reading the symptom (2,022 decls of this name exist)
  instead of probing the failure (which decl actually conflicts). Probe before COSTING, not just
  before scaling.
2026-07-30 13:44:22 -06:00
Drew T bd3c207088 docs(phase-29): SESSION-25 final checkpoint v7 — 2,575 banked, all 3 byte-identical stragglers closed 2026-07-30 13:13:40 -06:00
Drew T 7e32da8f64 feat(phase-29): T95/T96 — func_80142B2C 136/136 (§121); all 3 byte-identical stragglers closed
- The draft calls ((void(*)(void))func_80142C84)() but nothing declares that symbol above the
  splice: it is DEFINED by DEFINE_func_80142C84() in engine_core.h, so gather_externs has no
  extern line to harvest, and the member TU instantiates the macro BELOW our function.
- The wrong guess was the useful step: a no-prototype `extern s32 func_80142C84();` turned
  `undeclared` into `conflicting types` — a DIFFERENT error, proving the diagnosis right and the
  type wrong. Synthesised from the macro's own definition head -> MATCH (34 ins) -> 136/136.
- NEW macro_def_sig_map() (1,878 signatures): the complement of header_sig_map(), which reads the
  externs a macro emits FOR ITS CALLEES; this reads the signature a macro DEFINES. Cookbook §121.
- ALL THREE byte-identical stragglers carried since SESSION-24 are now closed: func_80146750
  137/137 (T84), func_801759D8 137/137 (T93), func_80142B2C 136/136 (T95) = 410 members, and not
  one was a compiler wall (a signedness-wrong header decl, a type-name collision, a missing extern).
- Blast radius 0 (74 further families re-swept). FOUR data points now: only §117 (wrong LOGIC)
  generalised at 1,209 members; §118/§120/§121 are path-reachability gaps worth ~one family each.
- GATES: R22 clean-fleet 140/140; dedup 1886/0; 0 NON_MATCHING (G4).
- METRICS: fn-count 91.88 -> 91.96% (+273, exact) · instr 87.3 -> 87.4% (+12,296) · distinct +0
  (both byte-identical families — §111 predicted exactly that).
2026-07-30 13:13:06 -06:00
Drew T 9a1507462f feat(phase-29): T93/T94 — func_801759D8 137/137 via type-uniquify (§120) + two T92 corrections
- CORRECTION 1 (R14/P9): T92's "strip-if-ambient" recipe was WRONG. Stripping the draft's duplicate
  typedef breaks the extern that USES it (the TU's own copy sits below the spliced function), so the
  "second stacked blocker" T92 recorded (D_800AF634 used prior to declaration) was my own fix
  misfiring, not a real blocker. RENAME, don't remove: rtu_match CC1 FAIL -> MATCH (56 ins).
- CORRECTION 2: T91's wiring never RAN. family_sweep has THREE staging sites sharing the identical
  two lines (edit-remap / hseq / plain h_norm); I patched by rindex twice, which lands on the PLAIN
  site, so --hseq staged the draft unchanged and the lever looked ineffective. Re-anchored on the
  hseq site's unique write (func_{to_addr:08X}.c) and the draft came out renamed. T91's revert was
  right discipline on a false premise.
- RESULT: _uniquify_draft_types wired into the hseq path (byte-neutral — C type names never reach
  codegen). func_801759D8, one of the three long-standing byte-identical stragglers: 0 -> 137/137,
  0 failed. Blast radius 0 (74 further families re-swept, none moved) => TARGETED lever, like §118
  and unlike §117.
- Cookbook §120, incl. the law: before concluding a lever does not work, prove it RAN — diff the
  staged artifact for the change it is supposed to make.
- GATES: R22 clean-fleet 140/140; dedup 1886/0; 0 NON_MATCHING (G4).
- METRICS: fn-count 91.88 -> 91.92% (+137, exact) · instr 87.3 -> 87.4% (+7,672) · distinct +0
  (byte-identical family — §111 predicted exactly that).
2026-07-30 12:57:32 -06:00
Drew T 9f1f2e94b6 docs(phase-29): SESSION-25 final checkpoint v6 — 3-step recipe for the stacked blocker 2026-07-30 12:15:29 -06:00
Drew T 2b76b73f73 docs(phase-29): T92 — typedef blocker confirmed by experiment; a SECOND blocker behind it
- Read the colliding decls out of the ASSEMBLED t.c (the step T91 named): the draft's file-scope
  typedef S_AF634 (line 2885) vs the TU's OWN file-scope S_AF634 (line 3016), character-identical,
  with the draft landing above. Stripping the draft's duplicate CLEARS the error — by experiment,
  not inference.
- SECOND BLOCKER revealed behind it: "D_800AF634 used prior to declaration" — the draft's
  extern S_AF634 D_800AF634[] sits at BLOCK scope below its first use (the §8d demotion). So
  func_801759D8 is two STACKED blockers; a typedef-only fix will still gate-fail. Recorded so the
  strip is not billed as the family's answer.
- tu_ambient DOES scan the whole file, so _uniquify_draft_types should have handled #1 and did not.
  Left unresolved rather than spend budget reconstructing a patch I had already reverted — but
  func_801759D8 is now a reproducible test case to gate any re-wiring against.
- Ordered recipe recorded: strip ambient-duplicate typedefs -> fix the §8d demotion (hoist the data
  extern above first use) -> re-probe with rtu_match -> only then sweep. 137 members / ~130 distinct,
  and the auto-named S_* typedefs recur across the byte-identical stragglers.
- No banks; tree clean; src/ untouched (the probe ran in .run/ and a scratch copy).
2026-07-30 12:14:54 -06:00
Drew T f09c80e8a9 docs(phase-29): SESSION-25 final checkpoint v5 — typedef-redefinition blocker named, §119 matrix exhausted 2026-07-30 11:29:46 -06:00
Drew T dac90f0fa1 docs(phase-29): T91 — §119 matrix exhausted; still-zero blocker is a typedef redefinition
- Ran the last untested corner (--fix-def-sig only) over the 82 still-zero families: 0 banked.
  The 2x2 is now fully enumerated (both 0 / neither 9 / NSD-only 23+138 / fds-only 0), so §119 is
  SPENT on this population — a clean negative for one sweep's cost.
- PROBE (func_801759D8, 137 members): rtu_match -> CC1 FAIL, conflicting types for 'S_AF634'.
  The TU already carries that typedef at file scope AND at block scope; the draft carries it too,
  and gcc-2.7.2 rejects a typedef redefinition even when character-identical. This class needs
  STRIP-IF-AMBIENT, not rename-if-colliding.
- Wired canon_sig_reconcile._uniquify_draft_types into the hseq staging path (it lived only on
  --reconcile-raw — the 5th 'lever unreachable from this path' this phase), re-probed, and the
  error was UNCHANGED. REVERTED it: a default-ON change to the shared staging path that did not
  fix its own motivating case and that I cannot validate on remaining budget is the T80/§61
  failure mode. The 3-line diff is trivial to redo once it can be gated.
- Named next step: the error's line numbers are ASSEMBLED offsets, not source ones — read the
  preprocessed t.c to find which two decls actually collide, then make tu_ambient see file-scope
  typedefs (or drop the draft's when the TU declares the same name). 137 members / ~130 distinct.
2026-07-30 11:29:15 -06:00
Drew T cc27701863 docs(phase-29): SESSION-25 final checkpoint v4 — 2,302 banked, fleet 87.3% instr / 78.0% distinct 2026-07-30 10:54:40 -06:00
Drew T f7c6d2eb2f feat(phase-29): T89/T90 — 0x80161c98 138/138 via the flag off-diagonal (§119) + a T84 correction
- CORRECTION (R14/P9): T84's '137 banked = all of 0x80161c98' is WRONG and committed wrong in
  commit:1193. The 137 were func_80146750 (a byte-identical straggler), banked 1-per-overlay in
  <ov>_after.c; 0x80161c98's members were still stubs. I assigned a count to the family I had
  been looking at without deriving it — third instance today of that error class. The
  --fix-def-sig-is-harmful finding itself stands (it unblocked func_80146750 x137).
- THE REAL BLOCKER was a flag OFF-DIAGONAL, not a defect. 0x80161c98's byte truth is (int,u32)
  -> sltiu; engine_core.h says (s32,s32); and an in-TU decl disagrees with the def. The levers
  pull opposite ways: --fix-def-sig bends the DEFINITION to the header; --normalize-self-decls
  bends the DECLARATIONS to the definition. both-on -> slti DIFF (T79). both-off -> correct
  sltiu but 'conflicting types' (T84/T88). NSD-only -> 138/138 (T89). Three sweeps across three
  sessions tested only the diagonal of the 2x2. Cookbook §119.
- T90 blast radius: 23 more (NSD-only) across the remaining still-zero families — targeted, not
  general; recorded so it is not over-projected.
- GATES: R22 clean-fleet 140/140; dedup 1886/0; 0 NON_MATCHING (G4).
- METRICS: fn-count 91.84 -> 91.88% (+161, exact) · distinct-code 69,593 -> 69,744 (+151).
2026-07-30 10:54:06 -06:00
Drew T a9c7f09775 docs(phase-29): SESSION-25 final checkpoint v3 — 2,141 banked, fleet 87.3% instr / 78.0% distinct 2026-07-30 10:27:01 -06:00
Drew T bf71232d0b feat(phase-29): T87/T88 — ordinal immediate resolution (§118): 158 banked
- The T86 asm-ambiguous refusal was CORRECT (a by-value swap would corrupt the non-differing
  occurrence); the safety TEST was too strict. It compared the C literal's occurrences against
  EVERY asm use of that value, but gcc synthesises uses no C token names — e.g.
  D_80187044[*(u16 *)((s32)a0 + 0x2)]() has one C literal 0x2 and TWO asm uses of 2 (the
  per-member offset + a fixed sll ..,2 for the 4-byte stride). Unsatisfiable by construction.
- FIX (_ordinal_edits, §118): pair C occurrences to asm positions IN ORDER, accepting either
  len(spans)==len(asm_pos) (every use named) or len(spans)==len(diff_pos) (extras are implicit).
  Rewrite only occurrences whose instruction is in diff_idx. Order is a heuristic, so the
  whole-binary byte-gate stays the sole arbiter — a wrong pairing is rejected, never banked.
- T87: func_801599A4 0 -> 137 drafts, 137 banked; +12 singletons = 149 (family 0x80131eec).
- T88 blast radius: only 9 of the other 144 immediate-refusals converted (refusals 67 -> 34).
  A TARGETED lever, not a second §117 — recorded so it is not over-projected.
- GATES: R22 clean-fleet 140/140; dedup 1886/0; 0 NON_MATCHING (G4).
- METRICS: fn-count 91.79 -> 91.84% (+158, exact) · distinct-code 69,450 -> 69,593 (+143).
2026-07-30 10:26:26 -06:00
Drew T 48a5bc358e docs(phase-29): SESSION-25 final checkpoint v2 — 1,983 banked, fleet 87.3% instr / 77.9% distinct 2026-07-30 09:53:35 -06:00
Drew T 1175849d01 docs(phase-29): T86 — items 3/5/6 resolved; item 6 was 8 eligible not 126 (my error) 2026-07-30 09:53:01 -06:00
Drew T dcbeebaf49 feat(phase-29): T84/T85 — 0x80161c98 137/138 + func_801457A4 133/133 (+270 members)
- T84 (item 1): the top still-zero family's whole diff was ONE instruction — slti (signed) vs the
  target's sltiu. --fix-def-sig was conforming a byte-correct draft to engine_core.h's
  signedness-wrong decl (extern void func_80161D20(s32,s32)) while the exemplar's own def is
  (int, u32). Re-swept the 92 still-zero families WITHOUT the flag: 137 banked (all of
  0x80161c98), other 91 unmoved => family-specific, NOT a second §117. Recorded as such.
- T85 (item 2): rewrote tools/rollout_801457a4_o0.py as the two-file ATOMIC driver §116 called for
  (remapped body -> <ov>_o0b.c AND drop the INCLUDE_ASM from <ov>_after.c in one edit; build vs
  config/check.<ov>.sha; restore BOTH files on mismatch, §61). Validated on 3, then 130/130.
  No splat change — the Arm-A re-carve wall never touched.
- Item 4 PRICED AND DROPPED: STRUCT residue = 34 families / 166 members / 0.02pp.
- R14: my new_distinct estimator over-projects ~2x (priced 259, measured 125) — it counts classes
  unmatched at run time, so concurrent sweeps double-count. Ranks correctly, overstates absolutely.
- GATES: R22 clean-fleet 140/140; dedup 1886/0; 0 NON_MATCHING (G4).
- METRICS: fn-count 91.72 -> 91.79% (+270, exact) · instr 87.2 -> 87.3% (+16,946) ·
  distinct-code 69,325 -> 69,450 (+125).
2026-07-30 09:51:02 -06:00
Drew T 3cb0e68fe4 docs(phase-29): SESSION-25 final checkpoint — 1,713 banked, fleet 87.2% instr / 77.8% distinct 2026-07-29 23:36:25 -06:00
Drew T 9d0ce20015 feat(phase-29): T83 — the §117 blast radius: 821 members, 138 families zero -> complete
- Re-swept the 229 eligible non-jr families (2,575 candidate members) that had never seen a
  correct target spelling. 821 banked / 1,538 failed; 138 families went zero -> COMPLETE (732
  members), 14 partial, 92 still zero. Top: 0x80172780 +135, 0x80128158 +31, 0x80187318 +28,
  0x8016f540 +27, 0x8017bef8 +20.
- Every one of those 138 families had been swept before and booked as a failure. None was a
  compiler problem — all were downstream of the one positional-map defect fixed in T82.
- GATES: R22 clean-fleet 140/140; dedup 1886/0; 0 NON_MATCHING (G4).
- METRICS: fn-count 91.48 -> 91.72% (+821, exact) · instr 86.9 -> 87.2% (+33,670) ·
  distinct-code 69,024 -> 69,325 unique fns (+301).
- The 92 still-zero families are the honest residue: swept with every lever this phase built
  (§114 callee, §115 named-symbol, §117 symbol-kind, def-sig, self-decl normalization), so no
  known harness defect applies to them. Correct starting population for the next diagnosis round.
2026-07-29 23:35:45 -06:00
Drew T 28dc3785f5 feat(phase-29): T82 — symbol-KIND fix in symbol_map: func_80174784 2/255 -> 251/251 (§117)
- CAUSE: family_remap.symbol_map zips exemplar/sibling reloc slots positionally and spelled the
  SIBLING's symbol from the EXEMPLAR's kind. Same-address families always agree, so it was
  invisible for 20+ phases; cross-address families need not agree — func_80174784's callback slot
  is the FUNCTION func_801747CC while member func_8017CFD4's same slot is the DATA symbol
  D_80182688. The map emitted func_80182688, the body materialized a name for an address that is
  not a function, and the fleet gate refused all 251 members.
- FIX: spell the target by what the target address IS in the SIBLING's overlay (func_ iff in that
  overlay's sig set — the same boundary oracle nins_of trusts, R33; memoized). Phase 26-A had
  already established this rule and applied it only to the exemplar side.
- WHY IT HID: rtu_match/match_one MASK HI16/LO16, so a wrong %hi/%lo symbol still reports a clean
  MATCH (measured: "MATCH (10 ins)" on a member the fleet gate rejected). masked-MATCH +
  whole-binary DIFF is the exact signature of a compiler wall. Cookbook §117 carries the law.
- Also refuted en route (cheaply): --normalize-self-decls was NOT the cause — re-swept without it,
  still 0/251.
- GATES: R22 clean-fleet 140/140; dedup 1886/0; 0 NON_MATCHING (G4).
- METRICS: fn-count 91.41 -> 91.48% (+251, exact) · distinct-code 68,782 -> 69,024 unique fns
  (+242, projected 246) · instr +2,510.
- BLAST RADIUS UNMEASURED: symbol_map serves every family sweep; 229 eligible non-jr families /
  2,575 members have never been swept with a correct target spelling, incl. the byte-identical
  families T76 measured at 0/682 (same failure shape).
2026-07-29 23:08:03 -06:00
Drew T 90a644fb80 docs(phase-29): T80/T81 — two 0/N diagnoses + the SESSION-25 checkpoint
- T80: the §116 rollout prescription was WRONG and the build refuted it in 56s across 133
  overlays. "Byte-neutral by construction" was a claim about the LINKER; splat keys asm/
  generation to the SEGMENT, so deleting func_801457A4's INCLUDE_ASM from <ov>_after.c stops
  func_801457A4.s being emitted and <ov>_o0b.c cannot assemble. Reverted, nothing committed.
  Cookbook §116 corrected IN PLACE with the refutation + the corollary (build it before you call
  it neutral). Real route: a two-file atomic driver (body -> _o0b.c AND drop the stub from
  _after.c in one edit). 129 distinct still on the table, now costed.
  tools/rollout_801457a4_o0.py kept as the inventory pass ONLY — do not --apply.
- T81: 0x80131eec 0/288, and the two halves have DIFFERENT blockers — func_80151944 (138)
  staged and gate-failed on the T71 decl conflict; func_801599A4 (137) + 13 singletons were
  REFUSED AT REMAP for unresolved immediates and never reached a compiler. My prediction that
  the correct-decl half would bank was the T76 error shape (reason from one property, ignore the
  disqualifying diff_class: IMM) — recorded, not buried.
  CORRECTION IT BUYS: T71's "the immediate engine is not the bottleneck" holds for T70's
  families and is FALSE here (150 of 288). T2a immediate resolution is now a named, sized lever.
- Refuted from source before spending a probe: the reloc tracker DOES see a function address
  materialized as an argument (LO_OPS includes addiu), so 0x80174784's 2/255 is not that.
- SESSION-25 checkpoint: fleet 86.9% instr / 77.4% distinct / 91.41% fn-count; 641 banked this
  session; ranked next-list with all six items measured. Nothing running, tree clean.
2026-07-29 22:49:28 -06:00
Drew T 774592c452 feat(phase-29): T79 — byte-VARIANT re-sweep: 641 banked; T70's "1 of 10" was a pre-lever measurement
- VALIDATED FIRST, then batched: 0x80143d28 (T66's #1, T76's ApplyMatrixSV callee diagnosis)
  banked 136/136 under the §114 callee axis + §115 named-symbol widening. Batch of 8 followed:
  505/1039. Totals: 5 families outright + 1 partial of 9; 641 members ×N.
- Attribution DERIVED (R33), not parsed from the sweep log: live stubs recomputed per family from
  corpus.stubs before/after. Reconciles exactly against the metric (fn-count +641).
- §116 (NEW): optimization level is a property of the FILE, not the function. 0x801457a4 swept
  0/137 because its exemplar lives in ov_SC01_077_o0b.c (-O0 via WHALE_O0B_OBJS) while all 137
  members' stubs live in <ov>_after.c (-O2). The fix moves the STUB line, not the def: <ov>_o0b's
  .text ends exactly at 0x801457A4, so the relocation is byte-neutral by construction and needs no
  splat re-carve (which is the Arm-A +0x20 wall). 13th time a family-wide 0/N was the harness.
- R14 CORRECTION to the handoff arithmetic: the tier is 123 families / 3,100 distinct on fresh
  sigs, but 1,287 of that distinct is the -O0 cluster behind the Arm-A splat wall. Honest
  addressable tier = 113 families / 85,360 ins / 1,813 distinct. Billing the walled 1,287 as sweep
  yield would have repeated the T76 error.
- 0x80131eec (214 distinct, the biggest item left) diagnosed precisely: header macro decl +
  §20 call-site cast + a scripted §99 pass over 2,022 overlay-local decls; param is void*, so the
  T75 narrow-param refusal does not apply.
- GATES: R22 clean-fleet 140/140 from make clean + extract-all + check-all; tools-health RC=0
  (corpus 0 PHANTOM/0 TRUNCATED, cdecl, audit-binaries, dedup 1886/0, C1 239604/239604);
  report RC=0; 0 NON_MATCHING (G4).
- METRICS: instr 86.7 -> 86.9% (+28,205 ins) · distinct-code 76.9 -> 77.4% (68,196 -> 68,782
  unique fns) · fn-count 91.23 -> 91.41% (+641). The distinct-code move is the point of this tier.
2026-07-29 22:36:09 -06:00
Drew T 47d7137a30 docs(phase-29): SESSION-24 REVISED-3 checkpoint — 2,180 banked, fleet 86.7% instr
Supersedes all three earlier SESSION-24 blocks. Session total reconciled against the metric (fn-count
320524 -> 322704 = +2,180; instr +152,366; per-task recount agrees exactly), the lesson earned ~12
times with every cause enumerated, a ranked measured NEXT list led by the byte-VARIANT re-sweep
(stale IN OUR FAVOUR — T70's 1/10 predates the §114 callee and §115 named-symbol levers, and 26 of 36
families were never swept), my errors, carried defects incl. the open §61 judgment call, and the 13
new cookbook entries.

Fresh session safe from here: HEAD commit:1186, nothing running, tree clean but for the R23 db.*.gbf
churn and a pre-existing .run/backlog.jsonl edit, R22 clean-fleet 140/140 (run 24x), tools-health OK,
dedup 1886/0, 0 NON_MATCHING.
2026-07-29 20:59:48 -06:00
Drew T 611622c9e7 feat(phase-29): T78 — PsyQ-symbol widening: func_8012F40C 0/137 -> 137/137 (three places, not one)
I called this "a one-line predicate widening". It was THREE, and fixing the first two changed nothing
— the sweep still reported 0/547 (cookbook §115):

  1. canonical_map     : re.fullmatch(r'func_[0-9A-Fa-f]{8}') + keyed by parsed ADDRESS
  2. DECL_LINE_RE      : (func_[0-9A-Fa-f]+) as the name group
  3. split_sig_string  : \bfunc_[0-9A-Fa-f]+\s*\(

Each is a SILENT SKIP indistinguishable from "no conflict found". With 1+2 done the symbol reached 3
and died there; only tracing transform's internals (`callees cast: 0` while the canonical map plainly
held `s32 RotTransPers(s32, s32, s32*, s32*)`) located it. THE TRAP WORTH REMEMBERING: a partial fix
to a name-form assumption produces the exact symptom of no fix at all, so a correct hypothesis looks
refuted. Curated naming increases as RE quality improves, so any func_-only predicate is
rot-by-design — the same shape as stub_map's (Phase 26-A).

RESULT: func_8012F40C 0/137 -> 137/137. The other three families (801759D8, 80146750, 80142B2C) still
fail on different causes.

GATES: R22 clean-fleet 140 passed, 0 failed of 140; tools-health OK; dedup 1886/0; 0 NON_MATCHING.
METRICS: instr 86.7% (+4,932 ins); fn-count 91.19% -> 91.23% (+137); distinct +0 (byte-identical).

NEXT: the byte-VARIANT tier is worth re-sweeping — T70 banked 1/10 BEFORE the callee axis existed, and
26 families remain unswept by the two levers added since.
2026-07-29 20:57:11 -06:00
Drew T 970559423d feat(phase-29): T77 — wire the callee-decl lever into family_sweep; func_80173A60 0/135 -> 135/135
Item 1. The T76 diagnosis was right and the fix was a lever we already owned. cast_call_sites
(§17a-1/§20) handles the callee-conflict class and lived ONLY in gate_stage, which the family sweep
deliberately does not use — the THIRD instance this session of a lever unreachable from the path that
needs it (T56 data-decl unreachable, T57 function-decl off-by-default, now T77 callee).

  the 5 byte-identical families : 0/682 -> 135/682
  func_80173A60 specifically    : 0/135 -> 135/135

Wired after scope_data_fix (orthogonal axes: data vs callee), default ON with --no-cast-callees. Two
details that matter: the canonical map is built from the TARGET sibling's TU via cpp
(canonical_map(ov, src_file=tu) -> cdecl.tu_scope) so it sees MACRO-INJECTED declarations — a
raw-text scan returns nothing for exactly the callees that conflict (§51g LAW 7) — and it is read
AFTER any tu-scope edit is on disk.

THE OTHER FOUR STILL FAIL, different causes. And the next finding is already visible:
func_8012F40C's blocker is RotTransPers, a PsyQ LIBRARY symbol — a callee conflict the cast should
have handled. It did not, because cast_call_sites' canonical map keys on
re.fullmatch(r'func_[0-9A-Fa-f]{8}'), so NAMED PsyQ callees are structurally invisible to it. That is
a one-line predicate widening with ~270 members behind it (RotTransPers + ApplyMatrixSV families).

GATES: R22 clean-fleet 140 passed, 0 failed of 140; tools-health OK; dedup 1886/0; 0 NON_MATCHING.

METRICS: instr 86.6% -> 86.7% (+7,965 ins); fn-count 91.15% -> 91.19% (+135); distinct +0
(byte-identical — §111 predicted it).

cookbook §114 — the three decl axes, and "conflicting types for X: READ X".
2026-07-29 20:34:09 -06:00
Drew T d9f1ccad45 docs(phase-29): T76 — byte-identical families bank 0 of 682; my recommendation was wrong
I recommended this as "the only remaining item with YIELD rather than findings — pure instr yield, no
new tooling". It banked NOTHING. Recording the reasoning error plainly.

WHERE IT FAILED: "byte-identical families bank 137/137" was true of T63/T64/T65/T68/T72 — but every
one of those had a specific blocker cleared FIRST. Byte-identity predicts the template is EXACT IF IT
COMPILES; it says nothing about whether it compiles. The still-unswept families are precisely those
never unblocked, so the property selects FOR being blocked. I had written that caveat two turns
earlier ("only true after each family's blocker is cleared; T58 swept 6 and banked 1") and then
ignored it when recommending.

THE BATCH: the 13 had already been drawn down to 6 by today's work; swept 5 (skipping func_80147364,
proven the narrow-param wall in T75) -> 0 banked / 682 failed.

DIAGNOSED TWO — two different causes, NEITHER the family's own function:
  func_80173A60 : conflicting types for func_80173B4C   (a CALLEE)
  func_8012F40C : conflicting types for RotTransPers    (a PsyQ LIBRARY symbol)
Same shape as 0x80143d28's ApplyMatrixSV. That is a THIRD distinct decl axis (not the def's, not the
shared header's) and nothing in the pipeline reconciles it.

HONEST STATE OF THE FAMILY LEVER — every cheap variant now measured: h_exact cores xN (spent),
byte-identical (0/682), byte-variant (1/10), -O0 (~1/137). The mechanical family sweep is EXHAUSTED
at 86.6% instr unless the callee-decl axis is addressed.

NEXT: cast_call_sites (§17a-1/§20) is the existing lever for the callee axis and is NOT in
family_sweep's pipeline — the same "lever unreachable from this path" shape as T56, ~410 members
behind it.
2026-07-29 20:17:00 -06:00