# RPTP project state — synthetic cross-path runtime; Gate 2 open

- **Snapshot date:** 2026-10-31
- **Remote repository:** RidTheWann/RPTP-Project, public.
- **Publication and CI status:** PRs #10–#76 merged every increment; latest PR #76 `6b77fd5` (run `41173920804`), after PR #75 `3db5bb0` (run `41161339070`), all green. See [VERIFICATION_LOG.md](VERIFICATION_LOG.md); local checks are not CI.
- **Git workflow:** `main` integrates; use isolated worktrees, explicit staging, local verification/review, both exact-head compiler jobs, pinned-head merges and merge-commit CI, as authorized in [AGENTS.md](../AGENTS.md). No direct main push, force-push, history rewrite or administrative override.
- **Manual automation:** user-profile `/rptp-develop` and read-only guards stay outside the repository; GitHub CLI write access is verified. Accepted Gate boundaries are unchanged.
- **Architecture:** from-scratch static ahead-of-time recompilation of supported Emotion Engine code to C++, plus a native Windows x64 runtime planned.
- **License:** GPL-3.0-or-later confirmed by the owner on 2026-10-21 (ADR-0001). **CLI/log/error language:** English.
- **Build outputs:** local only; never commit build directories, Python caches or generated binaries.
- **Verification evidence:** append-only [VERIFICATION_LOG.md](VERIFICATION_LOG.md); per-increment traceability in [INCREMENT_LEDGER.md](INCREMENT_LEDGER.md).
- **Progress page:** `https://ridthewann.github.io/RPTP-Project/progress.html`, generated by `tools/rptp_progress.py`.

## Single current status

1. **Gate 0:** accepted as a **technical pass for the narrow synthetic differential-spike scope**, recorded 2026-10-23 by owner delegation. It covers only the synthetic ELF32/EM_MIPS fixture and tested subset; it is not a clean-room certification, runtime, boot or compatibility claim. See [GATE0_REVIEW.md](GATE0_REVIEW.md).
2. **Gate 2:** **not passed** and read-only under [ADR-0004](DECISIONS/ADR-0004-gate2-read-only-scope.md); extraction needs a separate ADR and threat model. PRs #34/#36 record the inspector review, hardening and non-block-aligned lengths after an ECMA-119 re-check. The owner's disposition is open; gaps are in [GATE2_EVIDENCE.md](GATE2_EVIDENCE.md).
3. **Gate 3:** **not passed**. The `tools/rptp` pipeline (PR #35, `93bbc9c`) adds an R5900/MMI decoder, low-level IR, trusted-seed CFG, deterministic C++20 generation, a Python oracle and dual-model differentials. The subset includes aligned LD/SD, branch-likely, ordinary-branch, doubleword-shift and COP1-transfer forms (`RPTP-REF-015`). [research/isa-evidence.md](research/isa-evidence.md) (PR #37, `0944c84`) records 55 Level B instructions, 216/224 decoder-crosschecked, 174 unverified claims. Function discovery (PR #42, `0fd6186`) proves no extents. [ADR-0005](DECISIONS/ADR-0005-canonical-execution-path.md) (Proposed; owner decision required) records the canonical-path proposal; E3 is covered (PR #61). No product recompiler or game-code generation exists.
4. **ISO inspector and census:** single-volume ISO 9660, strict descriptor/record/config validation, root `SYSTEM.CNF`, BOOT path resolution, ELF PT_LOAD bounds/alignment/order/zero-fill, entry load-map metadata with overlap warnings, SHA-256 metadata, byte budgets, an error taxonomy and a metadata-only directory survey exist. All authorized images were censused read-only at 142 supported mnemonics: acceptance 76.96%–86.30%, a lower bound for the current 146. Counts include data/padding: an upper bound, not coverage. No extraction, execution or compatibility is implied.
5. **Native runtime foundation:** C++20 `rptp_runtime` provides sparse guest memory, a fail-closed ELF32 little-endian `ET_EXEC`/`EM_MIPS` `PT_LOAD` loader (`rptp-load`, `rptp.runtime.load.v1`, stable `LOAD_*` errors) and a synthetic execution harness (`rptp-run`, `rptp.runtime.run.v1`) for the documented subset, with `EXEC_*` errors and a step budget. The harness executes the eight branch-likely, six ordinary, nine doubleword-shift, six byte/halfword, eight HI/LO integer and four COP1 forms, enforces the `LW`/`SW`, `LH`/`SH`, `LWC1`/`SWC1` and `LD`/`SD` alignment policy, records width-tagged stores and is compared with the oracle and generated C++ by the cross-path suite. Test vehicle only: no kernel, syscall, ISO ingestion, boot or compatibility. Contract: [RUNTIME.md](RUNTIME.md).
6. **Provenance:** the Gate 0 spike, ISO inspector and native loader are `Provisional independent`; the build/CI/doctor layer is `Review required` and none is certified. The branch-likely, ordinary-branch, doubleword-shift, COP1-transfer, alignment and `tools/rptp` increments are `Recorded` expansion work. See [CLEAN_ROOM_AUDIT.md](CLEAN_ROOM_AUDIT.md) and [PROVENANCE_PLAN.md](PROVENANCE_PLAN.md).
7. **Repository baseline:** CMake presets, the RPTP doctor, CTest targets and Windows/Linux CI exist; the build/CI/doctor layer remains `Review required` ([BUILDING_WINDOWS.md](BUILDING_WINDOWS.md), [BUILD_PROVENANCE.md](BUILD_PROVENANCE.md)).
8. **Game work:** the owner-authorized retail samples are inspected, censused and indexed in [docs/games/README.md](games/README.md). No boot, recompilation, native port or compatibility exists.

## Scope and blockers

The accepted Gate 0 scope is the synthetic ELF32/EM_MIPS fixture and only ADDIU, ADDU, LW, SW, BEQ, BNE, J, JAL, JR and NOP plus tested delay slots. Later differentials (through the byte/halfword, HI/LO and COP1 forms), IR/CFG, known-edge reachability and lowering work are post-disposition Gate 3 work: no runtime-reachability, dead-code-proof, function-extent, product-runtime or compatibility claim.

1. **Provenance reviews (open):** the owner must decide whether the recorded ISO review satisfies the Gate 2 prerequisite; independent Gate 0 and build/CI/doctor reviews remain release prerequisites.
2. **Gate 2 (open):** multi-extent and ISO-variant review plus the owner's disposition; interleaved layouts are rejected although the BP 27/28 field mapping is spec-checked.
3. **Clean-room/source exposure (policy resolved):** prior exposure is documented in [REFERENCES.md](REFERENCES.md) and ADR-0001; ADR-0003 seals the affected projects and is not a legal guarantee.
4. **License (resolved):** GPL-3.0-or-later confirmed 2026-10-21; SPDX headers cover project source, build and workflow files.
5. **Renderer (open):** none selected or tested; ADR-0002 remains a plan.
6. **Dependencies:** no runtime dependency is vendored or linked; record license, version and notices before adding one.
7. **Path divergence (open, `R-031`):** the Gate 0 spike, `tools/rptp`, the older `rptp_ir`/`rptp_lower` pipeline and the C++ harness model instructions separately. Branch-likely, the six ordinary forms, the nine doubleword shifts, the four COP1 transfers and the alignment policy agree across `tools/rptp`, the harness and the cross-path suite, but the older paths reject them. [ADR-0005](DECISIONS/ADR-0005-canonical-execution-path.md) (Proposed; owner acceptance required) proposes `tools/rptp` plus the harness as canonical, freezes the legacy paths and defines E1–E4; `tests/test_path_contract.py` covers E1/E2, `tests/test_native_legacy_equivalence.py` covers E3 and four `tests/test_fail_closed_*.py` modules cover every E4 class; E4 awaits owner acceptance and no canonical path is declared.

## Next steps

1. Owner accepts or rejects [ADR-0005](DECISIONS/ADR-0005-canonical-execution-path.md); E3 and every listed E4 class have evidence, so owner acceptance is the remaining retirement prerequisite.
2. Apply the per-instruction semantics matrix from PR #45 to choose the next instruction family from the census distribution, under [PROVENANCE_PLAN.md](PROVENANCE_PLAN.md): permitted references, independent tests, fail-closed diagnostics and informative commit bodies.
3. Continue Gate 3 with the next narrow, tested step; keep function discovery conservative and never infer extents or reachability from candidate lists.
4. Commission the remaining provenance reviews; never claim clean-room certification or compatibility first, and do not infer boot support from an inspection, loaded image or generated artifact.
