One squashed commit of a fork that was developed on a Linux/Proton machine and tested on two native Windows machines. On all of them the retail 1.0.2.1 package now launches, shows its launch movie, first-run pages and landing prompt, runs the story load to its end with the loading slideshow drawing its artwork, and enters the world phase. A first world frame is not verified yet. docs/linux_proton.md has the setup, a healthy boot's timeline, the machines and where it stops. Runtime: frames in the title's own window; DirectStorage pinned reads, page-list scatter/gather, BCPack and unshuffle with a locally generated predictor file; pooled, device-local and deferred image backing for streamed and placed textures; enhanced barriers into LAYOUT_UNDEFINED; a bindless table that degrades instead of refusing a submission; a descriptor hash finalizer (off until a library carries it); directly indexed heap offsets for compute dispatches and VS/PS/GS draws; title buffer windows outside a fragmented arena; opt-in device-local copies of streamed buffer views; write-fault retries under the tracker lock, shared trackers and write-watched title memory for native Windows; device-loss, compute-input and memory probes. Translator: loop bounds at structured exits, the eight FidelityFX programs that use a packed-dot form the disassembler skips, buffer bounds modes per view kind, a compaction option, the hash finalizer option. Tools and scripts: Linux boot scripts (Wine/Proton, no network), a Windows boot script, the paired compute translation script. No game data. AI-assisted (Claude Code and Codex agents), reviewed and booted by people on the machines named in docs/linux_proton.md. Co-authored-by: Plaaasma <47513553+Plaaasma@users.noreply.github.com> Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
7.9 KiB
Linux (Proton/Wine) and second-machine test report
This page describes how the runtime is built and booted on Linux through Proton's Wine, what a healthy boot looks like there, and what was observed on the machines that tested this branch (one Linux, two native Windows). It holds counts, timings and settings only: no game data, no traces.
Status in one line: on Linux/Proton and on native Windows the retail 1.0.2.1 package launches, shows its launch movie, first-run pages and landing prompt, runs the story load to its end with the loading slideshow drawing its artwork, and enters the world phase. A first world frame has not been verified yet on any of the three machines; what stops it is listed under Where it stops.
Test machines
| Linux | Windows A | Windows B | |
|---|---|---|---|
| OS | CachyOS (Arch), kernel 7.3 | Windows 11 | Windows 11 |
| Run through | Proton Experimental (Wine 11) | native | native |
| CPU | Ryzen 5 5600X | Core i9-13900K | Ryzen 7 9800X3D |
| GPU, driver | RTX 4070 12 GB, NVIDIA 620.73 | RTX 4070 Ti 12 GB, NVIDIA 630.20 | RTX 5070 |
| RAM | 16 GB (+32 GB swap file) | 64 GB | not reported yet |
| Toolchain | clang-cl 23 + xwin SDK, Ninja, ccache | MSVC 2022, SDK 26100 | - |
| Results here | yes, ~80 boots on 2026-11-24 | yes | joining; none yet |
Windows A reaches every stage three to five times faster than the Linux machine (initialisation ~70 s against ~180 s, story load from ~110 s against ~240-300 s), so it is the better machine for iterating on the world phase; the Linux machine is the one that shows what 16 GB of RAM allows.
Building on Linux
The runtime is a Windows executable. On Linux it is cross-built with clang-cl against an xwin copy of the Windows SDK:
scripts/linux-boot/configure-worktree.sh <checkout> # XWIN_DIR=<sdk>, SDL3_SRC=<SDL3 tree> for an offline configure
cmake --build <checkout>/runtime/build/boot --target gta6rt -j6
gta6rt_tls_host.dll is built with the gta6rt target and must stay next to the executable. Unit tests are Windows
executables too and run under Wine (scripts/run_wine_tests.py, or directly with the same wine binary and a
prefix of their own: sharing the game's prefix with tests breaks its window).
Booting on Linux
scripts/linux-boot/boot.sh is the plain launcher and run-boot.sh wraps it as a systemd --user unit with a
memory sampler, a GPU lock, a build lock (no compile while the game runs) and a digest after the boot. They assume
the layout the comments at their top describe (/opt/leonida for traces, overlay and caches; the package under
/opt/gta6); adjust the paths at the top to yours. What matters:
- Wine: Proton Experimental's
files/bin/winewith its own prefix (WINEPREFIX),WINEDLLOVERRIDES="mscoree,mshtml=". - No network: the title runs inside
unshare -rn(new user and network namespace). Nothing is online. - Backend:
LEONIDA_D3D12=vulkan,LEONIDA_SHADERS=<translated library>. - NVIDIA shader cache:
__GL_SHADER_DISK_CACHE_SIZEraised (the library is ~19 GB of SPIR-V) and__GL_SHADER_DISK_CACHE_SKIP_CLEANUP=1. - Input: a pad through GameInput/SDL3, or the keyboard pad (
LEONIDA_KEYBOARD_PAD=always), or a script:LEONIDA_INPUT_SCRIPT=a@210,a@240presses A at those seconds (any length since this branch; it was cut at 63 characters before). - Window: frames are presented in the title's own window;
LEONIDA_PRESENT_WINDOW=own|hiddenchooses otherwise.
Three setup mistakes each give a blank or empty picture without an error: the executable's embedded shaders missing
from the library (exe/index.json), a build without SDL3 (no pad), and a BCPack predictor file that was never
generated (tools/build_dstorage_history.py; without it the loading art and most BC7 textures stay empty).
What a healthy boot looks like (Linux machine)
| Time | Stage |
|---|---|
| 0-10 s | package splash |
| ~60-90 s | launch movie, then the landing prompt appears while initialisation finishes |
| ~180 s | initialisation done; A is accepted |
| ~240-300 s | story load starts: loading slideshow with its artwork |
| ~540-630 s | story load ends (about 38,000 streamed images registered), world phase begins |
On Windows A the same stages are at ~70 s, ~110 s and ~190 s.
What this branch changes to get there
Each item was a stop on at least one of the machines. Tests named in the pull request cover them.
- Presentation: frames go to the title's own window (they went to a window that was never shown).
- DirectStorage: reads pin write-watched destination pages, page-list scatter/gather, BCPack and unshuffle, a locally generated predictor file, bounded staging.
- Story-load allocation stall: one device allocation per streamed texture exhausted the driver's CPU-visible mappings near 16,000 images; small streamed images now share pooled pages.
- Images on plain device-local memory: host-copy usage excluded it on NVIDIA and 4.8 GB of images spilled into host memory; streamed images are now filled through staging.
- Deferred backing: placed and streamed images get private memory at their first write or GPU copy. VRAM at the end of the load went from 11.8 GB to ~5 GB on Linux; on Windows A host private memory went from 22-24 GB to 11.9 GB.
- Enhanced barrier into
LAYOUT_UNDEFINED: accepted; it failedClose, which the title treats as fatal. - Bindless table: a table rebuild that cannot allocate no longer refuses the whole submission; larger image arrays; a hash finalizer for the descriptor table (runtime and translator halves, off until a library carries it).
- Translator: loop bounds on every emitted loop (5,128 compute modules have loops), the eight FidelityFX programs that used an instruction form the disassembler skips (all 29 translate), buffer bounds modes per view kind.
- Directly indexed descriptor heaps: the heap offset is supplied in the user-data dword after the explicit root arguments for compute and for VS/PS/GS draws. Mesh stages are not covered yet.
- Title buffers at raw addresses: a window outside the arena when title reservations fragment it; opt-in persistent device-local copies of streamed buffer views.
- Native Windows: write faults on shared pages retried under the tracker lock, one tracker per run of shared pages, write-watched title memory, a fault-lock that never waits for the process heap.
- Diagnostics: device-loss report with the last dispatches and NVIDIA checkpoints, a probe for the descriptors a compute dispatch receives, memory probe, press log. All off by default.
Where it stops
- Streamed memory that never reaches its destination. The title calls queue slot 31 (
CopyPageMappingsBatchX) about 300 times per boot and this branch still ignores it; tens of thousands of streamed views wait for memory that never becomes readable. An open pull request in this repository implements it. - Culling compute at world start reads buffers named by descriptors in the directly indexed heap; with the point above unfixed those reads leave mapped memory and the device is lost (NVIDIA Xid 13/109 on Linux).
- Mesh stages do not get the heap offset yet.
- 16 GB of RAM: at the end of the load the process holds ~14.6 GB (RAM plus swap) on the Linux machine after the cuts above. zram made this worse (compressed pages still occupy RAM); a swap file on disk is the better choice.
- Initialisation takes ~180 s under Proton against ~70 s natively. Not investigated.
- Under Wine a thread that takes an access violation while holding the process heap lock can still deadlock with xmem's fault handler; the test for it is skipped there.
Reporting a result
Say the machine (OS, GPU and driver, RAM), the commit, the environment switches that differ from the defaults, and counts: presents, the last stage reached with its time, the first refusal or device-loss line. Keep logs and traces on the machine that produced them.