Skip to content

Tests: accept Wine's missing-path error in pls_quota - #2415

Open
ldeep98154deep-jpg wants to merge 1 commit into
xcl-dev:mainfrom
ldeep98154deep-jpg:tests/pls-quota-wine-error
Open

ldeep98154deep-jpg wants to merge 1 commit into
xcl-dev:mainfrom
ldeep98154deep-jpg:tests/pls-quota-wine-error

Conversation

@ldeep98154deep-jpg

Copy link
Copy Markdown

Fixes #810

disk_free_space_ex_reports_pls_quota asserted ERROR_PATH_NOT_FOUND
unconditionally. On Wine, the forwarded host GetDiskFreeSpaceExW returns
ERROR_FILE_NOT_FOUND, so the test failed before it reached the quota checks.
PR #2197 adds other pls_quota coverage but leaves this assertion unchanged.

What is in it

  • Accept Wine's ERROR_FILE_NOT_FOUND for S:\missing only when under_wine(); Windows still requires ERROR_PATH_NOT_FOUND.
  • Read GetLastError() before calling under_wine(), so its GetProcAddress cannot overwrite the error.
  • Unit test covering both host branches and rejecting an unrelated error code.
  • Test-only diff: no runtime change, so no smoke regression run is needed.

Tested
Local Windows x64, Intel Iris Xe Graphics (16-lane waves),
stable-x86_64-pc-windows-gnu with llvm-mingw; DXC 1.9.2607.0 / DXIL 1.8.2502.11.

  • cargo +stable-x86_64-pc-windows-gnu test -p xcl --test pls_quota -- --nocapture
    — 2 passed, 0 failed.
  • cargo +stable-x86_64-pc-windows-gnu test --workspace -- --test-threads=4 --skip pe::tests::parses_own_test_binary_tls --skip test_title_runs_and_game_folder_is_untouched
    — 703 passed, 0 failed, 41 ignored, 2 filtered out; 87 SKIPPED ...: no wave64.

Not tested

  • Wine was unavailable, so the original Wine failure was not reproduced; its branch is covered by the new unit test only.
  • Wave64 GPU tests were skipped on this adapter. No retail title was run (not needed for a test-only diff).
  • The two skipped tests above are pre-existing toolchain/environment failures.

AI use
Claude: screened open issues and PRs, confirmed #810 had no fix in #2197/#1817/#1411/#1462, wrote the test-only change, and ran the commands above.

@ldeep98154deep-jpg
ldeep98154deep-jpg force-pushed the tests/pls-quota-wine-error branch from bb654ae to 9af2fce Compare November 25, 2026 18:51
Wine's GetDiskFreeSpaceExW answers ERROR_FILE_NOT_FOUND for a missing path
below a mounted PLS drive, where Windows answers ERROR_PATH_NOT_FOUND. The
test asserted 3 unconditionally and failed on Wine (xcl-dev#810); PR xcl-dev#2197 expands
other pls_quota coverage but leaves that assertion unchanged.

Keep the Windows assertion strict, accept Wine's code only under under_wine(),
and read GetLastError() before it so GetProcAddress cannot overwrite the
error. Cover both host branches with a unit test.
@ldeep98154deep-jpg
ldeep98154deep-jpg force-pushed the tests/pls-quota-wine-error branch from 9af2fce to 5e26d80 Compare November 25, 2026 18:54
@DavidM1911

Copy link
Copy Markdown
Contributor

Verification on RTX 3060 Ti (Windows 11), branch merged with current main:

  • cargo test -p xcl --lib: 1 real failure, deterministic (also fails --test-threads=1, 1219/1):
gpu::recomp::lower_dxil::tests::a_bridged_mask_write_where_one_half_is_elsewhere_meets_no_barrier
  assertion failed: group barriers in the program (lower_dxil.rs:1155)

The lowered program is missing an expected group barrier (or emits one where none is expected). Needs a fix before merge.

— Devin

gustavsi added a commit to gustavsi/xcl that referenced this pull request Nov 25, 2026
…#2414, xcl-dev#2415

Integrates per-draw mirror sync fast path (xcl-dev#2437), PresentX compositor
hardening (xcl-dev#2418), XAudio2 GetState buffer context fix (xcl-dev#2410), and Wine
test fixes (xcl-dev#2414, xcl-dev#2415).

Assisted-by: Antigravity (Gemini 4 Neon)
@pablogonz12

Copy link
Copy Markdown
Contributor

Test report from Linux + Wine (RADV). Prepared with AI assistance: DeepSeek V4.1 Flash in OpenCode; the commands below were run by it and the output is pasted verbatim.

Setup

  • CachyOS (Arch), kernel 7.3.6-1-cachyos-eevdf, Mesa 26.3.1-5 (RADV GFX1201), AMD Radeon RX 9070 XT 16 GB, Ryzen 9 9900X.
  • GE-Proton11-14 wine (~/.local/share/Steam/compatibilitytools.d/GE-Proton11-14-x86_64/files/bin/wine), scratch prefix, WINEDLLOVERRIDES="d3d12,d3d12core,dxgi,d3d11,d3d10core=n,b", VKD3D_CONFIG=ignore_shared_fence, WINEDEBUG=-all, DXC 1.9.2609.5.
  • Build (Linux cross-compile): RUSTFLAGS="-C target-feature=+crt-static" cargo xwin test --workspace --release --target x86_64-pc-windows-msvc --no-run, then wine <pls_quota exe> --test-threads=1.
  • Base = main 2898511 with this PR merged on top (it merges cleanly, so only this PR differs), head = 5e26d80.

Result, pls_quota integration test

base 2898511 this PR 5e26d80
pls_quota FAILED: 0 passed, 1 failed ok: 2 passed, 0 failed, 0 ignored (0.01 s)

Base, verbatim:

thread 'disk_free_space_ex_reports_pls_quota' (284) panicked at crates/xcl/tests/pls_quota.rs:144:9:
assertion `left == right` failed
  left: (0, 2)
 right: (0, 3)

2 is ERROR_FILE_NOT_FOUND, which is what Wine's GetDiskFreeSpaceExW answers here (GetDiskFreeSpaceExW(s:/<missing>): 0 MiB available of 1 MiB); the PR accepts it only under under_wine() and keeps ERROR_PATH_NOT_FOUND strict elsewhere. So this is the Wine half of #810, confirmed fixed here, and the new missing_pls_path_error_accepts_wines_code_only_under_wine passes on Wine as well.

Not tested

  • No game run; this exercises the test binary only.
  • Windows (the ERROR_FILE_NOT_FOUND branch is not taken there).

AI use

  • DeepSeek V4.1 Flash (OpenCode) built both commits, ran the tests above and wrote this report; no code was written or changed by it.

gustavsi added a commit to gustavsi/xcl that referenced this pull request Nov 25, 2026
…#2414, xcl-dev#2415

Integrates per-draw mirror sync fast path (xcl-dev#2437), PresentX compositor
hardening (xcl-dev#2418), XAudio2 GetState buffer context fix (xcl-dev#2410), and Wine
test fixes (xcl-dev#2414, xcl-dev#2415).

Assisted-by: Antigravity (Gemini 4 Neon)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Tests: pls_quota expects ERROR_PATH_NOT_FOUND for a missing path below S:\, Wine returns ERROR_FILE_NOT_FOUND

3 participants