Files
betterxen/docs/roadmap.md
T
Vicente Abarca 120a5ec5f6 Document D3DMetal GPU limits and add test_d3dmetal_gpu_limits (#453)
Adds docs/research/d3dmetal-gpu-limits.md: the D3DMetal and Apple GPU
constraints a shader translator has to handle (wave64 splitting, 64-bit
atomics and lock emulation, the 32 KiB mesh output limit, an Apple
shader compiler crash on early-merged output stores, and
OpenExistingHeapFromAddress). Each item is marked as either measured by
the new fixture or reported from local builds of a commercial title. It
is linked from the M2 and M3 roadmap rows and from the docs index.

Adds tests/conformance/test_d3dmetal_gpu_limits: an original D3D12
compute fixture that talks to the host d3d12.dll directly. It has four
original HLSL kernels with committed DXC 1.9.2609 output, and
shaders/compile.sh regenerates them. Expected values are computed on
the CPU.

On an Apple M3 Pro (macOS 27.2.1, CodeWeavers Wine 11.0 built from
source, D3DMetal 4.0b3) the WaveSize(64) pipeline and the kernels using
SM 6.6 64-bit atomics are created but never run. The bounded lock
emulation is exact at a 1024-try cap and drops updates at 64 tries.

Signed-off-by: Vicente Abarca <135478656+Scarlet-Noble@users.noreply.github.com>
2026-11-26 14:32:09 -03:00

6.0 KiB
Raw Blame History

BetterXen Roadmap

This is the single authoritative active roadmap. Strategic decisions are recorded in ADR 0005 (CrossOver-based hybrid direction) and ADR 0006 (retiring the paused native-first workspace to Git tag native-first-final). Track ownership and parallel workflow rules live in docs/architecture/parallel-tracks.md; Wave 1 contributor issues live in docs/issues/wave-1-backlog.md.

Direction

BetterXen builds a modular Xbox Series (Scarlett) compatibility layer for Apple Silicon macOS around externally installed CrossOver 26.3+, Rosetta 2 (ROSETTA_ADVERTISE_AVX=1), and D3DMetal 3.0:

BetterXen (in-tree):
  launcher/ (ARM64 CLI, probe, telemetry) + abi/ (frozen contracts)
  shims/ (16 cross-compiled x86-64 PE32+ Xbox Game OS DLLs)
  shader-transpiler/ (DXBC / DXIL / ACCC / FSPX classifier & RDNA 2 pipeline)
        |
External Foundation (user-installed, never bundled):
  CrossOver 26.3 / Wine (Win32, CRT, XAudio2, WinHTTP) | Rosetta 2 | D3DMetal 3.0
        |
Apple Silicon: ARM64, Metal, unified memory

This is an active engineering stack, not a verified commercial Xbox game compatibility layer. Progress is measured strictly by reproducible synthetic conformance tests and recorded verification evidence — never by commit counts or unverified compatibility claims.

Priorities, in order: practical compatibility, correctness, stability, observability, Apple Silicon performance, and long-term maintainability.


Completed Research Inputs (Carried Forward)


Milestones (M0 → M6)

Milestone Objective Exit Gate Status
M0 — Repo, ABI & Cross-Build Establish 6-track directory layout (abi/, launcher/, shims/, shader-transpiler/, tests/conformance/), frozen .def/header contracts, env-isolated bx-cli, strict PE Export Directory verifier, and live CrossOver + Rosetta 2 smoke tests (test_veh_clwb.exe, test_shim_exports.exe) ARM64 Rust checks green; 16/16 PE32+ DLLs pass strict export & zero-MinGW-dep verification; both synthetic EXEs pass live under CrossOver + Rosetta 2 In validation (PR #406)
M1 — Startup Shims to D3D12XboxCreateDevice Complete Wave 1 parallel issues across Tracks A–F: full clwb + crash register VEH, xmem core + physical/scatter page engine + Lockhart cap, XCRDAPI async file I/O MVP, d3d12_xs auto-logging COM proxy over Wine d3d12.dll, xg_xs linear-compatible layout MVP, dxbc-accc C ABI hook + d3dmetal-native evaluation, offline xgameruntime, non-blocking AcpHal/xapu/chad stubs, GameInput @1, and combined synthetic integration boot fixture All 13 Wave 1 conformance binaries pass under CrossOver + Rosetta 2; combined integration_boot.exe initializes every subsystem cleanly Next (Wave 1 ready)
M2 — First Rendered Frame & Shader Format Gate Implement d3d12_xs swapchain presentation (PresentX → IDXGISwapChain3::Present), placed resources over xmem, and dxbc-accc shader inspection to establish whether target runtime shader corpora use DXIL (Branch D1) or console-compiled ACCC/FSPX RDNA 2 ISA (Branch D2). Translator constraints: D3DMetal GPU limits Synthetic D3D12 PresentX workload renders and verifies pixel readback through D3DMetal 3.0; M2 Gate ADR selects Branch D1 or Branch D2 Planned
M3 — Full Shaders, Streaming & Texture Correctness DirectStorage decompression, accurate RDNA 2 (gfx1030) xg_xs tile-addressing & deswizzling, full d3d12_xs command-list/barrier/GPUVA fidelity, and Branch D1 DXIL normalization or Branch D2 ACCC/FSPX → DXIL/MSL transpiler, within the D3DMetal GPU limits (wave64 splitting, 64-bit image atomics, mesh output size) Synthetic textured/swizzled, compute, multi-queue, and compressed DirectStorage conformance suites pass Planned
M4 — 3D Rendering, DXR/BVH4 & Upscaling Bridge XboxBvhBuilder / ID3D12StateObject ray tracing to D3DMetal 3.0 DXR (intercepting incompatible AMD BVH4 rehydration → live rebuild), provide PC FidelityFX / MetalFX upscaling shim, and wire full GameInput controller/KB/M input Synthetic DXR + upscaled 3D scene and scripted GameInput conformance tests pass Planned
M5 — Software Audio/DSP, Saves & Stability Replace AcpHal/xapu/chad stubs with software audio/DSP decoding + XAudio2_9/CoreAudio output, wire PersistentLocalStorage, and resolve concurrency/memory/GPU hang bugs under soak testing Synthetic audio playback, save round-trip, and multi-hour soak benchmarks pass with bounded memory Planned
M6 — Shader Cache, 16 GB Optimization & Polish Persistent disk PSO + translated-shader cache, Lockhart 16 GB unified memory pressure tuning, Metal System Trace optimization, and optional Swift launcher UI Reproducible frame-pacing and memory-pressure receipts under docs/testing/hybrid-workloads.md Planned

How Progress Is Reported

Milestone status is one of: Planned, In development, In validation, Verified complete, or Blocked. A milestone reaches Verified complete only after independent verification of its exit gate per AGENTS.md.