ci: run the shader execution tests on lavapipe #251

Merged
adriadam10 merged 1 commit from upstream-pr/251 into main 2026-10-02 07:32:22 +00:00
adriadam10 commented 2026-10-01 19:38:09 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-01T19:38:09Z.


What

Runs the two shader execution tests in CI. agc_driver_mix_precision and agc_driver_sdwa_destination dispatch hand-assembled RDNA through the recompiler and compare every lane with a CPU model (that is how the fma_mix OP_SEL and SDWA high-half bugs were found, #205 #214), but they were not registered in ctest.

  • Moved both to tests/execution/, which is globbed: one test target per .cpp, same names as before (MixPrecision.cpp → agc_driver_mix_precision_tests). They join the existing AGC ctest loop with SKIP_RETURN_CODE 77. A new execution test is then just a new file, with no lines in the shared CMakeLists.txt (the usual conflict point between shader PRs).
  • tests/VulkanTestDevice.hpp: when no Vulkan device can be created the test exits 77 (skipped), so Windows, release builds and machines without a GPU are unaffected. With ANYPS5_REQUIRE_VULKAN set it fails instead.
  • Linux job: installs lavapipe (libvulkan1 mesa-vulkan-drivers) and sets ANYPS5_REQUIRE_VULKAN=1 for ctest, so the tests cannot silently skip there.

This makes it possible to add more recompiler tests that check results, not just that an IrOpcode is emitted.

Not included: agc_driver_mesh_tests and agc_driver_bda_device_tests pass on RADV but crash on lavapipe; agc_driver_recorder_tests and agc_driver_recompiler_tests fail on RADV too (the latter still expects "Recompile not implemented"). Left for separate PRs.

Tested

Linux (CachyOS), ctest on the two tests:

  • RADV (Radeon 660M): pass
  • lavapipe (Mesa 26.2, VK_DRIVER_FILES) with ANYPS5_REQUIRE_VULKAN=1: pass
  • no Vulkan driver: both Skipped
  • no Vulkan driver with ANYPS5_REQUIRE_VULKAN=1: both fail (vkCreateInstance: Vulkan result -9)
  • CI lavapipe (Ubuntu 24.04 Mesa): see this PR's checks

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed in TechnicalDebt
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source
  • Generic behaviour, not specific to one title
  • Depends on: none
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4708663498 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/251). Originally posted by [adriadam10](https://github.com/adriadam10) on 2026-10-01T19:38:09Z. --- ### What Runs the two shader execution tests in CI. `agc_driver_mix_precision` and `agc_driver_sdwa_destination` dispatch hand-assembled RDNA through the recompiler and compare every lane with a CPU model (that is how the fma_mix OP_SEL and SDWA high-half bugs were found, #205 #214), but they were not registered in ctest. - Moved both to `tests/execution/`, which is globbed: one test target per `.cpp`, same names as before (`MixPrecision.cpp` → `agc_driver_mix_precision_tests`). They join the existing AGC ctest loop with `SKIP_RETURN_CODE 77`. A new execution test is then just a new file, with no lines in the shared `CMakeLists.txt` (the usual conflict point between shader PRs). - `tests/VulkanTestDevice.hpp`: when no Vulkan device can be created the test exits 77 (skipped), so Windows, release builds and machines without a GPU are unaffected. With `ANYPS5_REQUIRE_VULKAN` set it fails instead. - Linux job: installs lavapipe (`libvulkan1 mesa-vulkan-drivers`) and sets `ANYPS5_REQUIRE_VULKAN=1` for ctest, so the tests cannot silently skip there. This makes it possible to add more recompiler tests that check results, not just that an `IrOpcode` is emitted. Not included: `agc_driver_mesh_tests` and `agc_driver_bda_device_tests` pass on RADV but crash on lavapipe; `agc_driver_recorder_tests` and `agc_driver_recompiler_tests` fail on RADV too (the latter still expects "Recompile not implemented"). Left for separate PRs. ### Tested Linux (CachyOS), ctest on the two tests: - RADV (Radeon 660M): pass - lavapipe (Mesa 26.2, `VK_DRIVER_FILES`) with `ANYPS5_REQUIRE_VULKAN=1`: pass - no Vulkan driver: both Skipped - no Vulkan driver with `ANYPS5_REQUIRE_VULKAN=1`: both fail (`vkCreateInstance: Vulkan result -9`) - CI lavapipe (Ubuntu 24.04 Mesa): see this PR's checks ### Checklist - [x] Based on current `main`; no other open PR implements the same functions - [x] One topic per PR; follow-ups go in a new PR - [x] No comments in code except [technical debt](https://github.com/boykopovar/AnyPS5/blob/main/docs/dev/CONVENTIONS.md) - [x] Unimplemented paths throw (`NotImplemented_nid_no_patch`); silent stubs are listed in [TechnicalDebt](https://github.com/boykopovar/AnyPS5/blob/main/docs/dev/TechnicalDebt.md#silent-stubs) - [x] No notes, investigation `.md` files or images added to the repository (attach them to this PR) - [x] New third-party code is a submodule built from source - [x] Generic behaviour, not specific to one title - [x] Depends on: none - [x] AI-assisted: yes
github-actions[bot] commented 2026-10-02 00:48:09 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-02T00:48:09Z.


Other open pull requests touch the same code. Merging one will break the other, or both implement the same thing. If this one builds on them, list them in Depends on.

Pull request Conflicting files (lines on main) Same exports Same new files
#304 core/libs/prx/libSceAgcDriver/CMakeLists.txt L395-417
#305 core/libs/prx/libSceAgcDriver/CMakeLists.txt L395-417
<!-- greyfinch-sync:boykopovar/AnyPS5:comment:5943476881 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/251#issuecomment-5943476881). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-10-02T00:48:09Z. --- <!-- pr-overlap --> Other open pull requests touch the same code. Merging one will break the other, or both implement the same thing. If this one builds on them, list them in **Depends on**. | Pull request | Conflicting files (lines on `main`) | Same exports | Same new files | |---|---|---|---| | #304 | `core/libs/prx/libSceAgcDriver/CMakeLists.txt` [L395-417](https://github.com/boykopovar/AnyPS5/blob/fbfe6bb13bd4538088a155db7df7df9d57bd5a18/core/libs/prx/libSceAgcDriver/CMakeLists.txt#L395-L417) | | | | #305 | `core/libs/prx/libSceAgcDriver/CMakeLists.txt` [L395-417](https://github.com/boykopovar/AnyPS5/blob/fbfe6bb13bd4538088a155db7df7df9d57bd5a18/core/libs/prx/libSceAgcDriver/CMakeLists.txt#L395-L417) | | |
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5!251
No description provided.