leonida-shader: guard 32-lane host tests by the adapter's wave width #2964
Closed
aznohonza wants to merge 4 commits from
upstream-pr/2964 into main
pull from: upstream-pr/2964
merge into: ProjectLeonida:main
ProjectLeonida:main
ProjectLeonida:claude/loop-total
ProjectLeonida:claude/pops-collision-seed
ProjectLeonida:claude/dstorage-hold-page-reads
ProjectLeonida:claude/host-image-copy-switch
ProjectLeonida:feat/gdk-lifecycle-window-hook
ProjectLeonida:claude/d16s8-uav-nvidia-fallback
ProjectLeonida:feat/mfplat-offline-shim
ProjectLeonida:claude/gameinput-slow-reader
ProjectLeonida:fix/rt-null-barrier-clear
ProjectLeonida:claude/depth-resolve-sample-positions
ProjectLeonida:integration/palmetto-parity
ProjectLeonida:claude/valu-literal-sext
ProjectLeonida:claude/slot74-pool-handle
ProjectLeonida:claude/rgb9e5-uint-alias-view
ProjectLeonida:claude/fssm-root-layout-tables
ProjectLeonida:feat/gdk-speech-display-lifecycle
ProjectLeonida:asset-audio-skip-current
ProjectLeonida:qemmhd/old-9940-rectangle-quad-lists
ProjectLeonida:feat/ws2-offline-shim
ProjectLeonida:qemmhd/rt-d16-unorm-uav
ProjectLeonida:feat/xs-device-stops-7-9
ProjectLeonida:qemmhd/rt-depth-same-base-shapes
ProjectLeonida:qemmhd/rt-lazy-attachment-variant
ProjectLeonida:feat/acphal-xma2-decoder
ProjectLeonida:asset-audio-skip
ProjectLeonida:codex/coord-claim-check-20261124-7e48
ProjectLeonida:feat/xs-frame-pacing-presentx
ProjectLeonida:feat/xs-device-vm-options
ProjectLeonida:old-pr/9844
ProjectLeonida:old-pr/9978
ProjectLeonida:old-pr/9815
ProjectLeonida:old-pr/10057
ProjectLeonida:old-pr/9874
ProjectLeonida:old-pr/9965
ProjectLeonida:old-pr/9863
ProjectLeonida:old-pr/10068
ProjectLeonida:old-pr/10066
ProjectLeonida:old-pr/10067
ProjectLeonida:old-pr/10007
ProjectLeonida:old-pr/10061
ProjectLeonida:old-pr/10065
ProjectLeonida:old-pr/10059
ProjectLeonida:old-pr/10063
ProjectLeonida:old-pr/10055
ProjectLeonida:old-pr/10062
ProjectLeonida:old-pr/10042
ProjectLeonida:old-pr/10041
ProjectLeonida:old-pr/10049
ProjectLeonida:old-pr/10047
ProjectLeonida:old-pr/10046
ProjectLeonida:old-pr/10045
ProjectLeonida:old-pr/10056
ProjectLeonida:old-pr/10043
ProjectLeonida:old-pr/10036
ProjectLeonida:old-pr/10034
ProjectLeonida:old-pr/9984
ProjectLeonida:old-pr/10052
ProjectLeonida:old-pr/10038
ProjectLeonida:old-pr/10033
ProjectLeonida:old-pr/10028
ProjectLeonida:old-pr/10050
ProjectLeonida:old-pr/9891
ProjectLeonida:old-pr/9889
ProjectLeonida:old-pr/10051
ProjectLeonida:old-pr/10019
ProjectLeonida:old-pr/10027
ProjectLeonida:old-pr/10029
ProjectLeonida:old-pr/10031
ProjectLeonida:old-pr/10026
ProjectLeonida:old-pr/9941
ProjectLeonida:old-pr/10030
ProjectLeonida:old-pr/10040
ProjectLeonida:old-pr/9990
ProjectLeonida:old-pr/10021
ProjectLeonida:old-pr/9962
ProjectLeonida:old-pr/10022
ProjectLeonida:old-pr/10020
ProjectLeonida:old-pr/10015
ProjectLeonida:old-pr/10025
ProjectLeonida:old-pr/9886
ProjectLeonida:old-pr/10048
ProjectLeonida:old-pr/10014
ProjectLeonida:old-pr/10011
ProjectLeonida:old-pr/9861
ProjectLeonida:old-pr/10010
ProjectLeonida:old-pr/10008
ProjectLeonida:old-pr/9860
ProjectLeonida:old-pr/10006
ProjectLeonida:old-pr/9920
ProjectLeonida:old-pr/9995
ProjectLeonida:old-pr/10000
ProjectLeonida:old-pr/10016
ProjectLeonida:old-pr/10004
ProjectLeonida:old-pr/10023
ProjectLeonida:old-pr/9982
ProjectLeonida:old-pr/9981
ProjectLeonida:old-pr/9983
ProjectLeonida:old-pr/9970
ProjectLeonida:old-pr/9969
ProjectLeonida:old-pr/9968
ProjectLeonida:old-pr/9971
ProjectLeonida:old-pr/9972
ProjectLeonida:old-pr/9942
ProjectLeonida:old-pr/9963
ProjectLeonida:old-pr/9960
ProjectLeonida:old-pr/9964
ProjectLeonida:old-pr/9985
ProjectLeonida:old-pr/9973
ProjectLeonida:old-pr/9862
ProjectLeonida:old-pr/9953
ProjectLeonida:old-pr/10017
ProjectLeonida:old-pr/9952
ProjectLeonida:old-pr/9955
ProjectLeonida:old-pr/9946
ProjectLeonida:old-pr/9954
ProjectLeonida:old-pr/9938
ProjectLeonida:old-pr/9956
ProjectLeonida:old-pr/9856
ProjectLeonida:old-pr/9947
ProjectLeonida:old-pr/9924
ProjectLeonida:old-pr/9961
ProjectLeonida:old-pr/9927
ProjectLeonida:old-pr/9979
ProjectLeonida:old-pr/10032
ProjectLeonida:old-pr/9926
ProjectLeonida:old-pr/5237
ProjectLeonida:old-pr/9951
ProjectLeonida:old-pr/9931
ProjectLeonida:old-pr/9902
ProjectLeonida:old-pr/9921
ProjectLeonida:old-pr/9994
ProjectLeonida:old-pr/9775
ProjectLeonida:old-pr/9768
ProjectLeonida:old-pr/9905
ProjectLeonida:old-pr/9936
ProjectLeonida:old-pr/9901
ProjectLeonida:old-pr/9904
ProjectLeonida:old-pr/9906
ProjectLeonida:old-pr/9988
ProjectLeonida:old-pr/9908
ProjectLeonida:old-pr/9909
ProjectLeonida:old-pr/9911
ProjectLeonida:old-pr/9912
ProjectLeonida:old-pr/9913
ProjectLeonida:old-pr/9887
ProjectLeonida:old-pr/9916
ProjectLeonida:old-pr/9919
ProjectLeonida:old-pr/9925
ProjectLeonida:old-pr/9933
ProjectLeonida:old-pr/9935
ProjectLeonida:old-pr/9918
ProjectLeonida:old-pr/9879
ProjectLeonida:old-pr/9880
ProjectLeonida:old-pr/9881
ProjectLeonida:old-pr/9996
ProjectLeonida:old-pr/9876
ProjectLeonida:old-pr/9892
ProjectLeonida:old-pr/9899
ProjectLeonida:old-pr/9915
ProjectLeonida:old-pr/9914
ProjectLeonida:old-pr/9872
ProjectLeonida:old-pr/9869
ProjectLeonida:old-pr/9866
ProjectLeonida:old-pr/9819
ProjectLeonida:old-pr/10012
ProjectLeonida:old-pr/9857
ProjectLeonida:old-pr/9893
ProjectLeonida:old-pr/9897
ProjectLeonida:old-pr/9928
ProjectLeonida:old-pr/9868
ProjectLeonida:old-pr/9917
ProjectLeonida:old-pr/9940
ProjectLeonida:old-pr/9873
ProjectLeonida:old-pr/9816
ProjectLeonida:old-pr/10009
ProjectLeonida:old-pr/9900
ProjectLeonida:old-pr/9966
ProjectLeonida:old-pr/9859
ProjectLeonida:old-pr/9843
ProjectLeonida:old-pr/9991
ProjectLeonida:old-pr/10058
ProjectLeonida:old-pr/9883
ProjectLeonida:old-pr/9838
ProjectLeonida:old-pr/9835
ProjectLeonida:old-pr/9959
ProjectLeonida:old-pr/9895
ProjectLeonida:old-pr/9837
ProjectLeonida:old-pr/9858
ProjectLeonida:old-pr/9865
ProjectLeonida:old-pr/9864
ProjectLeonida:old-pr/9840
ProjectLeonida:old-pr/9820
ProjectLeonida:old-pr/4669
ProjectLeonida:old-pr/9848
ProjectLeonida:old-pr/9850
ProjectLeonida:old-pr/9810
ProjectLeonida:old-pr/9799
ProjectLeonida:old-pr/9853
ProjectLeonida:old-pr/9875
ProjectLeonida:old-pr/9831
ProjectLeonida:old-pr/9796
ProjectLeonida:old-pr/9801
ProjectLeonida:old-pr/9813
ProjectLeonida:old-pr/9794
ProjectLeonida:old-pr/7417
ProjectLeonida:old-pr/9781
ProjectLeonida:old-pr/9806
ProjectLeonida:old-pr/9958
ProjectLeonida:old-pr/9809
ProjectLeonida:old-pr/9791
ProjectLeonida:old-pr/9792
ProjectLeonida:old-pr/10053
ProjectLeonida:old-pr/9784
ProjectLeonida:old-pr/9789
ProjectLeonida:old-pr/9849
ProjectLeonida:old-pr/9846
ProjectLeonida:old-pr/9773
ProjectLeonida:old-pr/9785
ProjectLeonida:old-pr/9803
ProjectLeonida:old-pr/9826
ProjectLeonida:old-pr/9839
ProjectLeonida:old-pr/9922
ProjectLeonida:old-pr/9948
ProjectLeonida:old-pr/7189
ProjectLeonida:old-pr/9957
ProjectLeonida:old-pr/9823
ProjectLeonida:old-pr/9807
ProjectLeonida:old-pr/9851
ProjectLeonida:old-pr/9774
ProjectLeonida:old-pr/9830
ProjectLeonida:old-pr/9836
ProjectLeonida:old-pr/9822
ProjectLeonida:old-pr/9783
ProjectLeonida:old-pr/9833
ProjectLeonida:old-pr/9890
ProjectLeonida:old-pr/9770
ProjectLeonida:old-pr/9769
ProjectLeonida:old-pr/9772
ProjectLeonida:old-pr/9787
ProjectLeonida:old-pr/9852
ProjectLeonida:old-pr/9834
ProjectLeonida:old-pr/9845
ProjectLeonida:old-pr/9871
ProjectLeonida:old-pr/9771
ProjectLeonida:old-pr/9776
ProjectLeonida:old-pr/10005
ProjectLeonida:old-pr/9949
ProjectLeonida:old-pr/9923
ProjectLeonida:old-pr/9805
ProjectLeonida:old-pr/9829
ProjectLeonida:old-pr/9790
ProjectLeonida:old-pr/9827
ProjectLeonida:old-pr/9929
ProjectLeonida:old-pr/9855
ProjectLeonida:old-pr/9934
ProjectLeonida:old-pr/9907
ProjectLeonida:old-pr/9910
ProjectLeonida:old-pr/9779
ProjectLeonida:old-pr/9780
ProjectLeonida:old-pr/9885
ProjectLeonida:old-pr/9882
ProjectLeonida:old-pr/9877
ProjectLeonida:old-pr/9998
ProjectLeonida:old-pr/4251
ProjectLeonida:old-pr/9987
ProjectLeonida:old-pr/9989
ProjectLeonida:old-pr/9950
ProjectLeonida:old-pr/9777
ProjectLeonida:old-pr/10044
ProjectLeonida:old-pr/9884
ProjectLeonida:old-pr/2906
ProjectLeonida:old-pr/5076
ProjectLeonida:old-pr/9937
ProjectLeonida:old-pr/9986
ProjectLeonida:old-pr/3014
ProjectLeonida:old-pr/9943
ProjectLeonida:old-pr/9939
ProjectLeonida:old-pr/4682
ProjectLeonida:old-pr/4765
No reviewers
Labels
Clear labels
No items
No labels
Milestone
Clear milestone
No items
No milestone
Assignees
Clear assignees
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
ProjectLeonida/mandy!2964
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/2964"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from ubiquitarianism/leonida. Originally posted by aznohonza on 2026-12-01T21:55:52Z.
Re-created from the original #2920.
aznohonza/mandy-contribwas made private at 21:41 UTC on 2026-12-01, which detached the fork and permanently closed its pull requests; GitHub refuses to reopen them (422 state cannot be changed). Same branch, same head00a0681069b64b150fb287f6c8e0ee696e27caea. The original review thread is at #2920.LEONIDA_WARP=1makesHost::new(false)return the software adapter, so tests that ask for "hardware only" still run on it. The software adapter takes 4-lane waves, while the translator lowers these programs for 32-lane host waves, so eight of theleonida-shadertests fail with that switch.Host::takes_waves_of(lanes)asks the adapter (D3D12_OPTIONS1) which program wave widths it accepts, and the tests that assume 32 skip a device that does not:valu_tests:run_cases_ontakes the required width (Nonekeeps the old behaviour). The quadmask and the two cross-wave LDS tests use a 32-lane path, and the whole-wave f64 test checks its own loop.pack_tests: the five host sites guard for 32 and printSKIP: the adapter does not run 32-lane waves.wave64_tests:host_32()is the hardware lookup plus the width check; all 14 sites use it, and the two manualD3D12_OPTIONS1queries now use the helper.Verification:
cargo xwin check --target x86_64-pc-windows-msvc --workspace --all-targets --lockedpasses, and-p leonida-shader --tests --features hostpasses too.Claimed in #2570 (RS-WARP-TEST-WAVES). AI-assisted.
The full
leonida-shadersuite on the software adapter still has four failures onbarycentric/rect; they are the DXIL validator refusing the shader (#2864), not wave width. With #2864's commit on this head the crate is 415 passed, 0 failed, 5 ignored on WARP.Imported from ubiquitarianism/leonida. Originally posted by KelboLive on 2026-12-01T22:19:24Z.
Review: COMMENTED
Identical to #2920 (
00a068106), which I reviewed — the guard shape is right (32/32 here, 4/4 on WARP, Arc 16..32 still runs), andmerge-treeagainst current main is clean. No re-review needed; the two nits from there are non-blocking: two sites still skip silently (wave64_tests.rs:1358,:1954), andtakes_waves_ofdrops theWaveOpscheck the old block had.Imported from ubiquitarianism/leonida. Originally posted by merzleckeier on 2026-12-01T22:21:43Z.
The wave-width guard admits the physical readbacks and skips the four-lane fixture.
I tested
00a0681069b64b150fb287f6c8e0ee696e27caeaintegrated onto mainc4ca5761508f136c5530482093bb3053b0bad4fa, using Wine 11.22 / VKD3D-Proton 3.1.0. The pack, scalar quad and partial-dispatch selections each completed on RTX 4070 SUPER (620.73.4) and AMD Raphael (RADV 26.3.1).45, 1, 33, 0. The main controls also passed.The observed source on this head also requires
waves.WaveOps.as_bool()intakes_waves_of. The injected range exercises the width branch on physical devices. Native WARP was outside this fixture. AI-assisted, independently verified against the raw results.Imported from ubiquitarianism/leonida. Originally posted by aznohonza on 2026-12-01T22:28:18Z.
Thanks — the device matrix matches what the guard is for.
On the two nits: I think they are from the earlier head. At
00a068106both sites print the named skip (wave64_tests.rs:1358and:1954carryeprintln!("no SM 6.6 device that runs 32-lane waves; not run")), andtakes_waves_of(emit/host.rs:155) requireswaves.WaveOps.as_bool()before the width range. That wasa06018f3e, included in the head you reviewed. Nothing else changed on this branch.AI-assisted.
Imported from ubiquitarianism/leonida. Originally posted by ammonium231 on 2026-12-02T01:19:17Z.
RTX 3090 / 621.47,
00a068106merged onto main5d06e4793(hardware waves 32..32): cargo test -p leonida-shader --locked is 420 passed, 0 failed, 5 ignored on both trees. 32-lane hardware cases ran. WARP 32-lane cases now skip, and they didn't run on main either.Imported from ubiquitarianism/leonida. Originally posted by imShangLi on 2026-12-02T05:32:04Z.
VERIFY-2964 — Linux, Fedora 45, Rust 1.98.1 (the pinned toolchain), no GPU device, no game files
Verdict: MIXED. The change is a clean, correct refactor that I reviewed statically and found sound — it removes a real panic path and unifies four inconsistent adapter guards behind one method. But every file it touches is
#[cfg(... windows ...)], so neither the new method nor any of its tests compile or run on Linux; the repository's ownred_green.pyreturns "no red" here and I have no runtime evidence for it. This is a static review only.Head
00a0681069b64b150fb287f6c8e0ee696e27caea, base the currentmain(origin/main8422def759cda12c89f918438eeb8d53dd5972a6), merge base60f7dcd904cfc5874a1da62c4297a14e62bca74a, 4 files, +151/−83:d3d12/crates/leonida-shader/src/emit/host.rs(+19/−0)d3d12/crates/leonida-shader/src/emit/pack_tests.rs(+20/−0)d3d12/crates/leonida-shader/src/emit/valu_tests.rs(+71/−22)d3d12/crates/leonida-shader/src/emit/wave64_tests.rs(+41/−61)1. What it changes
It adds one method to the host D3D12 adapter and routes every 32-lane host test through it.
In
host.rsit adds the reusable query (the heart of the change):Before, the same idea was done four different ways inline in the tests, and not all of them were safe:
wave64_tests.rs'sboth_host_waves_observe_the_lds_flag_after_the_joincalledCheckFeatureSupport(...).expect("query host wave sizes")— a panic if the feature query fails — then checkedWaveLaneCountMax != 32.a_first_lane_read_of_a_wave_alike_sum_under_a_wave_alike_loopdid a different inline query checking only(WaveLaneCountMin..=WaveLaneCountMax).contains(&32).valu_tests.rs'srun_cases_onhad a singleran == 0escape hatch that only covered "hardware-only, no hardware", not a width mismatch.The pull request deletes both inline
CheckFeatureSupportblocks (and their now-unneededuse windows::...D3D12_OPTIONS1imports), adds alanes: Option<u32>parameter torun_cases_onwithrun_cases/run_cases_32wrappers, and makes the skip non-fatal:pack_tests.rsgets the sameif !host.takes_waves_of(32) { eprintln!("SKIP: ..."); return; }guard in its fiveHost::new(false)tests.wave64_tests.rsintroduces ahost_32()helper and switches ~14 tests fromHost::new(false)to it.2. The new test checks the property that matters
This is a test-only change plus one production helper; there is no new assertion that fails on
main. The property it adds is: a test that assumes the card's 32-lane waves must ask the adapter first, and skip rather than run wrong or panic. That property is only observable on Windows with a non-32-lane adapter (e.g. a software adapter that runs 4-lane waves) or when the feature query fails. The concrete defects it removes are the.expect("query host wave sizes")panic and thepanic!("{label}: compute_pipeline failed")that a WARP pipeline creation of aWaveSize(32)program would hit (the code's own comment says "WARP does not support fixed WaveSize(32) on SM 6.6"). I could not execute any of this on Linux —Host::newneeds a D3D12 device andtakes_waves_ofneedsCheckFeatureSupport, neither of which exists off Windows.3. What the tests do here
python3 -I scripts/red_green.py pr2964 --no-fetch --crate leonida-shader --work-dir .../rg-2964(verdictno red, exit 1):origin/main+ this PR's tests only)origin/main+ this PR merged)origin/mainon its ownNothing failed on either side and no test moved red→green, because none of the four changed files is compiled on Linux:
emit/mod.rsgates them all off.So the crate's Linux suite is byte-for-byte unaffected by this pull request, and the red/green tool has nothing to discriminate. That "252 on both" is a true statement about Linux, but it is not a verification of this PR — it is the absence of one.
4. Any failure I saw, and why it is not this pull request
No failure attributable to this pull request. Two things I want to state plainly so they are not misread:
00a06810, a merge oforigin/mainintogpu/warp-wave-guards) runs 246 Linux tests, not 252, because that branch predates ~6 Linux tests thatmainhas since gained.red_green.pytests against currentmain(where the green side is 252), so this is a stale-branch artifact, not a regression the PR causes.source_hash_tests(the shared-CARGO_TARGET_DIRtrap in the brief) never appeared: I gave this run its own--work-dir, and both sides ran in one worktree with one target dir as the tool intends.5. What I did not check
takes_waves_ofor the rewrittenrun_cases_on/host_32— on Linux these files are not compiled at all, so a syntax or type error in them would not be caught by any Linux build. My "it is correct" is a reading of the diff, not a compiler's..expect("query host wave sizes")panic or the WARPcompute_pipelinepanic, nor confirm the new guards prevent them — that needs a Windows box with a non-32-lane adapter.run_gpu_tests.py) or Wine/Proton (run_wine_tests.py) suites. Not run; they are Windows/Wine paths.Net: on static review this meets the repository's bar — it fixes the root cause (one shared query instead of stacked inline guards), removes a panic, keeps the code simple and modular, and adds no workaround. I just could not run it here.
Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-12-02T12:33:04Z.
This pull request touches the render path, so it needs an in-game run before it can be merged: unit tests and CI do not catch rendering regressions (a device loss after an earlier merge is why this gate exists).
Could you, or anyone with a working setup, post a run report on the current head merged onto current
main:mainSHA it was merged onto;mainalone for comparison, if you can.Please do not attach logs or screenshots that show game content. If a run on this exact head is already posted, a link to it in a reply is enough.
AI-assisted (Claude Code).
Imported from ubiquitarianism/leonida. Originally posted by Kal0s-design on 2026-12-02T15:56:54Z.
Ran natively on Windows 11, head
00a068106merged into currentmain(3c106eb2f, clean merge). The one exception is the PR's default full run (1,149 s), which was on the merge into83046a713, the previousmain;leonida-shaderhas no changes between the two. Allmainbaselines are3c106eb2f.Wave widths (measured, throwaway test printing
D3D12_OPTIONS1)Host::new(false), cardHost::new(true), WARPHost::new(false)withLEONIDA_WARP=1Full suite (measured,
cargo test -p leonida-shader --locked)mainLEONIDA_WARP=1The 8
mainfailures under WARP are the ones the PR describes: 2 pack,ds_min_max_f32_order…,lds_subtracts_return…,v_permlane16…,whole_wave_f64…,a_lane_mask_joined…,partial_dispatch…. The fourbarycentric/rectvalidator failures mentioned in the PR body did not occur on currentmain.New: the PR also drops WARP legs that ran and passed on
main(measured)I added a temporary
eprintln!afterran += 1inrun_cases_onand ran the four tests one at a time with the card present:main: WARP legs run and passedscalar_quad_masks_pack_nibbles_and_set_sccds_min_max_f32_are_atomic_across_waveslds_subtracts_are_atomic_across_waveswhole_wave_f64_sum_and_cvt_f32_f64So 13 of the 14
warp: … skippedlines in the default PR run are checks that ran and passed onmain. Only thewhole_wave_f64one replaces an existing skip. This differs from the earlier note that the WARP 32-lane cases did not run onmain, which holds only forwhole_wave_f64.Under
LEONIDA_WARP=1(one test at a time, per-test output attributed), 38 tests print a 32-lane skip on the PR. Onmain:valu_testsabove (instrumented),wave64_tests::a_16_bit_sum_rounds_to_nearest_when_asked_to(it prints its WARP results onmain), and the two pack testsa_grid_past_what_one_dimension_holds…anda_packed_program_runs_every_console_group_once…. Their helperrun()creates the pipeline with.expect(…), so a pass means the dispatch ran;one_d_wave64_group_skips_entry_ticket_barrier…continues silently on a pipeline refusal.These 6 pass at 4 lanes, so a 32-lane guard on them is stricter than the failures require. On a 32-wide card no test is skipped on both legs: every guarded test still runs its hardware leg.
Skip visibility (measured)
Under
LEONIDA_WARP=1without--nocapture, 0 skip lines are visible and libtest reports every guarded test asok. With--nocapture, each skip is named: 4×SKIP: the adapter does not run 32-lane waves, 34×hardware: … skipped, 14×warp: … skipped, 58×no SM 6.6 device that runs 32-lane waves; not run, plus the per-shape lines.Clippy (measured)
cargo clippy -p leonida-shader --features host --locked(lib, the feature theleonidaapp enables):main0 warnings, PR 1:method takes_waves_of is never used(dead_code,emit/host.rs:143), because only test modules call it.--all-targetsis otherwise identical tomain. The d3d12 clippy job is report-only, so this does not fail CI.#[cfg(test)]on the method would remove the warning.On the in-game request (reading only): the changed test modules are
cfg(test). The only code this PR adds to a non-test build istakes_waves_of, and thedead_codewarning above shows nothing calls it there.Not checked: Arc/AMD or any adapter with a range other than 32..32 or 4..4 natively, the debug layer, an in-game run (requested above; not done here).
GPUs tested: one NVIDIA desktop card + WARP.
AI-assisted: yes (Claude Code).
Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-12-02T17:06:48Z.
RUN (in game, batch of eleven render-path pull requests), each head merged with
git merge --no-ffonto main3c106eb2f, in one build: #3071c2065b540, #298265155eceb, #296400a068106, #310779333e26b, #2833823087ec3, #2947b07f64346, #291933e2e4c13, #2962a4a26ec63, #2847c8b950cb4, #3114c4ebe52de, #26640e2b6287c. RTX 4060 8 GB, driver 610.88, Windows 11. Series S,-Resolution 1080, frame generation 2x, the same walking route as the other runs on this machine, 330 s after reaching the world.For reference, the same machine and route rendered 13.3 to 17.2 fps today on main with single pull requests or other batches. These fps are a check that nothing fell over, not a measurement of a gain.
Verdict: PASS for the in-game gate (300 s or more in the world, no device loss) for this batch, on the heads listed above. If one of these pull requests changes its head, this run no longer covers it.
Limits: one run; free system memory was low (median 0.6 GB); arrival in the world was driven by keys and not checked on pictures. An earlier attempt of this batch is not counted: two runs were started at the same time by mistake on one GPU (no device loss in either, but the measure is not clean).
AI-assisted (Claude Code).
Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-12-02T18:18:59Z.
Verification of #2964 (third party, code review on Linux; not built: the touched files are Windows-only,
#[cfg(windows)])00a0681069b64b150fb287f6c8e0ee696e27caea(4 files underleonida-shader/src/emit/, +151/-83).This is the same head as the closed #2920.
60f7dcd90.git merge-tree --write-tree origin/main pr/2964againstmain45dc41f95is clean(355 commits behind). CI on the head: 12/12 success.
python -I scripts/check_no_game_data.pyon the 4 files: exit 0.3c106eb2fthat includes00a068106(PASS).
Review
LEONIDA_WARP=1makesHost::new(false)return WARP, which runs 4-lane waves. Programs lowered for32-lane host waves then fail there. Guarding on what the device reports is the right fix, not a skip list:
takes_waves_of(emit/host.rs) requiresWaveOpsand32 in WaveLaneCountMin..=Max. Hardware still runsevery case. RDNA (32..64) and NVIDIA (32..32) both pass the check, as the reviewers measured.
run_cases_ongains alanes: Option<u32>, so each call site states whether it needs 32 lanes. Cases thatare width-independent pass
Noneand still run on WARP. Each skip prints a named line, so nothing is silent.if !host.takes_waves_of(32) { eprintln!("SKIP: ..."); return; }invalu_tests.rs/pack_tests.rsdo whatthe new
host_32()(inwave64_tests.rs) already does. One shared helper inemit/host.rswould keep themessage and the check in one place. Not blocking.
stops exercising them. That matches what the tests can honestly prove there. The body should say that hardware
runs remain the only coverage for them.
Process
Verdict: ready (not built here). The disclosure needs the model names.
AI-assisted verification: Claude Opus (Claude Code), separate agent per batch.
Generated by Claude Code
Imported from ubiquitarianism/leonida. Originally posted by fiestorra on 2026-12-03T05:38:25Z.
VERIFY-2964 — 414 tests en verde, y el cambio es de los que evitan un rojo ajeno
El título: «guard 32-lane host tests by the adapter's wave width» — y eso es exactamente lo que esta noche me faltó: tests que asumen 32 lanes en un adaptador que tiene 64
fallan en una máquina y pasan en otra, y el que lo lee no sabe si el código está mal.Y fíjate en el signo del diff: 151 inserciones y 83 borrados en ficheros de tests — no es añadir pruebas, es reorganizar las que existen para que dependan del ancho de onda del adaptador.
wave64_tests.rs+102/−… es el fichero que se separa, yvalu_tests.rs+93 pierde las que no eran suyas.Por qué esto importa más que un test nuevo: un test que falla por la máquina no se puede distinguir de uno que falla por el código, y eso es lo que hace que un revisor (o un agente) escriba «la suite falla» cuando la suite está bien y el adaptador es otro. Lo he hecho yo esta noche con la iGPU y con el
IsWindowVisibledel escritorio: dos rojos que no eran del código, y ninguno de los dos estaba guardado.Lo que verifiqué: 414 tests del crate en verde con la reorganización — y en esta máquina, que tiene una 4090 con un ancho de onda concreto, eso dice que la guarda no excluye de más. Lo que no puedo verificar: que en una tarjeta de 64 lanes el reparto sea el correcto, porque no la tengo; lo que sí puedo decir es que aquí no se ha perdido cobertura, porque el número de tests no cae.
Pull request closed