Repository navigation
Conversation
|
Apple M2 data point for the new denormal/special-value fixture. Tested head 469cebe on Apple M2 (Mac14,3), macOS 26.4 (25E246), MoltenVK 1.4.2 (direct), subgroup 4..32, llvm-mc 23.1.6, Python 3.13.18.
Build note: full build fails on AppleClang 17 at vk_pipeline_check.cpp:567 (BUILD-822, fixed by open PR #2927); GPU binaries built, so the run above is valid. Head fetched unchanged into a separate worktree; no rebase/edit/push. Synthetic shader and counts only; no game files. AI-assisted. |
469cebe to
02df6ef
Compare
|
Rebased on Thanks @bobcatchris for the M2 run. One clarification: with this PR the RX 9070 also returns |
|
Tested 02df6ef on AMD Radeon RX 6800 (RDNA2, Navi 21, subgroup 32..64), AMD 26.8.1 (Windows 32.0.21045.5002), Vulkan 1.4.315, Windows 11 Pro 25H2 (build 26200): pass As far as I can see in this thread, this is the first run of the new fixture on a discrete RDNA2 card (the expected words come from gfx1036).
Built with AI-assisted (Claude Code): it built both commits and ran the tests. |
|
Tested
llvm-mc 21.1.8, SPIRV-Tools via WSL forwarders, Python 3.13. Synthetic fixtures only, no game files. AI-assisted (OpenCode). |
|
Tested
Synthetic fixtures only, no game data. AI-assisted (Claude Code). |
|
Tested 02df6ef on AMD Radeon RX 9070 XT (RADV GFX1201) and the Ryzen 7 9800X3D iGPU (RADV RAPHAEL_MENDOCINO, gfx1036), Mesa 26.2.6, Linux 7.3.4: pass, no regressions.
No game files. AI-assisted. |
|
Tested 02df6ef on NVIDIA GeForce RTX 3070 (Ampere, subgroup 32..32), driver 617.42, Windows 11 24H2 (26100): pass, plus the negative control nobody has run on NVIDIA yet.
Toolchain: llvm-mc 23.1.6 and SPIRV-Tools 2026.4 from conda-forge, Python 3.14.2. Synthetic fixtures only, no game files. AI-assisted (Claude). |
|
Tested on Windows 11 with two GPUs on one machine (head merged with main f847748, MSVC 14.51, Python 3.13.1):
The vk_* programs came from a runtime built from main. No concerns. |
|
Tested
No game files. AI-assisted (Claude Code). |
…a denormal No GPU test fed these ops an f32 denormal: ps_fnan_fract gives v_fract_f32 a normal -1e-10, and nothing used floor, ceil or cvt_flr. cs_round_f32_denorm runs eight of the rows measured natively on gfx1036 for ItsNotRexed#2139 (a denormal operand is a zero of its sign, fract(+-inf) is 0xffc00000, a signalling NaN passes through), one per lane, with the operand picked per lane at run time and the result stored to memory. Registered in check.py and run_gpu_tests.py, with a semantic fixture and test_round_f32_denorm.py; test_shader_checks.py's fake vk_compute_test knows its words. ItsNotRexed#2139's change is on main (0fe4e45, f0ea562). With the translator from before it (4947579) the CPU test fails seven of the eight lanes, with the "before" words of ItsNotRexed#2139's table, and an RX 9070 fails three: fract(+-inf) and the signalling NaN (its driver already flushes f32 denormals). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
02df6ef to
94381e1
Compare
|
Rebased on Thanks @vibryxcx, @sds-228, @ttd0x, @sperm, @MKmajster, @kapitche and @crastinator for the runs. @MKmajster's negative control on the RTX 3070 covers what the RX 9070 can't: that driver keeps f32 denormals, so 7 of the 8 lanes catch the translator from before #2139, where on the RX 9070 only 3 do (fract(±inf) and the signalling NaN). |
|
Tested 94381e1 (the head rebased on Same laptop, one GPU at a time through
So an RDNA2 GPU on AMD's Windows driver and a Blackwell GPU give the eight words the fixture expects. 215 shaders translated, 215 pass spirv-val in each run. I did not run the CPU tests of this PR. One run of each. No game files. AI-assisted (Claude Code). |
|
Tested Ran the PR’s synthetic fixture through
AI-assisted verification with synthetic inputs. |
|
Tested
Synthetic fixtures only, no game files. AI-assisted (Claude Code). |
Claimed in the coordination issue as: TEST-515 (#2516 (comment))
Rebased on
mainf847748:scripts/run_gpu_tests.pyconflicted with TEST-510'scs_buf_load_sub/cs_buf_fmt8entries andtests/test_shader_checks.pywithvs_base_ids; both sides are kept, so the fixture count there is now+ 13. The numbers below are from that base unless noted.What and why
#2139's change, on
mainas 0fe4e45 and f0ea562, makesv_floor_f32,v_ceil_f32,v_fract_f32andv_cvt_flr_i32_f32read an f32 denormal as a zero of its sign, as gfx1036 does in the game's MODE. No GPU test fed these ops a denormal:ps_fnan_fractgivesv_fract_f32a normal -1e-10, and nothing used floor, ceil or cvt_flr. This was claimed as stacked on #2139; that change is onmainnow, so the branch is based onmain.runtime/test/shaders/cs_round_f32_denorm.asm: 8 lanes (wave32). Each lane gets one operand picked per lane at run time (v_cndmaskon the lane id, so the driver cannot fold it) and stores one of the four results to memory (a buffer store, so no export path can canonicalise the NaN words). The 8 words are rows measured natively on gfx1036 intests/semantic/test_alu_floor_ceil_fract_hw.py: floor(-1e-45) = -0, ceil(+1e-45) = +0, fract(±1e-45) = 0, fract(±inf) = 0xffc00000, cvt_flr_i32(-1e-45) = 0, and floor of the signalling NaN 0x7fa00000 unchanged.cs_cvt_pk_u8:ROUND_F32_DENORM_WORDSand acompute_testincheck.py, the per-lane dump list inscripts/run_gpu_tests.py,tests/semantic/regen_fixtures.pywith the generated fixture,tests/semantic/test_round_f32_denorm.py(each lane through the interpreter), and the fakevk_compute_testwords plus the fixture count intests/test_shader_checks.py(the same change 9df5969 made forcs_cvt_pk_u8).Tested
AMD Radeon RX 9070 (RDNA4, subgroup 32..64), AMD 26.10.1 (LLPC), Vulkan 1.4.359, Windows 11 26300, Python 3.12.10, llvm-mc 21.1.8, Vulkan SDK 1.4.363.0; this branch on
mainf847748 (no C++ change), withLEONIDA_VK_DEVICE=9070.run_gpu_tests.py --filter cs_round_f32_denorm: 1/1 in three runs,0x80000000 0x0 0x0 0x0 0xffc00000 0xffc00000 0x0 0x7fa00000each time.build.py: 225 shaders translated, all passspirv-val(mainf847748: 224).check.py: 172 of 175 pass, 3 skipped (main: 171 of 174, the same skips).run_gpu_tests.py: 186/200 passed, 14 skipped, 0 failed (mainf847748: 185/199, the same 14 skips); the only difference is the new test.main4947579): the CPU test fails seven of the eight lanes with the "before" words of Translator: v_floor/ceil/fract_f32 and v_cvt_flr_i32_f32 read an f32 denormal as zero, as RDNA2 does #2139's table (floor -1.0, ceil +1.0, fract 0x3f7fffff and 0x00000001, fract(±inf) 0x7fc00000, cvt_flr -1); lane 7 passes on the CPU (the same on this base). On the RX 9070 (run before the rebase) the GPU test fails three lanes, in three runs: fract(±inf) gives 0x3f7fffff and the signalling NaN comes back quieted (0x7fe00000). The denormal lanes already match there because this driver flushes f32 denormals itself; Translator: v_floor/ceil/fract_f32 and v_cvt_flr_i32_f32 read an f32 denormal as zero, as RDNA2 does #2139 notes that NVIDIA keeps them by default, which is where those lanes differ.python -I -m unittest discover -s tests/semantic7323 tests OK (4 skipped, 1 expected failure;main: 7322),tests/test_shader_checks.py70 OK,tests/test_run_gpu_tests.py38 OK,regen_fixtures.py --checkclean, on Python 3.14.2 (WSL), andtest_round_f32_denorm.py,test_shader_checks.py,test_run_gpu_tests.pyandregen_fixtures.py --checkon 3.12.10 (Windows).git diff --checkclean.Checklist
docs/design.md, with how it was confirmed. (Not applicable: no translator change.)AI-assisted (Claude Code).
🤖 Generated with Claude Code