Files
BFM-decomp/docs/backlog.md
T
Drew T ce79a3e432 docs(cookbook): §449 — four compiler dials from the S75 redraft wave, two byte-gate confirmed
Provenance stated per row (CONFIRMED = banked through the whole-binary gate;
CLAIMED = the agent's own measurement on a function that did not bank), because
one of these came from a function that was adversarially upheld and then FAILED
the real gate.

A. reg_n_sets is a one-line scheduling dial (CONFIRMED, func_80180ABC 257 ins).
   sched1 schedules backward; a pseudo set exactly once gets the birthing_insn_p
   launch boost (priority = 7f000001 in cc1 -dS), which drags its load LATE.
   Splitting the RMW as 't = t + 1; *p = t;' makes reg_n_sets 2, suppresses the
   boost, and floats the load to the block head -- the block-local dual of §350's
   shared temp, WITHOUT the global-allocno penalty that costs the in-place addiu.
   Companions: 180 legal statement permutations all scored identically while one
   cc1 -dS dump named the cause (diagnose, don't permute); a pin-free fix for
   paired-register inversion; and gcc frame slot order is NOT declaration order
   (BLKmode aggregates go in order at expand_decl, an addressable scalar is
   forced to the stack later -- declare 's32 x[2]' to place a slot between two
   aggregates).

B. A single-set local's VALUE is visible at a switch join and erases a
   zero-extension (CONFIRMED, func_801806F8 241 ins). combine.c:10035 lets
   get_last_value bypass the label_tick guard when reg_n_sets == 1, so all seven
   narrowing spellings emit nothing. Diagnostic: a visible extension in the
   target means the variable has MORE THAN ONE SET in the original source.
   Verified against a matched sibling: andi is the multi-set zero-extend and
   sll;srl is NEVER reachable from a single expression.

C. CORRECTION to §439 -- the sll 16; srl 16 pair lands AFTER the jal, not before
   it (sched1 sinks the ashift past the call), and it works even for a KNOWN
   CONSTANT, because the call-split defeats folding structurally rather than by
   hiding the value.

D. An offline jtbl-rodata placement audit (CLAIMED, func_800CB00C -- did not
   bank, which is the point: both matchers compare .text only, so a jtbl
   function's MATCH says nothing about its table).
2026-09-03 00:30:55 -06:00

29 lines
4.4 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Backlog — automation near-misses for hand-finishing
> Generated by `tools/backlog.py render` from `.run/backlog.jsonl`. These are functions the Phase-21 automation got **close** on but did NOT byte-match. The whole-binary byte-gate is the sole arbiter (G3/P9): **byte-matches bank and are NOT listed here** — only genuine near-misses/blockers are. Ranked by hand-session priority: **reach** (×N propagation leverage) → **closeness** (match_one mismatch count, lower = closer) → **size**. Each row's `best_draft` is the closest C the machine reached — resume from there.
**Open near-misses:** 20 · by status {'near': 11, 'failed': 9} · by class {None: 20}
| # | addr | reach | class | nins | status | closeness | where it stuck | best draft |
|--:|------|------:|-------|-----:|--------|----------:|----------------|------------|
| 1 | func_80181804 | None | | None | near | 0 | match_one MATCH but the whole-binary gate rejected — CAUSE NOT DETERMINED. FIRST re-derive the destination TU from the asm subdir: asm/<ov>/nonmatchings/<TU_stem>/<fn>.s => src/<ov>/<TU_stem>.c (the third path component IS the TU). Only then look for a decl conflict or a codegen residual. | `.run/backlog_drafts/func_80181804.c` |
| 2 | func_80181CB8 | None | | None | near | 0 | match_one MATCH but the whole-binary gate rejected — CAUSE NOT DETERMINED. FIRST re-derive the destination TU from the asm subdir: asm/<ov>/nonmatchings/<TU_stem>/<fn>.s => src/<ov>/<TU_stem>.c (the third path component IS the TU). Only then look for a decl conflict or a codegen residual. | `.run/backlog_drafts/func_80181CB8.c` |
| 3 | func_8002B0B4 | None | | None | near | 0 | match_one MATCH but the whole-binary gate rejected — CAUSE NOT DETERMINED. FIRST re-derive the destination TU from the asm subdir: asm/<ov>/nonmatchings/<TU_stem>/<fn>.s => src/<ov>/<TU_stem>.c (the third path component IS the TU). Only then look for a decl conflict or a codegen residual. | `.run/backlog_drafts/func_8002B0B4.c` |
| 4 | func_8017D918 | None | | None | near | 4 | residual: 4 mismatch | `.run/backlog_drafts/func_8017D918.c` |
| 5 | func_80182CBC | None | | 28 | near | 7 | resolver DIFF (real-TU rtu_match, 20260825-233820): mine=28 target=28 | `.run/backlog_drafts/func_80182CBC.c` |
| 6 | func_80180EC0 | None | | None | near | 9 | residual: 9 mismatch | `.run/backlog_drafts/func_80180EC0.c` |
| 7 | func_80181294 | None | | None | near | 19 | residual: 19 mismatch | `.run/backlog_drafts/func_80181294.c` |
| 8 | func_80181344 | None | | None | near | 48 | residual: 48 mismatch | `.run/backlog_drafts/func_80181344.c` |
| 9 | func_80180B3C | None | | 297 | near | 125 | resolver DIFF (real-TU rtu_match, 20260825-233820): mine=296 target=297 | `.run/wave_eo/shard478/func_80180B3C.c` |
| 10 | func_800CB00C | None | | 123 | near | 168 | resolver DIFF (real-TU rtu_match, 20260826-053145): mine=174 target=123 | `.run/wave_g0c/shard30/func_800CB00C.c` |
| 11 | func_80180B3C | None | | 21 | near | 287 | resolver DIFF (real-TU rtu_match, 20260826-022235): mine=287 target=21 | `.run/wave_eq/shard63/func_80180B3C.c` |
| 12 | func_800D06E8 | None | | None | failed | | resolver CC1 (real-TU rtu_match, 20260825-233820): .run/resolver/work/resident__func_800D06E8/c0/rtu/func_800D06E8/t.c:1770: conflicting types for `Struct80078E78' | `.run/wave_ch/shard62/func_800D06E8.c` |
| 13 | func_8017FBCC | None | | None | failed | | won't compile standalone (loose-typing / missing decl) | `.run/backlog_drafts/func_8017FBCC.c` |
| 14 | func_801832F8 | None | | None | failed | | won't compile standalone (loose-typing / missing decl) | `.run/backlog_drafts/func_801832F8.c` |
| 15 | func_8017F018 | None | | None | failed | | won't compile standalone (loose-typing / missing decl) | `.run/backlog_drafts/func_8017F018.c` |
| 16 | func_8018095C | None | | None | failed | | won't compile standalone (loose-typing / missing decl) | `.run/backlog_drafts/func_8018095C.c` |
| 17 | func_80181720 | None | | None | failed | | won't compile standalone (loose-typing / missing decl) | `.run/backlog_drafts/func_80181720.c` |
| 18 | func_8018DFC4 | None | | None | failed | | won't compile standalone (loose-typing / missing decl) | `.run/backlog_drafts/func_8018DFC4.c` |
| 19 | func_80062144 | None | | None | failed | | won't compile standalone (loose-typing / missing decl) | |
| 20 | func_80180B3C | None | | None | failed | | won't compile standalone (loose-typing / missing decl) | `.run/backlog_drafts/func_80180B3C.c` |