Repository navigation
Conversation
ps_vcmp_int32 runs v_cmp_{eq,ne,lt,le,gt,ge,f,t}_{u32,i32} in the e32 and
e64 forms with inline constants and literals, on operands where signed and
unsigned disagree. Words derived by hand in the .asm header; the same shader
is a tests/semantic fixture with a plain-Python reference.
AI-assisted.
|
Tested 7d370cd on AMD Radeon RX 9060 XT (RDNA4), AMD driver 26.10.44 (LLPC, Vulkan driver 2.0.395), Windows 11 Pro 10.0.26300, subgroup 32..64: pass.
Test programs: an MSVC 14.44 build of 4eb6155, this PR's base. The PR changes no C++ or CMake, so they are what its head builds; the translator, runner and This adds an RDNA4 card to the RDNA2 iGPU and NVIDIA runs in the description. No negative control run here. No game files. AI-assisted (Claude Code). |
|
Tested 7d370cd on NVIDIA GeForce RTX 3090 (Ampere, subgroup 32..32), driver 610.88 (Vulkan 1.4.341), Windows 11 Pro 26300: pass. The PR's diff applied cleanly to
|
|
Tested 7d370cd on Intel UHD Graphics (Xe-LP, Tiger Lake-H iGPU, driver 101.7088) and NVIDIA RTX 3050 Laptop GPU (driver 617.42), Windows 11 Pro build 26300,
|
tests/semantic/regen_fixtures.py AI-assisted.
|
Tested
No game files. AI-assisted (Claude Code). |
|
Tested Runtime and test programs built from this head (MSVC 14.51, Ninja, RelWithDebInfo), native Windows
This PR's shaders:
AI-assisted (Claude Code); I checked the results. |
tests/semantic/regen_fixtures.py AI-assisted.
|
Tested
No game files. AI-assisted (Claude Code). |
|
Tested
Not run: AI-assisted (Claude Code). |
Requested by Lucas · project thread
Claimed in the coordination issue as: EGEN-GPU-VOPC-INT, #2078 (comment)
What and why
Adds
ps_vcmp_int32, a GPU test for the 32-bit integer VOPC compares:v_cmp_{eq,ne,lt,le,gt,ge,f,t}_{u32,i32}, in the e32 form (VCC) and the e64 form (SGPR pair). The signed 32-bit compares andv_cmp_f/t_{u32,i32}had no GPU test on main.Five operand pairs per op: a literal
0x80000000vs 1 and an inline-1vs 0 (unsigned and signed disagree), an inline 1 vs0x80000000(the mirror), a literal0x12345678vs itself (equal) and two VGPRs 3 vs 5. The e64 words use the mirrored operand order (VGPR in src0, constant in src1). The four expected words are derived by hand in the.asmheader. The same shader is atests/semanticfixture, asserted in the newtests/semantic/test_vcmp_int32.pyagainst a plain-Python reference.Not covered: the 64-bit compares (#1299), the cmpx forms (
ps_vcmpx_forms) and the 16-bit forms.Tested
run_gpu_tests.py --filter ps_vcmp_int32: PASS, 4096/4096 pixels exact on both.v_cmp_gt_u32signed intools/rdna2spirv.py(one line) fails on both GPUs:got 0x964e52e8, 0x984dcee8, 0xb9358ee8, 0xb73612e8, want0x963e52e8, 0x984dcee8, 0xb9458ee8, 0xb73612e8(4096/4096 mismatches). Reverted.python -m unittest discover -s tests/semantic(1673 tests OK),python tests/semantic/regen_fixtures.py --check(clean) andpython -I tests/test_shader_checks.py(60 tests OK).Checklist
AI-assisted.