Features — IronFrame OuterFortress (Cart) 01 Decomp
Overview of what this repository supports today (v0.4.0 Execution Lockstep, clean-room Bank 1..4 / BANK_06 table decoders, and zero-tell clean idiomatic C11 baseline) and what is scheduled for v1.0.0 (Archival Gold Reference). See ROADMAP.md for the full release plan.
Feature Summary
| Feature | Status | Target | Primary Code | What It Does |
|---|---|---|---|---|
| Clean-Room 6502 Assembler | Live |
v0.1.0 |
Dev/scripts/asm6502_d5.py |
Assembles symbolic 6502 source (56 mnemonics, 151 opcodes) to 1:1 ROM bytes (8/8 banks). |
| Self-Contained BYO-ROM Unpacker | Live |
v0.1.0 |
Dev/scripts/nes_unrom_unpack.py |
Validates .nes SHA-256/CRC32, splits Mapper 2 banks, traces CFG (nes_6502_cfg.py), and supports --offline-synthetic. |
| Cohesive Domain C Modules & Tiers | Live |
v0.2.0 |
Dev/scripts/coalesce_d4_modules.py, Dev/scripts/materialize_decomp_tiers.py |
Consolidates 68 line-split fragments into 26 domain C modules (499/499 functions), resolves all 299 raw globals & 44 raw calls (0 raw tokens, 8 synthesized adapters), and preserves raw, sliced, mapped, and clean C11 local tiers. |
| Clean Idiomatic C & Zero Warnings | Live |
v0.3.0 |
Dev/scripts/craftsmanship_d4_{helpers,ast_cleaner,normalizer}.py |
Eliminates all decompiler tells across 34 C/header files (507 symbols), compiles 26/26 modules with 0 errors/warnings under -Wall -Wextra -Wno-unused-parameter, emits 5 zero-body d4_rewrites/*.json shards, and syncs 36 files into Corpus/readable/. |
C11 NesBus & Execution Lockstep |
Live |
v0.4.0 |
Dev/scripts/d4_harness/, Dev/scripts/{d4b_oracle_bridges,run_d4b_lockstep}.py |
Drives 650 frames / 5 gameplay scenes ($0100-$01FF stack masked) in clean-room C11 NesBus, achieving mismatchedFrames: 0 against Mesen 2.1.1 plus reCart InterpreterOracle differential witness and 8/8 linked clean C11 checkpoints. |
Bank 1..4 & BANK_06 Table Decoders |
Live |
v0.4.0 |
Dev/scripts/decode_*.py, Dev/docs/specifications/*.md |
Extracts room/metatile/CHR, guard/spawn/weapon/password, and codec/BANK_06 audio tables strictly to --out-dir (Corpus/work/decoded_tables/) with unresolvedFieldCount: 0 across 4 specification spokes. |
Portable .decomp Bundle & Packager |
Live |
v0.4.0 |
Dev/scripts/export_decomp_bundle.py, Dev/scripts/package_release.py |
Emits reCart (0.1.x) validated v0.4.0 IronFrame-OuterFortress-Cart-01.decomp (55 entries including d4_build_report.json, d4b_lockstep_report.json, decoder scripts, and 5 d4_rewrites/*.json shards) and 10-invariant release mirrors. |
| Offline Unit Tests & Track Verifiers | Live |
v0.4.1 |
Dev/scripts/tests/, Dev/scripts/{d4b_validation_helpers,verify_track_d5}.py |
Passes 27/27 offline unittest tests (-W error), 17/17 full (11/11 synthetic) verify_track_d5.py checks, 10/10 host parity assertions, and lockstep report/spoke/link hygiene checks. |
| Symbol, Module & Call-Graph Catalog | Live |
v0.4.0 |
Dev/schemas/ |
Indexes 507 symbols across 26 domain modules (499 functions + 8 adapters), 2,324 mapped globals (2,344 header externs), 44 call overrides, 22 structs, 22 enums (unresolvedFieldCount: 0), 5 rewrite shards, and 0 retail strings. |
| Technical Manuals, Emblems & Docs Site | Live |
v0.4.0 |
Dev/docs/, Dev/assets/, .github/workflows/ |
Documents UNROM topology, 4 specification spokes, lockstep/table findings, and clean-room operations with CI validation and human-first GitHub Pages generation. |
| Archival Gold Certification | Planned |
v1.0.0 |
Dev/schemas/, Dev/scripts/ |
Certifies fresh-clone BYO-ROM round-trip (CRC32=25BA3D04), s5_gold_report.json, finalized Gold manuals, and non-prerelease release status. |
Capability Details
C11 NesBus Runtime & Execution Lockstep
- What it does: Implements a cycle-synced clean-room C11
NesBusruntime (56mnemonics /151RP2A03 opcodes, RP2C02 PPU scanline 241 VBlank NMI and odd-frame skip,$4014OAM DMA, RP2A03 APU/DMC latches and DMA stalls, UNROM bus-conflict latching) driving650deterministic frames across5gameplay scenes ($0100-$01FFhardware stack masked) withmismatchedFrames: 0against Mesen 2.1.1 (--testRunnerLua tracer), passing8/8live clean C11 linked checkpoints and cross-checking read-onlyreCart.Core.dllInterpreterOracle(650frames,649transitions, boot WRAM CRC32f1e8ba9e) into digest-onlyd4b_lockstep_report.json. - Entry Points: run_d4b_lockstep.py, d4b_oracle_bridges.py, d4b_validation_helpers.py, nes_bus.h, nes_bus.c, nes_ppu_apu.c, nes_cpu_ops.c, nes_cpu_exec.c, d4b_lockstep_scenes.c, d4b_lockstep_report.json
- Tests: test_d4b_and_decoders.py
Clean-Room Bank 1..4 & BANK_06 Table Decoders
- What it does: Decodes
256rooms (165unique),6metatile/attribute tilesets,18door returns,8elevators,17special warps,256room neighbor vectors (235unique),51CHR headers,256$FD00/$FE00room metadata bytes,123patrol pointers (96unique),160dialog pointer offsets (144unique, metadata only with zero retail text),217room actor spawns (85unique),7weapon/projectile tables,4password layout tables,7codec frequencies,255room call tables (75unique,116entries,72unique message IDs),5volume envelopes,12note periods,132sound/BGM descriptors (64SFX /68BGM), anddmc[0]strictly into--out-dir(Corpus/work/decoded_tables/) withunresolvedFieldCount: 0inspec_coverage.json(5/5checks). - Entry Points: decode_rooms_and_metatiles.py, decode_guards_and_weapons.py, decode_codec_and_audio.py, decode_all_bank_tables.py, spec_coverage.json
- Specifications & Tests: rooms-metatiles-and-chr-format.md, guards-weapons-and-password-format.md, codec-and-bank06-audio-format.md, test_d4b_and_decoders.py
Clean Idiomatic C11 Normalizer & Zero-Body Rewrite Shards
- What it does: Transforms all
26cohesive C modules (507symbols =499catalog functions +8synthesized adapters across34C/header files) into zero-tell idiomatic C11 (0decompiler tells,0warnings under-Wall -Wextra -Wno-unused-parameter): removes dead stack locals, zero-initializes and renames register/SSA locals, unrolls69comma-operatorifconditions, parenthesizes55bitwise&expressions, lowers P-code macros and typed pointer/array accesses (g_actor_soa_ram[128],g_apu_mmio_regs[24]), emits clean fixed-widthghidra_compat.h(s8..u64only) plus zero-suppression.clangdandcompile_commands.json, syncs36files intoCorpus/readable/, and generates5dependency-grouped zero-body JSON shards underDev/schemas/d4_rewrites/. - Entry Points: craftsmanship_d4_helpers.py, craftsmanship_d4_ast_cleaner.py, craftsmanship_d4_normalizer.py, d4_rewrites/
- Verification & Tests: test_tiers_and_coalesce.py, synthetic_d4_fixtures.py, d4_build_report.json
Cohesive Domain C Coalescer & Multi-Tier Snapshots
- What it does: Merges all
499functions out of68line-split fragments into26domain-grouped C modules (10fixed-bank core modules +16switchable-bank overlay modules), resolves1local label,22synthetic/bank-scoped alias entries (20deduplicated externs), and44raw cross-bank function calls with0remaining raw tokens, synthesizes8clean-room bank/signature adapters and9sub-entry prototypes (factor,table_index), and materializes preserved raw, sliced, mapped, and clean C11 local snapshot tiers (36synced files inCorpus/readable/). - Entry Points: coalesce_d4_modules.py, materialize_decomp_tiers.py, d3_module_map.json, d3_symbol_overrides.json
- Verification & Tests: test_tiers_and_coalesce.py, d4_build_report.json
Clean-Room 6502 Assembler & BYO-ROM Unpacker
- What it does: Implements a pure-stdlib two-pass MOS 6502 assembler (
56official mnemonics,151opcodes,13addressing modes,a:absolute override) alongside a self-contained UNROM unpacker and CFG tracer (nes_6502_cfg.py) that reproduces all8PRG banks and the131,088-byte image (CRC32=25BA3D04) without external archive binaries. - Entry Points: asm6502_d5.py, build_and_verify_d5.py, nes_unrom_unpack.py, nes_6502_cfg.py
- Verification & Tests: d5_byte_match.json, standalone_integrity.json, test_nes_unpack_and_asm.py
Portable .decomp Bundle, Release Packager & Verification CLI
- What it does: Exports and verifies deterministic
v0.4.1IronFrame-OuterFortress-Cart-01.decomparchives (55entries, includingd4_build_report.json,d4b_lockstep_report.json, decoder scripts, and the5d4_rewrites/*.jsonshards) validated againstreCart(0.1.x) clean-room rules (0retail strings,0C function bodies,0harness/test leaks), stages 10-invariant release bundles, and enforces17/17full verification checks (11/11offline synthetic) via shared CLI path overrides (nes_cli_common.py) andd4b_validation_helpers.py. - Entry Points: export_decomp_bundle.py, package_release.py, verify_track_d5.py, d4b_validation_helpers.py, nes_cli_common.py, decomp_recipe.json
- Tests: test_decomp_cleanroom_and_release.py, test_scripts_cli_and_schemas.py, test_d4b_and_decoders.py
Modular Host C Parity & NesBus Harness
- What it does: Compiles all
26clean C11 domain modules under-Wall -Wextra -Wno-unused-parameter(0errors,0warnings,0decompiler tells, zero pointer-cast suppressions) and links the10-filed4_harness/suite (<= 242lines per file) to run both10/10host subsystem parity assertions (via<extracted_prg_dir>) and650-frame /5-scene execution lockstep +8/8live clean C11 checkpoints (via--lockstep <rom.nes> <out.json>). - Entry Points: build_and_verify_d4.py, parity_harness.h, parity_runner_main.c, parity_rom_and_mapper_tests.c, parity_gameplay_and_audio_tests.c, nes_bus.h
- Verification Output: d4_build_report.json, s4_verify_report.json, d4b_lockstep_report.json
Symbol, Type & Call-Graph Catalog
- What it does: Provides clean-room C headers and JSON registries covering the
NES-ME-USAmemory map,499named functions across8domains and26modules (507symbols with8synthesized adapters),2,324mapped globals (2,344header externs),22synthetic/bank-scoped symbol overrides,44cross-bank call mappings, and5zero-body rewrite shards (core_runtime.json,core_gameplay.json,overlays_b00_b02.json,overlays_b03_b04.json,overlays_b05_b06.json) with zero embedded retail strings or C bodies. - Entry Points: metalgear_types.h, functions_catalog.json, globals_map.json, d3_module_map.json, d3_symbol_overrides.json, d4_rewrites/, call_graph.json, spec_coverage.json
- Sub-Headers: nes_hardware.h, mg_player.h, mg_world.h, mg_audio.h
Research Technical Manuals & Documentation Site
- What it does: Captures verified
iNES Mapper 2 / UNROMbus-conflict mechanics ($FFD0-$FFD7LUT),$C6B7inline jump-table dispatch, reset/NMI/IRQ vectors,26-module clean C11 layout, timing lockstep, Bank1..4andBANK_06binary formats, and clean-room operations, compiled into a responsive light/dark human-first GitHub Pages site (pages.yml) with clean-room emblems (Dev/assets/). - Entry Points: ARCHITECTURE.md, SPECIFICATIONS.md, FINDINGS.md, OPERATIONS.md, pages.yml, ci.yml
- Spokes: symbol-and-bank-reference.md, rooms-metatiles-and-chr-format.md, guards-weapons-and-password-format.md, codec-and-bank06-audio-format.md
Archival Gold Pipeline (v1.0.0)
- What it does: Builds upon the completed
v0.4.0execution lockstep (mismatchedFrames: 0),unresolvedFieldCount: 0bank decoders, and validated55-entryIronFrame-OuterFortress-Cart-01.decompbundle to certify fresh-clone BYO-ROM archival Gold status (CRC32=25BA3D04) and publish the non-prerelease archival milestone. - Entry Points: research.manifest.json, ROADMAP.md