Recompiler: direct DXIL applies NEG_HI as ABS on v_dot2_f32_f16's accumulator (stacked on #1286) #1979
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
goal:world-load
good first issue
help wanted
invalid
keep-open
off-goal
question
stale
test-only
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/xcl-dev--xcl!1979
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/1979/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?
@regiumlepidi on GitHub · 2026-11-25 00:21 UTC · original
regiumlepidi:direct-dxil-pr1286→main· +56 −0 · 3 files · 2 commits · merged 2026-11-25 18:22 UTCStacked on #1286. Part of #1269.
#1286 fixes
v_dot2_f32_f16(NEG_HI bit 2 applies |x| to the f32 accumulator) in the HLSL path(
recomp/emit.rs). The direct RDNA2 -> DXIL translator (XCL_DIRECT_DXIL=1,gpu/dxil/lower_wide.rs)still applied NEG only, so the PR's own GPU test fails there (-3.0 instead of 7.0). This adds the same
rule to the direct path.
What is in it
main(its head predatesgpu/dxil/)lower_wide.rsappliesfabsto SRC2 when NEG_HI bit 2 is set, before NEGIf #1286 merges first, only the second commit remains; if the author prefers to take it into #1286, this can be closed.
Tested
cargo test --workspace -- --test-threads=4, default path: 942 passed, 4 failed, 25 ignored (23 SKIPPED GPU tests); the new test passesXCL_DIRECT_DXIL=1: 942 passed, 4 failed, 25 ignored (23 SKIPPED); the new test passesfuzz_validate_and_gpu_*failures are the same onmainon this machine (#1905, E_OUTOFMEMORY on this driver)gpu_dot2_f32_f16_abs_neg_on_src2withXCL_DIRECT_DXIL=1on the first commit alone: FAILED (so the second commit is what fixes it)Regression run
Run by @Toons29 on a retail title, AMD Radeon RX 9070, release build, 60 s (#1979); blocks as posted there. Within the CONTRIBUTING.md limits: frames 100 % of
main, no crash, no device removal.main:
PR:
Not tested
AI use
regiumlepidiaccount at the account owner's request.🤖 Generated with Claude Code
@DarkPanda69 on GitHub · 2026-11-25 00:47 UTC · original
AMD run with native 64-lane waves, which this PR lists as not tested (the author's GPU runs wave32 only).
Tested: pass, head
b0b7532applied onmain6567c5f, debug, Rust 1.100.0, Windows 11 Pro 26200, Ryzen 7 5800X, DXC 1.9.2602.17.cargo test -p xcl --lib -- gpu:: --test-threads=4:gpu_dot2_f32_f16_abs_neg_on_src2anddot2_f32_f16_neg_hi_on_src2_is_absok. The 2 failures aregpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1and_3, which fail the same way onmain6567c5fwithout this PR on this card.Not tested: release build; the whole workspace suite; a title.
AI use: Claude Code (Claude Opus 5.5) ran the tests on this machine and wrote this report.
@DavidM1911 on GitHub · 2026-11-25 03:19 UTC · original
Verification on RTX 3060 Ti (Windows 11), branch merged with current
main:cargo test -p xcl --lib: all passed, 0 failed, ~26 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun.)Thanks!
@JJAutoCompare on GitHub · 2026-11-25 03:55 UTC · original
Intel Arc A770 verification for xcl-dev/xcl PR #1979
#1979
Tested
GitHub showed the PR open at
b0b753228bbefore and after the run. Read AGENTS.md and CONTRIBUTING.md. The checkout was clean and detached at that exact SHA before and after testing. The PR description, comments, and reviews contained no equivalent Arc report.STOR-WINLAB ran Windows 11 Enterprise Evaluation x64 build 26200.9974 on an AMD Ryzen 7 3800X and Intel Arc A770 (driver 32.0.101.9175). Rust 1.100.0 (0ef1bc386, x86_64-pc-windows-msvc), Cargo 1.100.0, unoptimized test profile. Both GPU runs logged DXC and DXIL 1.9.2609.5.
Prebuild outside the Arc mutex
cargo test --locked -p xcl --lib --no-run
Exit 0 in 39.54 s.
Build and test settings
CARGO_TARGET_DIR=L:/XclTooling/pr1778-2e2ee55-20261125-020159/target
CARGO_BUILD_JOBS=2
CARGO_INCREMENTAL=0
CARGO_PROFILE_DEV_DEBUG=0
CARGO_PROFILE_TEST_DEBUG=0
TEMP=TMP=L:/XclTooling/pr1979/temp
XCL_DXC_DIR was set to LOCALAPPDATA/XclTooling/dxc-1.9.2609/bin/x64.
Exact test commands
$binary = 'L:\XclTooling\pr1778-2e2ee55-20261125-020159\target\debug\build\xcl\77aca8ccb20e299f\out\xcl-77aca8ccb20e299f.exe'
CPU, outside the Arc mutex
& $binary 'gpu::recomp::tests::dot2_f32_f16_neg_hi_on_src2_is_abs' --exact --nocapture --test-threads=1
GPU, one independent PowerShell process and one Arc mutex acquisition for each backend
$env:XCL_ADAPTER = 'A770'
$env:XCL_DIRECT_DXIL = '0' # HLSL/DXC run
& 'L:/XclTooling/Invoke-ArcTest.ps1' -Test { & $binary 'gpu::recomp::tests::gpu_dot2_f32_f16_abs_neg_on_src2' --exact --nocapture --test-threads=1 }
$env:XCL_ADAPTER = 'A770'
$env:XCL_DIRECT_DXIL = '1' # Direct DXIL run
& 'L:/XclTooling/Invoke-ArcTest.ps1' -Test { & $binary 'gpu::recomp::tests::gpu_dot2_f32_f16_abs_neg_on_src2' --exact --nocapture --test-threads=1 }
Each GPU wrapper process used powershell.exe -NoProfile -NonInteractive -ExecutionPolicy RemoteSigned -OutputFormat Text -EncodedCommand, with the literal executable path in the encoded command. Both GPU logs show mutex acquisition and release.
Run Passed Failed Ignored Explicit SKIPPED Filtered out Exit Test time
CPU 1 0 0 0 970 0 0.01 s
GPU HLSL/DXC 1 0 0 0 970 0 0.18 s
GPU direct DXIL 1 0 0 0 970 0 0.15 s
The CPU fixture checked HLSL emission for an unmodified SRC2, ABS, and NEG applied after ABS. The GPU fixture checked 7.0, -3.0, and 7.0 for ABS, ABS then NEG, and NEG alone with an accumulator of -5.0. Each backend checked all three values across 32 lanes (96 assertions per backend). The fixture's wave-size gate selected wave32. The earlier same-host Arc D3D12 capability log records WaveLaneCountMin=8 and WaveLaneCountMax=32 at L:/XclTooling/pr1577/wave-capability-20261125-033726.log.
Not tested
Native wave64, split wave64, other adapters, release builds, the full suite, and retail-title smoke. The fixture omits wave64 on this adapter without emitting a SKIPPED line.
AI use
T3 Code / Codex (gpt-6.2-sol) verified the revision, ran the checked-in fixtures, and wrote this report from the captured logs.
Separate stdout and stderr logs, exact invocation records, and test exit records are in L:/XclTooling/pr1979.
@Toons29 on GitHub · 2026-11-25 04:40 UTC · original
Regression run of
b0b75322on the retail title, for this PR's Regression run section. Both blocks are fromscripts/smoke.ps1as printed, not edited:mainoncbc296ab, this PR on its head commit with no uncommitted changes, same title and time.Against the limits in CONTRIBUTING.md: 100 % of
main's frames, 100 % of its peak commit, no crash, no device removal.AMD Radeon RX 9070 (RDNA4, driver 32.0.32029.2010), Ryzen 7 7800X3D, 32 GB, Windows 11 build 26300, Rust 1.100.0,
cargo build --release -p xcl, 60 s,XCL_NETWORK=0. This is a regression check only: it does not show whether the run reaches the code this PR changes.AI use: Claude Code (Claude Opus 5.5) built both trees and ran
scripts/smoke.ps1; a script posted this right after the run, with both blocks exactly as printed.@upipibi on GitHub · 2026-11-25 17:12 UTC · original
NVIDIA test report for
b0b7532(head as is, base80f4819), for #1607's NVIDIA list. RTX 3070 8 GB (Ampere, 32-lane waves), driver 616.56, Windows 11, debug, aftercargo build --workspace:cargo test --workspace --no-fail-fast -- --test-threads=4 --skip hle::xaudio2: 986 passed, 0 failed, 45 ignored. The end-to-end title tests pass.main0829441on the same machine, same command: 1263 passed, 0 failed, 46 ignored (the PR's base is older, so it has fewer tests).hle::xaudio2, because its tests fail or hang on this machine onmaintoo. The PR doesn't touch it.no wave64on this card, 3 f16/f32 forms the per-lane path refuses, 1 no heap windows, and 1 PSO measurement that needs Developer Mode to turn the driver cache off.AI-assisted (Claude Code, Claude Opus 5.5). Synthetic tests only; no title run.