Patch (fork): indirect draw stream compaction pass and Intel Arc DG2 wave clamping #740
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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 Marvisak/VIctory. Originally posted by UnkwnDev on 2026-11-24T09:05:46Z.
Fork branch: https://github.com/UnkwnDev/VIctory/tree/arc-optimizations
Commits:
Summary
Indirect draw stream compaction:
Empty indirect draw calls from engine passes caused 0.5 to 1.8 second stalls on hardware command queues. We add an atomic compute shader compaction pass and HostList CompactionScratch UMA arena in crates/victory-gpu to filter zero-instance records before ExecuteIndirect dispatch.
WaveSize hardware clamping and bit-exact NaN detection:
Intel Arc DG2 hardware executes waves of width 32 rather than 64. We add wave_size_max() clamping via VICTORY_WAVE_SIZE_MAX in crates/victory-shader/src/emit/mod.rs and lower.rs so compute threadgroups respect the 32-lane hardware limit. We also implement bit-exact NaN detection in vector median3 operations.
Verification
Repository interaction limits prevent non-collaborators from opening PRs directly; maintainers can cherry-pick directly from UnkwnDev/VIctory:arc-optimizations or grant collaborator access to submit as a PR.
Imported from Marvisak/VIctory. Originally posted by UnkwnDev on 2026-11-24T09:48:12Z.
Added commit
f1aaaa3to the fork branch:shader: lower packed dot products to DXIL dot4AddPacked and fused multiply-adds
Imported from Marvisak/VIctory. Originally posted by UnkwnDev on 2026-11-24T11:04:40Z.
Updated rc-optimizations branch on fork (https://github.com/UnkwnDev/VIctory/tree/arc-optimizations) with two additional optimization passes:
Commit 1aaaa3 (shader: lower packed dot products to DXIL dot4AddPacked and fused multiply-adds):
Lowers packed 8-bit dot products directly to SM 6.4 dot4AddPacked and fused multiply-adds (ma) for native execution on Intel Arc Xe-cores and SM 6.4 hardware.
Commit
7bfa689(shader: clamp whole-wave simulation width to wave_size_max for Wave32 execution):Aligns crates/victory-shader/src/emit/wave.rs whole-wave simulation width to super::wave_size_max(), preventing 64-element symbolic vector allocations and 64-bit mask assumptions when running with VICTORY_WAVE_SIZE_MAX=32 on Wave32 hardware. Evaluates wave_size_max() dynamically and adds unit and dispatch test coverage in alu_tests.rs.
Full test suite: cargo test --workspace clean across all crates.
Imported from Marvisak/VIctory. Originally posted by Marvisak on 2026-11-25T03:49:35Z.
Automated triage for the maintainers.
This offered several changes on a fork branch (
arc-optimizations). Thanks for splitting what is left against currentmain(940d32f) into pull requests: #2201 (compaction of non-empty indirect draw and dispatch arguments) and #2202 (the remaining packed dot products and clamped integer forms). Review happens on those PRs.What the other parts map to:
v_dot4_i32_i8andv_dot4c_i32_i8already lower todot4AddPackedincrates/victory-shader/src/emit/lower.rs, so #2202 should carry only the forms still missing there. #2092 also lowersv_dot4_u32_u8andv_dot8_u32_u4, so the two PRs overlap.v_med3with a NaN operand: tracked in #726. Open PR #2010 carries a fix.Generated by Claude Code
Imported from Marvisak/VIctory. Originally posted by UnkwnDev on 2026-11-25T07:45:05Z.
Split the remaining uncovered changes against current
main(940d32f) into separate single-purpose PRs per the triage note:gpu: compact non-empty indirect draw and dispatch argumentsshader: lower remaining packed dot products and clamped integer forms