Repository navigation
Conversation
|
Independent native Windows AMD check of exact PR head Tested
This checks the focused GPU and DXIL tests. I did not run the full workspace suite or a paired title smoke on this PR. No claim about speed or title shader use follows from these tests. AI-assisted checkout, testing, log verification, and report drafting with OpenAI Codex (GPT-6). No game data was used. |
|
Verification on RTX 3060 Ti (Windows 11), branch merged with current
Thanks! |
3a599af to
838eb4e
Compare
Replace the 64-bit extend/mul/shift/trunc expansion in Lw::mul_hi with dx.op.binaryWithTwoOuts UMul (op 42) and IMul (op 41), extracting the high dword directly and avoiding i64 ops and Feature::Int64Ops across s_mul_hi_u32/i32, v_mul_hi_u32/i32, and v_mul_hi_u32_u24/i32_i24. Part of xcl-dev#1269 Assisted-by: Antigravity (Gemini 4 Neon)
838eb4e to
aeab327
Compare
|
Regression run of Against the limits in CONTRIBUTING.md: 104 % of AMD Radeon RX 9070 (RDNA4, driver 32.0.32029.2010), Ryzen 7 7800X3D, 32 GB, Windows 11 build 26300, Rust 1.100.0, AI use: Claude Code (Claude Opus 5.5) built both trees and ran |
Lower RDNA2 32x32→high-32 multiplication (
Lw::mul_hi) directly to DXILdx.op.binaryWithTwoOuts.i32(umul_wide, op 42, andimul_wide, op 41) instead of widening operands toi64, multiplying in 64 bits, shifting right by 32, and truncating back toi32.This covers
s_mul_hi_u32,s_mul_hi_i32,v_mul_hi_u32,v_mul_hi_i32,v_mul_hi_u32_u24, andv_mul_hi_i32_i24and avoids unnecessary 64-bit integer operations andFeature::Int64Opsflags.Part of #1269
What is in it
crates/xcl/src/gpu/dxil/lower.rs: replaceLw::mul_hiwithif signed { self.s.imul_wide(a, b).0 } else { self.s.umul_wide(a, b).0 }(+1/-5 lines).crates/xcl/src/gpu/dxil/core_tests.rs: addmul_hi_lowers_to_dxil_wide_mulverifying DXIL validation and disassembly emitdx.op.binaryWithTwoOuts.i32opcodes 42 (UMul) and 41 (IMul) withoutmul i64orsext i32.crates/xcl/src/gpu/recomp/tests.rs: addgpu_mul_hi_edge_casestesting scalar and vectormul_hi(u32,i32,u24,i24with dirty upper 8 bits and sign/boundary inputs) against 64-bit CPU reference.(V_MUL_HI_U32, V_MUL_HI_I32)pairs, wave32):n = 1changes2272→2348bytes (firstdx.types.twoi32/binaryWithTwoOutsdeclarations);n = 64drops5748→5676bytes (-72bytes) and removes alli64arithmetic.Tested
32.0.15.9579, wave32), AMD Ryzen 7 9700X, Windows 11 Pro10.0.26100,rustc 1.100.0, DXC1.8.2502.11(XCL_DXC_DIR=D:\Windows Kits\10\bin\10.0.26100.0\x64), debug & release builds.cargo test --workspace -- --test-threads=4: 1156 passed, 0 failed, 46 ignored (24 SKIPPEDhardware-capability / policy checks: native wave64 unavailable on RTX 5080 and rejected direct-pathf16arithmetic), includingmul_hi_lowers_to_dxil_wide_mulandgpu_mul_hi_edge_cases.XCL_DIRECT_DXIL=1targeted GPU parity runs on RTX 5080 (gpu_mul_hi_edge_cases,gpu_scalar_sext_mulhi_and_vector_i24_sub_co_ci_u64_shifts): both passed.Regression run
main:
PR:
Not tested
XCL_DIRECT_DXIL=1in thesmoke.ps1launch (because on unmergedmainwithout PR VFS: exempt xcl.exe and host tool dirs from console drive mounts #2101,D:\Windows Kits\...inXCL_DXC_DIRis intercepted by the{game}D-drive VFS mount inside the host process;XCL_DIRECT_DXIL=1was verified in unit/GPU tests).AI use
Lw::mul_hito emitumul_wide/imul_wide, added the disassembly and GPU edge-case tests, and ran the test suite andscripts/smoke.ps1regression checks.