shader/lower: take mask lane bit by console lane in halves mode #33
No reviewers
Labels
No labels
accessibility
area: build
area: formats
area: gpu
area: launcher
area: loader
area: runtime
area: shader
bug
documentation
duplicate
enhancement
good first issue
gpu: amd
gpu: intel
gpu: nvidia
help wanted
host: wine
invalid
out of scope
question
run report
security: hold
triage: confirmed
triage: has patch
triage: merge candidate
triage: needs gpu test
triage: needs info
triage: needs rebase
triage: needs work
triage: proposed close
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Androtim--MiniVI!33
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/33/head"
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?
@Androtim on GitHub · 2026-11-28 10:04 UTC · original
Androtim:feat/iter48-halves-mode-console-lane-bit→main· +48 −5 · 2 files · 1 commits · merged 2026-11-28 18:44 UTCSummary
Port rustno1-coder/VIctory-NVIDIA c1d8179 (Shaders: take a mask's lane bit by console lane in halves mode):
Rig Specs Tested On
Run Settings & Profile
elease @ $sha (static/lowering + D3D12 hardware wave64_tests on RTX 4060 Ti + CI full workspace suite; no separate live game capture for this targeted halves-mode lane-index bugfix)
Measurements & Verification
@Androtim on GitHub · 2026-11-28 11:03 UTC · original
Automated triage for the maintainers (not an approval).
Verdict:
needs-gpu-test· CI (check):passingReview Summary
The fix is minimal, well-targeted, and logically sound:
crates/victory-shader/src/emit/lower.rs:Lower::console_lanepreviously fell back toself.lane_index()wheneverself.exchange.is_none(), even whenself.halves.is_some()(console wave64 lowered as two 32-lane host waves). BecauseLower::wave_basealready supportsself.halves.or(self.ticket)andLower::console_threaduses it to compute the relabelled console thread index (base + rank), gating the fallback onself.exchange.is_none() && self.halves.is_none()ensuresconsole_lane()returnsconsole_thread() & 63(0..63) in halves mode as well.Lower::lane_bitnow checksself.exchange.is_some() || self.halves.is_some()so lanes 32–63 select thehimask dword (lane < 32false) and shift bylane & 31(lane - 32), instead of erroneously indexinglowith their 0–31 host lane index.crates/victory-shader/src/emit/wave64_tests.rs:dispatched_wordsfromdispatchedand addslanes_past_32_take_the_high_dword_of_a_mask_held_as_a_number, which exercisesv_cndmask_b32with an untracked 64-bit mask in halves mode (lowered_on(..., 32)) across all 64 lanes.Local GPU Verification Needed
CI is passing, but
wave64_testsskips the D3D12 hardware dispatch when no SM 6.6 device is present. Because this modifies shader lowering for 32-lane host waves, please confirm the new hardware test runs and passes locally on a real GPU before merging.Generated with Antigravity CLI (
agy).