Tests: the stand-in race test keeps the let-go pipeline on its thread #3474
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/3474"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from ivall/xcl. Originally posted by Foniass on 2026-11-29T23:19:11Z.
hle::d3d12x::standin::tests::concurrent_shell_miss_reuses_winner_and_releases_loser_pipeline(from #2369, merged) fails on every run on main53e85fb1: 15 of 15 runs, also run alone (left: (0, 1, 1),right: (0, 0, 1)). The test expects the winner's driver pipeline to be released with the last shell. On main the last shell lets it go throughlate_release::hold_pipeline, which holds it until the queues are past the lists that may bind it. So one reference is still there when the test checks. The runtime is right; the test is not.The test now keeps what
let_gois given on its thread (LET_GO, asset_private_data_validation_and_per_shell_set_namedoes), checks that it is the winner's pipeline, and releases it. Test-only: only the test changes.What is in it
crates/xcl/src/hle/d3d12x/standin.rs: the test aboveTested
cargo test -p xcl --lib standin::tests: 7 passed, 0 failed, 5 runs in a row. Before the change, the test failed on 15 of 15 runs.cargo test --workspace --no-fail-fast -- --test-threads=4on54544682: 2793 passed, 0 failed, 49 ignored. SKIPPED GPU tests: 45 distinct notices, almost allno wave64.Regression run
main:
this PR:
Not tested
AI use
🤖 Generated with Claude Code
Imported from ivall/xcl. Originally posted by tiagonleal on 2026-11-29T23:22:38Z.
merge-check
base:
53e85fb124head:
5454468201merge: clean
build: cargo build --workspace -> ok
tests: Tier 0 (test-only diff, +5/-0 in
standin.rsinsidemod tests), so the touched targets and not the whole suite:cargo test -p xcl --lib hle::d3d12x::standin::tests::concurrent_shell_miss_reuses_winner_and_releases_loser_pipeline -- --exact-> passed 10 of 10 on the merged tree; on the base alone it fails withleft: (0, 1, 1),right: (0, 0, 1).cargo test -p xcl --lib hle::d3d12x::standin:: -- --test-threads=4-> 7 passed, 0 failed, 0 ignored.cargo test -p xcl --lib hle::d3d12x::late_release:: -- --test-threads=4-> 4 passed, 0 failed, 0 ignored. SKIPPED: none in these. Whole suite not run on this head.review: whole diff read. The test arms
LET_GOon its own thread before the shells are made, so the winner's pipeline that the lastreleaselets go is caught there and never reacheslate_release'sHELD. It then checks that exactly the winner was let go, once, drops that reference and keeps the original(0, 0, 1)check, so it still proves the loser is released and nothing leaks.LET_GOis cleared at the end, as the test above it does. Both releases run on the test's thread, so the capture does not depend on timing. Nothing outsidemod testschanges.performance: none, test-only.
verdict: safe to merge
hardware / tool and model: RTX 5070 Ti 16 GB (617.42), Ryzen 7 9800X3D, 32 GB, Windows 11 26300, rustc 1.100.0, debug / Claude Code (Claude Fable 5.2 ran the tests, read the diff and wrote this)
Imported from ivall/xcl. Originally posted by vasanex on 2026-11-29T23:52:45Z.
Tier 0 (test-only diff): no retail run. A second card for @tiagonleal's check above; the failure on plain
mainreproduces here on every run, and is gone with this.Imported from ivall/xcl. Originally posted by Parakeet-Wheat on 2026-11-30T01:56:06Z.
merge-check
base:
9335bc0d86head:
5454468201merge: clean
build: cargo build --workspace -> ok
tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2802 passed, 0 failed, 50 ignored; SKIPPED: 29 (22 no wave64, 3 wave32 per-lane form refused (#1426), 2 no heap windows, 1 driver cache needs Developer Mode, 1 no GPU_UPLOAD heaps); failing: none
review: Run alone,
concurrent_shell_miss_reuses_winner_and_releases_loser_pipelinefails in 5 of 5 runs on the base and 0 of 5 runs on the merge. Each base failure is the same assertion atstandin.rs:459:left: (0, 1, 1),right: (0, 0, 1). The diff adds 5 lines to the test module ofstandin.rsand changes no runtime code. On the base, the last shell's drop callslet_go, andlet_gogives the pipeline tolate_release::hold_pipeline. That hold keeps one reference to the winner's pipeline, so the old assertion finds one reference left. The test now turns on the thread-localLET_GOcapture, checks thatlet_gogot only the winner's pipeline, and releases that pipeline itself. The test releases both shells on its own thread, so the capture sees the last drop.pipelines_of_one_key_share_a_driver_pipeline_while_one_of_them_livesanda_shell_has_the_drivers_interfaces_and_its_own_references_and_private_datause the same capture and reset. The description namesset_private_data_validation_and_per_shell_set_nameas the model, but that test does not useLET_GO.standin.rsandlate_release.rshave no changes between53e85fb1and the base.performance: No runtime change: the PR changes only a test. This check made no title run.
verdict: safe to merge (test-only; the stand-in race test now passes on our RTX 3070, where it fails on main)
hardware / tool and model: RTX 3070 8 GB (610.88), AMD Ryzen 5 5600X, Windows 11 Home 26300, Rust 1.95.0, debug / Claude Code, Claude Opus 5.5 (merge, build, suite, base and merge reruns, and review)