XGameRuntime: a task queue's termination callback runs on its completion port #1154

Open
github-bot wants to merge 1 commit from github-bot/gh-1154 into main AGit
Owner

@⁠emirduran707 on GitHub · 2026-11-24 12:35 UTC · original
emirduran707:taskqueue-terminate-port → main · +114 −10 · 1 files · 1 commits · open

XTaskQueueTerminate with wait = false ran the title's termination callback on XCL's own worker thread, as soon as the queue's work had finished. Microsoft's documentation of XTaskQueueTerminate says the callback is invoked from the completion thread at the end of termination. Its example for a manual completion port relies on that: the callback is queued to the completion port, so it already runs on the title's UI thread. A title that dispatches its completion port by hand could get the callback on a thread it does not expect, while that thread may still be touching the queue.

Now, with wait = false, the callback is submitted to the queue's completion port once the pending work and completions are done. The port's monitors are notified, so on a manual port the callback runs from the title's own XTaskQueueDispatch. While an async termination callback is still pending submission, a completion-port XTaskQueueDispatch with a timeout (including INFINITE) waits for it instead of returning false early. With wait = true the callback still runs on the calling thread before Terminate returns: queuing it there could hang a caller whose manual port nobody dispatches while it waits.

What is in it

  • crates/xcl/src/hle/xgameruntime/taskqueue.rs:
    • submit_now goes through a private submit that can let the termination entry past the terminated check.
    • QueueState::termination_cb_pending keeps a manual completion-port dispatch waiting until the async termination entry has been queued.
    • run_terminated runs the queued callback.
    • Tests termination_callback_runs_from_a_manual_completion_port_dispatch and infinite_completion_pump_receives_termination_callback.

Tested

  • AMD Radeon RX 9060 XT (driver 32.0.31044.16), Ryzen 5 5600, Windows 11 Pro 26300, Rust 1.100.0; tests debug, smoke release
  • cargo test --workspace -- --test-threads=4 on cc8fbcd: 743 passed, 0 failed, 41 ignored; no SKIPPED GPU tests
  • cargo test -p xcl --lib taskqueue -- --test-threads=4: 12 passed, 0 failed
  • infinite_completion_pump_receives_termination_callback failed before the pending-termination wait (pump exited before termination callback in 49 of 50 runs); passes 50/50 after

Regression run

main:

xcl-smoke v1
commit: 47efa2ecea0a12934719ae69b81930cf02a4b1c3
gpu: AMD Radeon RX 9060 XT
title: retail-title
seconds: 60
exit: 0x0
frames shown: 1541 (PresentX 1541)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 19650 MB

this PR:

xcl-smoke v1
commit: cc8fbcd64d5aaa3efe11dd937a623082801e7c95
gpu: AMD Radeon RX 9060 XT
title: retail-title
seconds: 60
exit: 0x0
frames shown: 1593 (PresentX 1593)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 14785 MB

Not tested

  • A title that terminates a queue with a manual completion port and wait = false (the smoke title's run is a regression check only).
  • If the title never dispatches that manual port again, the small record holding the callback is not freed.
  • NVIDIA and Intel GPUs.

AI use

  • Claude Code with Claude Opus 5.5: original change, test and description.
  • Antigravity with Gemini 4 Neon: addressed the infinite-dispatch race from review, added the regression test, ran the updated test suite and smoke run, and updated this description.
**@⁠emirduran707** on GitHub · 2026-11-24 12:35 UTC · [original](https://github.com/xcl-dev/xcl/pull/1154) `emirduran707:taskqueue-terminate-port` → `main` · +114 −10 · 1 files · 1 commits · open `XTaskQueueTerminate` with `wait = false` ran the title's termination callback on XCL's own worker thread, as soon as the queue's work had finished. Microsoft's documentation of `XTaskQueueTerminate` says the callback is invoked from the completion thread at the end of termination. Its example for a manual completion port relies on that: the callback is queued to the completion port, so it already runs on the title's UI thread. A title that dispatches its completion port by hand could get the callback on a thread it does not expect, while that thread may still be touching the queue. Now, with `wait = false`, the callback is submitted to the queue's completion port once the pending work and completions are done. The port's monitors are notified, so on a manual port the callback runs from the title's own `XTaskQueueDispatch`. While an async termination callback is still pending submission, a completion-port `XTaskQueueDispatch` with a timeout (including `INFINITE`) waits for it instead of returning `false` early. With `wait = true` the callback still runs on the calling thread before `Terminate` returns: queuing it there could hang a caller whose manual port nobody dispatches while it waits. **What is in it** - `crates/xcl/src/hle/xgameruntime/taskqueue.rs`: - `submit_now` goes through a private `submit` that can let the termination entry past the terminated check. - `QueueState::termination_cb_pending` keeps a manual completion-port `dispatch` waiting until the async termination entry has been queued. - `run_terminated` runs the queued callback. - Tests `termination_callback_runs_from_a_manual_completion_port_dispatch` and `infinite_completion_pump_receives_termination_callback`. **Tested** - AMD Radeon RX 9060 XT (driver 32.0.31044.16), Ryzen 5 5600, Windows 11 Pro 26300, Rust 1.100.0; tests debug, smoke release - `cargo test --workspace -- --test-threads=4` on cc8fbcd: 743 passed, 0 failed, 41 ignored; no SKIPPED GPU tests - `cargo test -p xcl --lib taskqueue -- --test-threads=4`: 12 passed, 0 failed - `infinite_completion_pump_receives_termination_callback` failed before the pending-termination wait (pump exited before termination callback in 49 of 50 runs); passes 50/50 after **Regression run** main: ``` xcl-smoke v1 commit: 47efa2ecea0a12934719ae69b81930cf02a4b1c3 gpu: AMD Radeon RX 9060 XT title: retail-title seconds: 60 exit: 0x0 frames shown: 1541 (PresentX 1541) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 19650 MB ``` this PR: ``` xcl-smoke v1 commit: cc8fbcd64d5aaa3efe11dd937a623082801e7c95 gpu: AMD Radeon RX 9060 XT title: retail-title seconds: 60 exit: 0x0 frames shown: 1593 (PresentX 1593) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 14785 MB ``` **Not tested** - A title that terminates a queue with a manual completion port and `wait = false` (the smoke title's run is a regression check only). - If the title never dispatches that manual port again, the small record holding the callback is not freed. - NVIDIA and Intel GPUs. **AI use** - Claude Code with Claude Opus 5.5: original change, test and description. - Antigravity with Gemini 4 Neon: addressed the infinite-dispatch race from review, added the regression test, ran the updated test suite and smoke run, and updated this description.
XTaskQueueTerminate(wait = false) had a worker of the shared pool call the
title's termination callback directly. The GDK docs say the callback "will be
invoked from the completion thread at the end of termination", and their
example terminates a queue with a manual completion port from WM_CLOSE and
calls DestroyWindow in the callback, relying on it running from the UI
thread's own XTaskQueueDispatch. libHttpClient likewise queues a termination
entry on the completion port and notifies the queue's monitors.

Once in-flight work and completions have drained, the callback is now
submitted to the completion port through the same path as other completion
callbacks (which notifies monitors), allowed past the terminated check. On a
manual port it runs from the title's XTaskQueueDispatch, on a thread-pool
port on the pool. QueueState tracks pending async termination callbacks so
a completion-port XTaskQueueDispatch with a timeout (such as INFINITE) waits
for the termination entry before returning false. With wait = true the
callback still runs on the calling thread before Terminate returns: on a
manual port nobody may dispatch while the caller waits, which the docs warn
may deadlock.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Assisted-by: Antigravity (Gemini 4 Neon)
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 04:45:20 +00:00
Author
Owner

@⁠thehollowedone on GitHub · 2026-11-24 12:48 UTC · original

Independent Windows 11 build 26300 check, Ryzen 7 9800X3D, Rust 1.99.1 MSVC, debug. I queued a completion on a parent, then terminated a child asynchronously while both shared that manual completion port.

  • On 47efa2e, the child’s termination callback ran before any dispatch. Dispatching the parent then ran only its own completion.
  • On ea68eaa, neither callback ran before dispatch. The parent handle dispatched its own uncanceled completion first, then the child’s termination callback. Both ran on the dispatching thread. This passed in the 12-test taskqueue::tests run and in three separate runs of scratch_child_termination_obeys_shared_manual_port_order.

Both revisions used cargo test --offline --locked -p xcl --lib <filter> -- --nocapture --test-threads=1. Synthetic queue callbacks only.

AI-assisted. Codex (GPT-6, exact variant unavailable) wrote and ran the scratch fixture and drafted this report.

**@⁠thehollowedone** on GitHub · 2026-11-24 12:48 UTC · [original](https://github.com/xcl-dev/xcl/pull/1154#issuecomment-7131943546) Independent Windows 11 build 26300 check, Ryzen 7 9800X3D, Rust 1.99.1 MSVC, debug. I queued a completion on a parent, then terminated a child asynchronously while both shared that manual completion port. - On [`47efa2e`](https://github.com/ivall/xcl/commit/47efa2ecea0a12934719ae69b81930cf02a4b1c3), the child’s termination callback ran before any dispatch. Dispatching the parent then ran only its own completion. - On [`ea68eaa`](https://github.com/ivall/xcl/commit/ea68eaab214f941b0f12b4274b156b165c588cfa), neither callback ran before dispatch. The parent handle dispatched its own uncanceled completion first, then the child’s termination callback. Both ran on the dispatching thread. This passed in the 12-test `taskqueue::tests` run and in three separate runs of `scratch_child_termination_obeys_shared_manual_port_order`. Both revisions used `cargo test --offline --locked -p xcl --lib <filter> -- --nocapture --test-threads=1`. Synthetic queue callbacks only. AI-assisted. Codex (GPT-6, exact variant unavailable) wrote and ran the scratch fixture and drafted this report.
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-24 12:48 UTC · original

Independent verification on current main 384f7f7 (branch already contains it — clean).

Machine: Windows 11, Ryzen 9 7900X; Rust stable MSVC, debug.

  • cargo test -p xcl --lib taskqueue: 11 passed, 0 failed — includes the new termination_callback_runs_from_a_manual_completion_port_dispatch.

AI use: test runs by Devin (Cognition, SWE-2); no code changes.

**@⁠DavidM1911** on GitHub · 2026-11-24 12:48 UTC · [original](https://github.com/xcl-dev/xcl/pull/1154#issuecomment-7131952123) Independent verification on current `main` `384f7f7` (branch already contains it — clean). **Machine:** Windows 11, Ryzen 9 7900X; Rust stable MSVC, debug. - `cargo test -p xcl --lib taskqueue`: **11 passed, 0 failed** — includes the new `termination_callback_runs_from_a_manual_completion_port_dispatch`. AI use: test runs by Devin (Cognition, SWE-2); no code changes.
Author
Owner

@⁠kacper-serewis on GitHub · 2026-11-24 20:20 UTC · original

On ea68eaa, a title that pumps its manual completion port with XTaskQueueDispatch(h, Completion, INFINITE) in a loop does not get the termination callback.

Tested: Windows 11, debug, CPU only. Idle queue (ThreadPool / Manual), a pump thread blocked in dispatch, then XTaskQueueTerminate(wait = false). The pump is joined, then 50 ms pass:

callback not run
base 47efa2e 0 of 200
ea68eaa 200 of 200

From the code: Terminate wakes the dispatcher, which returns false because the queue is terminated and empty, so the pump ends before the callback is queued. The PR's test waits for the entry and then dispatches once with a zero timeout. Suggested (not tested): an infinite dispatch must not return false on a terminated queue until its termination entry has run.

Test (append to taskqueue.rs)
#[cfg(test)]
mod pump_probe {
    use super::*;
    #[test]
    fn infinite_completion_pump_gets_the_termination_callback() {
        unsafe extern "system" fn terminated(ctx: *mut c_void) {
            (*(ctx as *const std::sync::atomic::AtomicBool)).store(true, std::sync::atomic::Ordering::SeqCst);
        }
        let mut missed = 0;
        for _ in 0..200 {
            unsafe {
                let mut h = std::ptr::null_mut();
                assert_eq!(XTaskQueueCreate(MODE_THREAD_POOL, MODE_MANUAL, &mut h), S_OK);
                let ran = std::sync::atomic::AtomicBool::new(false);
                let hp = h as usize;
                let pump = std::thread::spawn(move || while XTaskQueueDispatch(hp as *mut c_void, PORT_COMPLETION, u32::MAX) {});
                std::thread::sleep(Duration::from_millis(5));
                assert_eq!(XTaskQueueTerminate(h, false, &ran as *const _ as *mut c_void, terminated as usize), S_OK);
                pump.join().unwrap();
                std::thread::sleep(Duration::from_millis(50));
                if !ran.load(std::sync::atomic::Ordering::SeqCst) { missed += 1; }
                // drain so that `ran` outlives the callback
                let t = Instant::now() + Duration::from_secs(2);
                while !ran.load(std::sync::atomic::Ordering::SeqCst) && Instant::now() < t { XTaskQueueDispatch(h, PORT_COMPLETION, 1); }
                XTaskQueueCloseHandle(h);
            }
        }
        assert_eq!(missed, 0, "missed {missed} of 200");
    }
}

AI use: Claude Code (Claude Opus 5.5) ran the tests and wrote this comment. I checked the points before posting.

**@⁠kacper-serewis** on GitHub · 2026-11-24 20:20 UTC · [original](https://github.com/xcl-dev/xcl/pull/1154#issuecomment-7143383782) On `ea68eaa`, a title that pumps its manual completion port with `XTaskQueueDispatch(h, Completion, INFINITE)` in a loop does not get the termination callback. **Tested:** Windows 11, debug, CPU only. Idle queue (ThreadPool / Manual), a pump thread blocked in dispatch, then `XTaskQueueTerminate(wait = false)`. The pump is joined, then 50 ms pass: | | callback not run | |---|---| | base `47efa2e` | 0 of 200 | | `ea68eaa` | 200 of 200 | From the code: Terminate wakes the dispatcher, which returns false because the queue is terminated and empty, so the pump ends before the callback is queued. The PR's test waits for the entry and then dispatches once with a zero timeout. Suggested (not tested): an infinite dispatch must not return false on a terminated queue until its termination entry has run. <details><summary>Test (append to taskqueue.rs)</summary> ```rust #[cfg(test)] mod pump_probe { use super::*; #[test] fn infinite_completion_pump_gets_the_termination_callback() { unsafe extern "system" fn terminated(ctx: *mut c_void) { (*(ctx as *const std::sync::atomic::AtomicBool)).store(true, std::sync::atomic::Ordering::SeqCst); } let mut missed = 0; for _ in 0..200 { unsafe { let mut h = std::ptr::null_mut(); assert_eq!(XTaskQueueCreate(MODE_THREAD_POOL, MODE_MANUAL, &mut h), S_OK); let ran = std::sync::atomic::AtomicBool::new(false); let hp = h as usize; let pump = std::thread::spawn(move || while XTaskQueueDispatch(hp as *mut c_void, PORT_COMPLETION, u32::MAX) {}); std::thread::sleep(Duration::from_millis(5)); assert_eq!(XTaskQueueTerminate(h, false, &ran as *const _ as *mut c_void, terminated as usize), S_OK); pump.join().unwrap(); std::thread::sleep(Duration::from_millis(50)); if !ran.load(std::sync::atomic::Ordering::SeqCst) { missed += 1; } // drain so that `ran` outlives the callback let t = Instant::now() + Duration::from_secs(2); while !ran.load(std::sync::atomic::Ordering::SeqCst) && Instant::now() < t { XTaskQueueDispatch(h, PORT_COMPLETION, 1); } XTaskQueueCloseHandle(h); } } assert_eq!(missed, 0, "missed {missed} of 200"); } } ``` </details> **AI use:** Claude Code (Claude Opus 5.5) ran the tests and wrote this comment. I checked the points before posting.
Author
Owner

@⁠emirduran707 on GitHub · 2026-11-24 21:21 UTC · original

Fixed in cc8fbcd (squashed and force-pushed).

QueueState now tracks pending async termination callbacks (termination_cb_pending): set in XTaskQueueTerminate when !wait && cb != 0, and decremented inside the p.items + q.state locks in submit as the termination entry is pushed onto PORT_COMPLETION (waking waiting dispatchers with notify_all). dispatch keeps waiting on PORT_COMPLETION while termination_cb_pending > 0, and returns false once the queue is empty and terminated with no pending termination entry.

Reproduced the failure with infinite_completion_pump_receives_termination_callback (missed 49 of 50 runs on ea68eaa); on cc8fbcd it passes 50/50, cargo test -p xcl --lib taskqueue passes 12/12, and the full workspace suite passes (743 passed, 0 failed, 41 ignored).

AI use: Antigravity with Gemini 4 Neon wrote the fix, test, and this reply.

**@⁠emirduran707** on GitHub · 2026-11-24 21:21 UTC · [original](https://github.com/xcl-dev/xcl/pull/1154#issuecomment-7144819016) Fixed in `cc8fbcd` (squashed and force-pushed). `QueueState` now tracks pending async termination callbacks (`termination_cb_pending`): set in `XTaskQueueTerminate` when `!wait && cb != 0`, and decremented inside the `p.items` + `q.state` locks in `submit` as the termination entry is pushed onto `PORT_COMPLETION` (waking waiting dispatchers with `notify_all`). `dispatch` keeps waiting on `PORT_COMPLETION` while `termination_cb_pending > 0`, and returns `false` once the queue is empty and terminated with no pending termination entry. Reproduced the failure with `infinite_completion_pump_receives_termination_callback` (missed 49 of 50 runs on `ea68eaa`); on `cc8fbcd` it passes 50/50, `cargo test -p xcl --lib taskqueue` passes 12/12, and the full workspace suite passes (743 passed, 0 failed, 41 ignored). **AI use:** Antigravity with Gemini 4 Neon wrote the fix, test, and this reply.
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-26 03:52 UTC · original

Re-verification on RTX 3060 Ti (Windows 11), new head merged with current main:

  • cargo test -p xcl --lib: all passed, 0 failed, 27 ignored. The earlier merge conflict is resolved.

Thanks!

— Devin

**@⁠DavidM1911** on GitHub · 2026-11-26 03:52 UTC · [original](https://github.com/xcl-dev/xcl/pull/1154#issuecomment-7182099517) Re-verification on RTX 3060 Ti (Windows 11), new head merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, 27 ignored. The earlier merge conflict is resolved. Thanks! — Devin
Author
Owner

@⁠fromthemoonx on GitHub · 2026-11-24 12:59 UTC · original · edited 2026-11-26 04:07 UTC

Rerun on the new head cc8fbcd (the INFINITE completion-pump fix): still passes on the RTX 3060, and the new pump test catches the case it was added for.

result
cargo test --workspace --no-fail-fast -- --test-threads=4, cc8fbcd merged onto main b49be18 (clean) 1437 passed, 0 failed, 47 ignored; 25 SKIPPED lines
termination_callback_runs_from_a_manual_completion_port_dispatch, infinite_completion_pump_receives_termination_callback, composite_queue_termination_preserves_shared_parent_port_work, alone, 40 runs each 40 of 40 each
hle::xgameruntime::taskqueue:: (12 tests), --test-threads=8, 30 runs 30 of 30
scratch: the dispatch wait loop without || (port == PORT_COMPLETION && state.termination_cb_pending > 0) infinite_completion_pump_receives_termination_callback fails at taskqueue.rs:951; the other 11 pass

Same machine, debug. The report below is for ea68eaa.


NVIDIA run with the whole suite, since Not tested lists NVIDIA.

Tested

  • NVIDIA GeForce RTX 3060 12 GB (32-lane waves), driver 32.0.16.1088; AMD Ryzen 7 5700X; native Windows 11 Pro 26H2 (build 26300.9974), Graphics Tools installed; rustc 1.100.0 stable-x86_64-pc-windows-msvc; DXC 1.9.2602.17; debug
  • Exact head ea68eaab214f941b0f12b4274b156b165c588cfa, which is on current main 47efa2e (so also the merged result): cargo build --workspace, then cargo test --workspace --no-fail-fast -- --test-threads=4: 742 passed, 0 failed, 41 ignored. The new taskqueue::tests::termination_callback_runs_from_a_manual_completion_port_dispatch passed.
  • Fails without the change: with taskqueue.rs as on main plus only the new test, it fails with the termination callback ran before the completion port was dispatched, left: Some(ThreadId(4)), right: None.
  • hle::xgameruntime::taskqueue tests, 10 runs: 10 of 10 passed (11 each)
  • e2e, 3 runs: 3 of 3 passed. The test title uses XGameRuntime task queues through the GDK thunks.
  • SKIPPED (no wave64 on this adapter): gpu_geometry_wave32_prefix_count_over_a_mask, gpu_wave32_program_in_wave64_hardware

Not tested

  • A retail title closing a task queue with a manual completion port; release build.

AI use

  • Claude Code (Claude Opus 5.5) ran the build and tests on the machine above, including the check without the change, and wrote this report from the output.
**@⁠fromthemoonx** on GitHub · 2026-11-24 12:59 UTC · [original](https://github.com/xcl-dev/xcl/pull/1154#issuecomment-7132204158) · edited 2026-11-26 04:07 UTC **Rerun on the new head `cc8fbcd` (the `INFINITE` completion-pump fix): still passes on the RTX 3060, and the new pump test catches the case it was added for.** | | result | |---|---| | `cargo test --workspace --no-fail-fast -- --test-threads=4`, `cc8fbcd` merged onto `main` `b49be18` (clean) | 1437 passed, 0 failed, 47 ignored; 25 `SKIPPED` lines | | `termination_callback_runs_from_a_manual_completion_port_dispatch`, `infinite_completion_pump_receives_termination_callback`, `composite_queue_termination_preserves_shared_parent_port_work`, alone, 40 runs each | 40 of 40 each | | `hle::xgameruntime::taskqueue::` (12 tests), `--test-threads=8`, 30 runs | 30 of 30 | | scratch: the dispatch wait loop without `\|\| (port == PORT_COMPLETION && state.termination_cb_pending > 0)` | `infinite_completion_pump_receives_termination_callback` fails at `taskqueue.rs:951`; the other 11 pass | Same machine, debug. The report below is for `ea68eaa`. --- NVIDIA run with the whole suite, since **Not tested** lists NVIDIA. **Tested** - NVIDIA GeForce RTX 3060 12 GB (32-lane waves), driver 32.0.16.1088; AMD Ryzen 7 5700X; native Windows 11 Pro 26H2 (build 26300.9974), Graphics Tools installed; rustc 1.100.0 `stable-x86_64-pc-windows-msvc`; DXC 1.9.2602.17; debug - **Exact head `ea68eaab214f941b0f12b4274b156b165c588cfa`**, which is on current `main` `47efa2e` (so also the merged result): `cargo build --workspace`, then `cargo test --workspace --no-fail-fast -- --test-threads=4`: **742 passed, 0 failed, 41 ignored**. The new `taskqueue::tests::termination_callback_runs_from_a_manual_completion_port_dispatch` passed. - **Fails without the change:** with `taskqueue.rs` as on `main` plus only the new test, it fails with `the termination callback ran before the completion port was dispatched`, `left: Some(ThreadId(4)), right: None`. - `hle::xgameruntime::taskqueue` tests, 10 runs: **10 of 10 passed** (11 each) - `e2e`, 3 runs: **3 of 3 passed**. The test title uses XGameRuntime task queues through the GDK thunks. - SKIPPED (no wave64 on this adapter): `gpu_geometry_wave32_prefix_count_over_a_mask`, `gpu_wave32_program_in_wave64_hardware` **Not tested** - A retail title closing a task queue with a manual completion port; release build. **AI use** - Claude Code (Claude Opus 5.5) ran the build and tests on the machine above, including the check without the change, and wrote this report from the output.
Author
Owner

@⁠futurepro62 on GitHub · 2026-11-26 08:54 UTC · original

NVIDIA and AMD full-suite run, to go with the reports above by fromthemoonx, since none of them covers AMD. Tested exact head cc8fbcd6 (on its base 47efa2e).

Tested

  • NVIDIA GeForce RTX 5070 Ti 16 GB (Blackwell, 32-lane waves only, mesh shaders), driver 621.40, Ryzen 7 9800X3D, Windows 11 Home 26300, Rust 1.100.0 MSVC, DXC + dxil.dll 1.9.2602.17 (Windows SDK 10.0.26100), debug, D3D12 debug layer installed.
  • cargo build --workspace, then XCL_REQUIRE_GPU=mesh cargo test --workspace -- --test-threads=4 --skip heap_window_out_of_memory_falls_back_to_the_switch_form --skip gpu::recomp::lower_dxil::tests::f16_programs_on_the_gpu --skip gpu::recomp::lower_dxil::tests::f32_programs_on_the_gpu --skip gpu::recomp::lower_dxil::tests::integer_programs_on_the_gpu --skip gpu::recomp::lower_dxil::tests::f64_programs_on_the_gpu --skip gpu::recomp::lower_dxil::tests::const_and_null_mask_operands_agree_with_hlsl_on_the_gpu --skip gpu::recomp::lower_dxil::tests::mask_ff0_and_flbit_agree_with_hlsl_on_the_gpu --skip gpu::dxil::fuzz_tests: 743 passed, 0 failed, 41 ignored. SKIPPED (no wave64): gpu_geometry_wave32_prefix_count_over_a_mask, gpu_wave32_program_in_wave64_hardware.
  • The new tests ran and passed: termination_callback_runs_from_a_manual_completion_port_dispatch, infinite_completion_pump_receives_termination_callback.
  • Same head on the AMD Radeon integrated GPU (iGPU) of the Ryzen 7 9800X3D (RDNA2, XCL_ADAPTER=radeon), cargo test --workspace -- --test-threads=4 --skip gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1: 743 passed, 0 failed, 41 ignored, no skips.
  • --skip leaves out tests that fail on main b49be183 too, not because of this PR. On NVIDIA: heap_window_out_of_memory_falls_back_to_the_switch_form (#1651), the four gpu::recomp::lower_dxil::tests::*_programs_on_the_gpu tests, const_and_null_mask_operands_agree_with_hlsl_on_the_gpu and mask_ff0_and_flbit_agree_with_hlsl_on_the_gpu (follow-up on #1651) fail because runner::skip_test turns their skips into failures under XCL_REQUIRE_GPU=mesh, and gpu::dxil::fuzz_tests seeds 70, 545, 1019 and 1507 fail CreateComputePipelineState with E_OUTOFMEMORY on this card (drivers 616.64 and 621.40). On AMD: fuzz_validate_and_gpu_1 fails on seed 540 (res[833] 0x7 vs CPU 0x6). The AMD run does not set XCL_REQUIRE_GPU.

Not tested

  • a release build, a game (test run only).

AI use

  • Claude Code (Claude Opus 5.5) ran the tests and wrote this report. I checked it before posting.
**@⁠futurepro62** on GitHub · 2026-11-26 08:54 UTC · [original](https://github.com/xcl-dev/xcl/pull/1154#issuecomment-7187169218) NVIDIA and AMD full-suite run, to go with the reports above by fromthemoonx, since none of them covers AMD. Tested exact head `cc8fbcd6` (on its base `47efa2e`). **Tested** - NVIDIA GeForce RTX 5070 Ti 16 GB (Blackwell, 32-lane waves only, mesh shaders), driver 621.40, Ryzen 7 9800X3D, Windows 11 Home 26300, Rust 1.100.0 MSVC, DXC + dxil.dll 1.9.2602.17 (Windows SDK 10.0.26100), debug, D3D12 debug layer installed. - `cargo build --workspace`, then `XCL_REQUIRE_GPU=mesh cargo test --workspace -- --test-threads=4 --skip heap_window_out_of_memory_falls_back_to_the_switch_form --skip gpu::recomp::lower_dxil::tests::f16_programs_on_the_gpu --skip gpu::recomp::lower_dxil::tests::f32_programs_on_the_gpu --skip gpu::recomp::lower_dxil::tests::integer_programs_on_the_gpu --skip gpu::recomp::lower_dxil::tests::f64_programs_on_the_gpu --skip gpu::recomp::lower_dxil::tests::const_and_null_mask_operands_agree_with_hlsl_on_the_gpu --skip gpu::recomp::lower_dxil::tests::mask_ff0_and_flbit_agree_with_hlsl_on_the_gpu --skip gpu::dxil::fuzz_tests`: **743 passed, 0 failed, 41 ignored**. SKIPPED (no wave64): `gpu_geometry_wave32_prefix_count_over_a_mask`, `gpu_wave32_program_in_wave64_hardware`. - The new tests ran and passed: `termination_callback_runs_from_a_manual_completion_port_dispatch`, `infinite_completion_pump_receives_termination_callback`. - Same head on the AMD Radeon integrated GPU (iGPU) of the Ryzen 7 9800X3D (RDNA2, `XCL_ADAPTER=radeon`), `cargo test --workspace -- --test-threads=4 --skip gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1`: **743 passed, 0 failed, 41 ignored**, no skips. - `--skip` leaves out tests that fail on main `b49be183` too, not because of this PR. On NVIDIA: `heap_window_out_of_memory_falls_back_to_the_switch_form` (#1651), the four `gpu::recomp::lower_dxil::tests::*_programs_on_the_gpu` tests, `const_and_null_mask_operands_agree_with_hlsl_on_the_gpu` and `mask_ff0_and_flbit_agree_with_hlsl_on_the_gpu` ([follow-up on #1651](https://git.gtahub.st/github/xcl-dev--xcl/issues/1651)) fail because `runner::skip_test` turns their skips into failures under `XCL_REQUIRE_GPU=mesh`, and `gpu::dxil::fuzz_tests` seeds 70, 545, 1019 and 1507 fail `CreateComputePipelineState` with `E_OUTOFMEMORY` on this card (drivers 616.64 and 621.40). On AMD: `fuzz_validate_and_gpu_1` fails on seed 540 (`res[833]` 0x7 vs CPU 0x6). The AMD run does not set `XCL_REQUIRE_GPU`. **Not tested** - a release build, a game (test run only). **AI use** - Claude Code (Claude Opus 5.5) ran the tests and wrote this report. I checked it before posting.
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/1154/head:github-bot/gh-1154'
git switch 'github-bot/gh-1154'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-1154'
git switch 'github-bot/gh-1154'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-1154'
git switch 'github-bot/gh-1154'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-1154'
git switch 'main'
git merge --squash 'github-bot/gh-1154'
git switch 'main'
git merge --ff-only 'github-bot/gh-1154'
git switch 'main'
git merge 'github-bot/gh-1154'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.