shader: accept SDWA for VOP1 bit operations #360

Manually merged
github merged 1 commit from gh-pr/360/head into gh-pr/360/base 2026-11-26 09:17:39 +00:00
Owner

@⁠Techx3 on GitHub · 2026-08-28 22:03 UTC · original
Techx3:techx3/vop1-sdwa-bit-ops → main · +50 −0 · 2 files · 1 commits · merged 2026-08-29 06:28 UTC

Summary

Accept the documented VOP1 SDWA encoding for V_NOT_B32 and V_FFBL_B32.

Both operations already had decoder, IR, and SPIR-V implementations. They were rejected only because the VOP1 SDWA validation table did not list them.

Changes

  • allow byte, word, and full-dword SDWA source selectors for both operations
  • keep source modifiers and partial destinations disabled
  • add captured binary regressions for:
    • _ffbl_b32 v16, v2.word1
    • _not_b32 v2, v2.byte0

The tests verify the decoded selector, sub-dword extraction IR, emitted SPIR-V operation, and final GPU result.

Validation

  • ctest -R ^shader_cfg$ --output-on-failure
  • ctest -R ^shader_recompiler_compute$ --output-on-failure
  • Release builds: shader_recompiler_compute_tests, kyty_emulator

Scope

Isolated from the compatibility work authored by SueryRD. No unrelated VOP2 rule, ALU lowering, or runtime changes are included.

**@⁠Techx3** on GitHub · 2026-08-28 22:03 UTC · [original](https://github.com/KytyPS5/KytyPS5/pull/360) `Techx3:techx3/vop1-sdwa-bit-ops` → `main` · +50 −0 · 2 files · 1 commits · merged 2026-08-29 06:28 UTC ## Summary Accept the documented VOP1 SDWA encoding for V_NOT_B32 and V_FFBL_B32. Both operations already had decoder, IR, and SPIR-V implementations. They were rejected only because the VOP1 SDWA validation table did not list them. ## Changes - allow byte, word, and full-dword SDWA source selectors for both operations - keep source modifiers and partial destinations disabled - add captured binary regressions for: - _ffbl_b32 v16, v2.word1 - _not_b32 v2, v2.byte0 The tests verify the decoded selector, sub-dword extraction IR, emitted SPIR-V operation, and final GPU result. ## Validation - ctest -R ^shader_cfg$ --output-on-failure - ctest -R ^shader_recompiler_compute$ --output-on-failure - Release builds: shader_recompiler_compute_tests, kyty_emulator ## Scope Isolated from the compatibility work authored by SueryRD. No unrelated VOP2 rule, ALU lowering, or runtime changes are included.
Allow byte, word, and full-dword SDWA source selection for V_NOT_B32 and V_FFBL_B32. Add captured instruction tests that verify decoding, IR extraction, SPIR-V generation, and runtime results.

Co-authored-by: SueryRD <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 09:17:38 +00:00
github manually merged commit 0135faf126 into gh-pr/360/base 2026-11-26 09:17:39 +00:00
This discussion has been locked. Commenting is limited to contributors.
No description provided.