Review findings: upstream Wine has the userfaultfd and PAGEMAP_SCAN write watch from the
10.7 development release (not 10.6, not the stable 10.0), so the version rule is 10.7, and
only when no ntdll.so is found beside wine; a found one decides by its PAGEMAP_SCAN message.
Tests cover the lib, lib64 and Debian multiarch layouts and wine reached through a symbolic
link. docs/linux.md: Linux 6.7 is needed but not always enough, and which figures are a
native program's. The benchmark checks its arguments and allocations.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JPqXc6svM4pbBagTsVEYA3
Wine 9.0 and 10.0, or any Wine on Linux before 6.7, track write-watched pages by making
them read-only and taking a SIGSEGV at the first write after each reset; Wine 11.0 and
Proton's Wine use userfaultfd's asynchronous write protection and PAGEMAP_SCAN instead.
Measured on a cloud VM: 2.3-3.8 us against 0.7-0.85 us per first write. The launcher now
says so in one line (LEONIDA_WINE_CHECK=0 leaves it out); docs/linux.md, "Which Wine", has
the numbers, and scripts/write_watch_bench.c measures them under any Wine.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JPqXc6svM4pbBagTsVEYA3
* scripts, tools: build llvm-mc 23.1.5 by default, so the pipeline library translates
LLVM 21.1.8's gfx1013 decoder cannot decode 840 of the 2,684 compute
programs in the pipeline library of 1.0.2.1: their listings carry 79,490
undecodable words and 8,310 exp invalid_target_N lines, the translator
refuses all of them as "fall-through into undecodable words", and the
shaders stage keeps 1,844 of 2,684. LLVM 21 does translate all 26,503
shaders of shaders.rpf; the library is what it loses.
The same bytes under llvm-mc 23.1.5 have no rejected word in those 840,
and 839 of them translate and pass spirv-val (the last wants s_sethalt,
which the translator does not implement, under either version). The 1,844
that already translated were re-disassembled too: 1,674 listings change
and all 1,674 still translate, the other 170 are byte-identical, so the
stage goes from 1,844/2,684 to 2,683/2,684.
The build helper now builds 23.1.5 by default. The docs that name the
minimum version (README, docs/design.md, docs/testing.md, docs/linux.md)
and the three user-facing messages that still said 21+ (make_game.py's
preflight, shader_disasm.py's probe error, mc_command.py's install hint)
now say 23+, with the tests that assert those texts updated.
AI-assisted (DeepSeek Harness).
Written with an AI assistant.
* docs: LLVM 23 is what the shaders stage needs, and a test pins the script's default
scripts/install_deps_linux.sh installs what docs/linux.md lists with apt
(Debian, Ubuntu and derivatives), dnf or pacman. It takes the newest
llvm-21 or later the distribution packages, leaves out optional packages
it lacks, shows the commands and asks before running them (--dry-run,
--yes, --minimal), then checks Python 3.12+, llvm-mc with AMDGPU,
SPIRV-Tools, CMake 3.24+, Ninja, a C++ compiler and the Vulkan headers.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The launcher runs gta6rt.exe --run once under Wine on Linux, headless on a
private kwin_wayland --virtual --xwayland session (Xvfb has no DRI3, so RADV
cannot present there) or on the current display with --visible. Sound is off
(Wine's audio drivers disabled, Pulse/PipeWire/ALSA pointed at nothing,
LEONIDA_AUDIO=silent for the runtime's silent output endpoint), --device pins
the Vulkan device through MESA_VK_DEVICE_SELECT, and a hard time limit, a lock
and full teardown bound the run. Every path comes from arguments or the
environment.
tools/game_run_summary.py prints counts only: run time, end, exceptions by
code, D3D12 calls by outcome, presents, the top failing calls and the [rt]
lines by category with numbers masked. It never prints a log line.
Tests need no game, Wine or GPU: the script against stubs, the summary on
synthetic run folders. docs/linux_proton.md describes the script.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Configure checks only that the file passed with -DLEONIDA_XMA2_DECODER_LIB
exists, not which source, version or target it was built from. Say so, and
give the command that builds the library from this checkout's
runtime/xma_decoder for x86_64-pc-windows-msvc, where it lands, that it
needs only the Rust target (so it works on Linux), that the option stops
CMake from rebuilding the decoder after source changes, and that a
relative path given with -D is resolved against the directory CMake runs in.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
docs/linux.md gathers what a Linux user needs in one place: which pieces
run natively and which run under Wine or Proton, with the CI job that
checks each; the Ubuntu 26.04 packages for each stage (no .NET 8 SDK is
packaged there, and the .NET 10 SDK builds rpf9dump through global.json's
roll-forward); ./Build.sh; the clang-cl + xwin cross-build of gta6rt; and
why there is no native Linux gta6rt (imports bind to host Windows DLLs,
Windows x64 ABI, RtlAddFunctionTable, the TLS host DLL, a vectored
exception handler), which is the work Wine already does.
README's How to build and Platforms rows and docs/README.md link it.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>