Repository navigation
GPU tests: image_sample_l, image_sample_b_o, image_sample_c_lz_o, image_gather4_lz, image_load_mip - #2225
GPU tests: image_sample_l, image_sample_b_o, image_sample_c_lz_o, image_gather4_lz, image_load_mip#2225evilclanker9000 wants to merge 6 commits into
Conversation
…ge_load_mip Five image ops had CPU tests only. Each gets a hand-written pixel shader on vk_texture_test's existing textures, with the expected words derived in the .asm header. vk_texture_test gets an opt-in dref_o mode (D32 depth ramp for image_sample_c_lz_o) and now honours LEONIDA_VK_DEVICE like the other tools. AI-assisted.
|
Tested 894070d 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 on Windows 11 with two GPUs on one machine (MSVC 14.51, llvm-mc 23.1.6): pass. All five new fixtures are 4096/4096 exact on the RTX 4080 SUPER. On the Intel UHD 770, |
Conflicts: tests/test_shader_checks.py AI-assisted.
|
Merged main (2ce15a4) again; CPU checks and the PR's GPU tests pass on Radeon RDNA2 iGPU. AI-assisted. |
|
Tested 894070d 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,
Full
|
The same pick_device block as ItsNotRexed#2225, so whichever merges first leaves the other a trivial merge there. AI-assisted.
Conflicts: tests/test_shader_checks.py AI-assisted.
tests/test_shader_checks.py AI-assisted.
tests/test_shader_checks.py AI-assisted.
|
Tested
No game files. AI-assisted (Claude Code). |
Conflicts: runtime/test/vk_texture_test.cpp AI-assisted.
|
Tested All five synthetic texture fixtures passed at AI-assisted verification. |
Requested by Lucas · project thread
Claimed in the coordination issue as: #2078 (comment) (EGEN-GPU-MIMG-SAMPLE)
What and why
Five image ops had only CPU tests; none had a GPU test (
grepofruntime/test/shadersand no open PR or claim for any of them). Each gets a hand-written pixel shader onvk_texture_test's existing textures. Expected words and their derivation are in each.asmheader, worked out from the ISA operand order and the texture contents, not from a run.ps_sample_limage_sample_lps_sample_b_oimage_sample_b_ops_sample_c_lz_oimage_sample_c_lz_ops_gather4_lzimage_gather4_lzps_load_mipimage_load_mipHarness changes in
runtime/test/vk_texture_test.cpp:dref_o(D32 texture with a two-dimensional depth ramp, runsps_sample_c_lz_o, judges its own frame); the existingdref,dref_a16,cubeand--two-mipmodes are unchanged.pick_device, soLEONIDA_VK_DEVICEapplies to this tool as it does tovk_compute_test. Before, it always took the best-ranked device, so a run withLEONIDA_VK_DEVICE=radeonstill ran on the discrete GPU.check.pygetsMIMG_TESTSwith one expected-words function per shader;run_gpu_tests.pyruns them.check.runtakes an optionalcwd.No tests/semantic fixture: the semantic interpreters model no image operations (as for
ps_get_lodandps_texoff, which have none either).No translator bug found; no translator change.
Tested
All five pass 4096/4096 pixels exact on both GPUs, driver names as the tool reports them:
Negative control, one line each in
tools/rdna2spirv.py, then reverted; each fails on both GPUs:image_sample_lLOD operand replaced with 0: 2048 of 4096 pixels differimage_sample_b_obias dropped: 3072 differimage_sample_c_lz_ooffset dropped: 4096 differimage_gather4_lzcomponent forced to 0: 4096 differimage_load_mipmip operand forced to 0: 4096 differExisting
ps_get_lod,ps_texoff*,ps_sample_c_lz*,ps_cube_sample,ps_texture_*andps_gather_*still pass on the Radeon after the harness change.python -m unittest discover -s tests/semantic(1671 tests, OK),tests/semantic/regen_fixtures.py --checkandtests/test_shader_checks.py(newMimgChecks,TOTALupdated) are clean;tests/test_run_gpu_tests.pyandtests/test_run_gpu_tests_paths.pypass.May conflict textually with #826, #2048 and #2136, which also touch
check.py,run_gpu_tests.pyorvk_texture_test.cpp(different regions); whichever lands second rebases.AI-assisted.
Checklist
docs/design.md, with how it was confirmed. (No translator rule changed.)