What Is Marvisak/VIctory?
Marvisak/VIctory is an open-source systems engineering project written in Rust by developer Marvisak with a concise stated goal: "Runs Grand Theft Auto VI (Xbox Series X|S) natively on Windows, from files the user supplies." Rather than emulating a foreign CPU instruction set or statically decompiling console binaries into C++, Marvisak/VIctory acts as an in-process Windows compatibility layer — conceptually closer to how Wine/Proton translates Windows APIs on Linux, adapted here for Xbox Series X|S system interfaces (xgameruntime.dll and Direct3D 12.X) on a 64-bit Windows 10/11 host.
Because the Xbox Series X|S runs standard x86-64 instructions with AVX2 extensions, the title's compiled machine code executes directly inside the host Windows process without CPU emulation overhead. Meanwhile, the runtime intercepts system imports, virtualizes console storage paths, decodes proprietary texture/audio formats, and recompiles console GPU shader containers into standard PC Direct3D 12 Shader Model 6.6 DXIL.
Complete 11-Crate Workspace Breakdown
According to upstream docs/architecture.md, the Cargo workspace is cleanly modularized into 11 crates (plus an internal hle-probe test fixture). Notably, every crate except victory-game is platform-generic and can be tested against general Xbox Series software without title-specific assumptions:
| Crate / Path | Architectural Responsibility |
|---|---|
victory-core |
Workspace configuration (victory.toml), logging setup (VICTORY_LOG), and the asset-policy guard |
victory-pe |
Read-only PE32+ executable analysis and import-library (import.lib) inspection |
victory-loader |
Prepares, maps, binds, redirects TLS slot 0, installs crash unwinding (crashes.log), and starts the title image |
victory-hle |
High-level emulation of Xbox console runtime APIs (xgameruntime), virtual drive mapping, and HostPolicy pass-through |
victory-gpu |
Translates Xbox Direct3D 12.X objects, command lists, root signatures, and GPU heaps onto host Windows Direct3D 12 |
victory-shader |
Decompiles Xbox shader containers and SGD5 packs into SSA IR, structurizes lane masks, and emits DXIL SM 6.6 |
victory-formats |
Handles console GPU texture layouts (tiling/detiling), parallel zlib and BCPack decompression, and XMA/Opus audio codecs |
victory-pipeline |
Defines the converter trait and content-addressed disk cache for ahead-of-time and on-demand asset/shader conversion |
victory-game |
Isolates Grand Theft Auto VI-specific archive formats (shaders.rpf), build identities, and targeted runtime hooks |
apps/victory |
Command-line front-end (inspect, census, lib-exports, shader-info, translate, run, config) |
xtask |
Developer hygiene automation and Git pre-commit hooks preventing copyrighted files from entering the repository |
How Import Resolution & TLS Mapping Work Inside victory-loader
When you execute victory run <exe> --execute, Marvisak/VIctory maps the console PE32+ executable into memory alongside its dependent DLLs. Because a Windows process gives static Thread-Local Storage (TLS) slot 0 to the host victory.exe runner itself — whereas the console title's compiled machine code expects its own static TLS at slot 0 — victory-loader::tls rewrites and redirects those TLS accesses seamlessly.
For every dll!function imported by the title, the loader resolves symbols in strict four-step priority order:
- Custom HLE Override (
victory-hle::modules): Always wins first. Console-exclusive libraries likexgameruntime.dllreturn pseudo handles onLoadLibrary*and hand out offline console user, license, package, and save-data interfaces viaQueryApiImpl. - Host Windows Pass-Through (
HostPolicy): Shared standard Win32 APIs allowed by policy pass straight to the host OS for native speed, while path-taking file functions (kernel32and C/C++ runtime) rewrite console virtual drive paths to folders under%LOCALAPPDATA%\victory\data. - Title-Shipped Companion DLLs: Libraries shipped next to the executable (such as
XboxBvhBuilder.dlloramd_fidelityfx_upscaler_xbox.dll) are mapped into the process just like the main binary if neither step 1 nor step 2 serves them. - Generated Diagnostic Stubs: Any unimplemented import receives a named stub that either logs once and returns
0(--unimplemented zero) or breaks immediately into the debugger (--unimplemented trap). Runningvictory census <exe> --missingpreviews this entire classification without executing title code.
How victory-shader Translates Console GPU Code to DXIL SM 6.6
The hardest engineering challenge in Marvisak/VIctory is translating low-level console GPU machine instructions into valid Direct3D 12 Shader Model 6.6 DXIL containers:
- SSA Construction & EXEC Structurization:
victory_shader::ir::buildlifts native GPU instructions 1:1 into Static Single Assignment (SSA) form. Next,victory_shader::structureeliminates raw hardwareEXECwave masks — converting lane masks into per-lane booleans and wave-wide mask checks into structured branches. - Bounded Register-Relative Moves & Waterfall Loops:
victory_shader::range::buildproves index bounds onv_movrel*instructions, whilevictory_shader::resourcetraces descriptors andv_readfirstlane_b32waterfall loops back to root parameters so non-uniform descriptor heap indexing works in a single pass on PC GPUs. - Current Scale: As tracked on our VIctory status page, this compiler already converts 8,765 / 8,765 mesh shaders, 12,550 / 12,592 vertex/pixel shaders, and 2,579 / 2,637 compute shaders, leaving ~195 merged geometry stages and ~100 specialized programs still in progress.
To try compiling the workspace or inspecting shader disassembly (victory shader-info --disasm), continue to our GTA VI port GitHub guide and Windows build & install tutorial.
Community Build Notes & Questions (0)
Share your Cargo compile results, GPU shader cache timings, or ask a question about building from source. Plain text only — URLs are blocked to prevent fake download spam.
No build reports on this page yet. Be the first to share your GPU test configuration or question above.