upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/docs/testing.md
diff options
context:
space:
mode:
authorTreXito <81475944+TreXito@users.noreply.github.com>2026-11-22 22:56:57 +0000
committerTreXito <81475944+TreXito@users.noreply.github.com>2026-11-22 22:56:57 +0000
commit9b28252a69b7fc46cfb86a4b4c009a497b3a36a6 (patch)
tree60c00eae22dca1c0d9179dc3d0e55845be2706f8 /docs/testing.md
parent0f7125e674aada17e33a8812ee9094b6eee1407b (diff)
vk_compute_test: take the validation setup from a shared runtime/test/vk_validation.h
OptInValidation reads LEONIDA_VK_VALIDATION, adds VK_LAYER_KHRONOS_validation, VK_EXT_debug_utils and a messenger to the instance (keeping what the program already enables), counts validation-type errors and turns them into the exit status. vk_compute_test uses it instead of its own copy, so the other shader test programs can opt in with a few lines. docs/testing.md also no longer lists vk_image_fuzz as a program that ignores the variable (it reads it). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'docs/testing.md')
-rw-r--r--docs/testing.md9
1 files changed, 5 insertions, 4 deletions
diff --git a/docs/testing.md b/docs/testing.md
index a84cdf371..a646e0254 100644
--- a/docs/testing.md
+++ b/docs/testing.md
@@ -138,10 +138,11 @@ python -I runtime/test/shaders/mullit_readback.py <out-dir> <harness-directory>
138 138
139For D3D12/runtime tests, `LEONIDA_VK_VALIDATION=1` enables `VK_LAYER_KHRONOS_validation`. When running with validation, set `DISABLE_RTSS_LAYER=1` and `DISABLE_VULKAN_OBS_CAPTURE=1` if MSI Afterburner (RivaTuner) or OBS is installed: their overlay layers can add unsupported swapchain usage, and in an elevated (administrator) terminal the loader ignores `VK_LOADER_LAYERS_DISABLE=~implicit~` (see "Known problems"). 139For D3D12/runtime tests, `LEONIDA_VK_VALIDATION=1` enables `VK_LAYER_KHRONOS_validation`. When running with validation, set `DISABLE_RTSS_LAYER=1` and `DISABLE_VULKAN_OBS_CAPTURE=1` if MSI Afterburner (RivaTuner) or OBS is installed: their overlay layers can add unsupported swapchain usage, and in an elevated (administrator) terminal the loader ignores `VK_LOADER_LAYERS_DISABLE=~implicit~` (see "Known problems").
140 140
141`vk_compute_test` reads `LEONIDA_VK_VALIDATION` too: it prints each validation message to stderr and a validation 141`vk_compute_test`, `vk_bindless_test` and `vk_image_fuzz` read `LEONIDA_VK_VALIDATION` too (`vk_compute_test`
142error makes it exit 1, so `LEONIDA_VK_VALIDATION=1 VK_KHRONOS_VALIDATION_GPUAV_ENABLE=1 python scripts/run_gpu_tests.py` 142through `runtime/test/vk_validation.h`): each validation message goes to stderr and a validation error makes the
143fails every compute test the layer objects to; the program's output ends with "N validation errors". The other shader 143program exit 1, so `LEONIDA_VK_VALIDATION=1 VK_KHRONOS_VALIDATION_GPUAV_ENABLE=1 python scripts/run_gpu_tests.py` fails
144test programs (`vk_harness`, `vk_store_test`, `vk_texture_test`, `vk_sampler_test`, `vk_image_fuzz`) don't read it. 144every compute test the layer objects to; the program's output ends with "N validation errors". The other shader test
145programs (`vk_harness`, `vk_store_test`, `vk_texture_test`, `vk_sampler_test`) don't read it.
145To check one, load the layer through the loader and run it by hand, for example 146To check one, load the layer through the loader and run it by hand, for example
146`VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation VK_KHRONOS_VALIDATION_GPUAV_ENABLE=1 vk_harness vs.spv ps.spv out.raw`. 147`VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation VK_KHRONOS_VALIDATION_GPUAV_ENABLE=1 vk_harness vs.spv ps.spv out.raw`.
147The layer prints its messages to stdout and the program's exit status doesn't change, and `run_gpu_tests.py` shows 148The layer prints its messages to stdout and the program's exit status doesn't change, and `run_gpu_tests.py` shows