xcl run: skip startup shader preparation when no pipeline device exists (#2958) #2983

Open
retrope13 wants to merge 1 commit from upstream-pr/2983 into main
retrope13 commented 2026-11-27 07:09:43 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by retrope13 on 2026-11-27T07:09:43Z.


Fixes #2958.

What is in it

When xcl run starts a title with a shaders.rpf pack or loose shaders/*.dxbc files, startup shader preparation (present::preparation::before_guest → shaders::prepare_for_launch) previously aborted the run with exit code 2 (No pipeline device: ...) if no D3D12 pipeline device could be created. This blocked device-less test lanes as well as real-GPU machines with an unmatchable XCL_ADAPTER / d3d12_adapter (where real::init_with_remap would otherwise warn and fall back to auto / WARP / Backend::Null).

  • crates/xcl/src/shaders.rs:
    • prepare_for_launch validates shaders.rpf / shaders/ and checks progress.cancel first, keeping corrupt/empty packs, I/O errors, and cancellation fatal (exit 2).
    • Opens Pipelines::for_adapter once for startup preparation; on Err, logs xlog_warn!("Shader preparation skipped (no pipeline device: {e}) – starting the title without it") and returns Ok(LaunchPreparationStatus::SkippedNoDevice).
    • Preserves standalone xcl shaders --precompile --pipelines failing with exit 2 (xcl shaders: No pipeline device: ...).
    • Adds unit tests startup_preparation_skips_when_no_pipeline_device_is_available and startup_preparation_keeps_bad_pack_and_cancel_fatal_without_device.
  • crates/xcl/src/hle/d3d12x/present/preparation.rs:
    • Releases the preparation window cleanly on SkippedNoDevice (honoring cancellation, attaching kbm, and clearing the preparation screen without painting 100%) while preserving single-HWND handoff when backend_before_guest() falls back to a usable adapter.
  • crates/xcl/tests/launcher_e2e.rs:
    • Adds missing_pipeline_device_skips_shader_preparation_and_reaches_host_loader and shaders_cli_precompile_pipelines_fails_without_device.
  • README.md:
    • Notes that hosts without a D3D12 pipeline device skip startup shader preparation.

Tested

  • hardware (GPU + driver, CPU), Rust version, debug / release: Windows 11 26H2, NVIDIA GeForce RTX 4060 Laptop GPU (driver 32.0.16.2140), Intel Core i5-14500HX, rustc 1.100.0 (debug)
  • XCL_ADAPTER=NVIDIA cargo test --workspace --locked --no-fail-fast -- --test-threads=4: 1,459 passed, 1 failed (unrelated parallel VRAM-delta underflow flake in hle::d3d12x::title_textures::tests::placed_title_textures_share_vram_and_preserve_pixels, passed 1/1 standalone), 47 ignored
  • cargo test --locked -p xcl --lib startup_preparation_: 2 passed, 0 failed
  • cargo test --locked -p xcl --lib preparation::tests::: 3 passed, 0 failed
  • cargo test --locked -p xcl --test launcher_e2e: 9 passed, 0 failed
  • cargo test --locked -p xcl --test e2e: 4 passed, 0 failed

Regression run

main (c2ee10e4): xcl run on xcl_testtitle + shaders/vertex.dxbc with XCL_ADAPTER=nonexistent exited with code 2 (xcl: No pipeline device: ...) before backend_before_guest().

PR (bce0653c): same command logs Shader preparation skipped (no pipeline device: ...), falls back to RTX 4060 with same-HWND handoff (0x907c8 → 0x907c8), and finishes with xcl_testtitle: done, failures: 0 (exit 0).

Not tested

  • Linux / WineHQ 11.0 / Xvfb device-less container (Backend::Null fallback).
  • WARP-only Windows VM without a hardware GPU.
  • Retail shader packs or interactive Explorer menu-mode MessageBoxW.

AI use

  • Antigravity (Gemini 4) assisted with root-cause tracing, patch and test authoring, and drafting this description; all builds and test runs were executed and verified locally on my Windows 11 RTX 4060 laptop.
<!-- greyfinch-sync:ivall/xcl:issue:5522700400 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2983). Originally posted by [retrope13](https://github.com/retrope13) on 2026-11-27T07:09:43Z. --- Fixes #2958. ## What is in it When `xcl run` starts a title with a `shaders.rpf` pack or loose `shaders/*.dxbc` files, startup shader preparation (`present::preparation::before_guest` → `shaders::prepare_for_launch`) previously aborted the run with exit code `2` (`No pipeline device: ...`) if no D3D12 pipeline device could be created. This blocked device-less test lanes as well as real-GPU machines with an unmatchable `XCL_ADAPTER` / `d3d12_adapter` (where `real::init_with_remap` would otherwise warn and fall back to `auto` / WARP / `Backend::Null`). - `crates/xcl/src/shaders.rs`: - `prepare_for_launch` validates `shaders.rpf` / `shaders/` and checks `progress.cancel` first, keeping corrupt/empty packs, I/O errors, and cancellation fatal (`exit 2`). - Opens `Pipelines::for_adapter` once for startup preparation; on `Err`, logs `xlog_warn!("Shader preparation skipped (no pipeline device: {e}) – starting the title without it")` and returns `Ok(LaunchPreparationStatus::SkippedNoDevice)`. - Preserves standalone `xcl shaders --precompile --pipelines` failing with `exit 2` (`xcl shaders: No pipeline device: ...`). - Adds unit tests `startup_preparation_skips_when_no_pipeline_device_is_available` and `startup_preparation_keeps_bad_pack_and_cancel_fatal_without_device`. - `crates/xcl/src/hle/d3d12x/present/preparation.rs`: - Releases the preparation window cleanly on `SkippedNoDevice` (honoring cancellation, attaching `kbm`, and clearing the preparation screen without painting `100%`) while preserving single-HWND handoff when `backend_before_guest()` falls back to a usable adapter. - `crates/xcl/tests/launcher_e2e.rs`: - Adds `missing_pipeline_device_skips_shader_preparation_and_reaches_host_loader` and `shaders_cli_precompile_pipelines_fails_without_device`. - `README.md`: - Notes that hosts without a D3D12 pipeline device skip startup shader preparation. ### Tested - hardware (GPU + driver, CPU), Rust version, debug / release: Windows 11 26H2, NVIDIA GeForce RTX 4060 Laptop GPU (driver `32.0.16.2140`), Intel Core i5-14500HX, `rustc 1.100.0` (debug) - `XCL_ADAPTER=NVIDIA cargo test --workspace --locked --no-fail-fast -- --test-threads=4`: 1,459 passed, 1 failed (unrelated parallel VRAM-delta underflow flake in `hle::d3d12x::title_textures::tests::placed_title_textures_share_vram_and_preserve_pixels`, passed 1/1 standalone), 47 ignored - `cargo test --locked -p xcl --lib startup_preparation_`: 2 passed, 0 failed - `cargo test --locked -p xcl --lib preparation::tests::`: 3 passed, 0 failed - `cargo test --locked -p xcl --test launcher_e2e`: 9 passed, 0 failed - `cargo test --locked -p xcl --test e2e`: 4 passed, 0 failed ### Regression run main (`c2ee10e4`): `xcl run` on `xcl_testtitle` + `shaders/vertex.dxbc` with `XCL_ADAPTER=nonexistent` exited with code `2` (`xcl: No pipeline device: ...`) before `backend_before_guest()`. PR (`bce0653c`): same command logs `Shader preparation skipped (no pipeline device: ...)`, falls back to RTX 4060 with same-HWND handoff (`0x907c8` → `0x907c8`), and finishes with `xcl_testtitle: done, failures: 0` (exit `0`). ## Not tested - Linux / WineHQ 11.0 / Xvfb device-less container (`Backend::Null` fallback). - WARP-only Windows VM without a hardware GPU. - Retail shader packs or interactive Explorer menu-mode `MessageBoxW`. ### AI use - Antigravity (Gemini 4) assisted with root-cause tracing, patch and test authoring, and drafting this description; all builds and test runs were executed and verified locally on my Windows 11 RTX 4060 laptop.
Anon64 commented 2026-11-27 08:37:03 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Anon64 on 2026-11-27T08:37:03Z.


Checked on the device-less lane where #2958 came from: Ubuntu 24.04 in Docker, WineHQ 11.0, Xvfb, no GPU (so no vkd3d device and no WARP), x86_64-pc-windows-gnu debug, Rust 1.100.0.

On 827b27d7 (cargo test -p xcl --target x86_64-pc-windows-gnu --test e2e): the skip works. The log says Shader preparation skipped (no pipeline device: Call failed. (0x80004005)) – starting the title without it, and the title starts. The other three e2e tests pass. test_title_runs_and_game_folder_is_untouched still fails afterwards, because the title then panics:

panicked at crates/xcl/src/gpu/tiling.rs:478:20: range start index 9525837 out of range for slice of length 131072
panic in a function that cannot unwind
Game exited with code 0xc0000409

That is Chain::tile_level's dst[o..o + e], which, unlike the detile path above it (src.get(..)), has no bounds check.

For comparison, main 83b00818 with XCL_PREPARE=0: the title also starts, then its own GPU checks fail one after another (CreatePlacedResourceX hr=0x1, CreateGraphicsPipelineS…, PresentX, DirectStorage status 0x8000000a, …), and it exits 0xc0000005. So without a device the e2e title cannot pass either way. This PR turns the early exit 2 into the title's own failures, which is what #2958 asked for. The tile_level panic is a separate robustness point that a device-less run happens to reach.

Not checked: a GPU machine with an unmatchable XCL_ADAPTER, Windows.

AI use: Claude Code (Claude Opus 5.5) ran the tests and wrote this comment.

<!-- greyfinch-sync:ivall/xcl:comment:7213729836 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2983#issuecomment-7213729836). Originally posted by [Anon64](https://github.com/Anon64) on 2026-11-27T08:37:03Z. --- Checked on the device-less lane where #2958 came from: Ubuntu 24.04 in Docker, WineHQ 11.0, Xvfb, no GPU (so no vkd3d device and no WARP), `x86_64-pc-windows-gnu` debug, Rust 1.100.0. **On `827b27d7`** (`cargo test -p xcl --target x86_64-pc-windows-gnu --test e2e`): the skip works. The log says `Shader preparation skipped (no pipeline device: Call failed. (0x80004005)) – starting the title without it`, and the title starts. The other three e2e tests pass. `test_title_runs_and_game_folder_is_untouched` still fails afterwards, because the title then panics: ``` panicked at crates/xcl/src/gpu/tiling.rs:478:20: range start index 9525837 out of range for slice of length 131072 panic in a function that cannot unwind Game exited with code 0xc0000409 ``` That is `Chain::tile_level`'s `dst[o..o + e]`, which, unlike the detile path above it (`src.get(..)`), has no bounds check. **For comparison, `main` `83b00818` with `XCL_PREPARE=0`:** the title also starts, then its own GPU checks fail one after another (`CreatePlacedResourceX hr=0x1`, `CreateGraphicsPipelineS…`, PresentX, DirectStorage status `0x8000000a`, …), and it exits `0xc0000005`. So without a device the e2e title cannot pass either way. This PR turns the early exit 2 into the title's own failures, which is what #2958 asked for. The `tile_level` panic is a separate robustness point that a device-less run happens to reach. Not checked: a GPU machine with an unmatchable `XCL_ADAPTER`, Windows. **AI use:** Claude Code (Claude Opus 5.5) ran the tests and wrote this comment.
ettehn commented 2026-11-27 10:30:07 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by ettehn on 2026-11-27T10:30:07Z.


I compared clean main 623d02e465a17497a757a4ce867f482b0a6c8f3b and clean PR head 827b27d73c48fae94b1d23fe9ed508bd70e23ef5 on Windows 11 26200.9974, RTX 5070 Ti Laptop (621.24), Rust 1.97.1 MSVC, SDK DXC 1.8.2502.11, debug. I ran the repository test title with the same synthetic compute shader in both shaders.rpf and shaders/loose.dxbc, starting each run with empty cache and title data directories.

  • With the NVIDIA selector, both runs per revision exited 0 with zero test-title failures. Both inputs logged precompiling 1 shaders. Main reported PSOs made / disk hits as 1 / 0 for the pack and 1 / 1 for the loose input. This head reported 1 / 0 and 2 / 1. Each run produced the same single driver-cache filename and reported zero refusals. The second PSO summary now includes the first input’s PSO count, although it follows a separate per-input header.
  • With an unmatchable XCL_ADAPTER, main stopped in preparation (exit 2). This head skipped preparation for both inputs, fell back to the NVIDIA adapter, reused the preparation HWND for the swap chain, and exited 0 with zero test-title failures.

Scope was synthetic Windows startup and selector fallback. I did not test a device-less host, retail startup, or GPU performance.

AI use: OpenAI Codex (GPT-6) prepared the inputs, ran the comparisons, and drafted this report.

<!-- greyfinch-sync:ivall/xcl:comment:7215958927 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2983#issuecomment-7215958927). Originally posted by [ettehn](https://github.com/ettehn) on 2026-11-27T10:30:07Z. --- I compared clean main `623d02e465a17497a757a4ce867f482b0a6c8f3b` and clean PR head `827b27d73c48fae94b1d23fe9ed508bd70e23ef5` on Windows 11 26200.9974, RTX 5070 Ti Laptop (621.24), Rust 1.97.1 MSVC, SDK DXC 1.8.2502.11, debug. I ran the repository test title with the same synthetic compute shader in both `shaders.rpf` and `shaders/loose.dxbc`, starting each run with empty cache and title data directories. - With the NVIDIA selector, both runs per revision exited 0 with zero test-title failures. Both inputs logged `precompiling 1 shaders`. Main reported PSOs made / disk hits as `1 / 0` for the pack and `1 / 1` for the loose input. This head reported `1 / 0` and `2 / 1`. Each run produced the same single driver-cache filename and reported zero refusals. The second PSO summary now includes the first input’s PSO count, although it follows a separate per-input header. - With an unmatchable `XCL_ADAPTER`, main stopped in preparation (exit 2). This head skipped preparation for both inputs, fell back to the NVIDIA adapter, reused the preparation HWND for the swap chain, and exited 0 with zero test-title failures. Scope was synthetic Windows startup and selector fallback. I did not test a device-less host, retail startup, or GPU performance. AI use: OpenAI Codex (GPT-6) prepared the inputs, ran the comparisons, and drafted this report.
JJAutoCompare commented 2026-11-27 12:17:32 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by JJAutoCompare on 2026-11-27T12:17:32Z.


Tested

Clean 827b27d73c48fae94b1d23fe9ed508bd70e23ef5 on Windows 11 build 26200.9974, Ryzen 7 3800X, Rust 1.100.0 MSVC, Intel Arc A770 driver 32.0.101.9175, DXC/DXIL 1.9.2609.5. Built with cargo test -j 2 --locked -p xcl --lib --test launcher_e2e --no-run. Ran xcl run <synthetic-title-folder> in three fresh processes with XCL_ADAPTER=A770 XCL_NETWORK=0, each under its own shared Arc lock. The fixtures used a deliberately invalid title executable so the loader boundary was observable.

  • Cold preparation compiled one compute shader, made one PSO, refused zero, and reached loader error 0x7C10002. The backend identified the Arc A770.
  • Setting XCL_PREPARE=0 logged the bypass and reached the same loader error without shader-build or PSO counters.
  • A malformed loose shader produced one preparation record failure and exited 2 before the loader.

Three controls passed their expected-outcome checks. No runtime skips. Executable SHA-256 matched before, under, and after each lock acquisition.

Not tested

A native device-less lane, guest startup, HWND handoff, workspace suite and retail smoke.

AI use

T3 Code / Codex (gpt-6.2-sol) ran the original verification, independently reproduced the cases reported here, and wrote this report.

<!-- greyfinch-sync:ivall/xcl:comment:7218067717 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2983#issuecomment-7218067717). Originally posted by [JJAutoCompare](https://github.com/JJAutoCompare) on 2026-11-27T12:17:32Z. --- **Tested** Clean `827b27d73c48fae94b1d23fe9ed508bd70e23ef5` on Windows 11 build 26200.9974, Ryzen 7 3800X, Rust 1.100.0 MSVC, Intel Arc A770 driver 32.0.101.9175, DXC/DXIL 1.9.2609.5. Built with `cargo test -j 2 --locked -p xcl --lib --test launcher_e2e --no-run`. Ran `xcl run <synthetic-title-folder>` in three fresh processes with `XCL_ADAPTER=A770 XCL_NETWORK=0`, each under its own shared Arc lock. The fixtures used a deliberately invalid title executable so the loader boundary was observable. - Cold preparation compiled one compute shader, made one PSO, refused zero, and reached loader error `0x7C10002`. The backend identified the Arc A770. - Setting `XCL_PREPARE=0` logged the bypass and reached the same loader error without shader-build or PSO counters. - A malformed loose shader produced one preparation record failure and exited 2 before the loader. Three controls passed their expected-outcome checks. No runtime skips. Executable SHA-256 matched before, under, and after each lock acquisition. **Not tested** A native device-less lane, guest startup, HWND handoff, workspace suite and retail smoke. **AI use** T3 Code / Codex (`gpt-6.2-sol`) ran the original verification, independently reproduced the cases reported here, and wrote this report.
LocranKing commented 2026-11-27 13:59:42 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by LocranKing on 2026-11-27T13:59:42Z.


Tested PR #2983 (827b27d7) on Windows 11 (origin/main 06f90c19 baseline vs #2983), including unit tests, launcher_e2e, and a live launcher check with an unmatchable XCL_ADAPTER.

Environment

  • GPU: NVIDIA GeForce RTX 3060 Ti (8024 MiB VRAM, driver 32.0.16.2140)
  • CPU / RAM: AMD Ryzen 5 5500 (6C/12T), 32 GB DDR4, Windows 11 Build 26300

Unit & integration tests

  • cargo test --locked -p xcl --lib -- startup_preparation_skips_when_no_pipeline_device --nocapture:
    • shaders::tests::startup_preparation_skips_when_no_pipeline_device_is_available — ok (1 passed, 0 failed)
  • cargo test --locked -p xcl --test launcher_e2e -- --nocapture:
    • 9 passed, 0 failed (missing_pipeline_device_skips_shader_preparation_and_reaches_host_loader, shaders_cli_precompile_pipelines_fails_without_device, etc.)

Live title A/B with invalid XCL_ADAPTER (without XCL_PREPARE=0)

Set XCL_ADAPTER=NonexistentAdapter999 on a warm DXIL cache (lockhart, 15 s smoke):

  • origin/main (06f90c19): Aborted during startup shader prep with exit: 0x2:
    • [0.388] [ERROR] Shader preparation: No pipeline device: XCL_ADAPTER / d3d12_adapter "nonexistentadapter999" matches no hardware adapter (have: 0 = NVIDIA GeForce RTX 3060 Ti)
  • #2983 (827b27d7): Skipped startup shader preparation, fell back to auto, launched the title cleanly, and exited 0x0 (2 frames shown, 0 crashes / 0 removals):
    • [0.291] [WARN ] Shader preparation skipped (no pipeline device: XCL_ADAPTER / d3d12_adapter "nonexistentadapter999" matches no hardware adapter (have: 0 = NVIDIA GeForce RTX 3060 Ti)) – starting the title without it
    • [0.386] [WARN ] D3D12: XCL_ADAPTER / d3d12_adapter "nonexistentadapter999" matches no hardware adapter (have: 0 = NVIDIA GeForce RTX 3060 Ti) – using auto
<!-- greyfinch-sync:ivall/xcl:comment:7220199178 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2983#issuecomment-7220199178). Originally posted by [LocranKing](https://github.com/LocranKing) on 2026-11-27T13:59:42Z. --- Tested PR #2983 (`827b27d7`) on Windows 11 (`origin/main` `06f90c19` baseline vs `#2983`), including unit tests, `launcher_e2e`, and a live launcher check with an unmatchable `XCL_ADAPTER`. ### Environment - **GPU:** NVIDIA GeForce RTX 3060 Ti (8024 MiB VRAM, driver `32.0.16.2140`) - **CPU / RAM:** AMD Ryzen 5 5500 (6C/12T), 32 GB DDR4, Windows 11 Build 26300 ### Unit & integration tests - `cargo test --locked -p xcl --lib -- startup_preparation_skips_when_no_pipeline_device --nocapture`: - `shaders::tests::startup_preparation_skips_when_no_pipeline_device_is_available` — **ok** (`1 passed, 0 failed`) - `cargo test --locked -p xcl --test launcher_e2e -- --nocapture`: - **9 passed, 0 failed** (`missing_pipeline_device_skips_shader_preparation_and_reaches_host_loader`, `shaders_cli_precompile_pipelines_fails_without_device`, etc.) ### Live title A/B with invalid `XCL_ADAPTER` (without `XCL_PREPARE=0`) Set `XCL_ADAPTER=NonexistentAdapter999` on a warm DXIL cache (`lockhart`, `15 s` smoke): - **`origin/main` (`06f90c19`):** Aborted during startup shader prep with **`exit: 0x2`**: - `[0.388] [ERROR] Shader preparation: No pipeline device: XCL_ADAPTER / d3d12_adapter "nonexistentadapter999" matches no hardware adapter (have: 0 = NVIDIA GeForce RTX 3060 Ti)` - **`#2983` (`827b27d7`):** Skipped startup shader preparation, fell back to `auto`, launched the title cleanly, and exited **`0x0`** (`2` frames shown, `0` crashes / `0` removals): - `[0.291] [WARN ] Shader preparation skipped (no pipeline device: XCL_ADAPTER / d3d12_adapter "nonexistentadapter999" matches no hardware adapter (have: 0 = NVIDIA GeForce RTX 3060 Ti)) – starting the title without it` - `[0.386] [WARN ] D3D12: XCL_ADAPTER / d3d12_adapter "nonexistentadapter999" matches no hardware adapter (have: 0 = NVIDIA GeForce RTX 3060 Ti) – using auto`
retrope13 commented 2026-11-28 09:44:41 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by retrope13 on 2026-11-28T09:44:41Z.


Merged latest main (e429936c) into fix/prep-no-device-2958 at 81f3e5cc to resolve the conflicts in crates/xcl/src/shaders.rs around the new pso_corpus / warm_library / worker-based startup preparation flow (keeping corrupt packs/corpora, cancellation, and xcl shaders --precompile --pipelines fatal while skipping startup preparation when no pipeline device is available).

Re-verified locally on Windows 11 (NVIDIA GeForce RTX 4060 Laptop GPU, rustc 1.100.1, DXC 1.9.2602.17):

  • cargo check --locked -p xcl --lib --bins --tests — pass
  • XCL_ADAPTER=NVIDIA shaders::tests:: — 22 passed, 0 failed
  • XCL_ADAPTER=NVIDIA shaders::warm_library::tests:: — 4 passed, 0 failed
  • XCL_ADAPTER=NVIDIA shaders::pso_corpus::tests:: — 1 passed, 0 failed
  • --test launcher_e2e — 9 passed, 0 failed
  • XCL_ADAPTER=NVIDIA --test shaders_e2e — 9 passed, 0 failed

(Conflict resolution and local test commands assisted by Antigravity (Gemini 4).)

<!-- greyfinch-sync:ivall/xcl:comment:7237437183 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2983#issuecomment-7237437183). Originally posted by [retrope13](https://github.com/retrope13) on 2026-11-28T09:44:41Z. --- Merged latest `main` (`e429936c`) into `fix/prep-no-device-2958` at `81f3e5cc` to resolve the conflicts in `crates/xcl/src/shaders.rs` around the new `pso_corpus` / `warm_library` / worker-based startup preparation flow (keeping corrupt packs/corpora, cancellation, and `xcl shaders --precompile --pipelines` fatal while skipping startup preparation when no pipeline device is available). Re-verified locally on Windows 11 (`NVIDIA GeForce RTX 4060 Laptop GPU`, `rustc 1.100.1`, DXC `1.9.2602.17`): - `cargo check --locked -p xcl --lib --bins --tests` — pass - `XCL_ADAPTER=NVIDIA` `shaders::tests::` — 22 passed, 0 failed - `XCL_ADAPTER=NVIDIA` `shaders::warm_library::tests::` — 4 passed, 0 failed - `XCL_ADAPTER=NVIDIA` `shaders::pso_corpus::tests::` — 1 passed, 0 failed - `--test launcher_e2e` — 9 passed, 0 failed - `XCL_ADAPTER=NVIDIA --test shaders_e2e` — 9 passed, 0 failed *(Conflict resolution and local test commands assisted by Antigravity (Gemini 4).)*
Aniseto commented 2026-11-28 09:55:05 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Aniseto on 2026-11-28T09:55:05Z.


Ran the startup-preparation tests at 81f3e5cc on an NVIDIA Blackwell desktop part:

Environment: Windows 11 Pro build 26200 x64, NVIDIA GeForce RTX 5070 Ti (Blackwell, wave32 only, 16 GB) driver 32.0.16.2124, Intel Core i5-12400F, 64 GB RAM, rustc 1.100.0 (0ef1bc386 2026-11-09), MSVC 14.44.35207, DXC 1.9.2609.5, debug build.

XCL_ADAPTER=NVIDIA cargo test --locked -p xcl --lib startup_preparation_ -- --test-threads=1
2 passed; 0 failed; 0 ignored; 0 measured; 2029 filtered out      (exit 0)

Both unit tests pass, covering the skip when no pipeline device is available and the fatal cases for a bad pack or cancellation. The head is the merge of current main; the thread has a device-less Linux run, a Windows run on RTX 5070 Ti Laptop and other NVIDIA checks, but none on a desktop RTX 5070 Ti. I did not run a title with an unmatchable adapter here.

Not tested: launcher_e2e, a title run with XCL_ADAPTER set to a nonexistent adapter, a paired smoke run, the full workspace suite, AMD and Intel GPUs, native wave64 hosts, Wine, game data.

AI-assisted (OpenCode), model: DeepSeek V4.1 Flash Free - checked out the PR's head commit in a detached worktree, built it, ran the tests, wrote this report; the worktree was not modified; no game data was used.

<!-- greyfinch-sync:ivall/xcl:comment:7237550513 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2983#issuecomment-7237550513). Originally posted by [Aniseto](https://github.com/Aniseto) on 2026-11-28T09:55:05Z. --- Ran the startup-preparation tests at `81f3e5cc` on an NVIDIA Blackwell desktop part: Environment: Windows 11 Pro build 26200 x64, NVIDIA GeForce RTX 5070 Ti (Blackwell, wave32 only, 16 GB) driver 32.0.16.2124, Intel Core i5-12400F, 64 GB RAM, rustc 1.100.0 (0ef1bc386 2026-11-09), MSVC 14.44.35207, DXC 1.9.2609.5, debug build. ``` XCL_ADAPTER=NVIDIA cargo test --locked -p xcl --lib startup_preparation_ -- --test-threads=1 2 passed; 0 failed; 0 ignored; 0 measured; 2029 filtered out (exit 0) ``` Both unit tests pass, covering the skip when no pipeline device is available and the fatal cases for a bad pack or cancellation. The head is the merge of current `main`; the thread has a device-less Linux run, a Windows run on RTX 5070 Ti Laptop and other NVIDIA checks, but none on a desktop RTX 5070 Ti. I did not run a title with an unmatchable adapter here. Not tested: `launcher_e2e`, a title run with `XCL_ADAPTER` set to a nonexistent adapter, a paired smoke run, the full workspace suite, AMD and Intel GPUs, native wave64 hosts, Wine, game data. AI-assisted (OpenCode), model: **DeepSeek V4.1 Flash Free** - checked out the PR's head commit in a detached worktree, built it, ran the tests, wrote this report; the worktree was not modified; no game data was used.
retrope13 commented 2026-11-29 10:35:35 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by retrope13 on 2026-11-29T10:35:35Z.


Rebased fix/prep-no-device-2958 cleanly onto main (d8bd9a38) as a single commit at 7d569414, resolving the 3 conflicts in crates/xcl/src/shaders.rs around the new title_inputs() helper and XCL_PREPARE_HISTORY_PRESENT (milestone::prepare_launch) path so missing-device skips startup preparation cleanly on both paths while keeping corrupt packs/corpora, cancellation, and xcl shaders --precompile --pipelines fatal.

Re-verified locally on Windows 11 (NVIDIA GeForce RTX 4060 Laptop GPU, rustc 1.100.1, DXC 1.9.2602.17):

  • cargo check --locked -p xcl --lib --bins --tests — pass
  • XCL_ADAPTER=NVIDIA shaders::tests:: — 24 passed, 0 failed
  • XCL_ADAPTER=NVIDIA shaders::warm_library::tests:: — 4 passed, 0 failed
  • XCL_ADAPTER=NVIDIA shaders::pso_corpus::tests:: — 1 passed, 0 failed
  • XCL_ADAPTER=NVIDIA shaders::milestone::tests:: — 9 passed, 0 failed
  • --test launcher_e2e — 9 passed, 0 failed
  • XCL_ADAPTER=NVIDIA --test shaders_e2e — 9 passed, 0 failed

(Rebase and local test verification assisted by Antigravity (Gemini 4).)

<!-- greyfinch-sync:ivall/xcl:comment:7254538415 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2983#issuecomment-7254538415). Originally posted by [retrope13](https://github.com/retrope13) on 2026-11-29T10:35:35Z. --- Rebased `fix/prep-no-device-2958` cleanly onto `main` (`d8bd9a38`) as a single commit at `7d569414`, resolving the 3 conflicts in `crates/xcl/src/shaders.rs` around the new `title_inputs()` helper and `XCL_PREPARE_HISTORY_PRESENT` (`milestone::prepare_launch`) path so missing-device skips startup preparation cleanly on both paths while keeping corrupt packs/corpora, cancellation, and `xcl shaders --precompile --pipelines` fatal. Re-verified locally on Windows 11 (`NVIDIA GeForce RTX 4060 Laptop GPU`, `rustc 1.100.1`, DXC `1.9.2602.17`): - `cargo check --locked -p xcl --lib --bins --tests` — pass - `XCL_ADAPTER=NVIDIA` `shaders::tests::` — 24 passed, 0 failed - `XCL_ADAPTER=NVIDIA` `shaders::warm_library::tests::` — 4 passed, 0 failed - `XCL_ADAPTER=NVIDIA` `shaders::pso_corpus::tests::` — 1 passed, 0 failed - `XCL_ADAPTER=NVIDIA` `shaders::milestone::tests::` — 9 passed, 0 failed - `--test launcher_e2e` — 9 passed, 0 failed - `XCL_ADAPTER=NVIDIA --test shaders_e2e` — 9 passed, 0 failed *(Rebase and local test verification assisted by Antigravity (Gemini 4).)*
Foniass commented 2026-12-01 09:16:57 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Foniass on 2026-12-01T09:16:57Z.


Triage (#1607) – head 653c7ed

This is the only open PR for #2958. It follows the plan in that issue. prepare_for_launch now opens the pipeline device once, up front. If that fails, it returns SkippedNoDevice and the title starts; a bad pack and cancel are still errors. The xcl shaders --pipelines CLI keeps its exit code 2. The tests inject the device opener and cover both paths.
The CI failure is standin::tests::concurrent_shell_miss_reuses_winner_and_releases_loser_pipeline, which this diff does not touch. The lib suite stopped there, so the new launcher_e2e tests did not run in CI.
One small point: in the prepare_title_inputs worker path, the launcher's own Pipelines device now stays open while the worker processes run. Before this change, that path never created a device.
Recommendation: keep open.

AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.

<!-- greyfinch-sync:ivall/xcl:comment:7306476139 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2983#issuecomment-7306476139). Originally posted by [Foniass](https://github.com/Foniass) on 2026-12-01T09:16:57Z. --- **Triage (#1607)** – head 653c7ed This is the only open PR for #2958. It follows the plan in that issue. `prepare_for_launch` now opens the pipeline device once, up front. If that fails, it returns `SkippedNoDevice` and the title starts; a bad pack and cancel are still errors. The `xcl shaders --pipelines` CLI keeps its exit code 2. The tests inject the device opener and cover both paths. The CI failure is `standin::tests::concurrent_shell_miss_reuses_winner_and_releases_loser_pipeline`, which this diff does not touch. The lib suite stopped there, so the new `launcher_e2e` tests did not run in CI. One small point: in the `prepare_title_inputs` worker path, the launcher's own `Pipelines` device now stays open while the worker processes run. Before this change, that path never created a device. Recommendation: keep open. AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/2983:upstream-pr/2983'
git switch 'upstream-pr/2983'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/2983'
git switch 'upstream-pr/2983'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/2983'
git switch 'upstream-pr/2983'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/2983'
git switch 'main'
git merge --squash 'upstream-pr/2983'
git switch 'main'
git merge --ff-only 'upstream-pr/2983'
git switch 'main'
git merge 'upstream-pr/2983'
git push origin 'main'
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
xcl-dev/xcl!2983
No description provided.