Skip to content

Tests: capture the truncate error before checking for Wine - #633

Closed
WebIdentity1 wants to merge 1 commit into
xcl-dev:mainfrom
WebIdentity1:codex/vfs-test-error-snapshot
Closed

WebIdentity1 wants to merge 1 commit into
xcl-dev:mainfrom
WebIdentity1:codex/vfs-test-error-snapshot

Conversation

@WebIdentity1

@WebIdentity1 WebIdentity1 commented Nov 24, 2026 •

Copy link
Copy Markdown

truncate_existing_validation_errors fails by itself on native Windows with 127 instead of the expected 5. Its first under_wine() call looks up wine_get_version between CreateFileW and GetLastError, overwriting the error being tested. Capture that error immediately. Found while validating #618; independent of its runtime change.

What is in it

  • Two added lines and one removed line in the existing vfs.rs test. Assertions and Wine handling are preserved; no runtime behavior changes.

Tested

  • Head bd6116452e990a0af69dd21eef4cc673364fe013, base 3db536ebe231418d76e8d6e52ccee0b47330a522. Native Windows 10 build 19045, Ryzen 7 7800X3D, RTX 3090 driver 591.74 plus AMD integrated driver 32.0.21030.2001, Rust 1.98.1 MSVC, SDK DXC 1.8.2502.11, Agility 1.620.2, debug.
  • cargo test --locked -p xcl --lib vfs::tests::truncate_existing_validation_errors -- --exact --show-output: baseline 0 passed / 1 failed / 0 ignored; candidate 1 / 0 / 0, no skips. cargo test --locked -p xcl --lib vfs::tests:: -- --test-threads=4 --show-output: 10 / 0 / 0, no skips.
  • cargo build --locked --workspace passed. Four-thread full workspace attempt timed out at 180 s with gpu_uma_import_check_at_init, large_heaps_get_shared_pages_as_used, slots_copy_and_release, and copy_descriptors_remaps_xbox_extra_cbv_srv_uav_to_pc_enum stalled (also observed on untouched main during VFS: reject creation beneath existing virtual files #618 validation).
  • Diagnostic cargo test --locked --workspace --no-fail-fast -- --test-threads=1 --show-output: 685 passed / 1 failed / 41 ignored. Only the previously observed gpu_clamp_and_omod_per_instruction failed. This is a serial result, not a completed four-thread run.
  • Four explicit skips: gpu_geometry_wave32_prefix_count_over_a_mask, gpu_wave32_program_in_wave64_hardware (no native wave64 on NVIDIA), test_title_draws_with_a_root_signature_under_the_debug_layer, uploads_start_from_each_subresources_state (debug layer unavailable). Sample variables unset. Presentation tests ran in desktop session1; some fixtures select AMD directly despite XCL_ADAPTER=3090.

Regression run
Not run: no retail title available. #507 has now added a maintainer-reviewed test-only exemption for this situation (#452). Please consider that label after reviewing this exact test-only revision; the draft still needs the other required checks. No runtime change or smoke evidence is claimed.

Not tested
Wine, release builds, retail titles. Full four-thread run did not complete; keeping this draft pending required checks.

AI use
Codex (GPT-6) isolated the failure, made the test-only change, ran native Windows validation and prepared the description.

The first under_wine call looks up wine_get_version and leaves error 127
on native Windows. Saving CreateFileW's error immediately keeps the test
independent of whether another fixture has already initialized that check.

The exact isolated test failed before this change and passes after it.
@fladit123

Copy link
Copy Markdown

Independent validation on my RTX 4060. I previously encountered this exact failure while working on #644, and can confirm that this patch resolves it.

Tested

  • Base: 3db536ebe231418d76e8d6e52ccee0b47330a522
  • PR head: bd6116452e990a0af69dd21eef4cc673364fe013
  • RTX 4060 8 GB, driver 610.88
  • Intel Core i5-12400F, 32 GB RAM
  • Windows 11 Pro build 26300
  • Rust 1.100.0 MSVC, DXC 1.8.2502.11
  • Debug, XCL_ADAPTER=4060
Configuration Result
Baseline isolated truncate test FAIL (127 instead of 5, exit 101)
PR isolated truncate test PASS (exit 0)
VFS tests, 4 threads 10 passed, 0 failed
Workspace build PASS
Full workspace, 4 threads 686 passed, 0 failed, 41 ignored

Commands

cargo test --locked -p xcl --lib vfs::tests::truncate_existing_validation_errors -- --exact --show-output

cargo test --locked -p xcl --lib vfs::tests:: -- --test-threads=4 --show-output

cargo build --workspace --locked

cargo test --workspace --locked --no-fail-fast -- --test-threads=4 --show-output

The full workspace run completed with exit code 0, without reproducing the reported GPU stalls or CLAMP failure. The worktree remained clean.

Two explicit capability skips, included in the passed count:

  • gpu_geometry_wave32_prefix_count_over_a_mask
  • gpu_wave32_program_in_wave64_hardware

The diff only changes when the test captures GetLastError(), preserving its assertions and Wine handling. No runtime behavior changes.

I support the maintainer-reviewed test-only label for this revision. No blocking findings within the tested scope.

Not tested: Wine, release, native wave64, retail titles, optional external samples or a full baseline workspace run.

AI use: ChatGPT (GPT-6.2) assisted with review, test planning, log analysis and reporting. All commands were executed locally by me.

@WebIdentity1

Copy link
Copy Markdown
Author

The equivalent test-only fix is now on main in d78597d: capture GetLastError immediately after CreateFileW, before under_wine can overwrite it. I compared both diffs; only the variable name and explanatory comment differ.

Closing this duplicate draft. The tested branch and original before/after evidence remain available.

AI use: Codex (GPT-6) checked the landed code and prepared this update.

@WebIdentity1 WebIdentity1 mentioned this pull request Nov 24, 2026
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.

2 participants