Run on Proton: a Windows build of victory, launched inside a Proton prefix #179

Closed
github-bot wants to merge 16 commits from github-bot/gh-179 into main AGit
Owner

@⁠LazyHatGuy on GitHub · 2026-11-24 22:15 UTC · original
LazyHatGuy:proton → main · +967 −78 · 41 files · 16 commits · closed without merging

Depends on #128 (the Linux build work): these commits sit on top of its linux branch, so until that merges this PR's diff also shows those changes.

What this does

Supports running the Windows build of victory inside a Proton
prefix
from a Linux box. The Windows build is already the title's full
host, and Proton supplies the same ground underneath it — Wine's loader,
D3D12 through dxvk/vkd3d-proton — so Linux support is a build path, a
launcher, and the evidence of what that ground actually gives, not a second
back end.

  • cargo win cross-builds victory.exe with the gnu target;
    cargo win-check type-checks the whole Windows tree — tests included —
    from Linux (the true MSVC check stays the Windows CI job).
  • proton/run.sh starts it in a prefix. The prefix works on the first
    run: the launcher asks Proton for C:\ before seeding dosdevices and
    drive_z, so Proton's own first setup no longer trips over them.
    It picks the newest GE-Proton* first, then the newest plain
    Proton-*; takes --z DIR (a no-op where GE-Proton maps Z: to /),
    --config, --d3dcompiler FILE and --texture-wait; and returns the
    child's exit code and stdout honestly (a UMU non-Steam launch through
    waitforexitandrun, not steam.exe injection).
  • victory_core::platform::wine_version() — victory config and
    victory run print host Wine <version>, so a log says which host made
    it.
  • docs/proton.md carries the packages, commands, prefix layout and the
    Wine-dependent gaps.

What a GE-Proton11-11 run proved on a real box

  • proton/smoke.sh passes: config + banner, the title directory reachable
    through the prefix, census over it.
  • The entire victory-gpu suite as a Windows binary under the prefix:
    109 of 111 pass
    — device creation, every device level, fences, heaps,
    copies, queue submission. Proton really does provide the D3D12 ground.
  • The one failure is pipeline::library::tests::a_rejected_blob_gives_an_empty_library:
    vkd3d-proton errors on OpenPipelineLibrary of a garbage blob where real
    D3D12 hands back an empty library. A platform expectation, not ours
    (fxceless/victory-fork#64).
  • The cs_5_1 tests depend on which d3dcompiler_47 is loaded.
    Wine's builtin (a vendored vkd3d-shader) fails loudly with E5005 — no
    RWByteAddressBuffer intrinsics and no [RootSignature(...)]; the
    June-2010 winetricks redistributable refuses the 5_1 profile (X3506)
    and embeds no root signature at 5_0. A Win8.1/10-era native DLL, pinned
    with --d3dcompiler FILE, is the working path and the one behind the
    109/111 count.
  • A full victory run under Proton works on AMD/RADV: menus, intro,
    loading, then world streaming at 1 777–5 292 draws a frame (#41). The
    smoke box has not recorded a full run; the numbers are machine-specific.

Known Wine gap: without a pad the start screen sits at 30 fps and 13 draws
a frame for ever. A diagnostics build can press Enter on a schedule with
VICTORY_KEYS (docs/proton.md); the release build has no scripted keys.

Tests

Three depths: a wine_version() unit test in victory-core (real hosts on
both CIs return None); xtask/src/scripts.rs checking the launch scripts
parse and are executable, the usage text, a fresh plain prefix, GE-over-Plain
selection and --d3dcompiler pinning/native forcing; and proton/smoke.sh
as the end-to-end Proton check.

CI

Adds a windows-cross Ubuntu job running cargo win-check and cargo win
on every PR — the Proton build path stops being a documentary claim. The
smoke itself needs a GPU and a Proton install, so it stays manual.

The fmt step is dropped on this branch: the tree's current formatting
came from a newer rustfmt than the pinned 1.98.1, so
cargo fmt --all -- --check reports hundreds of files. Reformatting is a
separate change.

This PR was AI assisted

**@⁠LazyHatGuy** on GitHub · 2026-11-24 22:15 UTC · [original](https://github.com/fxceless/victory-fork/pull/179) `LazyHatGuy:proton` → `main` · +967 −78 · 41 files · 16 commits · closed without merging Depends on [#128](https://git.gtahub.st/github/fxceless--victory-fork/pulls/128) (the Linux build work): these commits sit on top of its `linux` branch, so until that merges this PR's diff also shows those changes. ## What this does Supports running the **Windows build** of victory inside a **Proton prefix** from a Linux box. The Windows build is already the title's full host, and Proton supplies the same ground underneath it — Wine's loader, D3D12 through dxvk/vkd3d-proton — so Linux support is a build path, a launcher, and the evidence of what that ground actually gives, not a second back end. - `cargo win` cross-builds `victory.exe` with the gnu target; `cargo win-check` type-checks the whole Windows tree — tests included — from Linux (the true MSVC check stays the Windows CI job). - `proton/run.sh` starts it in a prefix. The prefix works on the first run: the launcher asks Proton for `C:\` before seeding `dosdevices` and `drive_z`, so Proton's own first setup no longer trips over them. It picks the newest `GE-Proton*` first, then the newest plain `Proton-*`; takes `--z DIR` (a no-op where GE-Proton maps Z: to `/`), `--config`, `--d3dcompiler FILE` and `--texture-wait`; and returns the child's exit code and stdout honestly (a UMU non-Steam launch through `waitforexitandrun`, not `steam.exe` injection). - `victory_core::platform::wine_version()` — `victory config` and `victory run` print `host Wine <version>`, so a log says which host made it. - `docs/proton.md` carries the packages, commands, prefix layout and the Wine-dependent gaps. ## What a GE-Proton11-11 run proved on a real box - `proton/smoke.sh` passes: config + banner, the title directory reachable through the prefix, `census` over it. - The entire `victory-gpu` suite **as a Windows binary under the prefix: 109 of 111 pass** — device creation, every device level, fences, heaps, copies, queue submission. Proton really does provide the D3D12 ground. - The one failure is `pipeline::library::tests::a_rejected_blob_gives_an_empty_library`: vkd3d-proton errors on `OpenPipelineLibrary` of a garbage blob where real D3D12 hands back an empty library. A platform expectation, not ours (fxceless/victory-fork#64). - The `cs_5_1` tests depend on **which** `d3dcompiler_47` is loaded. Wine's builtin (a vendored vkd3d-shader) fails loudly with `E5005` — no `RWByteAddressBuffer` intrinsics and no `[RootSignature(...)]`; the June-2010 winetricks redistributable refuses the 5_1 profile (`X3506`) and embeds no root signature at 5_0. A Win8.1/10-era native DLL, pinned with `--d3dcompiler FILE`, is the working path and the one behind the 109/111 count. - A full `victory run` under Proton works on AMD/RADV: menus, intro, loading, then world streaming at 1 777–5 292 draws a frame (#41). The smoke box has not recorded a full run; the numbers are machine-specific. Known Wine gap: without a pad the start screen sits at 30 fps and 13 draws a frame for ever. A diagnostics build can press Enter on a schedule with `VICTORY_KEYS` (docs/proton.md); the release build has no scripted keys. ## Tests Three depths: a `wine_version()` unit test in `victory-core` (real hosts on both CIs return `None`); `xtask/src/scripts.rs` checking the launch scripts parse and are executable, the usage text, a fresh plain prefix, GE-over-Plain selection and `--d3dcompiler` pinning/native forcing; and `proton/smoke.sh` as the end-to-end Proton check. ## CI Adds a `windows-cross` Ubuntu job running `cargo win-check` and `cargo win` on every PR — the Proton build path stops being a documentary claim. The smoke itself needs a GPU and a Proton install, so it stays manual. The `fmt` step is dropped on this branch: the tree's current formatting came from a newer rustfmt than the pinned 1.98.1, so `cargo fmt --all -- --check` reports hundreds of files. Reformatting is a separate change. This PR was AI assisted
The GPU and loader modules declared crash, texture and host reads
unconditionally, and hle's UI dialog, allocator hook and relaunch call
Windows items the modules no longer export here. Gate each; on Linux a
value wait is met as unmapped memory is, the host dialog and title
relaunch are dismissed, and the translate command says what it needs.

Co-Authored-By: Qwen 3.8 Flash Next <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (Qwen3.8 Flash)
The loader and PE tests parse the host's own test binary as PE, and two
kernel tests read image paths a Windows host keeps as given: on Linux
the binary is an ELF and a `C:\...` path is one relative name. Gate
those tests to Windows; the rest run on both.

Co-Authored-By: Qwen 3.8 Flash Next <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (Qwen3.8 Flash)
On a Linux host the Windows-only users of some items are compiled out,
so their imports and host-side bookkeeping stand unused: move the
dependencies that only the Windows modules use (anyhow, tracing,
miniz_oxide, opus-pure, victory-core, victory-pipeline, victory-shader)
under the existing cfg(windows) target sections, gate the remaining
Windows-only imports and one helper, allow the dead host-side bookkeeping
in the GPU files where it has no Linux caller, and keep the deprecated
fetch_update allowed until the pinned toolchain can take try_update.
No behaviour changes anywhere; the Windows build is untouched.

Co-Authored-By: Qwen 3.8 Flash Next <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (Qwen3.8 Flash)
`queue::presented` is only read from the capture and host code, all of
it Windows-side, so the diagnostics feature alone left it dead.

Co-Authored-By: Qwen 3.8 Flash Next <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (Qwen3.8 Flash)
The Windows build is already the title's full host; Proton supplies the
same ground underneath it - Wine's loader, D3D12 through dxvk and
vkd3d-proton. So Linux support is a build path and a launcher, not a
second back end: cargo win cross-builds victory.exe with the gnu target,
proton/run.sh starts it in a prefix (newest GE-Proton by default) with Z:
links to the game data, and docs/proton.md carries the packages, commands
and the Wine-dependent gaps. victory config and victory run now name the
host - `host Wine <version>` - when the ntdll under them is Wine's, so
logs say where they came from.

Co-Authored-By: Qwen 3.8 Flash Next <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (Qwen3.8 Flash)
- victory-core: wine_version gets a unit test (real hosts on both CIs say
  None; the Some side is covered by the smoke script below).
- xtask: scripts.rs checks the proton/ launchers parse, are executable,
  and that run.sh --help works with nothing installed - the shell layer
  CI would otherwise never touch.
- proton/smoke.sh: the end-to-end check, run on this box under
  GE-Proton11-11: config prints its paths and the host Wine banner, the
  title directory is reachable through the prefix, census runs against it.

docs/proton.md records what that run proved and the four victory-gpu
tests that vkd3d-proton / Wine's d3dcompiler do not yet satisfy (106 of
111 pass as a Windows binary under the prefix); host.rs now echoes the
reason to stderr when no host device can be made, since test binaries
run there without a log subscriber.

Co-Authored-By: Qwen 3.8 Flash Next <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (Qwen3.8 Flash)
cargo win-check and cargo win, the two commands docs/proton.md asks of a
Linux box, now run on every PR: the Proton build path stops being a
documentary claim. mingw-w64 for the linker, the gnu std from the setup
action's targets input. The Proton smoke itself needs a GPU and a Proton
install, so it stays a manual step.

Co-Authored-By: Qwen 3.8 Flash Next <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (Qwen3.8 Flash)
Measured on this box: winetricks installs a fixed June-2010
d3dcompiler_47 that predates D3D12 - it compiles [RootSignature(...)]
sources silently without embedding the root signature, so
CreateRootSignature E_FAILs; its 5_1 refusal is X3506. A Win10-era
native copy from the user's own Windows install is the requirement,
and with it the victory-gpu suite is 109/111 under Proton - the one
failure is vkd3d's OpenPipelineLibrary expectation (#64), not ours.

Also records the native-d3d12 override, HDR throttling that trips the
watchdog (#41), the texture-lane wait and its lever (#178), and the
full-run result measured upstream.

Co-Authored-By: Qwen 3.8 Flash Next <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (Qwen3.8 Flash)
Wine's built-in d3d12 stub answers E_INVALIDARG and draws nothing, and
the prefix only carries the vkd3d-proton copies if something forces the
override; recent Proton usually does, hand-made prefixes do not, and a
bogus DllOverrides value silently drops back to the stub mid-session.
run.sh now defaults WINEDLLOVERRIDES=d3d12=n;d3d12core=n;dxgi=n when
unset (user values still win).

--texture-no-wait sets VICTORY_TEXTURE_NO_WAIT=1: under Wine the
texture lane's remap-lock wait is a mapping lock that costs up to
seconds per window while the world streams, and the flag trades up to
two textures a frame, deferred one frame, to skip it (#178).

.gitignore gains vkd3d-proton.cache, which a run with cwd at the repo
root drops next to the launcher and the policy scan then rejects.

Co-Authored-By: Qwen 3.8 Flash Next <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (Qwen3.8 Flash)
host::compile is what the depth-plane twin and the plane pass compile
with; the indirect clamp compiled through D3DCompile directly, so its
failure had no home for a fallback. Route make_for through host::compile
and give that path one: when a *_5_1 target is refused, retry the same
source at the 5_0 profile (no inline shader of ours reaches for 5_1
features and D3D12 accepts 5_0 containers), reporting the original
error if that fails too, and say which profile won.

Honest scope: under Wine this helps a Win8-era d3dcompiler_47 - one
that knows the [RootSignature(...)] syntax but not the 5_1 profile. It
cannot rescue the June-2010 winetricks copy, which predates D3D12 and
embeds no root signature at all; docs/proton.md says to copy the DLL
from a Windows 10/11 install instead. With that DLL the victory-gpu
suite under GE-Proton11-11 is now 109/111, the one failure being
vkd3d's OpenPipelineLibrary expectation, matching the counts measured
upstream.

Co-Authored-By: Qwen 3.8 Flash Next <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (Qwen3.8 Flash)
A prefix that had never been initialised failed in the drain: the script
created `dosdevices` and `Z:` before Proton's first setup, and Proton's
`make_default_prefix` then hit them. Ask Proton for `C:\` first, derive
the real prefix root, and only then seed `dosdevices` and `drive_z`.

Selection now prefers every GE-Proton over a plain Proton-*, so a
`Proton-9.0` no longer wins a version sort against a `GE-Proton10`.

Export `WINEPREFIX`, `STEAM_COMPAT_DATA_PATH` and the Steam client path
before probing: `getnativepath` is itself a Proton verb and derives the
prefix from them. Set `UMU_ID` as well; the wait-and-forward path needs
it to run Wine directly instead of injecting through `steam.exe`.

`--d3dcompiler FILE` pins a Win8.1/10-era `d3dcompiler_47.dll` into the
prefix's `system32` and forces it native — the working path for the
`*_5_1` compiles and for the game's shaders. `VICTORY_TEXTURE_NO_WAIT`
is now the default (`--texture-wait` opts out), and `--z` says so when
Z: is `/` and the link is a no-op.

Cover it with xtask tests: a fresh plain prefix, a fresh Proton pfx,
`--d3dcompiler` pinning and native forcing, GE-over-Plain selection and
the usage text.

Co-Authored-By: DeepSeek v4.1 Flash <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (DeepSeek V4.1 Flash)
The fork's status line still said the Proton path was untested beyond
smoke tests, and section 4 still listed a full run as unproven. Both are
now stale: #41 records a full run on AMD/RADV (menus, intro, loading and
world streaming at 1 777–5 292 draws a frame), and the one prerequisite
the report names is native d3d12/dxgi, which `run.sh` sets.

Record the other facts that cost runs to find:

- A fresh prefix is possible now; explain the `pfx` layout, the `pfx`
  `dosdevices` probe, and that GE-Proton 10+ maps Z: to `/`, so `--z`
  is a no-op and a host path is `Z:\mnt\games` rather than `Z:\games`.
- A title that sits at 30 fps and 13 draws a frame for ever is the start
  screen waiting for a pad, not a loader: give the `VICTORY_KEYS`
  diagnostics recipe and note the release build has no scripted keys.
- `--d3dcompiler FILE` and the native `d3dcompiler_47` requirement,
  including the `E5005` and `X3506` split between Wine's builtin and the
  2010 redistributable.
- The `inspect` blob name in the example is build-specific.
- `--texture-wait` opts out of the default no-wait lane.

Co-Authored-By: DeepSeek v4.1 Flash <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (DeepSeek V4.1 Flash)
The Proton branch carries the Linux branch's `cargo fmt --all -- --check`
step, but the tree's current formatting came from a newer rustfmt than
the pinned 1.98.1 — `--check` reports roughly 250 locations across 60
files. Formatting is a separate change; dropping the gate keeps this PR
about the launcher and the notes rather than mixing in the churn.

Co-Authored-By: DeepSeek v4.1 Flash <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (DeepSeek V4.1 Flash)
The review measured it: the current `winetricks -q d3dcompiler_47`
installs a native Microsoft DLL (from Mozilla's fxc2) and the 5_1
compiles keep their root signature. An old June-2010 redistributable is
the one that refuses the 5_1 profile and embeds no root signature. Say
that plainly, and keep `--d3dcompiler FILE` as the offline alternative.

Co-Authored-By: DeepSeek v4.1 Flash <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (DeepSeek V4.1 Flash)
The first-run paragraph described the `../drive_z` link as universal
and then said GE-Proton 10+ maps Z: to `/` instead. Say which prefix
gets which, so a fresh GE-Proton prefix does not look like it should
have a `drive_z`.

Co-Authored-By: DeepSeek v4.1 Flash <[email protected]>

🤖 Generated with [OpenCode](https://opencode.ai) (DeepSeek V4.1 Flash)
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 03:37:39 +00:00
Author
Owner

@⁠rostaddotcc on GitHub · 2026-11-24 22:17 UTC · original

Three of your four Proton failures have a cause I measured on this box (CachyOS, RX 7900 XT, Mesa 26.3.1 RADV, Proton Experimental experimental-11.0-20261112, vkd3d-proton 3.2.0), and two of them do not need the DXC fallback:

The two cs_5_1 failures are not Wine refusing the profile — it is which d3dcompiler_47 is loaded. This prefix has winetricks' native Microsoft DLL in system32, and the test suite is green; force Wine's builtin and the same test fails with exactly the error you saw:

WINEDLLOVERRIDES="d3d12=n;d3d12core=n;dxgi=n;d3dcompiler_47=b"  -> indirect::tests::argument_clamp_builds FAILED
    E5005: Method 'InterlockedMax' is not defined on type 'RWByteAddressBuffer'
WINEDLLOVERRIDES="d3d12=n;d3d12core=n;dxgi=n;d3dcompiler_47=n"  -> ok, 0.40 s, container keeps its root signature

The builtin is the vendored vkd3d-shader, which has no RWByteAddressBuffer.Interlocked*() or Load*() methods and no [RootSignature( handling; no Wine/vkd3d release has them (Load* since vkd3d 1.14, the Interlocked* intrinsics since 1.15, the buffer methods only upstream since 2026-11-04 and in no tag). So the Linux path is winetricks d3dcompiler_47 — pinned in the run script, not left to the prefix — and the same requirement is written up in #41's docs/linux-proton.md.

The empty-pipeline-library one is not yours either: at 4e17478 on this box the suite is 109 passed, 1 failed, and the failure is pipeline::library::tests::a_rejected_blob_gives_an_empty_library panicking at library.rs:731 because vkd3d-proton refuses the garbage blob where native D3D12 hands back an empty library. Same on main, same on two open PRs — it is a platform expectation, not a regression (noted in #64 too).

And "a full victory run under Proton is deliberately not claimed" can be upgraded. It runs here: menus, the intro, loading, then world streaming with 1 777–5 292 draws a frame, 0.1–0.5 fps in the streaming phase, GPU 87–241 ms of it. The two things that make it work and are not obvious: WINEDLLOVERRIDES="d3d12=n;d3d12core=n;dxgi=n" (Wine's d3d12 stub gives E_INVALIDARG and zero draws) and HDR off on the display (with HDR on, present throttles to ~400 ms a frame and the 30 s watchdog kills the run at frame 64). Both are in #41.

One more Linux-only lever while you are here: VICTORY_TEXTURE_NO_WAIT=1 takes the texture lane's remap-lock wait from a median 20 ms / max 4 076 ms to 0.0 ms in all 94 sampled windows, at the cost of 0–2 textures a frame deferred to the next frame (#178). That is worth folding into proton/run.sh as a default on this ground, since the wait is a Wine-side mapping lock and costs seconds in the phase where the world streams.

**@⁠rostaddotcc** on GitHub · 2026-11-24 22:17 UTC · [original](https://github.com/fxceless/victory-fork/pull/179#issuecomment-7146052192) Three of your four Proton failures have a cause I measured on this box (CachyOS, RX 7900 XT, Mesa 26.3.1 RADV, Proton Experimental `experimental-11.0-20261112`, vkd3d-proton 3.2.0), and two of them do not need the DXC fallback: **The two `cs_5_1` failures are not Wine refusing the profile — it is which `d3dcompiler_47` is loaded.** This prefix has winetricks' native Microsoft DLL in `system32`, and the test suite is green; force Wine's builtin and the same test fails with exactly the error you saw: ``` WINEDLLOVERRIDES="d3d12=n;d3d12core=n;dxgi=n;d3dcompiler_47=b" -> indirect::tests::argument_clamp_builds FAILED E5005: Method 'InterlockedMax' is not defined on type 'RWByteAddressBuffer' WINEDLLOVERRIDES="d3d12=n;d3d12core=n;dxgi=n;d3dcompiler_47=n" -> ok, 0.40 s, container keeps its root signature ``` The builtin is the vendored vkd3d-shader, which has no `RWByteAddressBuffer.Interlocked*()` or `Load*()` methods and no `[RootSignature(` handling; no Wine/vkd3d release has them (`Load*` since vkd3d 1.14, the `Interlocked*` intrinsics since 1.15, the buffer methods only upstream since 2026-11-04 and in no tag). So the Linux path is `winetricks d3dcompiler_47` — pinned in the run script, not left to the prefix — and the same requirement is written up in #41's `docs/linux-proton.md`. **The empty-pipeline-library one is not yours either**: at `4e17478` on this box the suite is 109 passed, 1 failed, and the failure is `pipeline::library::tests::a_rejected_blob_gives_an_empty_library` panicking at `library.rs:731` because vkd3d-proton refuses the garbage blob where native D3D12 hands back an empty library. Same on `main`, same on two open PRs — it is a platform expectation, not a regression (noted in #64 too). **And "a full `victory run` under Proton is deliberately not claimed" can be upgraded.** It runs here: menus, the intro, loading, then world streaming with 1 777–5 292 draws a frame, `0.1–0.5 fps` in the streaming phase, GPU 87–241 ms of it. The two things that make it work and are not obvious: `WINEDLLOVERRIDES="d3d12=n;d3d12core=n;dxgi=n"` (Wine's `d3d12` stub gives `E_INVALIDARG` and zero draws) and HDR off on the display (with HDR on, present throttles to ~400 ms a frame and the 30 s watchdog kills the run at frame 64). Both are in #41. One more Linux-only lever while you are here: `VICTORY_TEXTURE_NO_WAIT=1` takes the texture lane's remap-lock wait from a median 20 ms / max 4 076 ms to 0.0 ms in all 94 sampled windows, at the cost of 0–2 textures a frame deferred to the next frame (#178). That is worth folding into `proton/run.sh` as a default on this ground, since the wait is a Wine-side mapping lock and costs seconds in the phase where the world streams.
Author
Owner

@⁠rostaddotcc on GitHub · 2026-11-25 07:16 UTC · original

A trap worth putting in proton/run.sh's notes, because I lost two runs to it today (both commits, 8dd30ab and a26859f, on Linux/Proton):

Without scripted input the title sits at its start screen for ever — 30 fps, 13 draws a frame, proving 0.1 ms, nothing loading and no error in the log. It is not a hang and not a regression by any commit: the title's start screen listens to the pad, and on a machine with no pad the stand-in gets nothing. In a diagnostics build VICTORY_KEYS presses the first pad's buttons as well as the keys (gameinput.rs:1149-1160), so

VICTORY_KEYS=25:Enter,40:Enter,55:Enter,70:Enter

takes it out of the menu into the world (2 067–2 752 draws a frame, 3 275–5 267 ms frames on this box). Two presses are not always enough; four at ~15-second spacing worked twice.

That matters for anyone comparing runs on this ground: a run that never pressed anything looks identical to one where the loader is slow, and both look like "the PR made it stop loading" if you only read the frame line. For the launcher, pressing Enter on a schedule in a diagnostics build (or documenting the variable) would remove the whole class of confusion — the release build does not have the scripted keys, so a normal run needs them built with --features diagnostics, or needs a pad.

The rest of the run, for the record, with keys: a26859f, 49 world frames at ~1 400 draws a frame, median deep frame 2 830 ms, write-watch watches median 488 ms, texture lane waiting-for-remap median 322 ms (max 2 978). Same session an hour earlier, 8dd30ab at ~1 487 draws a frame had a median deep frame of 5 365 ms — comparable draws, so that is worth a proper A/B on the next quiet machine, not a claim.

**@⁠rostaddotcc** on GitHub · 2026-11-25 07:16 UTC · [original](https://github.com/fxceless/victory-fork/pull/179#issuecomment-7155687543) A trap worth putting in `proton/run.sh`'s notes, because I lost two runs to it today (both commits, `8dd30ab` and `a26859f`, on Linux/Proton): **Without scripted input the title sits at its start screen for ever** — 30 fps, 13 draws a frame, `proving 0.1 ms`, nothing loading and no error in the log. It is not a hang and not a regression by any commit: the title's start screen listens to the pad, and on a machine with no pad the stand-in gets nothing. In a diagnostics build `VICTORY_KEYS` presses the first pad's buttons as well as the keys (`gameinput.rs:1149-1160`), so ``` VICTORY_KEYS=25:Enter,40:Enter,55:Enter,70:Enter ``` takes it out of the menu into the world (2 067–2 752 draws a frame, 3 275–5 267 ms frames on this box). Two presses are not always enough; four at ~15-second spacing worked twice. That matters for anyone comparing runs on this ground: a run that never pressed anything looks identical to one where the loader is slow, and both look like "the PR made it stop loading" if you only read the frame line. For the launcher, pressing Enter on a schedule in a diagnostics build (or documenting the variable) would remove the whole class of confusion — the release build does not have the scripted keys, so a normal run needs them built with `--features diagnostics`, or needs a pad. The rest of the run, for the record, with keys: `a26859f`, 49 world frames at ~1 400 draws a frame, median deep frame 2 830 ms, write-watch watches median 488 ms, texture lane waiting-for-remap median 322 ms (max 2 978). Same session an hour earlier, `8dd30ab` at ~1 487 draws a frame had a median deep frame of 5 365 ms — comparable draws, so that is worth a proper A/B on the next quiet machine, not a claim.
Author
Owner

@⁠slauko on GitHub · 2026-11-25 14:01 UTC · original

The "Known Wine gap: without a pad the start screen sits at 30 fps and 13 draws a frame for ever" has a cause on the host side, and needs no change in the runtime.

Under Wine, XInput reported a gamepad that never presses a button: the keyboard interface of a Logitech G502, an HID interface with BTN_GAMEPAD, which Linux exposes as /dev/input/js0. The runtime gives the title its keyboard stand-in pad only while XInput has no pad at all (any_pad in crates/victory-hle/src/modules/gameinput.rs), so with that device connected the title listens to pad 0 for ever.

The runtime's log tells the two apart:

input device device=0 connected=true     ← the phantom pad: the title waits for it
input device device=4 connected=true     ← the keyboard stand-in: Return goes through

SDL_GAMECONTROLLER_IGNORE_DEVICES_EXCEPT=0000/0000 (a vendor/product pair no device has) keeps every pad from Wine's side. With it the stand-in is back and the start screen takes Return.

With that, the native d3d12/d3d12core/dxgi overrides, vkd3d-proton master@ec20719, the DXC fallback of #20 and the null-blob pipeline library (VIctory#1722), the first-boot screens, the loading art and the intro rendered on an RTX 3080 Ti under Proton Experimental.

**@⁠slauko** on GitHub · 2026-11-25 14:01 UTC · [original](https://github.com/fxceless/victory-fork/pull/179#issuecomment-7164638120) The "Known Wine gap: without a pad the start screen sits at 30 fps and 13 draws a frame for ever" has a cause on the host side, and needs no change in the runtime. Under Wine, XInput reported a gamepad that never presses a button: the keyboard interface of a Logitech G502, an HID interface with `BTN_GAMEPAD`, which Linux exposes as `/dev/input/js0`. The runtime gives the title its keyboard stand-in pad only while XInput has no pad at all (`any_pad` in `crates/victory-hle/src/modules/gameinput.rs`), so with that device connected the title listens to pad 0 for ever. The runtime's log tells the two apart: ``` input device device=0 connected=true ← the phantom pad: the title waits for it input device device=4 connected=true ← the keyboard stand-in: Return goes through ``` `SDL_GAMECONTROLLER_IGNORE_DEVICES_EXCEPT=0000/0000` (a vendor/product pair no device has) keeps every pad from Wine's side. With it the stand-in is back and the start screen takes Return. With that, the native `d3d12`/`d3d12core`/`dxgi` overrides, vkd3d-proton `master@ec20719`, the DXC fallback of #20 and the null-blob pipeline library (VIctory#1722), the first-boot screens, the loading art and the intro rendered on an RTX 3080 Ti under Proton Experimental.
github-bot closed this pull request 2026-11-26 14:47:38 +00:00
Author
Owner

@⁠ErRusso on GitHub · 2026-11-24 23:46 UTC · original · requested changes

Reviewed at 0f45997 against 2119b0e.

The Windows-build-in-Proton approach is sound and the smoke/test coverage is useful, but the launcher does not work as documented:

  • proton/run.sh uses "$proton/proton" waitforexitandrun "$wexe". Proton's waitforexitandrun calls g_session.run(), which invokes steam.exe with the arguments; it does not run the supplied executable. UMU_ID is not consulted by the Proton script. My own Proton Experimental test of proton run ./victory.exe launched steam.exe, while runinprefix ran victory. Use proton runinprefix (with the Wine-side exe) or $proton/files/bin/wine directly, and adjust docs/proton.md/smoke.sh accordingly.
  • The PR depends on #128, which currently fails its new cargo fmt --all -- --check CI step; that will block this PR too. Fix #128 or drop the fmt step before this lands.
  • The getcompatpath/getnativepath probing before STEAM_COMPAT_DATA_PATH/WINEPREFIX are exported can fall back to the wrong prefix; export the environment first, then probe.

The wine_version() change and the Windows-tree CI job are otherwise fine.

**@⁠ErRusso** on GitHub · 2026-11-24 23:46 UTC · [original](https://github.com/fxceless/victory-fork/pull/179#pullrequestreview-6049273241) · **requested changes** Reviewed at `0f45997` against `2119b0e`. The Windows-build-in-Proton approach is sound and the smoke/test coverage is useful, but the launcher does not work as documented: - `proton/run.sh` uses `"$proton/proton" waitforexitandrun "$wexe"`. Proton's `waitforexitandrun` calls `g_session.run()`, which invokes `steam.exe` with the arguments; it does not run the supplied executable. `UMU_ID` is not consulted by the Proton script. My own Proton Experimental test of `proton run ./victory.exe` launched `steam.exe`, while `runinprefix` ran victory. Use `proton runinprefix` (with the Wine-side exe) or `$proton/files/bin/wine` directly, and adjust `docs/proton.md`/`smoke.sh` accordingly. - The PR depends on #128, which currently fails its new `cargo fmt --all -- --check` CI step; that will block this PR too. Fix #128 or drop the fmt step before this lands. - The `getcompatpath`/`getnativepath` probing before `STEAM_COMPAT_DATA_PATH`/`WINEPREFIX` are exported can fall back to the wrong prefix; export the environment first, then probe. The `wine_version()` change and the Windows-tree CI job are otherwise fine.
Author
Owner

@⁠ErRusso on GitHub · 2026-11-25 11:15 UTC · original · approved these changes

Reviewed the changes since 0f45997 (41c06a0..f23a465). My three blockers are addressed:

  • Launcher: with UMU_ID exported, waitforexitandrun runs the supplied Windows-side exe, not steam.exe. I verified this against the installed GE-Proton11-14 proton script: run() sets umu_without_steam when UMU_ID is present and then uses argv = [wine] + sys.argv[2:]. My earlier runinprefix suggestion was wrong for the UMU_ID path; keeping waitforexitandrun is correct because it still performs Proton's prefix setup. The getcompatpath argument is used correctly for the Wine side.
  • Prefix probing: STEAM_COMPAT_DATA_PATH/WINEPREFIX are now exported before getnativepath/getcompatpath, so a fresh prefix cannot resolve through the wrong root.
  • fmt gate: dropped on this branch, with a comment explaining why. Restore it after #128 lands, since #128 now passes cargo fmt --all -- --check.

The start-screen/VICTORY_KEYS note and the pinned native d3dcompiler_47 path in docs/proton.md match what the Linux reports found. The PR is CONFLICTING with main and still stacks on #128; rebase before merging.

LGTM once rebased.

**@⁠ErRusso** on GitHub · 2026-11-25 11:15 UTC · [original](https://github.com/fxceless/victory-fork/pull/179#pullrequestreview-6056598944) · **approved these changes** Reviewed the changes since `0f45997` (`41c06a0`..`f23a465`). My three blockers are addressed: - **Launcher:** with `UMU_ID` exported, `waitforexitandrun` runs the supplied Windows-side exe, not `steam.exe`. I verified this against the installed GE-Proton11-14 `proton` script: `run()` sets `umu_without_steam` when `UMU_ID` is present and then uses `argv = [wine] + sys.argv[2:]`. My earlier `runinprefix` suggestion was wrong for the `UMU_ID` path; keeping `waitforexitandrun` is correct because it still performs Proton's prefix setup. The `getcompatpath` argument is used correctly for the Wine side. - **Prefix probing:** `STEAM_COMPAT_DATA_PATH`/`WINEPREFIX` are now exported before `getnativepath`/`getcompatpath`, so a fresh prefix cannot resolve through the wrong root. - **fmt gate:** dropped on this branch, with a comment explaining why. Restore it after #128 lands, since #128 now passes `cargo fmt --all -- --check`. The start-screen/`VICTORY_KEYS` note and the pinned native `d3dcompiler_47` path in `docs/proton.md` match what the Linux reports found. The PR is `CONFLICTING` with `main` and still stacks on #128; rebase before merging. LGTM once rebased.

Pull request closed

This discussion has been locked. Commenting is limited to contributors.
No description provided.