v1.19.0 "Afterburner"
Fifteenth release of the RustyNES-parity roadmap: an optional PGO/BOLT pipeline for the
shipping rustysnes binary, deliberately last per the plan (after mobile-specific hot-path
work landed, so the profile isn't invalidated).
Added
- PGO/BOLT pipeline (Mobile-track-adjacent, deliberately last per the RustyNES-parity
roadmap):scripts/pgo/run.shinstruments, trains against the committed permissive ROM corpus
(via a newcrates/rustysnes-test-harness/src/bin/pgo_trainer.rsbinary — thegilyon
CPU-instruction suite plus a handful ofundisbelieverHDMA-glitch/INIDISP-hammer ROMs, chosen
for control-flow breadth beyond the single steady-stateheadless_framebench ROM), and
rebuilds the shippingrustysnesbinary with the merged profile. New
.github/workflows/pgo.yml:workflow_dispatch+ release-tag push only (never the PR gate —
an instrument+train+rebuild cycle is far too slow for that). Promotion requires both a
measured>3%Criterion speedup over the plain release build and a byte-identical re-run
of the full--features test-romsoracle under the PGO-merged profile, citing
docs/adr/0004's determinism contract — never promotes on speed alone. An optional Linux-only
BOLT post-link stage chains onto an already-promoted PGO binary, best-effort. - Fixed a real, latent CI gap found while building this:
rust-toolchain.tomldidn't list
llvm-tools-preview, anddtolnay/rust-toolchainsilently ignores therust-setupcomposite
action's owncomponents:input whenever arust-toolchain.tomlfile exists in the repo (the
same behavior already found and fixed forios.ymlinv1.16.0) — without this,cargo-pgo's
.profraw/.profdatamerging would have silently failed to find the component on a fresh CI
runner. Addedllvm-tools-previewdirectly torust-toolchain.toml, the actual effective
source of truth. - Verified for real in this development environment: the full instrument → train (5 committed
ROMs) → optimized-rebuild pipeline produces a genuine, runningrustysnesbinary, and the
determinism oracle (cargo pgo optimize test) passes cleanly under the PGO-merged profile. The
local A/B speedup did not clear the>3%promotion bar on a short local training run (as
documented honestly indocs/performance.md— this is an expected, not a failure, state; a
short/narrow local run isn't representative of CI's real3600-frame training sweep).
Fixed
- A real bug in
pgo.yml's BOLT stage, found in PR review: re-invoking the whole
scripts/pgo/run.shbetweencargo pgo bolt buildandcargo pgo bolt optimizeran a
separate, non-BOLT PGO cycle that never fed BOLT's profile data and could clobber the
bolt-instrumented binary with an unrelated plain-PGO one. Fixed percargo-pgo's own
documented BOLT+PGO combined workflow:--with-pgoon bothcargo pgo bolt buildand
cargo pgo bolt optimize, with the erroneousrun.shre-invocation removed. Real BOLT profile
gathering (running the actual GUI frontend binary against a workload) stays out of scope —
this project's frontend has no headless CLI mode — so the fix deliberately usescargo-pgo's
own documented profile-less BOLT fallback instead.