Skip to content

Latest commit

 

History

History
1100 lines (922 loc) · 56.3 KB

ImplementationPlan.md

File metadata and controls

1100 lines (922 loc) · 56.3 KB

XGrid implementation plan

XGrid is the Avalonia shell + native xemu core. This file is the single product and core roadmap; it merges the product plan with the core modernization program. User documentation lives in docs/.

Status legend: [x] done, [~] in progress, [ ] not started. Effort: S (days), M (weeks), L (months).

Current focus: the in-process cleanup, win-x64 capture benchmark baseline, native hardening gates, compile-time measurement, automatic renderer choice, encode worker and WASAPI low-latency path are in. The async compile queue is deferred by the sub-millisecond measurements. Next: HDR/VRR; Vulkan-default stays blocked on B11/B12. E3/E5, B11/B12 and H2/H4 remain open.

0. How the product is put together

  • One native core, one host. The shell launches a separate core process and talks to it over the token-authenticated loopback control channel. The in-process DLL, its flat exports and the Windows shims are removed; the core has no native host ABI (§3.1).
  • One machine per core process. Each session starts a fresh core process; stopping the session stops the process. This is what removes the single-use QEMU global-state limitation instead of trying to reset QEMU in place.
  • The core owns every emulated pixel. It opens its own top-level game window, runs the presentation filter and presents with its own swapchain. The shell never receives, copies, filters, overlays, scales or draws a frame. Child-window embedding is not part of the product because child windows cannot host the Vulkan swapchain.
  • The core is a service, not an application. One binary, one command contract, no user interface. New host operations enter through the command dispatcher, not through a new export, environment variable or ad hoc channel.
  • The control channel is the only host contract. The line protocol and the optional HTTP listener share one decoder and one dispatcher. There is no per-feature flat export in the product path.
  • Renderer-neutral pictures. GL and Vulkan publish frames through one surface contract; presentation, filters, screenshots and recording do not assume GL.
  • Settings resolve in one order: launch argument > command/ABI > environment > TOML > default. The effective values are available as JSON and config events.
  • Portable by construction. hw/ and system/ never include a platform SDK. Windows, macOS, X11 and Wayland code lives behind the host/window, host/audio, host/input and host/gl interfaces.
  • Upstream edits are patches. Every edit to an existing upstream file is recorded in xemu/xemu-patches/; References2/xemu-0.8.139 is the read-only baseline. New XGrid-native files are ordinary tracked files.

0.1 Current state

Area State
Shell Avalonia desktop shell with Library, Game, Screenshots, Memory cards, Settings, Activity and About. The shell manages launches and never reads a frame.
Core hosting Separate process is the only product host. The shell no longer loads a native DLL, the DLL build/packaging and the flat exports are gone, and the core has no native host ABI.
Presentation The core opens its own window and presents through GL/DXGI or a Vulkan swapchain. Vulkan is GL-free at startup and uploads VGA/2D frames. OpenGL is still the configured default.
Capture Headless runs always publish full pixels even when the runner only reads the 32-byte counter. The counter-only sink, the persistent Vulkan readback buffer, the capture timings, the benchmark script and the win-x64 reference baseline are in; the GL/multi-slot ring remains.
Media ISO/XISO, CHD, CCI and ZArchive drivers in the core; MEDIA PROBE/MEDIA BROWSE return JSON. The shell still uses the managed readers for product paths (E3).
Input and audio Four-pad shell input sink with rumble return; XInput on Windows, SDL3 on Linux/macOS; WASAPI, DirectSound, WAV and null audio backends. WASAPI shared mode uses a 50 ms safety buffer; low latency is §3.6.
Recording Core-side H.264 MP4 with PCM audio, MJPEG AVI fallback and instant replay. Encoding runs on one bounded worker queue over a reused capture ring; the hardware path remains (§3.7).
Reliability Windows minidumps and POSIX backtraces; crash marker and safe mode; atomic settings/card writes. Parser fuzzing, the WASAPI soak, ASan/UBSan, scoped TSan, C/C++ CodeQL, coverage, LTO and the format/tidy gates are in place.
Release Five RIDs packaged and verified, unsigned archives, SBOM and osv-scanner; Windows signing and CI parity remain.

The core is xemu 0.8.139 (aa54c34c, October 2026). There is no newer upstream release, but upstream master has 32 commits since the baseline; the selective port is tracked in §3.9.

1. Shipped

1.1 Application

  • Avalonia desktop shell: Game, Library, Settings, Memory cards, Activity and About; dark theme with accent palettes, menu, toolbar, log dock, status bar and toasts.
  • Library scan of ISO/CHD/ZAR/XBE with title parsing, multiple roots, recently played, optional online cover catalog, local covers and multi-disc .m3u playlists.
  • Keyboard and host-pad bindings (XInput on Windows, SDL3 on Linux and macOS) with capture, dead zones and trigger thresholds; controller assignment for players 1-4.
  • Per-title overrides (memory, renderer, texture filtering, presentation filter) keyed by title ID or path.
  • Pause, resume, single-frame stepping and 4x fast-forward.
  • Fullscreen Esc sequence from either window; the game window forwards Esc and F8 saves a core-side screenshot.
  • Command-line launch switches, settings overrides, --autostart, -fullscreen, --benchmark and headless runs with console/JSON reports.
  • Disc swap and eject in both hosting modes; core-side screenshots in both modes; dedicated Screenshots page.
  • First-run wizard, shortcut sheet and tooltips on every interactive control.
  • Serilog rolling logs, warning/error bug reports with environment and exception details, startup usage statistics and a GitHub update check.
  • Donationware banner with email-based donation verification.
  • Memory cards page: FATX card creation, attach/eject, browsing, import/export, folders, rename and delete.
  • Multi-page documentation mirrored in wiki/; XML documentation required for every public type and member.

1.2 Core integration

  • Core built from the tracked xemu/ tree.
  • Core-owned frame sink and shell pad input sink; generated xemu.toml per launch.
  • Firmware, storage, RAM, AV pack, renderer, scale, filtering, aspect, audio and DSP settings.
  • Four save-state slots through the command dispatcher and the separate-process control channel.
  • A command-only host surface: lifecycle, event transport and guest-memory access run through the command dispatcher and the separate-process control channel; no native exports remain.
  • Renderer capability manifest (xgrid-core.json).
  • Core-side MEDIA PROBE and MEDIA BROWSE over every disc driver, including FATX memory-unit listings. The shell still parses media with XGrid.Xbe/XGrid.XboxFs; that migration is E3 in §2.2.
  • EEPROM profiles: sys.eeprom carries region, language and video standard; the core patches the EEPROM in place and preserves serial, MAC and keys.
  • Colour and geometry controls: brightness, contrast, saturation, gamma, integer scaling and overscan after the DAC palette.
  • Vulkan and GL caches on disk, per title, with atomic writes and a global budget.
  • Guest memory access: RAM-only physical read/write and a polling FNV hash through the command dispatcher or the control channel, a 1 MiB transfer limit and range validation.
  • Per-title patch engine: user JSON patch files keyed by XBE title ID and certificate version, applied once through the guest memory API in either hosting mode.
  • Core-side recording, recording audio muxing and instant replay.
  • Input recording and replay: four-pad XGDI stream with virtual-time offsets and guest frames in .xgin files.
  • XMU manager: attach/detach/list through a queued command, persisted through [input.peripherals.*]; the shell creates and browses 8 MB FATX cards.

1.3 Media and packaging

  • ISO/XISO, compressed CHD, CCI and entry-form ZAR discs; XDVDFS synthesis for file-tree ZArchive discs.
  • win-x64 frontend archive carries the core under core/xgrid/.
  • Package gate: licenses, archive contents, checksums, manifest and CLI smoke verified for win-x64, win-arm64, linux-x64, linux-arm64 and osx-arm64.
  • Unsigned archives with documented SmartScreen/Gatekeeper behavior.
  • Dependency license texts in licenses/; ABI, version and upstream-commit baseline check; GPL-2.0-or-later license set and third-party notices.

1.4 Landed fixes

These were the red gates and regressions from the previous plan. They are recorded here so the remaining work is not confused with them.

  • Recording and instant replay restored through the frame sink (2.1).
  • Dependency-manifest gate green (2.2).
  • Four unprovenanced upstream files recorded in patches 0097-0100 (2.3).
  • Native build cleanup: duplicate declaration, dead helpers, missing returns and lifecycle buffer (2.4).
  • MAIN command dispatch has a 5-second timeout and a clean shutdown (2.5).
  • Display publication and input/rumble handshakes use release/acquire ordering and seqlocks (2.6).
  • Command handlers are reentrant; results are caller-owned (2.7).
  • ZAR sections are bounded at 64 MiB and range-checked (2.8).
  • GL context helper is embed-safe and does not exit the host (2.9).
  • Dead picture paths removed; core-drawn overlays restored (2.10).
  • Tree-level provenance gate added (2.11).
  • Docs that described removed code corrected (2.12).
  • Vulkan letterbox bars no longer show a clamped edge or the blit triangle's hypotenuse; the overlay stays inside the picture.

2. Architecture checkpoints

2.1 Principles

  1. The core is a service, not an application: one binary, one command contract, no UI.
  2. One protocol. The line channel and the HTTP listener call the same command dispatcher. No feature gets its own export, environment variable or ad hoc channel.
  3. Renderer-neutral pictures. NV2A backends publish frames through one surface contract; presentation and filters do not assume OpenGL.
  4. No hidden globals. New code receives a context; existing singletons are retired incrementally.
  5. Portable by construction. hw/ and system/ never include a platform SDK; platform code lives behind host interfaces.
  6. Emulation stays in the core; the shell never parses media for product behavior and never touches a frame.
  7. One hosting model. The product path is a separate core process per session. The in-process DLL is removed, not a fallback.

2.2 Checkpoint status

Area Done In progress Not started
A. Protocol A1-A12 - -
B. Frame sink B1-B3, B6, B7, B9, B10 B4, B5, B8, B11, B12 -
C. Context/lifecycle C1-C6 (C5 superseded by §3.1) - -
D. Events/logs D1-D5 - -
E. Media E1, E2, E4 - E3, E5
F. Host isolation F1-F5 - -
G. Safety G1, G2, G6 G3, G5 G4
H. Release H1, H3, H5, H6 H2, H4 -

Open checkpoints:

  • B4/B5/B8/B11/B12. Vulkan is the product path on Windows, Linux X11 and Wayland; macOS presents VGA/2D through MoltenVK but the 3D path still waits on the 96-sampler cap. The fixed GL/Vulkan scene is byte-identical on Windows; Linux and macOS anchors remain.
  • E3. Move GameEntry, GameLibraryService, MemoryCardsViewModel, HeadlessRunner, SettingsViewModel and the CLI onto MEDIA PROBE / MEDIA BROWSE. The managed XGrid.Xbe/XGrid.XboxFs readers remain the test oracle.
  • E5. Move a first media probe off the main loop. The cache makes repeats cheap; a miss of a large CHD/ZAR still stalls the guest. Add a worker with its own block graph, a timeout and a progress event, or document the stall.
  • G3. POSIX crash reports are backtrace summaries; symbolization and host-side attach remain.
  • G4. The stateful soak is bounded for Vulkan and NULL; OpenGL grows about 147 MB per snapshot load and still fails the bound.
  • G5. The renderer hook and PCM timing come from scripts/recording-audio-check.ps1; container tests cover the muxers.
  • H2. Windows signing is wired but needs a production certificate and a signed release check; the macOS DMG is ad-hoc signed.
  • H4. Linux native CI runs the full suite; the Windows GPU/null-run and frame-parity jobs need a registered Windows x64 GPU runner. Linux ARM64 has no native CI runner.

3. Core modernization program

The program has seven tracks plus one architectural decision. Each track is one or more logical changes with tests, docs and provenance. The tracks are ordered by dependency and risk in §7, not by this numbering.

3.1 Retire in-process hosting (architecture decision)

Decision: the separate process is the only product host. The in-process DLL and its flat exports and Windows shims are removed. The shell never loads a core library.

Why.

  • QEMU is single-use in practice. Resetting every global in place is a large, fragile project; a fresh process is the reliable isolation boundary.
  • A core crash cannot take down the Avalonia shell.
  • Starting, stopping and starting another game needs no shell restart and no "one machine per process" error path.
  • One hosting model removes the dual implementation of playback, snapshots, recording, memory cards, guest memory and presentation.
  • The DLL currently needs a fixed image base, a larger image stack, a CRT loader workaround and a Windows sigsetjmp/siglongjmp mapping. Those are maintenance and security costs with no product benefit once the process path has feature parity.
  • Linux and macOS already use the separate process; Windows should match.

Status: [x] the separate process is the only product host, the managed in-process code is gone, and xgrid_core.dll is no longer built or packaged. The validation checks use the control channel. The flat exports, the ABI baseline export list and the Windows sigsetjmp/thread-stack shims are removed; the core has no native host ABI.

Work.

  1. Default switch. Launch XGridCore.exe / xemu for every product session. Remove the shell's in-process host, the hosting setting, the UI choice and the DLL build/package. Record the chosen host in the launch plan and logs.
  2. Feature parity. Exercise every command over the control channel: snapshots, disc load/eject, XMU, recording, replay, input recording, guest memory, presentation, fullscreen, screenshots, statistics, events and CONFIG. scripts/remote-control-check.ps1 -Relaunch covers the repeated start/stop/start test; the crash path stays in crash-report-check.ps1.
  3. Supervisor. One XemuCoreProcess owns the child: job-object kill on shell exit, startup handshake with timeout, port/token cleanup, log capture, graceful STOP, crash detection and safe-mode offer. No orphaned core process after a shell crash.
  4. Guest memory. Keep the chunked MEMORY command as the contract. If the per-title patch engine or tools need lower latency, add a validated shared-memory window with the same range checks, not a DLL.
  5. Removal. The managed in-process host, the DLL build/packaging, the direct-load checks, the flat xgrid_core_* exports, the ABI baseline export list and the dormant thread-stack and sigsetjmp shims are gone. The core is a standalone service with no native host ABI.

Acceptance. No product path loads a core DLL. The live check's -Relaunch verifies a second session; a ten-cycle launch/stop/relaunch run remains a release-host check. Every command in step 2 passes over the channel. A forced core crash leaves the shell alive and offers safe mode. docs/reference/architecture.md, docs/development/core.md and docs/development/threading.md describe one host. Effort L; risk medium-high because the retirement touches packaging, tests and the ABI.

3.2 Capture and benchmark path

Goal: no pixel readback, conversion or shared-memory copy when the host only counts frames; no per-capture allocation or full fence wait when a capture is needed.

Status: [x] counters-only sink, present.sink-mode, the multi-slot Vulkan readback ring, the GL capture framebuffer and PBO ring, the capture timings, the benchmark script and the win-x64 reference baseline are in.

Current state.

  • HeadlessRunner always sets a display sink name, and ui/xemu.c publishes full pixels. The runner reads only the 32-byte header with TryReadCounter().
  • xgrid_display_publish_rgba() converts RGBA to BGRA pixel by pixel.
  • Vulkan read_display_pixels() uses a three-slot ring of host-visible buffers, command buffers and fences; GL RenderFramebufferToRgb() reuses one capture framebuffer and a two-buffer PBO ring.
  • Recording calls the same read for every sampled frame.

Work.

  1. Add the counters-only switch and xgrid_display_publish_counters(width, height, stride) to display/xgrid-display.h; it maps only the 32-byte header, writes the geometry and increments the frame counter.
  2. Add the present.sink-mode setting (0 pixels, 1 counters) and let HeadlessRunner select counters through the launch argument. Keep the sink enabled so the core still renders off-screen and hides the window.
  3. Add a persistent capture ring: three Vulkan staging buffers with fences, and a GL capture framebuffer with a PBO ring. Reuse it for screenshots, recording and the headless pixel path. A capture uses a slot whose fence is already signaled; the current copy is still awaited because the read API returns pixels synchronously.
  4. Add capture_us, readback_us and encode_us to the extended STATS tail and bump the layout version.
  5. Add a fixed-scene benchmark script that runs counters-only, records median frame time and 1% low, and compares against the previous release. The win-x64 reference baseline is recorded in benchmarks/core-benchmark/win-x64.json; the script can gate guest frame times as well as presented frames.

Acceptance. A counters-only headless run performs no glReadPixels, no Vulkan readback and no pixel copy; the published frame count matches the guest frame count. Screenshots and recordings are unchanged. The capture path uses a reused ring and reports its cost. Effort M; risk low.

3.3 Vulkan-first renderer

Goal: Vulkan is the default renderer wherever the core and driver support it; OpenGL is the compatibility fallback.

Current state. config_spec.yml defaults to OPENGL and GraphicsSettings.Renderer defaults to OpenGL. AUTO resolves to Vulkan when the core manifest lists it and the last Vulkan launch for the host did not fail; the resolved choice is persisted in renderer-state.json and the shell logs the reason when AUTO stays on OpenGL. A failed device still restarts with OpenGL. B11 (MoltenVK sampler cap) and B12 (Linux/macOS anchors) are still open.

Status: [~] auto selection and persistence are in; the default switch and the matrix remain.

Work.

  1. Close B11 and B12.
  2. Add renderer = auto: select Vulkan when the manifest lists it and the last Vulkan launch for that host succeeded; otherwise OpenGL. Persist the decision and the reason.
  3. Record a ten-title matrix on Windows x64, Linux x64 and macOS arm64: boot/2D, 3D, screenshots, save state, recording, disc swap and exit.
  4. Change the defaults in the core config, the shell settings and the settings UI. Keep OpenGL as an explicit choice and as the fallback.
  5. Emit one renderer event and one toast when the fallback happens, with the core log tail; the shell records the reason for the next AUTO decision.

Acceptance. A fresh install uses Vulkan on a capable host; an unsupported device falls back once with a clear event; the matrix passes; GL/Vulkan parity anchors pass; the docs say which renderer is default and why. Effort M; risk medium because driver coverage is the real constraint.

3.4 Async shader and pipeline compilation

Goal: a first-use pipeline or program does not stall the render thread.

Current state. Vulkan creates pipelines synchronously from the draw path; GL compiles programs on demand. Both have disk caches, so repeats are cheap, but a new effect or a new title still pays the first compile. STATS now reports the last GL shader/program compile and Vulkan pipeline creation time, and logs a warning above 16 ms.

Reference measurements on the win-x64 host with a cold shader cache: 0.35 ms for the last GL program compile and 0.016 ms for the last Vulkan pipeline creation. No compile reached the 16 ms warning. The async queue is therefore deferred: the disk caches and the synchronous path stay until a title or driver reports a material compile.

Status: [~] measured; the queue and GL fallback are deferred by the measurement.

Work.

  1. Measure first. Add shader_compile_us and pipeline_compile_us to STATS and log a warning when a single compile exceeds a frame budget.
  2. Vulkan: add a compile queue and worker pool. Look up the disk pipeline cache first; on a miss, enqueue a compile and draw with a fallback pipeline (or skip that draw) until the completion callback installs the real pipeline. Synchronize VkPipelineCache and cancel queued work on renderer switch and shutdown. Deferred by measurement: the reference pipeline compile is 0.016 ms; revisit when a title or driver exceeds the 16 ms budget.
  3. GL: load program binaries from the disk cache, add a fallback program, and only add a shared-context worker if the measurements show GL compile time is material.
  4. Drain or cancel the queue in the save-state and renderer-switch paths.
  5. Add tests for cache hit/miss, fallback draw, renderer switch and shutdown.

Acceptance. First-use compilation does not block the render thread beyond the agreed budget; the fallback picture is valid; the cache survives restart; renderer switch and shutdown do not deadlock. Effort L; risk medium-high.

3.5 HDR and VRR presentation

Goal: modern display output, still owned entirely by the core.

Current state. The Vulkan swapchain offers FIFO, mailbox, immediate and a driver-paced VRR choice through present.mode; Auto follows the existing vsync toggle. HDR output is selectable as 10-bit HDR10 (BT.2020 PQ) or 16-bit scRGB (linear, 80-nit reference) with paper/peak nits. The presenter requires the display's advanced-colour state on Windows and falls back to the other HDR format or to SDR. The monitor refresh rate comes from SDL's current display mode and is reported in STATS together with the active presentation and HDR modes. VRR uses VK_KHR_present_wait/present_id when available to keep two frames in flight, with a bounded timeout and driver-paced fallback. HDR10 and scRGB swapchains reached the display and passed recording checks on ten titles each; Vulkan validation is clean. Visual colour calibration on an HDR display remains a hardware review.

Status: [~] explicit presentation modes, HDR10/scRGB output with a safe SDR fallback, the refresh-rate readout, present-wait VRR pacing and the ten-title format matrix are in; visual colour calibration and a soft tone-map remain.

Work.

  1. [~] Add display settings: HDR mode (off, HDR10, scRGB), paper-white nits, peak nits, tone-map and present mode (vsync, mailbox, immediate, VRR). HDR10, scRGB, paper/peak and the present mode are in; a soft tone-map remains.
  2. Vulkan: query VK_EXT_swapchain_colorspace, select HDR10 ST2084 or extended sRGB linear, create a 10-bit or 16-bit swapchain and tone-map in the final blit. Fall back to SDR when the surface/format is unavailable.
  3. VRR: use VK_KHR_present_wait/present_id where available, expose the display refresh rate, and define how VRR interacts with the presentation frame limit. The explicit VRR mode, driver-paced immediate presentation, SDL refresh-rate readout and present-wait two-frame gate are in.
  4. Captures: tone-map to SDR for screenshots and recording by default; HDR capture is a later option. Captures read the SDR display image before the swapchain encode.
  5. Shell: capability probe, settings UI, safe-mode fallback and docs. The Settings page reports the primary display's HDR support and Windows HDR state; the core still probes the surface at launch.

Acceptance. HDR10 output is correct on a capable display; SDR captures are unchanged; VRR presents without tearing or judder; an unsupported device falls back cleanly; validation and the matrix pass. Effort L; risk medium-high.

3.6 Low-latency WASAPI

Goal: an optional low-latency shared-mode path without losing the stable 50 ms default.

Current state. audio/wasapiaudio.c defaults to a 50 ms shared buffer and polls GetCurrentPadding; exclusive mode exists. The WASAPI latency audiodev option now asks IAudioClient3 for a 10 or 20 ms period with the event callback and falls back to the 50 ms IAudioClient path. The negotiated period is in STATS and the Activity page; the soak takes -LatencyMs and -RequireLowLatency.

Status: [x] the setting, low-latency path, event-gated refill, fallback, statistics and soak are in; the ten-minute 10 ms soak remains a release-host check because it needs an active render endpoint.

Work.

  1. Add the shared-mode latency choice (10, 20, 50 ms) to Settings and the WASAPI latency audiodev option; audio.exclusive is unchanged.
  2. Use IAudioClient3::InitializeSharedAudioStream with AUDCLNT_STREAMFLAGS_EVENTCALLBACK and SetEventHandle when the endpoint supports it; fall back to the current IAudioClient path on any failure.
  3. Add an event-driven refill path while keeping the APU monitor ring and the silence fill. The endpoint event gates a refill while the buffer is more than half full; the APU audio timer remains the safety net.
  4. Report the negotiated period, padding and underruns in STATS and the Activity page.
  5. Extend the soak with -LatencyMs and a forced-stall case at the lowest supported period.

Acceptance. 10 ms shared mode is stable for ten minutes on Windows x64 and ARM64 hardware; unsupported endpoints fall back once; exclusive, null, WAV and DirectSound are unchanged; the soak passes. Effort M; risk medium.

3.7 Encode offload and hardware encode

Goal: recording does not steal render or TCG time.

Current state. xgrid_record_add_frame() copies each due frame into a bounded queue; one worker runs x264 or JPEG encoding and the container writes. The render thread never waits for the encoder. The queue depth and dropped frames are in STATS. The capture ring from §3.2 feeds the queue without a per-frame target allocation; the hardware encoder path remains.

Work.

  1. Add a bounded encode queue and one worker thread. Move H.264/JPEG encoding and container writes off the render thread, preserve timestamps and order, drain on stop and expose queue depth/dropped frames in STATS.
  2. Use the capture ring from §3.2 so a recording does not allocate or wait per frame. The queue and the ring are in.
  3. Phase 2: hardware H.264/AV1 through NVENC, AMF, QSV or VideoToolbox behind a runtime probe, with x264/AVI fallback and SDR tone-mapping for captures.
  4. Tests: container tests, long recording, A/V sync, dropped frames, replay save, hardware/software parity.

Acceptance. 1080p60 recording stays within an agreed frame-time budget; the hardware path works on supported GPUs; the fallback is identical; the shell still never receives a pixel. Effort L; risk medium-high because of driver and licensing work.

3.8 Native hardening and performance gates

Goal: catch memory and race bugs, scan the native code, and prevent performance regressions.

Current state. The native CI has warnings, unit/Xbox tests, fuzzing, a Linux ASan/UBSan job, a scoped nightly TSan job, C/C++ CodeQL, a nightly coverage report, a nightly LTO build, the win-x64 benchmark gate, a clang-format ratchet, a nightly clang-tidy gate and provenance gates. PGO remains an optional release experiment.

Status: [x] the native hardening gate set is in place.

Work.

  1. Add a Linux native-sanitize job with -Dasan=true -Dubsan=true that runs the native suite and the short fuzz pass. Run a longer fuzz pass nightly.
  2. Add a scoped TSan job for the shared-memory, input seqlock, rumble and event-ring stress tests.
  3. Add C/C++ CodeQL with a manual or build-mode-none extraction and path filters to first-party code; run it weekly and on native changes.
  4. Add clang-format and clang-tidy gates for xgrid-core/ and the touched ui/xemu* files, with an accepted-findings baseline.
  5. Add native coverage (llvm-cov/gcov) for the native unit tests; report first, gate later.
  6. Add LTO release builds, an optional PGO profile and the fixed-scene benchmark gate from §3.2. LTO is built and tested nightly, and the native-benchmark job applies the win-x64 baseline. PGO remains an optional experiment.

Acceptance. The sanitizer jobs are green on the native suite; CodeQL is clean for first-party paths; format/tidy have a recorded baseline; LTO builds pass; the benchmark baseline is recorded and a large regression fails the gate. Effort M; risk low-medium.

3.9 Upstream sync

The baseline is xemu 0.8.139 (aa54c34c); upstream master has 32 commits since that point. The tree evolves separately, so this is a selective port, not a release rebase.

Ported: 25e1ee2fd5, 03b988c9d7, bf45c033b0, 6f797b9c88, 49bfab07a5, 97ef814361, 04ff7fb4a7 and 8593a61ae7, recorded in 0101-nv2a-upstream-fixes.patch, 0104-nv2a-two-sided-lighting.patch, 0106-nv2a-rcp-rounding.patch and 0110-nv2a-renderer-switch-reclaim.patch. b2aeafac4b was already present. 0105 rejects corrupt GL shader-cache entries; 0108 refreshes the SDL3, toml++ and VMA pins; 0111 adds the Vulkan texture swizzle fallback.

The point-size and colour ports (0051, 0053, 0054, 0055) were checked against 49bfab07a5 and 6f797b9c88: the generated GLSL already uses the rgba aliases, the point-sprite helper has no linear-texture assert, and the Xbox point-size, point-sprite and swizzle tests pass. XEMU_REVIEWED_COMMIT is now 04ff7fb4a750496e311498550bfb8ce5f54b7534 (the newest ported upstream commit), and docs/reference/upstream-differences.md records it.

The remaining upstream work is the next review window; do not replay the historical patch files, they are records, not a script.

Acceptance. The upstream report is green, the provenance check reports no unrecorded edit, the native suite passes against the new headers, and the reviewed commit is current.

4. Product roadmap

4.1 Release engineering

0.4.0 shipped the single frontend + CLI + core bundle on five RIDs, the per-user Windows installers and the Apple Silicon DMG.

  • Align release.yml with scripts/package.ps1: package the real bundles, run package-verify.ps1, and smoke-test the x64/ARM64 installers, both AppImages and the DMG on native runners.
  • Add the native media producer and artifact-upload jobs.
  • Add native-core CI jobs for Windows x64 and ARM64.
  • Complete the update flow: GitHubUpdateChecker reports a new version and offers an explicit Download action that verifies the published SHA-256 and opens the installer or archive. Never install silently.
  • Dry-run the release workflow with publish=false against 0.4.0 media.
  • Ship 0.4.0 with the false bug-report fix, the compatibility matrix, the release-workflow fixes and the installer/DMG follow-ups.
  • Automate the ARM64 installer smoke.
  • [~] Ship the separate-process-only release; the DLL is already removed from the installer and manifest, so the next package gate verifies the archives contain no xgrid_core.dll.

4.2 Validation and compatibility

  • [~] Vulkan validation. The Khronos layer loads on the Windows test host with explicit synchronization validation. Zero-extent swapchain creation on a minimized window and the uninitialized overlay placeholder layout are fixed; a windowed 3D run reports no validation messages. Linux X11/Wayland present the same frame; Linux/macOS anchors remain (B12).
  • Record the 0.3.0 boot matrix: ten titles on Windows x64 and Linux x64, three titles on Windows ARM64, Linux ARM64 and macOS; input on Windows and save states on both Windows architectures.
  • Validate on real Windows ARM64 hardware with a vendor OpenGL 4.x driver and a working audio endpoint.
  • Extend the ARM64 and macOS columns to all ten titles.
  • Add in-game scene checks, not only publisher/title frames.
  • Reproduce the Linux x64 matrix on a faster GPU/CPU host.
  • Add a netplay end-to-end check: two shell instances over loopback, the lobby protocol, host/join, System Link Ethernet and the Chihiro relay.
  • [~] Add the performance budget: per-runner benchmark baselines (median frame time, 1% low, startup) and fail only on large regressions. The win-x64 guest-frame baseline and CI gate are in; the other runners remain.
  • [~] Add the Vulkan-default matrix from §3.3 and the HDR/VRR checks from §3.5. HDR10 and scRGB swapchains reached the display on ten titles each; VRR and Vulkan validation are clean. Visual HDR colour calibration remains.

4.3 Separate game window

The product follows the RPCS3 model: the Avalonia shell manages the launch, and the core opens its own top-level game window with its own swapchain.

  • Windows: the game runs in its own window for OpenGL and Vulkan.
  • Vulkan is a true backend: a Vulkan launch creates no GL context or GL filter, and VGA/2D frames upload into the Vulkan display image.
  • Xbox pads stay on the portable shell input sink for both backends.
  • Linux X11 and Wayland: the core opens the separate window, presents Vulkan through its own swapchain and reaches a 3D frame.
  • [~] macOS uses the same separate window. MoltenVK presents VGA/2D, fan draws are triangle lists and texture swizzles use the pixel-shader fallback, but the 96-sampler cap keeps the product on OpenGL for 3D. B11 closes this.
  • Fullscreen and focus shortcuts target the game window; F11, Alt+Enter, F8 and Esc work from either window.
  • Audio selection reaches the running core through AUDIO.
  • Shell pad input and rumble with the separate window; the physical rumble check remains in §4.7.
  • Remove the in-process window/host choice; the game window is always the child process's window.

The former single-window embedding (X11 reparent, macOS NSView, Wayland subsurface, Windows child/overlay) was removed: child windows cannot host a Vulkan swapchain reliably, and the D3D11/overlay alternatives were withdrawn.

4.4 Graphics

The core has OpenGL, Vulkan and NULL render backends plus DXGI presentation on Windows. Direct3D 11 was removed; Vulkan covers Windows, and a third GPU path split the renderer work for no product gain.

Vulkan presents through its own swapchain in the separate game window: the display image is published as a VK_IMAGE, the filter pass runs in Vulkan and the picture never touches the CPU. With vsync off the swapchain uses IMMEDIATE (MAILBOX fallback). The core reads frames back only for screenshots, recording/instant replay and headless output.

Remaining work:

  • [~] Validation and parity (B4/B5/B12).
  • Present handoff. The Vulkan display pass is fenced, the presenter returns the display image through a semaphore ring, and the GL path releases one pass later on a GL fence instead of glFinish(). A PRESENTING submit stays in flight; the display pass queues behind it and the next command-buffer use reaps the fence.
  • [~] Platform surfaces (B8/B11).
  • Device-failure fallback. A Vulkan launch has no GL context, so the shell detects a device-initialization failure and relaunches the title with OpenGL instead of switching in-process.
  • Vulkan default (§3.3).
  • Async pipeline compilation (§3.4).
  • [~] HDR and VRR (§3.5): explicit presentation modes, HDR10/scRGB output with paper/peak controls, the refresh-rate readout, present-wait VRR pacing and the ten-title format matrix are in; visual colour calibration remains.

Do not advertise Vulkan as a fully independent backend until the macOS portability gaps and the deterministic parity scene pass.

4.5 Library

  • Optional online cover-art catalog; local and R2 covers share annotation stripping and Jaro-Winkler matching; content-addressed cache.
  • Multi-disc playlists (.m3u/.m3u8): one library entry, relative or absolute discs, first disc on launch and referenced discs hidden.
  • Next disc command and a Disc N of M indicator.
  • Automatic "insert disc" prompt for the next playlist disc. The manual swap remains the fallback; the guest usually leaves the virtual tray closed, so revisit with a title-tested tray or read probe.

4.6 Platform

  • Standalone core build on Linux from the tracked tree.
  • Package a core build in the Linux frontend archive.
  • [~] Separate game window on macOS: the Metal surface presents the VGA/2D frame, but the 3D path waits on the sampler cap (B11).
  • Verify Linux save states through the control channel.
  • Verify save states on macOS through the control channel.
  • Quiesce the APU promptly with the DSP enabled.
  • Validate a handheld/Steam Deck profile on the Linux AppImage (gamescope, suspend/resume, shell pads and audio device changes).
  • Make Windows ARM64 a first-class release host: Vulkan on a vendor driver, WASAPI playback, the ten-title matrix and the low-latency soak.

4.7 Core input and audio

Rumble return path

  • XGDI version 3: 32-byte input plus a 16-byte output tail per pad (rumble left/right, core sequence, reserved).
  • The core writes rumble for INPUT_DEVICE_XGRID; the shell applies XInput vibration and writes neutral on pause, stop, rebind and exit.
  • Layout version bump and round-trip test.
  • Manual test with a title that uses continuous and impulse rumble.

WASAPI

  • wasapi driver on IMMDeviceEnumerator, IAudioClient and IAudioRenderClient, with shared and opt-in exclusive mode.
  • Shared mode accepts the core's 48 kHz S16 stereo mix; exclusive falls back on unsupported format, disallowed mode or period mismatch.
  • Register the driver, add it to the -audio-drivers probe, and put it before DirectSound in the priority list.
  • Select endpoints by endpoint ID; enumerate friendly names; refresh and fall back to the default endpoint.
  • Handle device loss with IMMNotificationClient.
  • Validate a physical endpoint unplug, replug and default-device change on Windows hardware.
  • Track buffer duration, padding and underruns in STATS.
  • Feed the APU monitor mix to the selected QEMU backend through a ring and callback; keep the SDL stream as a muted pacing clock.
  • Hold the shared endpoint with a 50 ms buffer and fill quiet passages with silence.
  • Verify the routed APU mix against the AC'97 path on a host with audio.
  • Add the instrumented soak; a ten-minute Windows x64 run is clean and a forced 4 s stall adds exactly one underrun.
  • Low-latency shared mode (§3.6) and its soak.
  • Verify null, WAV and DirectSound remain selectable; update the audio guide, configuration, architecture, compatibility and settings tests.

Cross-platform shell pad input

  • XInput on Windows and SDL3 on Linux/macOS behind one host-pad interface; stable IDs, friendly names and hot-plug.
  • Select exactly one input path per launch: shell pads when the input sink is active, SDL pads for Chihiro and hosts without the sink.
  • Test players 1-4, keyboard merge, rumble, disconnect/reconnect and a controller added while the game runs on Windows, Linux and macOS.

4.8 Recording and capture

  • Core-side H.264 MP4 with PCM audio, MJPEG AVI fallback and instant replay; the render loop samples the frame sink after present.
  • Recording audio muxing; MP4 sowt and AVI auds tracks; long captures spool audio beside the file.
  • Capture ring and counter-only sink (§3.2).
  • Encode worker and hardware H.264/AV1 (§3.7).
  • HDR-to-SDR tone-mapped capture after §3.5.

5. Core enhancement backlog

These are candidate additions to the custom core, ordered by leverage rather than by release. Effort is S (days), M (weeks) or L (months).

5.1 Quick wins

  • EEPROM profiles (S-M) - region, language and video standard; patch in place, preserve serial/MAC/keys; auto region from the XBE certificate, auto language from the UI locale.
  • Colour and geometry controls (S) - brightness, contrast, saturation, gamma, integer scaling and overscan in the final blit.
  • Vulkan cache on disk (S-M) - VkPipelineCache and generated shader modules under the per-title cache; corrupt files are ignored.
  • Core statistics ABI (S-M) - frame count, present time, draw calls, VRAM and title ID.

5.2 Foundation

  • Guest memory access (M) - RAM-only physical read/write and a polling FNV hash; 1 MiB transfer limit and range validation.
  • Per-title patch engine (M) - user JSON patch files keyed by title ID and optional certificate version.
  • Cross-platform control channel (M) - token-authenticated loopback TCP for playback, snapshots, disc, memory units, recording, replay, input, guest memory and live presentation settings.
  • XMU save manager (M) - attach/detach/list, persisted through [input.peripherals.*]; the Memory cards page creates, browses, imports, exports, organizes, renames and deletes saves.
  • Media worker (E5, M) - move a cold MEDIA PROBE/BROWSE off the main loop with a worker, timeout and progress event.

5.3 Flagship differentiators

  • Core-side recording and instant replay (M-L) - frame-sink sampling, MP4/AVI writers, PCM audio and the replay ring.
  • Texture pack injection (L) - hash uploaded textures after unswizzle and substitute per-title DDS/PNG packs across GL and Vulkan. Deferred until test packs are available.
  • Direct Chihiro GD-ROM launch (M) - cue/bin, CHD, ZIP, XBOXOG ISO and FATX .bin; converts on first launch with the saved MAME key and caches the FATX image.
  • Core-native Chihiro GD-ROM mount (L) - boot and decrypt the disc in the core instead of preparing a cached netboot image.
  • Input recording and replay (M) - four-pad XGDI stream with virtual-time offsets and guest frames in .xgin files.
  • Hardware encode (L) - see §3.7.

5.4 Deep work

  • Disc and video accuracy (M-L) - XDVD security responses, PAL50/video timing and the open NV2A edge cases in the upstream watchlist.
  • APU and Chihiro audio (M-L) - cyclic voice-list lockup, surround hangs and missing Chihiro effects.
  • 256 MB guest RAM (S) - optional experimental sys.mem_limit.
  • CPU clock control (M) - optional experimental CPU frequency selection; needs a tested timing model.
  • Rewind (L, research) - frame-accurate rewind over the snapshot store. Input replay is the first step.

5.5 Renderer engineering review

A read-only comparison against RPCS3 0.0.44 found useful renderer, synchronization and instrumentation engineering. This is an idea source, not a porting commitment; any re-implemented algorithm follows docs/legal/porting-policy.md.

  • Diagnostics v2 (S-M) - p50/p95/p99/1% low frame times, present late-count/late-max and the NV2A_PROF_* cache/shader counters.
  • Present handoff (M) - fenced display pass, semaphore handoff and GL release on a fence instead of glFinish().
  • Surface-to-texture without a CPU round-trip (M) - replace the glReadPixels + glTexImage2D slow path in pgraph/gl/surface.c with region-aware sampling of compatible render targets. Start with base-level, same-format, whole-surface cases.
  • Deferred ZPASS report retirement (M) - stop blocking on glGetQueryObjectuiv(GL_QUERY_RESULT) in pgraph/gl/reports.c; queue reports, retire them on a result-available tick, write the report block with one atomic 16-byte store and set done. Needs a synchronous fallback outside TCG and a drain in the save-state path.
  • State-signal dirty mask and texture-stage pruning (S-M) - map NV2A register groups to dirty bits, skip unchanged uniform/state uploads, and bind only the texture stages the current pixel shader samples.
  • Cache namespacing and hygiene (S) - per-title shader/pipeline cache directories keyed by title ID + XBE timestamp/size, one global budget with 80% LRU trimming, atomic list writes and boot preload.
  • Async pipeline compilation (M, conditional) - see §3.4. Measure Vulkan and GL compile time first because NV2A shaders are small.
  • Texture cache predictor (M, research) - confidence-based write/flush history for texture ranges. Only pursue if SURF_DOWNLOAD/SURF_UPLOAD profiling shows repeated churn.
  • Region-based surface store (L-XL, research) - split/invalidate/reuse overlapping render targets and preserve contents across pitch/format changes. High accuracy value, high risk; requires a title-driven corpus and per-backend traits.

Do not port: PPU/SPU LLVM/ASMJIT recompilers, PPU function analysis, persistent TCG code caches, RSX FIFO flattening, generic RSX DMA offload, or the shader interpreter. They are Cell/RSX-specific or move GL work off the render thread without a matching win.

5.6 Backlog order

Before new features, close the remaining Vulkan gaps (B11/B12) and the separate-process retirement (§3.1). Then run the capture/benchmark path (§3.2), the hardening gates (§3.8), Vulkan-default and async compilation (§3.3/§3.4), audio and encode work (§3.6/§3.7), and HDR/VRR (§3.5). For frame time, diagnostics v2 is shipped; run surface-to-texture, deferred ZPASS and state pruning next. Cache hygiene can land in parallel; async pipeline compilation and the two research items wait for measurements.

  1. Texture packs when test packs exist.
  2. Core-native Chihiro GD-ROM mount.
  3. Disc/video accuracy and APU/Chihiro audio.
  4. CPU clock control; rewind stays a research project.

6. Reliability, data safety and engineering hygiene

Sections 2-5 cover features. This section covers failures that are cheap to prevent now and expensive to debug after release. Two controls already exist and should not be rebuilt: SettingsStore writes through a temp file and backs up corrupt JSON, and releases carry SPDX plus native CycloneDX SBOMs with an osv-scanner pass.

6.1 Quick Resume and snapshot compatibility

  • Autosave the session snapshot on pause and at a configurable interval; rotate between xgrid-session and xgrid-session-backup; update the resume sidecar and wait for an in-flight request before a failed-stop report.
  • Crash-safe resume: each save writes the inactive generation, and the sidecar (temp file plus rename) is the commit point.
  • Restore on the next launch; a successful resume deletes both generations and the sidecar.
  • Record the core build, title ID and timestamp; skip a mismatched resume with an Activity warning.
  • Test a crash, a forced power loss and a core rebase.
  • Compress the state payload and add an integrity hash once the container format is versioned; the qcow2 store has no explicit XGrid compression layer today.

6.2 Crash safety and safe mode

  • Crash marker with the launch plan; xemu/xgrid-crash.json keeps the count and the last launch summary.
  • Windows minidump and POSIX backtrace/core dump; reports land in XGRID_CRASH_DIR; the shell logs the newest one.
  • After two consecutive crashes, offer safe mode: null audio and OpenGL.
  • XGRID_CRASH_TEST=1 and scripts/crash-report-check.ps1.
  • Symbolize POSIX crash reports and add a host-side attach path (G3).
  • Exercise the safe-mode offer from the separate-process crash path after §3.1.

6.3 Settings and memory-card data safety

  • Settings schema version and migration chain; refuse a newer schema with a readable message.
  • Back up a memory-card image before a rewrite and offer Restore; edits use temp + verify + rename.
  • The same temp + rename discipline for cache writes, including GL shader binaries and the LRU list.
  • Test corrupt JSON, a read-only folder, a full disk and an interrupted write.

6.4 Parser fuzzing

  • Bound every directory allocation by the container before reading it: ZAR name/tree tables, FATX entries, XDVDFS entries and XBE section totals.
  • Deterministic test-xgrid-fuzz for XBE certificate/sections, XDVDFS tables and FATX directories; 2000 mutated inputs in the unit suite.
  • Block-backed ZAR/CHD/CCI fuzz targets through the block graph and media layer.
  • Split the control-line parser and fuzz 50,000 mutated lines per run.
  • Short corpus in CI and a longer nightly pass; crashes become regression inputs under tests/.
  • Run the corpus under ASan/UBSan in the hardening job (§3.8).

6.5 Build and provenance gates

  • Tree-level provenance: every changed upstream file is recorded in a patch record or an owned path.
  • Native first-party warnings are clean; vendored subprojects may keep their warnings.
  • xemu_upstream_report.py --check, host_include_check.py, core-baseline.ps1, package-verify.ps1 and git-audit.ps1 are green in the same run.

6.6 Native hardening and performance gates

See §3.8. The gate set is:

Gate Scope Cadence
ASan + UBSan Linux native unit/Xbox suite and short fuzz Every native change
TSan Shared-memory, input seqlock, rumble and event ring Nightly
CodeQL C/C++ First-party native paths Weekly and native changes
clang-format / clang-tidy xgrid-core/ and touched ui/xemu* Every native change
Native coverage xgrid-core unit tests Nightly report
LTO Release core builds Release
PGO Optional release profile Release experiment
Benchmark budget Fixed headless scene (median/1% low/startup) Nightly on the stable runner

7. Implementation order

Order by dependency and risk, not by the order of the sections. Each step is one logical change with tests, docs and provenance.

Phase 0 - Baseline and measurement

  1. Add capture/readback/encode timings to STATS (§3.2, step 4).
  2. Add the fixed-scene benchmark harness and record the current baseline (§3.2, step 5). The harness is in and the win-x64 reference baseline is recorded; other runners still need their own.
  3. Re-run the Vulkan validation check and the frame-parity anchors.

Phase 1 - One hosting model

  1. Make the separate process the only product host and remove the managed in-process path (§3.1, steps 1-2).
  2. Extend the live control check to every command and add the repeated start/stop/relaunch test (§3.1, step 2). -Relaunch verifies a second session.
  3. Consolidate the process supervisor and crash handling (§3.1, step 3).
  4. Remove the in-process DLL, exports, shims and baseline entries (§3.1, step 5). The DLL build and packaging are gone, and the flat symbols and the Windows shims are removed.

Phase 2 - Honest capture

  1. Add the counter-only sink and present.sink-mode (§3.2, steps 1-2).
  2. Add the Vulkan/GL capture ring (§3.2, step 3).
  3. Switch headless benchmarks to counters-only and verify the frame count (§3.2, acceptance).

Phase 3 - Hardening

  1. Add ASan/UBSan and the short fuzz pass to CI (§3.8, step 1).
  2. Add the scoped TSan job (§3.8, step 2).
  3. Add C/C++ CodeQL (§3.8, step 3).
  4. Add the format/tidy gate and the native coverage report (§3.8, steps 4-5).
  5. Add LTO and the benchmark budget (§3.8, step 6). LTO is built and tested nightly, and the benchmark gate applies the win-x64 baseline; PGO remains optional.

Phase 4 - Vulkan-first and smooth compilation

  1. Close B11/B12 and switch the default to Vulkan with auto-fallback (§3.3).
  2. [~] Add the compile timings, then the Vulkan pipeline queue and GL program binary fallback (§3.4). The timings are in and show sub-millisecond compiles; the queue and fallback are deferred until a title exceeds the budget.
  3. Re-run the ten-title matrix and the parity/validation checks.

Phase 5 - Audio and recording

  1. Add low-latency WASAPI and extend the soak (§3.6). The ten-minute 10 ms soak remains a release-host check.
  2. Add the encode worker and use the capture ring (§3.7, steps 1-2).
  3. Add hardware H.264/AV1 behind a runtime probe (§3.7, step 3).

Phase 6 - Modern display

  1. Add HDR10/scRGB swapchain and tone mapping (§3.5, steps 1-2).
  2. Add VRR/present-mode controls and the capture tone-map (§3.5, steps 3-4).
  3. Add the shell capability/settings UI and the safe fallback (§3.5, step 5).

Phase 7 - Product closure

  1. Run the full boot matrix, the netplay check and the performance budget (§4.2).
  2. Package the separate-process-only release and verify the installers, AppImages and DMG (§4.1).
  3. Update docs/, wiki/, the architecture diagrams and the ImplementationPlan.md status table.

8. Definition of done

A change is done when:

  • it builds with warnings as errors;
  • tests cover the new behavior, not only the happy path;
  • dotnet format --verify-no-changes is clean;
  • the native core still builds on Windows and Linux without a new first-party warning;
  • native changes pass the ASan/UBSan gate and the scoped TSan gate where the change touches shared state;
  • C/C++ CodeQL is clean for the first-party paths the change touches;
  • the ABI, manifest or schema baselines are updated in the same change;
  • the separate-process control channel covers any new host operation;
  • docs/ and wiki/ describe the behavior;
  • upstream edits have a patch record in xemu/xemu-patches/;
  • data-format changes include backup and recovery coverage;
  • the package gate passes for release-affecting changes;
  • scripts/git-audit.ps1 prints CLEAN and the change is pushed to origin.

9. Non-goals

  • Re-implementing the emulator in the shell.
  • A user interface in the core.
  • A Direct3D backend (removed; Vulkan covers Windows).
  • A second command implementation per transport.
  • A per-frame picture path through the shell, a WriteableBitmap/Image frame canvas or a shell frame sink.
  • Child-window embedding or the D3D11 bridge.
  • Treating the managed validation oracle as the product path.
  • Shipping firmware, BIOS images, EEPROMs, HDD images or game data.
  • Silent or unsigned update installation; the update action downloads, verifies and opens the installer.
  • In-process DLL hosting as a product path (retired in §3.1).
  • Frame generation or AI upscaling that changes guest timing or invents frames.
  • A second modern GPU backend (D3D12) alongside Vulkan.

10. References

  • docs/index.md - user documentation home.
  • docs/reference/architecture.md - shell/core split.
  • docs/development/building.md - toolchain.
  • docs/development/quality-gates.md - checks.
  • docs/development/core.md - native core map and ABI.
  • docs/development/threading.md - thread contract.
  • docs/development/xemu-upgrade.md - selective upstream port.
  • docs/guides/recording.md - recording and replay behavior.
  • docs/legal/ - licensing and provenance.
  • wiki/ - wiki-ready pages.
  • References2/xemu-0.8.139 - read-only pristine baseline.
  • xemu/xemu-patches/ - upstream edit record.
  • scripts/xemu-owned-paths.txt - XGrid-owned native paths.

Historical session logs and wave notes are intentionally not part of the product documentation.