Tests: the dot products run with operands loaded at run time, not literals #1900
No reviewers
Labels
No labels
accessibility
area: build
area: formats
area: gpu
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
request
run report
triage: confirmed
triage: has patch
triage: merge candidate
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/Marvisak--VIctory!1900
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/1900/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?
@fiestorra on GitHub · 2026-11-25 00:21 UTC · original
fiestorra:test/dot4-operands-from-user-data→main· +21 −30 · 1 files · 1 commits · closed without mergingThe test no longer needs literals: its operands come from user data now
I took the two things the report settled into a change, because you are right that the translator is not where the fix goes and the test is.
What changes:
fspx_programs_run_with_the_hardwares_dot_productsbuilds its program withbuild_valu_cs— a plain compute shader whose four root constants are the case's inputs — and the multiplicands and accumulator reachv_dot4_i32_i8throughv_mov_b32 vN, sNat run time, instead ofv_mov_b32 vN, <literal>. The case inputs are[a, b, acc, 0], so the three literal-multiplicand cases are gone.Why the operands could not stay literals in an FSPX program: in an
ACCC-shaped program the user data are the hardware's own SGPRs (s0-s3are the thread's ids), so a shader of that shape cannot carry operands at all — it can only name them as literals, which is exactly the form the RDNA1 driver folds intov_dot4cand zero-extends. So the test runs the same instructions with values loaded at run time, which is the shape a title's shader has whenever its multiplicands are computed rather than declared. Itsfspx_cshelper goes with the change (nothing else used it), and the doc comment says why the program is no longerACCC-shaped.What I could not verify, said plainly: my machine is an RTX 4090, where the literal and run-time forms agree, so here the test passed before and passes after — 209 passed, 2 ignored, unchanged. The evidence that it now passes on RDNA1 is yours to give; the reasoning is your table, where "none" and "accumulator only" are the signed result and every case with a literal multiplicand is not. The inline
2.0(sel_hi_lo, bytes below0x80) is untouched and stays a constant, as you said it could.Recipe:
cargo test -p victory-shader --locked --lib(209 passed, 2 ignored);cargo clippy --workspace --all-targetswith and without--all-featuresclean under-D warnings;rustfmt --check0 hunks on the file, which is also 0 onmain, so nothing of the file was reformatted.Pull request: #1893
No game data is involved: an opcode, two constants and test counts.
Written with an AI assistant.
fspx_programs_run_with_the_hardwares_dot_productsfails on RDNA1, where the driver folds a constantDot4AddI8Packedoperand as unsigned #1782@Headache3318 on GitHub · 2026-11-25 01:44 UTC · original
Tested on Linux (Arch, kernel 7.3.5, 3× RTX 4090 driver 620.73.04), Rust 1.98.1 (pinned). PR head
799f9a2applied cleanly onto currentmainccfb029.cargo test -p victory-shader --locked: 144 passed, 0 failed, 2 ignored. All tests pass.cargo clippy -p victory-shader --all-targets -- -D warnings: 4 pre-existing errors in test code (fail identically on mainccfb029). The PR introduces no new clippy warnings.Not tested: Windows MSVC build, the title itself. AI-assisted.
@Headache3318 on GitHub · 2026-11-25 02:10 UTC · original
Tested on Linux (Arch, kernel 7.3.5, 3× RTX 4090 driver 620.73.04), Rust 1.98.1 (pinned). PR head
799f9a2applied cleanly onto currentmainccfb029.cargo test -p victory-shader --locked: 144 passed, 0 failed, 2 ignored. All tests pass.cargo clippy -p victory-shader --all-targets -- -D warnings: 4 pre-existing errors in test code (fail identically on mainccfb029). The PR introduces no new clippy warnings.Not tested: Windows MSVC build, the title itself. AI-assisted.
@Marvisak on GitHub · 2026-11-25 08:17 UTC · original
Automated triage for the maintainers.
Proposed close: duplicate of a better open PR, #1790. Both PRs fix the RDNA1 failure of
emit::valu_tests::fspx_programs_run_with_the_hardwares_dot_products(#1782), and both pass on the reporter's RX 5700 (comparison table in #1782). This PR does it by deletingfspx_csand running the cases throughbuild_valu_cs. The test no longer exercises theACCCcontainer path its name and purpose refer to. #1790 makes the operands run-time values (v_add_nc_u32 vN, literal, v4withv4loaded from the zeroed UAV). It keeps theACCCprogram, the cases and the expected values, and its author showed the test still catches a signed/unsigned lowering error.CI
checkpasses here. The change itself is not wrong. It just covers less than #1790 for the same fix.This PR will be closed in 48 hours unless the author pushes a change (for example, one that keeps the
ACCCpath) or a maintainer removes the label.Generated by Claude Code
@sinan-cmyk on GitHub · 2026-11-25 11:38 UTC · original
Offline measurement on a retail dump
Result: no count change against
main.I merged head
799f9a22ontomain940d32f(clean merge) and ranvictory translate --validate --listonshaders.rpf(1.0.2.1), with dxil.dll 1.8.2502.11. I compared the result withmainprogram by program (25,889 programs). Validated: 23,918 onmain, 23,918 with this PR.No program changes its failure reason. The count shows that the change rejects nothing on this data. It does not show whether the output is right.
No shader names or data are included, per the asset policy. AI-assisted (Claude Code).
fspx_programs_run_with_the_hardwares_dot_productsfails on RDNA1, where the driver folds a constantDot4AddI8Packedoperand as unsigned #1782@fiestorra on GitHub · 2026-11-25 22:47 UTC · original
Closing: main runs the dot products with run-time operands already
Main's
49761f9("Shader tests: dot products take their operands at run time", #1790) made the operands a literal plus a word of the zeroed UAV, which is the change this branch proposed, and the comment in main now names the same reason (#1782: the RDNA1 driver zero-extends bytes of a multiplicand it sees as a constant). Nothing left to rebase.Written with an AI assistant.
Pull request closed