Tests: VICTORY_ADAPTER picks the hardware adapter by name (and intersect_tests on RDNA4 + RDNA2) #58
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/DexNom--VIctory!58
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-58"
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?
@alexdeliu on GitHub · 2026-11-25 23:42 UTC · original
alexdeliu:test/adapter-by-name→main· +38 −1 · 1 files · 1 commits · openOn a PC with two GPUs, the default D3D12 device may not be the card you want to test. This adds
VICTORY_ADAPTER: the hardware tests'Host::newpicks the first adapter whose description contains that text, in any case (for exampleVICTORY_ADAPTER=9070orVICTORY_ADAPTER="radeon(tm)"). It prints which adapter it took.VICTORY_WARP=1and the default device work as before, and an empty value is ignored. If no adapter matches,Host::newreturns an error listing the adapters it saw, and the hardware tests skip as they do on a machine without a card.It is test-side only, one file:
crates/victory-shader/src/emit/host.rs.Why: your ray-test emulation on two more AMD generations
Issues are off here, so I'm putting the results in this PR. They are why I needed the change: this PC has an RX 9070 and a Ryzen 7 7700 iGPU, and the iGPU can't be reached without it.
cargo test --locked -p victory-shader --lib intersect_tests -- --test-threads=1at2e01ab4+ this commit, Windows 11, dxil.dll 1.8.2502.11:intersect_testsVICTORY_WARP=1)The tests that ran:
So the slab tests, the sorting network and the watertight triangle test agree bit for bit with
bvh.rson RDNA2 and RDNA4 as well as on your 7900 XTX (RDNA3). The iGPU runs undeclared compute as 32-lane waves and the RX 9070 as 64-lane, and both pass.Whole
victory-shadersuite at the same head (cargo test --locked -p victory-shader --lib -- --test-threads=1):VICTORY_ADAPTER=9070)VICTORY_ADAPTER="radeon(tm)")VICTORY_WARP=1)The three WARP failures are
ds_min_max_f32_order_floats_and_return_the_old_value,v_permlane16_and_x16_read_the_lanes_their_selectors_pickandwhole_wave_f64_sum_and_cvt_f32_f64. The WARP path is untouched here, and all three pass on both AMD cards, so they look like WARP's own behaviour rather than anything in this change.cargo clippy --locked -p victory-shader --all-targets: no warnings in the changed file.🤖 Generated with Claude Code
@Yoshi-233 on GitHub · 2026-11-26 03:58 UTC · original
One diagnostic issue I found while checking how to reuse this on a dual-GPU machine: an explicit adapter typo can still produce a green result for
the_64_bit_node_test_in_a_host_buffer_matches_the_reference_on_the_card. At60d0b07, itsrunhelper discards the error fromHost::new(false), goes on to run WARP, and only checksran > 0. That also hides the list of adapters your new error returns. The reflected-ray test has a similar skip path.A useful Windows negative control, on a machine with working WARP, is:
I traced this in the PR source on Linux. For explicit hardware selection, could the hardware leg propagate the error when a name was requested, while keeping the automatic skip when no selector was supplied? Then this negative control would fail with the enumerated names, and a green run under an explicit selector would confirm the named device actually participated.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.