Repository navigation
Conversation
|
AI-assisted. Tested 010363c on Windows 11 with the NVIDIA GeForce RTX 4090 and AMD Radeon(TM) Graphics. The new GPU test passes on both adapters. I set
The shader passes SPIR-V validation. Both devices return the same eight words: With the new fixture and the runner from parent 3faac55, the same command translates the shader and exits 2 because the parent has no test case for it. The two tests in |
|
Tested At I checked the square-root fixture's sensitivity to lost input precision. Rounding its integer operand AI-assisted verification. |
Kam471
left a comment
There was a problem hiding this comment.
Head 010363c94. git diff --check clean. New GPU fixture plus one dispatch branch; no translator change.
- Build: vcvars64 + Ninja,
-DCMAKE_BUILD_TYPE=RelWithDebInfo -DBUILD_TESTING=ON -DLEONIDA_BUILD_WINDOWS_RUNTIME=OFF -DLEONIDA_REQUIRE_VULKAN=ON -DVulkan_INCLUDE_DIR=.../1.4.363.0/Include -DVulkan_LIBRARY=.../vulkan-1.lib -DVulkan_GLSLANG_VALIDATOR_EXECUTABLE=.../glslangValidator.exe;cmake --build <build> --target vk_compute_test-> exit 0. python -I scripts/run_gpu_tests.py --build <build> --filter cs_f64_trans(LEONIDA_VK_DEVICE='RTX 5070 Ti', Vulkan 1.4.363, LLVM_MC=wsl llvm-mc-21):
PASS cs_f64_trans 0x0 0x3fd00000 0x0 0x3fe00000 0x4000000 0x41900000 0x0 0x3ff00000,1/1 passed, exit 0. That reproduces the PR's two-device result on a third device (RTX 5070 Ti).spirv-disof the producedcs_f64_trans.spv:OpFDiv %double,InverseSqrt %double,Sqrt %double, andOpFNegate %double->Sqrt->OpFMul(div:2). All four intended forms are exercised, not just transcribed. The0x4330000008000001operand (2^52 + 2^27 + 1) and the exact 67108865 result are discriminating: no f32 round-trip can produce them.- Expected words match the .asm header (0 1070596096 0 1071644672 67108864 1099956224 0 1072693248) and the
judge_cs_dump(..., hexwords=True)list.
Verdict: merge. Note runtime/test/shaders/check.py has no cs_f64_trans entry, so only run_gpu_tests.py judges it; that matches most cs_* fixtures and the PR's stated scope.
|
AI-assisted. Independent run on an Apple M4 (macOS, MoltenVK 1.4.2) at Skip path.
Translation. The translated module passes
Full suite. 152/218 passed and 59 skipped, against Unit tests. |
x2Tweek
left a comment
There was a problem hiding this comment.
AI-assisted.
Verified cs_f64_trans on RTX 5090: v_rcp_f64/v_rsq_f64/v_sqrt_f64 on binary64 operands produce correct results, including the 53-bit significand operand (2^52 + 2^27 + 1) that no binary32 value can hold. 1/1 passed, exit 0.
Approved.
🤖 Generated with Claude Code
|
Tested Exit 0, 3 s. The words are the fixture's stated expectations, low word first: The two neighbouring tests in the same filter are unchanged and still exact on the RTX 3070, and This is the f64 row on Ampere; the PR's hardware note asked for a GPU with working binary64, and this one agrees with the fixture. AI-assisted. No game data. |
|
Tested
I got the same 4/4 with the SHADER-865 literal fixes merged on top: #2863, #3642, #3791, and #2863 + #3791 together. I also got it with this PR merged onto the new Merge-order note. I merged #4371 (SHADER-721, open) on top. It drops the f64 omod after gfx1036 measurements, and with it AI-assisted (Claude Code). Synthetic programs only, no game files. |
Adds
runtime/test/shaders/cs_f64_trans.asm, a hand-written compute fixture for the docs/design.md row "v_rcp_f64,v_rsq_f64,v_sqrt_f64", run and judged byscripts/run_gpu_tests.py.The fixture computes rcp(4.0) = 0.25, rsq(4.0) = 0.5, sqrt(2^52 + 2^27 + 1) = 67108865 and -sqrt(-4.0) div:2 = 1.0, storing each double low word first. The operand 2^52 + 2^27 + 1 = (2^26 + 1)^2 needs 53 significand bits, so no binary32 value can hold it and its square root is exact only in binary64; the last case carries the VOP3
neginput modifier, applied to the double operand, and thediv:2output modifier.Tested with
scripts/run_gpu_tests.py --filter cs_f64_transon the AMD RADV RAPHAEL_MENDOCINO (Ryzen 9 9950X3D iGPU) and the NVIDIA GeForce RTX 5080 (driver 620.70.06):PASS cs_f64_trans 0x0 0x3fd00000 0x0 0x3fe00000 0x4000000 0x41900000 0x0 0x3ff00000, 1/1 passed, exit 0. The branch changes no translator file, so the tested bytes are main's translator. Negative control, withtools/rdna2spirv.pypatched sov_rsq_f64emitsSqrtandv_sqrt_f64emitsInverseSqrt, fails on both devices: rsq(4.0) comes back as 2.0 and sqrt(2^52 + 2^27 + 1) as about 1.49e-8.The row now records this GPU run.
tests/test_f64_transcendentals.pystays the CPU check of the same lowering.AI-assisted.