Skip to content

docs/testing, gs_tri, pe_shader_containers: Linux VK_LOADER_DRIVERS_SELECT and comment fixes - #8775

Open
Fuwia wants to merge 1 commit into
ItsNotRexed:mainfrom
Fuwia:docs/linux-vk-loader-and-comment-fixes
Open

Fuwia wants to merge 1 commit into
ItsNotRexed:mainfrom
Fuwia:docs/linux-vk-loader-and-comment-fixes

Conversation

@Fuwia

@Fuwia Fuwia commented Nov 23, 2026

Copy link
Copy Markdown

Resolves three unclaimed documentation/comment findings from #8344 (reported by @wavehs and @ne1i; claimed in #8683 (comment)):

  1. docs/testing.md:534 (## Choosing the GPU): Add the Linux Vulkan loader ICD glob patterns (*radeon* and *nvidia*) alongside the Windows ones (*amd* and nv-vk*). On Linux the Vulkan loader matches the ICD JSON basename (radeon_icd.*.json, nvidia_icd.json; scripts/bench_wave64.py already uses *amd*,*radeon*), so VK_LOADER_DRIVERS_SELECT=nv-vk* matches no ICD and fails with VK_ERROR_INCOMPATIBLE_DRIVER (-9).
  2. runtime/test/shaders/gs_tri.asm:3: Update the header Run: command from nonexistent vs_attrs.spv to vs_tri.spv, matching scripts/run_gpu_tests.py:1533.
  3. tools/pe_shader_containers.py:62: Update the parse_container docstring reference from tools/fspx_unpack.parts() to tools/fspx_unpack.dxbc_parts().

Testing

  • Environment: Linux x86_64 (AMD Ryzen 5 3600, NVIDIA GeForce RTX 3060 driver 620.70.06 + Mesa llvmpipe LLVM 23.1.4, Vulkan 1.4.357, CPython 3.14.10).
  • Verified VK_LOADER_DRIVERS_SELECT='*nvidia*' vulkaninfo --summary selects NVIDIA GeForce RTX 3060 on Linux while VK_LOADER_DRIVERS_SELECT='nv-vk*' vulkaninfo --summary rejects nvidia_icd.json with ERROR_INCOMPATIBLE_DRIVER.
  • python3 -I tests/test_pe_shader_containers.py (19 passed)
  • python3 -I tests/test_fspx_unpack.py (34 passed, 1 skipped)
  • python3 -m compileall -q make_game.py tools tests
  • python3 -I scripts/check_no_game_data.py docs/testing.md runtime/test/shaders/gs_tri.asm tools/pe_shader_containers.py

AI-assisted. No game files were used.

@Digit4w

Digit4w commented Nov 23, 2026

Copy link
Copy Markdown

Reviewed 6e6ba479: looks good. I checked the Windows half of the new docs/testing.md sentence on a machine with one AMD and one NVIDIA GPU. The PR's own test was Linux only.

Windows 11 build 26200.9974, AMD Radeon(TM) Graphics (gfx1036 iGPU, AMD 25.10.42), RTX 4070 SUPER (NVIDIA 621.01), Vulkan loader from SDK 1.4.363.0, vulkaninfo --summary:

VK_LOADER_DRIVERS_SELECT Devices
unset RTX 4070 SUPER, AMD Radeon(TM) Graphics
*amd* AMD Radeon(TM) Graphics only
nv-vk* RTX 4070 SUPER only
*radeon* none: Found no drivers!, ERROR_INCOMPATIBLE_DRIVER
*nvidia* none: Found no drivers!, ERROR_INCOMPATIBLE_DRIVER

So the patterns differ by OS in both directions. The Linux ones select nothing on Windows, just as nv-vk* selects nothing on Linux, and "on Windows (... on Linux)" is the right way to say it.

The other two edits match the code on main (867d922f):

  • gs_tri.asm: run_gpu_tests.py builds vs_tri.spv (line 936), and nothing in the repository builds or names vs_attrs.spv.
  • pe_shader_containers.py: tools/fspx_unpack.py has dxbc_parts() (line 84) and no parts().

AI-assisted (Claude).

@haayden

haayden commented Nov 23, 2026

Copy link
Copy Markdown

Tested 6e6ba47 on Windows 11, RTX 5070 Ti (NVIDIA 621.14), MSVC 14.44 RelWithDebInfo: pass

Comment/doc-only change, so this checks that the new text matches what actually runs:

  • python -I scripts/run_gpu_tests.py --build build-B --llvm-mc "wsl -d Ubuntu -e /usr/lib/llvm-21/bin/llvm-mc" --assembler python --filter gs_tri --require-pass (vk_harness etc. built from this head, Vulkan-Headers fetch): PASS gs_tri 4096/4096 pixels exact on head and on base 867d922f0 (passes on both, as expected for a comment change).
  • The corrected header is right: run_gpu_tests.py draws gs_tri with vs_tri.spv + fs_loc1.spv (the name == "gs_tri" branch), and no vs_attrs shader exists anywhere in the tree, so the old run line pointed at a file nobody can build.
  • tools/fspx_unpack.py defines dxbc_parts() and no parts(), so the docstring fix in pe_shader_containers.py is correct.
  • VK_LOADER_DRIVERS_SELECT=nv-vk* + vulkaninfo --summary on this Windows box still selects the RTX 5070 Ti (621.14), matching the Windows example; the Linux names (*radeon*, *nvidia*) were not checked here (no Linux GPU).
  • pytest tests/test_gs_primitive_readback.py tests/test_spirv_gs_to_compute.py tests/test_pe_shader_containers.py: 21 passed, 26 skipped (skips need SPIRV-Tools on PATH, which this machine does not have).

AI-assisted (Claude Code). Synthetic tests only, no game files.

@comtek21516

Copy link
Copy Markdown

Tested 6e6ba4794 merged onto main at 867d922f0 on Quadro RTX 4000 (Turing, subgroup 32..32), NVIDIA 615.71.09, Ubuntu 22.04.5 (kernel 5.15), g++ 13.4, llvm-mc 21.1.8, Vulkan SDK 1.4.363.1, Python 3.12.16: pass, and the Linux selector in the new sentence checks out on this host.

vulkaninfo --summary here, where the loader has nvidia_icd.json and Mesa's lvp, radeon, intel and virtio manifests:

VK_LOADER_DRIVERS_SELECT devices listed
unset Quadro RTX 4000, llvmpipe
*nvidia* (the new Linux form) Quadro RTX 4000
nv-vk* (the Windows form) none
*radeon* none (no AMD GPU in this machine)

So on Linux nv-vk* selects nothing and *nvidia* selects the NVIDIA driver alone, as the doc now says. The *radeon* half is not shown by this machine.

No game files. AI-assisted (Claude Code).

@lordra9-svg

Copy link
Copy Markdown

Independent check of 6e6ba4794705f340784f5022c19950b0db4abff1 on Linux (Bazzite 45), RADV Mesa 26.3.1, Vulkan 1.4.363, Python 3.15.2. The machine has radeon_icd.*.json and lvp_icd.*.json in /usr/share/vulkan/icd.d/, so the loader/ICD naming claim in item 1 is directly testable:

selector result
VK_LOADER_DRIVERS_SELECT='*radeon*' both AMD devices (RX 7800 XT, Ryzen 7 7700 iGPU)
VK_LOADER_DRIVERS_SELECT='*amd*' vkCreateInstance: Found no drivers! / ERROR_INCOMPATIBLE_DRIVER
VK_LOADER_DRIVERS_SELECT='nv-vk*' vkCreateInstance: Found no drivers! / ERROR_INCOMPATIBLE_DRIVER

So the added Linux patterns are right and the old ones do match no ICD here.

  • Item 2: gs_tri.asm now says vk_harness vs_tri.spv, and scripts/run_gpu_tests.py uses vs_tri.spv (line 936 on main 867d922f0; the body says 1533, so that line reference is stale, but the name is the one the runner uses).
  • Item 3: tools/fspx_unpack.py defines dxbc_parts (line 84) and no parts, matching the new docstring.

python3 -I tests/test_pe_shader_containers.py: OK. python3 -I tests/test_fspx_unpack.py: OK (1 skipped). No game files.

AI-assisted (OpenCode).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants