Tests: the GPU tests load the D3D12 Agility SDK, as victory.exe does #2878

Open
github-bot wants to merge 4 commits from github-bot/gh-2878 into main AGit
Owner

@⁠lhnizdo on GitHub · 2026-11-25 22:57 UTC · original
lhnizdo:pr/tests-agility-sdk → main · +111 −0 · 4 files · 4 commits · open

What this fixes

On Windows 10 the system's D3D12 runtime has no shader model 6.6, so every GPU test in victory-shader and victory-gpu skipped its hardware device ("no SM 6.6 hardware device; skipped"), and then failed its "at least one device ran" check where WARP has no 6.6 either (Windows 10's WARP stops at 6.2). #2460 makes victory.exe load the Agility SDK from .\D3D12\; the test binaries had no such exports.

Changes

  • The test binaries of victory-shader and victory-gpu export D3D12SDKVersion (620) and D3D12SDKPath, like victory.exe. A test binary sits in target\<profile>\deps\, so the path is ..\D3D12\: the runtime is looked for in target\<profile>\D3D12\, where D3D12Core.dll from the NuGet package is copied once (as for victory.exe in #2460). Without that folder nothing changes: Windows uses its own runtime.
    • The exports are MSVC linker directives in a .drectve section of a cfg(test) static, so only test binaries get them. cargo:rustc-link-arg-tests is refused in a package without a tests\ target, and rustc-link-arg would also reach the shader crate's benchmark, which doesn't define the values.
  • On NVIDIA the shader crate's test host makes structured buffer views raw, as victory-gpu's buffer_srv does with #2464, with the same VICTORY_RAW_STRUCTURED override. With the hardware device running, a_heap_buffer_read_by_element_takes_the_views_stride read the wrong records there: lane l got the first word of element 3l + 1.
    • The test host works this out from its device's adapter when it makes the view, so the shared WARP device, the hardware device and Host::from_device all get it.

Tested

RTX 2080 (32-lane waves), Windows 10 19045, driver 32.0.16.1742, main f3578e3 plus this PR, with target\debug\D3D12\ holding D3D12Core.dll 1.620.2:

  • Before: every GPU test skipped the hardware device ("no SM 6.6 hardware device; skipped"), then failed its "at least one device ran" check (all 6 stride_tests, for example).
  • cargo test -p victory-gpu --lib: 226 passed, 2 failed. The two are the NVIDIA view-heap cap pair (dynamic_slots_are_held_until_released, lists_share_a_table_and_copies_keep_their_views), which #2461 fixes.
  • cargo test -p victory-shader --lib: 300 passed, 2 failed:
    • a_heap_buffer_read_where_no_buffer_view_is_reads_zeros: the same heap cap, also fixed by #2461.
    • pops_wait_loop_exits_immediately_for_inactive_lanes wants a shader model 6.6 WARP device, and Windows 10's WARP is 6.2.
  • With the raw views, a_heap_buffer_read_by_element_takes_the_views_stride passes on NVIDIA.
  • cargo clippy -p victory-shader -p victory-gpu --all-targets -- -D warnings is clean.

Still skipped here, as before: WARP (no 6.6 on Windows 10) and the tests that need the console's shader compiler.

AI-assisted (Claude Code); the runs were on my machine.

🤖 Generated with Claude Code

https://claude.ai/code/session_018sSQTfPXZpSkjMMNa7RB5G

**@⁠lhnizdo** on GitHub · 2026-11-25 22:57 UTC · [original](https://github.com/Marvisak/VIctory/pull/2878) `lhnizdo:pr/tests-agility-sdk` → `main` · +111 −0 · 4 files · 4 commits · open ## What this fixes On Windows 10 the system's D3D12 runtime has no shader model 6.6, so every GPU test in `victory-shader` and `victory-gpu` skipped its hardware device ("no SM 6.6 hardware device; skipped"), and then failed its "at least one device ran" check where WARP has no 6.6 either (Windows 10's WARP stops at 6.2). #2460 makes `victory.exe` load the Agility SDK from `.\D3D12\`; the test binaries had no such exports. ## Changes - **The test binaries of `victory-shader` and `victory-gpu` export `D3D12SDKVersion` (620) and `D3D12SDKPath`**, like `victory.exe`. A test binary sits in `target\<profile>\deps\`, so the path is `..\D3D12\`: the runtime is looked for in `target\<profile>\D3D12\`, where `D3D12Core.dll` from the NuGet package is copied once (as for `victory.exe` in #2460). **Without that folder nothing changes**: Windows uses its own runtime. - The exports are MSVC linker directives in a `.drectve` section of a `cfg(test)` static, so only test binaries get them. `cargo:rustc-link-arg-tests` is refused in a package without a `tests\` target, and `rustc-link-arg` would also reach the shader crate's benchmark, which doesn't define the values. - **On NVIDIA the shader crate's test host makes structured buffer views raw**, as `victory-gpu`'s `buffer_srv` does with #2464, with the same `VICTORY_RAW_STRUCTURED` override. With the hardware device running, `a_heap_buffer_read_by_element_takes_the_views_stride` read the wrong records there: lane `l` got the first word of element `3l + 1`. - The test host works this out from its device's adapter when it makes the view, so the shared WARP device, the hardware device and `Host::from_device` all get it. ## Tested RTX 2080 (32-lane waves), Windows 10 19045, driver 32.0.16.1742, `main` `f3578e3` plus this PR, with `target\debug\D3D12\` holding `D3D12Core.dll` 1.620.2: - **Before:** every GPU test skipped the hardware device ("no SM 6.6 hardware device; skipped"), then failed its "at least one device ran" check (all 6 `stride_tests`, for example). - **`cargo test -p victory-gpu --lib`:** 226 passed, 2 failed. The two are the NVIDIA view-heap cap pair (`dynamic_slots_are_held_until_released`, `lists_share_a_table_and_copies_keep_their_views`), which #2461 fixes. - **`cargo test -p victory-shader --lib`:** 300 passed, 2 failed: - `a_heap_buffer_read_where_no_buffer_view_is_reads_zeros`: the same heap cap, also fixed by #2461. - `pops_wait_loop_exits_immediately_for_inactive_lanes` wants a shader model 6.6 WARP device, and Windows 10's WARP is 6.2. - With the raw views, `a_heap_buffer_read_by_element_takes_the_views_stride` passes on NVIDIA. - `cargo clippy -p victory-shader -p victory-gpu --all-targets -- -D warnings` is clean. Still skipped here, as before: WARP (no 6.6 on Windows 10) and the tests that need the console's shader compiler. AI-assisted (Claude Code); the runs were on my machine. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_018sSQTfPXZpSkjMMNa7RB5G
On Windows 10 the system's D3D12 has no shader model 6.6, so every GPU
test skipped its hardware device (and failed where WARP has none
either). The test binaries of victory-shader and victory-gpu now export
D3D12SDKVersion and D3D12SDKPath like victory.exe, looking for the
runtime in target\<profile>\D3D12\ (one level up from deps\). Without
that folder nothing changes. The exports are linker directives in a
cfg(test) object, so only test binaries get them (the shader crate's
benchmark does not define the values).

RTX 2080, Windows 10 19045: 247 shader tests and 143 GPU tests pass
on the hardware device; before, they skipped it.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_018sSQTfPXZpSkjMMNa7RB5G
The view of a structured buffer read raw read the wrong records on an
RTX 2080 (lane l got the first word of element 3l+1), the same NVIDIA
behaviour victory-gpu's buffer_srv works around. The test host now
makes those views raw too, by its adapter's vendor, with the same
VICTORY_RAW_STRUCTURED override.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_018sSQTfPXZpSkjMMNa7RB5G
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 05:16:32 +00:00
Review of #2878: the NVIDIA raw-structured change in the shader crate's
test host is a separate matter (and is to be checked against #2885).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_018sSQTfPXZpSkjMMNa7RB5G
Review of #2878: exported without target\<profile>\D3D12\D3D12Core.dll,
the loader refused to make a device (0x887E0003) instead of using the
in-box runtime, which failed CI's root tests and quietly skipped every
other hardware test. build.rs now sets cfg(agility_runtime) only when the
runtime is there (as #486 does for victory-shader), and the exports hang
off it. The comments no longer lean on code that is not in main.

RTX 2080, Windows 10 19045: with the runtime staged, victory-gpu 226
passed, 2 failed (the NVIDIA heap-cap pair, #2461); without it, 224
passed, 4 failed, the same failures as main, and no 0x887E0003.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_018sSQTfPXZpSkjMMNa7RB5G
Author
Owner

@⁠fuzeofficlal on GitHub · 2026-11-25 23:18 UTC · original

Tested 6fc5deff on Windows 11 (RTX 5090 + WARP) and hit a blocking regression when target\<profile>\D3D12\D3D12Core.dll is not present (default cargo test and CI):

1. Exporting D3D12SDKVersion/D3D12SDKPath fails with 0x887E0003 instead of falling back

  • The comment assumes Windows falls back to the inbox system D3D12 runtime when ..\D3D12\D3D12Core.dll is missing. In practice, once a test binary exports D3D12SDKVersion = 620 and D3D12SDKPath = "..\\D3D12\\", the D3D12 loader hard-fails both D3D12CreateDevice and D3D12SerializeVersionedRootSignature with 0x887E0003 (DXGI_ERROR_SDK_COMPONENT_MISSING / -2005008381).
  • Local Windows 11 results without a manually copied D3D12Core.dll:
    • victory-shader --lib stride_tests: 0/8 passed, 8/8 failed (neither hardware nor WARP SM 6.6 device available).
    • victory-gpu --lib root::tests: 4/4 host tests failed (host_serialized_blobs_create_root_signatures, our_blobs_deserialize_on_the_host, versioned_descriptions_serialize_on_the_host, malformed_blobs_are_rejected_by_the_host all returned -2005008381 = 0x887E0003 on both RTX 5090 and WARP), while all other GPU tests silently skipped via host() -> None.

2. Other issues

  • Bundled unrelated commit (6fc5deff): mixes an NVIDIA raw_structured SRV-only workaround in emit/host.rs that overlaps (and is less complete than) #2885.
  • Non-Windows & build hygiene: D3D12SDKVersion/D3D12SDKPath are gated only on #[cfg(test)] without #[cfg(target_os = "windows")], MSVC emits linker stdout .lib/.exp warnings, apps/victory/src/main.rs on main does not have these exports, and #[cfg(test)] does not apply to integration tests (tests/*.rs).

Suggest dropping 6fc5deff and gating Agility SDK test exports behind an explicit opt-in feature or build-script deployment that guarantees D3D12Core.dll is staged beside the test binary.

**@⁠fuzeofficlal** on GitHub · 2026-11-25 23:18 UTC · [original](https://github.com/Marvisak/VIctory/pull/2878#issuecomment-7177392304) Tested `6fc5deff` on Windows 11 (RTX 5090 + WARP) and hit a **blocking regression** when `target\<profile>\D3D12\D3D12Core.dll` is not present (default `cargo test` and CI): ### 1. Exporting `D3D12SDKVersion`/`D3D12SDKPath` fails with `0x887E0003` instead of falling back - The comment assumes Windows falls back to the inbox system D3D12 runtime when `..\D3D12\D3D12Core.dll` is missing. In practice, once a test binary exports `D3D12SDKVersion = 620` and `D3D12SDKPath = "..\\D3D12\\"`, the D3D12 loader hard-fails both `D3D12CreateDevice` and `D3D12SerializeVersionedRootSignature` with **`0x887E0003` (`DXGI_ERROR_SDK_COMPONENT_MISSING` / `-2005008381`)**. - Local Windows 11 results without a manually copied `D3D12Core.dll`: - `victory-shader --lib stride_tests`: **0/8 passed, 8/8 failed** (`neither hardware nor WARP SM 6.6 device available`). - `victory-gpu --lib root::tests`: **4/4 host tests failed** (`host_serialized_blobs_create_root_signatures`, `our_blobs_deserialize_on_the_host`, `versioned_descriptions_serialize_on_the_host`, `malformed_blobs_are_rejected_by_the_host` all returned `-2005008381` = `0x887E0003` on both RTX 5090 and WARP), while all other GPU tests silently skipped via `host() -> None`. ### 2. Other issues - **Bundled unrelated commit (`6fc5deff`)**: mixes an NVIDIA `raw_structured` SRV-only workaround in `emit/host.rs` that overlaps (and is less complete than) `#2885`. - **Non-Windows & build hygiene**: `D3D12SDKVersion`/`D3D12SDKPath` are gated only on `#[cfg(test)]` without `#[cfg(target_os = "windows")]`, MSVC emits `linker stdout` `.lib`/`.exp` warnings, `apps/victory/src/main.rs` on `main` does not have these exports, and `#[cfg(test)]` does not apply to integration tests (`tests/*.rs`). Suggest dropping `6fc5deff` and gating Agility SDK test exports behind an explicit opt-in feature or build-script deployment that guarantees `D3D12Core.dll` is staged beside the test binary.
Author
Owner

@⁠Marvisak on GitHub · 2026-11-26 04:27 UTC · original · edited 2026-11-26 07:23 UTC

Automated triage for the maintainers.

Thanks. The NVIDIA change is reverted, and the exports now depend on cfg(agility_runtime), so the 0x887E0003 failure is gone and CI passes. Needs the maintainer's decision: this adds a new crates/victory-gpu/build.rs and changes crates/victory-shader/build.rs, and build scripts need the maintainer's approval. Two smaller points:

  • D3D12SDKVersion is fixed at 620. If someone stages a D3D12Core.dll from a different Agility release, the loader may still refuse to make a device. A note on which version to stage would help.
  • I believe Cargo treats a rerun-if-changed path that does not exist as always stale. If so, without a D3D12 folder (the default) both build scripts rerun on every build, and victory-shader's script hashes its sources each time. Please check this, and emit the line only when the folder exists if needed.

CI: passing.


Generated by Claude Code

**@⁠Marvisak** on GitHub · 2026-11-26 04:27 UTC · [original](https://github.com/Marvisak/VIctory/pull/2878#issuecomment-7182613239) · edited 2026-11-26 07:23 UTC <!-- victory-triage v1 head=5e63ca3d7d5e21427378de873774b72f19305e74 verdict=needs-work at=2026-11-26T07:23:12Z --> Automated triage for the maintainers. Thanks. The NVIDIA change is reverted, and the exports now depend on `cfg(agility_runtime)`, so the `0x887E0003` failure is gone and CI passes. **Needs the maintainer's decision:** this adds a new `crates/victory-gpu/build.rs` and changes `crates/victory-shader/build.rs`, and build scripts need the maintainer's approval. Two smaller points: - `D3D12SDKVersion` is fixed at 620. If someone stages a `D3D12Core.dll` from a different Agility release, the loader may still refuse to make a device. A note on which version to stage would help. - I believe Cargo treats a `rerun-if-changed` path that does not exist as always stale. If so, without a `D3D12` folder (the default) both build scripts rerun on every build, and victory-shader's script hashes its sources each time. Please check this, and emit the line only when the folder exists if needed. CI: passing. --- _Generated by [Claude Code](https://claude.ai/code)_
Author
Owner

@⁠lhnizdo on GitHub · 2026-11-26 06:12 UTC · original

Thanks @⁠fyernald, and for the triage. You're right, and my description was wrong: exported without the runtime, the loader refuses to make a device instead of falling back. Changes, pushed as new commits (405d851, 5e63ca3):

  • The exports are opt-in at build time. Both crates' build.rs set cfg(agility_runtime) only when target/<profile>/D3D12/D3D12Core.dll exists, as #486 does for victory-shader, and the statics and the .drectve directive hang off it. The scripts watch the D3D12 folder rather than the missing file, so they don't rerun on every build.
  • The NVIDIA raw-structured change is reverted here. #2885 covers it more completely: it also handles views that don't start on 16 bytes (with their own copies) and the table-bound path. So I've left it to that PR rather than opening a third one.
  • The comments no longer refer to code that isn't on main. The on_software_adapter doc-comment mix-up went with the revert.

On an RTX 2080, Windows 10 19045, cargo test -p victory-gpu --lib --test-threads=1:

passed failed 0x887E0003
runtime staged in target\debug\D3D12\ 226 2 0
folder removed 224 4 0
  • Staged, the two failures are the NVIDIA heap-cap pair (#2461).
  • Without the folder, the four are the same as main on this card: the in-box runtime refusing the 0xC00 root flags and lacking ID3D12Device10, plus the heap-cap pair.
**@⁠lhnizdo** on GitHub · 2026-11-26 06:12 UTC · [original](https://github.com/Marvisak/VIctory/pull/2878#issuecomment-7184197335) Thanks @⁠fyernald, and for the triage. You're right, and my description was wrong: exported without the runtime, the loader refuses to make a device instead of falling back. Changes, pushed as new commits (`405d851`, `5e63ca3`): - **The exports are opt-in at build time.** Both crates' `build.rs` set `cfg(agility_runtime)` only when `target/<profile>/D3D12/D3D12Core.dll` exists, as #486 does for `victory-shader`, and the statics and the `.drectve` directive hang off it. The scripts watch the `D3D12` folder rather than the missing file, so they don't rerun on every build. - **The NVIDIA raw-structured change is reverted here.** #2885 covers it more completely: it also handles views that don't start on 16 bytes (with their own copies) and the table-bound path. So I've left it to that PR rather than opening a third one. - **The comments** no longer refer to code that isn't on `main`. The `on_software_adapter` doc-comment mix-up went with the revert. On an RTX 2080, Windows 10 19045, `cargo test -p victory-gpu --lib --test-threads=1`: | | passed | failed | `0x887E0003` | |---|---:|---:|---:| | runtime staged in `target\debug\D3D12\` | 226 | 2 | 0 | | folder removed | 224 | 4 | 0 | - Staged, the two failures are the NVIDIA heap-cap pair (#2461). - Without the folder, the four are the same as `main` on this card: the in-box runtime refusing the `0xC00` root flags and lacking `ID3D12Device10`, plus the heap-cap pair.
Author
Owner

@⁠lerapeurdu62280-debug on GitHub · 2026-11-26 16:04 UTC · original

Test report on Windows 10 Pro 19045, AMD RX 6600 (Adrenalin 32.0.21045), head 5e63ca3 merged on main 63bcca4, Agility SDK 1.620.2 from NuGet in target\debug\D3D12\. No game files.

without target\debug\D3D12\ with it
victory-gpu 231 passed, 0 failed, with the three tests #3283 skips skipped (#3283 was merged locally too; main alone: 229 passed, 3 failed) 231 passed, 0 failed (runtime reports SM 6.6 and ID3D12Device10)
victory-shader 214 passed, 88 failed, as on main 301 passed, 1 failed

So the opt-in cfg(agility_runtime) works as described: nothing changes without the folder (no 0x887E0003 here either), and with it the hardware tests run on Windows 10. The one victory-shader failure left is pops_wait_loop_exits_immediately_for_inactive_lanes, which needs an SM 6.6 WARP; Windows 10's WARP is 6.2 even with the Agility SDK. #3283 makes it, and three victory-gpu tests, skip on a runtime without 6.6. With #3283 on top: 231 / 0 and 302 / 0.

Same loader behaviour for the exe: #2460 exports unconditionally and fails with 0x887E0003 without the folder (reported there).

AI-assisted: yes (Claude Code)

**@⁠lerapeurdu62280-debug** on GitHub · 2026-11-26 16:04 UTC · [original](https://github.com/Marvisak/VIctory/pull/2878#issuecomment-7197146915) Test report on **Windows 10 Pro 19045, AMD RX 6600** (Adrenalin 32.0.21045), head 5e63ca3 merged on `main` 63bcca4, Agility SDK 1.620.2 from NuGet in `target\debug\D3D12\`. No game files. | | without `target\debug\D3D12\` | with it | |---|---|---| | `victory-gpu` | 231 passed, 0 failed, with the three tests #3283 skips skipped (#3283 was merged locally too; `main` alone: 229 passed, 3 failed) | **231 passed, 0 failed** (runtime reports SM 6.6 and `ID3D12Device10`) | | `victory-shader` | 214 passed, 88 failed, as on `main` | **301 passed, 1 failed** | So the opt-in `cfg(agility_runtime)` works as described: nothing changes without the folder (no 0x887E0003 here either), and with it the hardware tests run on Windows 10. The one `victory-shader` failure left is `pops_wait_loop_exits_immediately_for_inactive_lanes`, which needs an SM 6.6 WARP; Windows 10's WARP is 6.2 even with the Agility SDK. #3283 makes it, and three `victory-gpu` tests, skip on a runtime without 6.6. With #3283 on top: 231 / 0 and 302 / 0. Same loader behaviour for the exe: #2460 exports unconditionally and fails with 0x887E0003 without the folder (reported there). AI-assisted: yes (Claude Code)
Author
Owner

@⁠kotekompotek on GitHub · 2026-11-25 23:36 UTC · original · reviewed

Mechanically right: the .drectve export trick under cfg(test) puts the Agility SDK exports only in test binaries (mirroring victory-shader and victory.exe's own load path), and the ..\D3D12\ relative path matches where the NuGet runtime lands. This is what makes the SM 6.6-dependent GPU tests actually run on Win10 hosts. LGTM.

**@⁠kotekompotek** on GitHub · 2026-11-25 23:36 UTC · [original](https://github.com/Marvisak/VIctory/pull/2878#pullrequestreview-6066492918) · **reviewed** Mechanically right: the .drectve export trick under cfg(test) puts the Agility SDK exports only in test binaries (mirroring victory-shader and victory.exe's own load path), and the ..\D3D12\ relative path matches where the NuGet runtime lands. This is what makes the SM 6.6-dependent GPU tests actually run on Win10 hosts. LGTM.
Author
Owner

@⁠fyernald on GitHub · 2026-11-26 01:57 UTC · original · requested changes

Tested on an RTX 3080 (driver 617.42), Windows 10 19045, main 63bcca4 + this head (6fc5def), --test-threads=1, D3D12Core.dll 1.620.2 in target\debug\D3D12\.

With the runtime staged it does what it says. The .drectve exports reach the linker here.

cargo test -p victory-gpu --lib passed failed
main 226 5
main + #2878 229 2

The three it fixes:

  • compute_view_marks_rebind_after_depth_twin_conversion (#2155) and depth_bounds_control_a_title_draw (#158) are new on main today. On Windows 10's in-box runtime, they fail because it refuses the root signature flags 0xC00 (*_HEAP_DIRECTLY_INDEXED) with E_INVALIDARG.
  • a_texture_written_in_one_format_reads_in_another_through_a_placed_view fails because there is no ID3D12Device10 in the in-box runtime.

The two left are the NVIDIA heap-cap pair.

victory-shader (main + #2596 for #2571, the suite crashes here without it): 298 passed / 4 failed with #486 in place of this PR, 300 / 2 with this PR. The raw structured views fix a_heap_buffer_read_by_element_takes_the_views_stride, and also gathers_at_a_level_match_the_hardware, whose coordinates come from a Structured(16) view. Both fail with VICTORY_RAW_STRUCTURED=0 and pass with =1, deterministically.

Without the runtime it is worse than main, and that is what CI hits. Same build, folder renamed away:

  • The 4 root::tests fail with -2005008381 (0x887E0003), as on CI.
  • Every other hardware test returns early because host() is None, and counts as passed. The heap-cap pair that fails on main "passes" here (227 / 4). So on a machine without the folder, this turns off the GPU suite's hardware coverage silently, not just those four tests.

What worked here: decide at build time and export only when the runtime is staged, as #486's build.rs does (cfg(agility_runtime) only if target/<profile>/D3D12/D3D12Core.dll exists). I copied that build script into victory-gpu locally. With the DLL: 229 / 2. Without it: 226 / 5, the same five as main, with nothing skipped.

Also:

  • #486 and this PR can't both land. Merged together, victory-shader's test build fails with symbol `D3D12SDKPath` is already defined. One of the two should own the shader crate's opt-in.
  • In emit/host.rs, raw_structured went in between on_software_adapter's doc comment and its fn. That comment now documents raw_structured, and on_software_adapter has none.
  • The raw-view change overlaps #2885 and doesn't depend on the Agility part. Splitting it out would let each be judged on its own.
**@⁠fyernald** on GitHub · 2026-11-26 01:57 UTC · [original](https://github.com/Marvisak/VIctory/pull/2878#pullrequestreview-6067538641) · **requested changes** Tested on an **RTX 3080 (driver 617.42), Windows 10 19045**, `main` `63bcca4` + this head (`6fc5def`), `--test-threads=1`, `D3D12Core.dll` 1.620.2 in `target\debug\D3D12\`. **With the runtime staged it does what it says.** The `.drectve` exports reach the linker here. | `cargo test -p victory-gpu --lib` | passed | failed | |---|---|---| | `main` | 226 | 5 | | `main` + #2878 | 229 | 2 | The three it fixes: - `compute_view_marks_rebind_after_depth_twin_conversion` (#2155) and `depth_bounds_control_a_title_draw` (#158) are new on `main` today. On Windows 10's in-box runtime, they fail because it refuses the root signature flags `0xC00` (`*_HEAP_DIRECTLY_INDEXED`) with `E_INVALIDARG`. - `a_texture_written_in_one_format_reads_in_another_through_a_placed_view` fails because there is no `ID3D12Device10` in the in-box runtime. The two left are the NVIDIA heap-cap pair. `victory-shader` (`main` + #2596 for #2571, the suite crashes here without it): 298 passed / 4 failed with #486 in place of this PR, 300 / 2 with this PR. The raw structured views fix `a_heap_buffer_read_by_element_takes_the_views_stride`, and also `gathers_at_a_level_match_the_hardware`, whose coordinates come from a `Structured(16)` view. Both fail with `VICTORY_RAW_STRUCTURED=0` and pass with `=1`, deterministically. **Without the runtime it is worse than `main`, and that is what CI hits.** Same build, folder renamed away: - The 4 `root::tests` fail with `-2005008381` (`0x887E0003`), as on CI. - Every other hardware test returns early because `host()` is `None`, and counts as passed. The heap-cap pair that fails on `main` "passes" here (227 / 4). So on a machine without the folder, this turns off the GPU suite's hardware coverage silently, not just those four tests. **What worked here:** decide at build time and export only when the runtime is staged, as #486's `build.rs` does (`cfg(agility_runtime)` only if `target/<profile>/D3D12/D3D12Core.dll` exists). I copied that build script into `victory-gpu` locally. With the DLL: 229 / 2. Without it: 226 / 5, the same five as `main`, with nothing skipped. Also: - #486 and this PR can't both land. Merged together, `victory-shader`'s test build fails with ``symbol `D3D12SDKPath` is already defined``. One of the two should own the shader crate's opt-in. - In `emit/host.rs`, `raw_structured` went in between `on_software_adapter`'s doc comment and its `fn`. That comment now documents `raw_structured`, and `on_software_adapter` has none. - The raw-view change overlaps #2885 and doesn't depend on the Agility part. Splitting it out would let each be judged on its own.
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/2878/head:github-bot/gh-2878'
git switch 'github-bot/gh-2878'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-2878'
git switch 'github-bot/gh-2878'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-2878'
git switch 'github-bot/gh-2878'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-2878'
git switch 'main'
git merge --squash 'github-bot/gh-2878'
git switch 'main'
git merge --ff-only 'github-bot/gh-2878'
git switch 'main'
git merge 'github-bot/gh-2878'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No reviewers
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.

Dependencies

No dependencies set

Reference
github/Marvisak--VIctory!2878
No description provided.