graphics: make fragment shader barycentrics optional #959

Closed
github-bot wants to merge 3 commits from gh-pr/959/head into gh-pr/959/base
Owner

@⁠Aryansh1520 on GitHub · 2026-10-01 14:46 UTC · original
Aryansh1520:fix/gpu-device-requirements → main · +143 −54 · 10 files · 3 commits · closed without merging

Fixes #489
Fixes #1059

Problem

VK_KHR_fragment_shader_barycentric was a hard device requirement. RADV only exposes it on GFX10.3+ (RDNA2), so older AMD GPUs were rejected with Could not find suitable device. The log attached to #489 shows the AMD BC-250 (RADV GFX1013, Mesa 26.2) passing every feature check and failing only on the missing extension. Other pre-RDNA2 RADV reports in that thread (e.g. RX 580) likely hit the same requirement.

Fix

Device setup (vulkanWindow.cpp): the extension is requested only when it is available, in the same way as the other optional extensions (provoking vertex, mesh shader, ...). Its feature struct is chained into device creation only when supported, and the result is stored in GraphicContext::fragment_shader_barycentric_enabled. Devices without it log a warning instead of being rejected.

Recompiler: ordinary V_INTERP_P1/P2 interpolation never needed barycentrics. They are only needed by pixel shaders that read raw vertex attributes (V_INTERP_MOV of a smooth or custom parameter) or that read the barycentric VGPRs directly. The new CompileOptions::fragment_shader_barycentric flag, passed through to CollectShaderInfo, changes how those shaders compile when the extension is missing:

  • Inputs stay ordinary interpolated inputs, not PerVertexKHR.
  • P0 reads the interpolated value, and the P10/P20 deltas read as zero. Shaders that rebuild p0 + i*p10 + j*p20 therefore still get the interpolated attribute.
  • The BaryCoord* builtins are not declared and read as 0.

With the extension available, the generated SPIR-V is unchanged.

macOS: the extension is now enabled when MoltenVK exposes it. Before this change it was never enabled there, even though the recompiler could still emit the capability.

Testing

  • New TestVintrpMovWithoutHostBarycentrics in shader_cfg_tests. It checks, for standard and custom parameters, that there is no FragmentBarycentricKHR, no PerVertexKHR, no BaryCoordKHR and no delta subtraction, and that the SPIR-V validates. I confirmed it fails when barycentrics are enabled. The rest of shader_cfg_tests passes.
  • Linux (RTX 5060), with the extension hidden locally to simulate an unsupported device:
    • The device is created and the warning is printed.
    • God of War Sons of Sparta (PPSA28997) reaches the menu and renders normally. None of its shaders take the fallback.
    • Subnautica (PPSA02453) boots without errors. 12 of its pixel shaders take the fallback, all P0 reads of smooth parameters. I have not compared its rendering against a run with barycentrics.
  • A normal run on the same machine still enables barycentrics.
  • Not tested on real pre-RDNA2 AMD hardware, Intel or macOS. #1059 (Intel Iris Xe, TGL GT2) shows fragmentShaderBarycentric as the only failed check on that GPU, so this should fix it. #451 (also Iris Xe) has no log, but is likely the same failure.

Platform impact

  • Devices with the extension (Linux/Windows/macOS): generated SPIR-V is unchanged. With barycentrics enabled, every mode < 2 interpolation read marks its input per-vertex, and that flag is never cleared, so the new zero-delta path in EmitInterpolationParameter is unreachable.
  • Windows: same code path as Linux; no platform-specific changes.
  • macOS: before this PR the extension was never enabled on MoltenVK, but the recompiler could still emit FragmentBarycentricKHR/PerVertexKHR. Now it is enabled only when MoltenVK reports it, and otherwise the shader takes the fallback, so no unsupported capability is emitted. The existing macOS paths (depth clip, color write, depth bounds) are untouched.
  • Rebased onto current main (after 64-bit image atomics and the Vulkan11Features probe); both are kept alongside the optional barycentric feature chain.
**@⁠Aryansh1520** on GitHub · 2026-10-01 14:46 UTC · [original](https://github.com/KytyPS5/KytyPS5/pull/959) `Aryansh1520:fix/gpu-device-requirements` → `main` · +143 −54 · 10 files · 3 commits · closed without merging Fixes #489 Fixes #1059 ## Problem `VK_KHR_fragment_shader_barycentric` was a hard device requirement. RADV only exposes it on GFX10.3+ (RDNA2), so older AMD GPUs were rejected with `Could not find suitable device`. The log attached to #489 shows the AMD BC-250 (RADV GFX1013, Mesa 26.2) passing every feature check and failing only on the missing extension. Other pre-RDNA2 RADV reports in that thread (e.g. RX 580) likely hit the same requirement. ## Fix **Device setup** (`vulkanWindow.cpp`): the extension is requested only when it is available, in the same way as the other optional extensions (provoking vertex, mesh shader, ...). Its feature struct is chained into device creation only when supported, and the result is stored in `GraphicContext::fragment_shader_barycentric_enabled`. Devices without it log a warning instead of being rejected. **Recompiler**: ordinary `V_INTERP_P1/P2` interpolation never needed barycentrics. They are only needed by pixel shaders that read raw vertex attributes (`V_INTERP_MOV` of a smooth or custom parameter) or that read the barycentric VGPRs directly. The new `CompileOptions::fragment_shader_barycentric` flag, passed through to `CollectShaderInfo`, changes how those shaders compile when the extension is missing: - Inputs stay ordinary interpolated inputs, not `PerVertexKHR`. - P0 reads the interpolated value, and the P10/P20 deltas read as zero. Shaders that rebuild `p0 + i*p10 + j*p20` therefore still get the interpolated attribute. - The `BaryCoord*` builtins are not declared and read as 0. With the extension available, the generated SPIR-V is unchanged. **macOS**: the extension is now enabled when MoltenVK exposes it. Before this change it was never enabled there, even though the recompiler could still emit the capability. ## Testing - New `TestVintrpMovWithoutHostBarycentrics` in `shader_cfg_tests`. It checks, for standard and custom parameters, that there is no `FragmentBarycentricKHR`, no `PerVertexKHR`, no `BaryCoordKHR` and no delta subtraction, and that the SPIR-V validates. I confirmed it fails when barycentrics are enabled. The rest of `shader_cfg_tests` passes. - Linux (RTX 5060), with the extension hidden locally to simulate an unsupported device: - The device is created and the warning is printed. - God of War Sons of Sparta (PPSA28997) reaches the menu and renders normally. None of its shaders take the fallback. - Subnautica (PPSA02453) boots without errors. 12 of its pixel shaders take the fallback, all P0 reads of smooth parameters. I have not compared its rendering against a run with barycentrics. - A normal run on the same machine still enables barycentrics. - Not tested on real pre-RDNA2 AMD hardware, Intel or macOS. #1059 (Intel Iris Xe, TGL GT2) shows `fragmentShaderBarycentric` as the only failed check on that GPU, so this should fix it. #451 (also Iris Xe) has no log, but is likely the same failure. ## Platform impact - **Devices with the extension (Linux/Windows/macOS):** generated SPIR-V is unchanged. With barycentrics enabled, every `mode < 2` interpolation read marks its input per-vertex, and that flag is never cleared, so the new zero-delta path in `EmitInterpolationParameter` is unreachable. - **Windows:** same code path as Linux; no platform-specific changes. - **macOS:** before this PR the extension was never enabled on MoltenVK, but the recompiler could still emit `FragmentBarycentricKHR`/`PerVertexKHR`. Now it is enabled only when MoltenVK reports it, and otherwise the shader takes the fallback, so no unsupported capability is emitted. The existing macOS paths (depth clip, color write, depth bounds) are untouched. - Rebased onto current `main` (after 64-bit image atomics and the `Vulkan11Features` probe); both are kept alongside the optional barycentric feature chain.
VK_KHR_fragment_shader_barycentric was a hard device requirement, but
RADV only exposes it on GFX10.3+ (RDNA2), so older AMD GPUs such as the
BC-250 (GFX1013) were rejected with "Could not find suitable device".

Enable the extension only when the device supports it, like the other
optional extensions, and record the result in GraphicContext. The
recompiler only needs barycentrics for pixel shaders that read raw
vertex attributes (V_INTERP_MOV of a smooth or custom parameter) or the
barycentric VGPRs; ordinary V_INTERP_P1/P2 interpolation never did.
Without host support those inputs stay ordinary interpolated inputs:
P0 reads the interpolated value and the P10/P20 deltas read as zero, so
shaders that rebuild p0 + i * p10 + j * p20 still get the interpolated
attribute. The barycentric builtins are left undeclared and read as 0.

macOS now also enables the extension when MoltenVK exposes it; before,
it was never enabled there although shaders could still require it.

Fixes #489
Host crash reports printed only a raw PC, so a fault inside a GPU driver or
system DLL looked the same as one inside the emulator. Print the module path
and offset of the faulting PC (GetModuleHandleEx on Windows, dladdr elsewhere).
The fault context (registers, module, code bytes, stack) was printed with
raw printf, so with the printf output set to File only the final error line
reached the log file. Build it as one string and emit it with
Log::WriteFatal, which writes to both the console and the log file.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 09:38:21 +00:00
github-bot closed this pull request 2026-11-26 09:38:21 +00:00
Author
Owner

@⁠coderabbitai[bot] on GitHub · 2026-10-01 14:56 UTC · original · edited 2026-10-07 14:19 UTC

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Repository: KytyPS5/KytyPS5/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 0259b56d-d4bb-4653-81d6-67295bf9fa6f
📥 Commits

Reviewing files that changed from the base of the PR and between cff346b5c3 and 074805a392.

📒 Files selected for processing (1)
  • src/loader/runtimeLinker.cpp

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.


📝 Walkthrough

Walkthrough

Vulkan fragment-shader barycentric support is optional during device selection and creation. The detected capability is stored in the graphics context and passed through the pipeline cache to shader compilation. Pixel shader input collection and SPIR-V emission account for the capability, and a regression test checks generated SPIR-V when host barycentrics are disabled. Guest fault reports now include host module details and use fatal logging.

Suggested reviewers: ew-sudo

Priority: ➖ Normal

Change: Bug fix · Severity of issue fixed: Medium

Merge Risk: ⚪ Minimal · up to 07480

No identified issue blocks merging. The changed fault report still reaches stdout before the process exits.

Security Architecture Review

Security architecture risk: 🔵 Low · up to cff34

The change supports more GPUs while retaining device capability checks. No added access or privilege was identified, but the available tests do not establish behavior across the newly supported hardware.

Retained concerns
No architecture-level concerns identified.

Security review details

Security Blast Radius

  • inferred — The changed exposure is local guest graphics execution on additional host GPU configurations. The inspected path does not add a remote entrypoint or grant guest code control over host capability selection.

Trust Boundaries and Controls

  • observed — Guest shader instructions influence interpolation operations, but host Vulkan discovery determines whether barycentrics may be used. Enablement requires both extension availability and feature support, and the device feature chain is gated by that result.

Resilience and Maintainability Implications

  • inferred — Normal cache reuse remains capability-consistent because ProgramCache captures device capability once and is owned by the corresponding rendering context. Cache hits therefore reuse shaders compiled under the same captured configuration, rather than sharing permutations across differently configured devices.
🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Out of Scope Changes check ⚠️ Warning src/loader/runtimeLinker.cpp adds host-module lookup and changes guest fault reporting. This change does not support optional barycentric device setup or shader fallback for [#489] or [#1059]. Remove the runtimeLinker.cpp host-module and fault-reporting changes from this pull request, or submit them in a separate pull request.
Docstring Coverage ⚠️ Warning Docstring coverage is 20.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 20 functions across 9 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely describes the main change: making fragment shader barycentric support optional.
Description check ✅ Passed The description directly explains the device setup change, recompiler fallback behavior, platform impact, linked issues, and testing for the changeset.
Linked Issues check ✅ Passed The changes address both active linked issues. [#489] Device selection no longer requires fragmentShaderBarycentric; device creation enables it only when available and records the capability. [#1059…
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Autopilot is currently an internal CodeRabbit preview.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

**@⁠coderabbitai[bot]** on GitHub · 2026-10-01 14:56 UTC · [original](https://github.com/KytyPS5/KytyPS5/pull/959#issuecomment-5934043652) · edited 2026-10-07 14:19 UTC <!-- This is an auto-generated comment: summarize by coderabbit.ai --> <!-- review_stack_entry_start --> <a href="https://app.coderabbit.ai/change-stack/KytyPS5/KytyPS5/pull/959?scope=ghh_OusAJGA4HG8ljoOV0wJvVx8NmnZIjc2DdjmxOu0xZWA&amp;cs_source=review_comment"><img src="https://storage.googleapis.com/coderabbit_public_assets/review-stack-in-coderabbit-ui-dark.svg?v=2" alt="Review in Change Stack →" width="220" height="32"></a> <!-- review_stack_entry_end --> <!-- recent_review_start --> No actionable comments were generated in the recent review. 🎉 <details> <summary>ℹ️ Recent review info</summary> <details> <summary>⚙️ Run configuration</summary> - **Configuration used**: Repository: KytyPS5/KytyPS5/.coderabbit.yaml - **Review profile**: CHILL - **Plan**: Advanced - **Run ID**: `0259b56d-d4bb-4653-81d6-67295bf9fa6f` </details> <details> <summary>📥 Commits</summary> Reviewing files that changed from the base of the PR and between cff346b5c318469819100d0c9d839159406921c3 and 074805a3927ccb06f4e88c0e37892ef679d2e2d6. </details> <details> <summary>📒 Files selected for processing (1)</summary> * `src/loader/runtimeLinker.cpp` </details> **Included review availability:** This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review. </details> --- <!-- recent_review_end --> <!-- walkthrough_start --> <details> <summary>📝 Walkthrough</summary> ## Walkthrough Vulkan fragment-shader barycentric support is optional during device selection and creation. The detected capability is stored in the graphics context and passed through the pipeline cache to shader compilation. Pixel shader input collection and SPIR-V emission account for the capability, and a regression test checks generated SPIR-V when host barycentrics are disabled. Guest fault reports now include host module details and use fatal logging. **Suggested reviewers:** `ew-sudo` </details> <!-- walkthrough_end --> <!-- change_assessment_start --> **Priority:** ➖ Normal <!-- change_assessment_commit:"074805a3927ccb06f4e88c0e37892ef679d2e2d6" --> **Change:** Bug fix · **Severity of issue fixed:** Medium <!-- change_assessment_end --> <!-- final_review_risk_start --> **Merge Risk:** _⚪ Minimal_ · up to `07480` <!-- final_review_risk_coverage:{"sourceCommitId":"074805a3927ccb06f4e88c0e37892ef679d2e2d6","coveredCommitId":"074805a3927ccb06f4e88c0e37892ef679d2e2d6","kind":"reviewed"} --> No identified issue blocks merging. The changed fault report still reaches stdout before the process exits. <!-- final_review_risk_end --> <!-- architecture_review_start --> ### Security Architecture Review **Security architecture risk:** _🔵 Low_ · up to `cff34` The change supports more GPUs while retaining device capability checks. No added access or privilege was identified, but the available tests do not establish behavior across the newly supported hardware. **Retained concerns** No architecture-level concerns identified. <details> <summary>Security review details</summary> **Security Blast Radius** - _inferred_ — The changed exposure is local guest graphics execution on additional host GPU configurations. The inspected path does not add a remote entrypoint or grant guest code control over host capability selection. **Trust Boundaries and Controls** - _observed_ — Guest shader instructions influence interpolation operations, but host Vulkan discovery determines whether barycentrics may be used. Enablement requires both extension availability and feature support, and the device feature chain is gated by that result. **Resilience and Maintainability Implications** - _inferred_ — Normal cache reuse remains capability-consistent because ProgramCache captures device capability once and is owned by the corresponding rendering context. Cache hits therefore reuse shaders compiled under the same captured configuration, rather than sharing permutations across differently configured devices. </details> <!-- architecture_review_end --> <!-- pre_merge_checks_walkthrough_start --> <details> <summary>🚥 Pre-merge checks | ✅ 3 | ❌ 2</summary> ### ❌ Failed checks (2 warnings) | Check name | Status | Explanation | Resolution | | :------------------------: | :--------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :---------------------------------------------------------------------------------------------------------------------------------------- | | Out of Scope Changes check | ⚠️ Warning | `src/loader/runtimeLinker.cpp` adds host-module lookup and changes guest fault reporting. This change does not support optional barycentric device setup or shader fallback for [`#489`] or [`#1059`]. | Remove the `runtimeLinker.cpp` host-module and fault-reporting changes from this pull request, or submit them in a separate pull request. | | Docstring Coverage | ⚠️ Warning | Docstring coverage is 20.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 20 functions across 9 files. | Write docstrings for the functions missing them to satisfy the coverage threshold. | <details> <summary>✅ Passed checks (3 passed)</summary> | Check name | Status | Explanation | | :-----------------: | :------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | Title check | ✅ Passed | The title clearly and concisely describes the main change: making fragment shader barycentric support optional. | | Description check | ✅ Passed | The description directly explains the device setup change, recompiler fallback behavior, platform impact, linked issues, and testing for the changeset. | | Linked Issues check | ✅ Passed | The changes address both active linked issues. [`#489`] Device selection no longer requires `fragmentShaderBarycentric`; device creation enables it only when available and records the capability. [`#1059`… | </details> </details> <!-- pre_merge_checks_walkthrough_end --> <!-- autopilot:start --> - [ ] <!-- {"checkboxId":"2708ad07-9f24-4260-9c11-7dc76a49f2e3"} --> <strong title="Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts">Autopilot</strong> · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts > Autopilot is currently an internal CodeRabbit preview. <!-- autopilot:end --> <!-- tips_start --> --- Thanks for using [CodeRabbit](https://coderabbit.ai?utm_source=oss&utm_medium=github&utm_campaign=KytyPS5/KytyPS5&utm_content=959)! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. <details> <summary>❤️ Share</summary> - [X](https://twitter.com/intent/tweet?text=I%20just%20used%20%40coderabbitai%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20the%20proprietary%20code.%20Check%20it%20out%3A&url=https%3A//coderabbit.ai) - [Mastodon](https://mastodon.social/share?text=I%20just%20used%20%40coderabbitai%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20the%20proprietary%20code.%20Check%20it%20out%3A%20https%3A%2F%2Fcoderabbit.ai) - [Reddit](https://www.reddit.com/submit?title=Great%20tool%20for%20code%20review%20-%20CodeRabbit&text=I%20just%20used%20CodeRabbit%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20proprietary%20code.%20Check%20it%20out%3A%20https%3A//coderabbit.ai) - [LinkedIn](https://www.linkedin.com/sharing/share-offsite/?url=https%3A%2F%2Fcoderabbit.ai&mini=true&title=Great%20tool%20for%20code%20review%20-%20CodeRabbit&summary=I%20just%20used%20CodeRabbit%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20proprietary%20code) </details> <sub>Comment `@coderabbitai help` to get the list of available commands.</sub> <!-- tips_end -->
Author
Owner

@⁠AdelRdp2024 on GitHub · 2026-10-03 21:35 UTC · original

Thanks for this fix. I’m also affected by the Could not find suitable device issue on an older NVIDIA GPU (GTX 980).

It would be great if this PR could be merged into main so users with older GPUs can test it. I’d be happy to test a Windows build of this commit on my GTX 980 and report the result.

**@⁠AdelRdp2024** on GitHub · 2026-10-03 21:35 UTC · [original](https://github.com/KytyPS5/KytyPS5/pull/959#issuecomment-5973715574) Thanks for this fix. I’m also affected by the Could not find suitable device issue on an older NVIDIA GPU (GTX 980). It would be great if this PR could be merged into main so users with older GPUs can test it. I’d be happy to test a Windows build of this commit on my GTX 980 and report the result.
Author
Owner

@⁠salvatorelobianco on GitHub · 2026-10-11 13:28 UTC · original

Hi, I can help test this on real RDNA 1 hardware.

My setup:

  • GPU: AMD Radeon RX 5700 XT (RDNA 1)
  • CPU: Ryzen 5 3600
  • OS: Windows 11

With the official build KytyPS5-2026-10-11-16a7fe6 the emulator exits at startup with:

Could not find suitable device:
AMD Radeon RX 5700 XT: fragmentShaderBarycentric is not supported in vulkanWindow.cpp:980

This is the same error as in #1340, #1364 and #1416. As far as I can tell, no one has tested this PR on an RDNA 1 GPU yet, so I'd be happy to try a build that includes it and report back with logs, both for startup and for any games that hit the shader fallback path.

Is there an artifact or a branch I can test? Thanks!

**@⁠salvatorelobianco** on GitHub · 2026-10-11 13:28 UTC · [original](https://github.com/KytyPS5/KytyPS5/pull/959#issuecomment-6109528546) Hi, I can help test this on real RDNA 1 hardware. My setup: - GPU: AMD Radeon RX 5700 XT (RDNA 1) - CPU: Ryzen 5 3600 - OS: Windows 11 With the official build KytyPS5-2026-10-11-16a7fe6 the emulator exits at startup with: Could not find suitable device: AMD Radeon RX 5700 XT: fragmentShaderBarycentric is not supported in vulkanWindow.cpp:980 This is the same error as in #1340, #1364 and #1416. As far as I can tell, no one has tested this PR on an RDNA 1 GPU yet, so I'd be happy to try a build that includes it and report back with logs, both for startup and for any games that hit the shader fallback path. Is there an artifact or a branch I can test? Thanks!
Author
Owner

@⁠salvatorelobianco on GitHub · 2026-10-11 13:33 UTC · original

Hi, I can help test this on real RDNA 1 hardware.

My setup:

* GPU: AMD Radeon RX 5700 XT (RDNA 1)

* CPU: Ryzen 5 3600

* OS: Windows 11

With the official build KytyPS5-2026-10-11-16a7fe6 the emulator exits at startup with:

Could not find suitable device: AMD Radeon RX 5700 XT: fragmentShaderBarycentric is not supported in vulkanWindow.cpp:980

This is the same error as in #1340, #1364 and #1416. As far as I can tell, no one has tested this PR on an RDNA 1 GPU yet, so I'd be happy to try a build that includes it and report back with logs, both for startup and for any games that hit the shader fallback path.

Is there an artifact or a branch I can test? Thanks!

Update: I tested the Windows artifact from this PR's CI (source build 356e980) on real RDNA 1 hardware.

Setup:

  • GPU: AMD Radeon RX 5700 XT (RDNA 1)
  • CPU: Ryzen 5 3600
  • OS: Windows 11

Result:

  • The "Could not find suitable device ... fragmentShaderBarycentric is not supported" error is gone and the emulator now creates the device.
  • The expected warning is logged: "fragmentShaderBarycentric is unavailable. Pixel shaders that read raw vertex attributes will use interpolated values, which may cause rendering errors."
  • The Vulkan pipeline cache initializes, the title (PPSA21567) is detected, and shaders compile (3 VS, 2 PS, 15 CS at the point of failure).

The emulator then crashes with an unhandled host exception (access violation, address 0x18, inside VCRUNTIME140.dll) at runtimeLinker.cpp:749. Right before it, there are four "Unresolved import stub called" lines for NpCppWebApi_v1. I don't see anything in the log pointing at shaders or barycentrics, so this looks unrelated to this PR, but I can't say for sure. Full log attached below.

So the device-selection change works on RDNA 1. I haven't yet been able to check rendering on a game that gets further. I'll test other titles and report back.

Initialized: Config
Initialized: Log
Initialized: Timer
Initialized: Pthread
Initialized: Profiler
Initialized: Network
Initialized: Memory
Initialized: FileSystem
Initialized: Controller
Initialized: Audio
WARNING: fragmentShaderBarycentric is unavailable. Pixel shaders that read raw vertex attributes will use interpolated values, which may cause rendering errors.
Vulkan pipeline cache: initializing _PipelineCache\PPSA21567.bin
Vulkan pipeline cache: initialized empty
Initialized: Graphics
Title ID: PPSA21567
version = 13
Unresolved import stub called: Y295ygEccqk[NpCppWebApi_v1][NpCppWebApi_v1.1][Func]
Unresolved import stub called: 8x++mBOUeso[NpCppWebApi_v1][NpCppWebApi_v1.1][Func]
Unresolved import stub called: UYPxv8MIzGo[NpCppWebApi_v1][NpCppWebApi_v1.1][Func]
Unresolved import stub called: 52AlYvq+dmk[NpCppWebApi_v1][NpCppWebApi_v1.1][Func]
Shaders: VS 0 | PS 0 | CS 1 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 0 | PS 0 | CS 2 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 0 | PS 1 | CS 2 | GS 0 | LS 0 | HS 0 | TES 0
Shader: emitted zero-position clip guard
Shaders: VS 1 | PS 1 | CS 2 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 1 | PS 1 | CS 3 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 1 | PS 1 | CS 4 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 1 | PS 1 | CS 5 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 1 | PS 1 | CS 6 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 1 | PS 1 | CS 7 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 1 | PS 1 | CS 8 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 1 | PS 1 | CS 9 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 1 | PS 1 | CS 10 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 1 | PS 1 | CS 11 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 1 | PS 1 | CS 12 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 1 | PS 1 | CS 13 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 2 | PS 1 | CS 13 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 2 | PS 1 | CS 14 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 2 | PS 1 | CS 15 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 2 | PS 2 | CS 15 | GS 0 | LS 0 | HS 0 | TES 0
Shaders: VS 3 | PS 2 | CS 15 | GS 0 | LS 0 | HS 0 | TES 0
--- Guest fault context ---
thread: (host thread)
rax=0000013ff69eda60 rbx=0000013ff69ede70 rcx=0000013ff69eda60 rdx=0000000000000018
rsi=0000000000000018 rdi=0000013ff69eda98 rbp=0000000000000000 rsp=0000013ff69ed9c8
r8 =0000000000000004 r9 =00007ffb4e38dc1a r10=00007ffb4e370000 r11=0000000000000000
r12=0000000000000018 r13=000001400a732040 r14=000001400c6c48b0 r15=0000000000000000
module: C:\WINDOWS\SYSTEM32\VCRUNTIME140.dll+0x1dc1a
code (pc-48 .. pc+48, fault at byte 48):
89 00 89 48 08 c3 8b 0a 44 0f b7 42 04 89 08 66
44 89 40 04 c3 8b 0a 44 0f b6 42 04 89 08 44 88
40 04 c3 48 8b 0a 48 89 08 c3 0f b6 0a 88 08 c3
8b 0a 89 08 c3 90 49 83 f8 20 77 17 f3 0f 6f 0a
f3 42 0f 6f 54 02 f0 f3 0f 7f 09 f3 42 0f 7f 54
01 f0 c3 4e 8d 0c 02 48 3b ca 4c 0f 46 c9 49 3b
stack:
0000000140a03d2e 0000000000000000 0000000000000000 0000000000000000
0000013ff69eda90 fffffffffffffffe 000001400c6c4820 0000013ff69edf28
0000013ff69edd40 0000000000000018 0000b3ee11d211d6 0000013ff69eda60
0000013ff69edf28 0000013ff69edd40 0000000140a304ed 0000014003cb4d70
0000014003cb44a0 000000000000008e 0000000000000060 0000000000000000
0000000000000000 0000000000440000 0000000000000000 0000000000000000
0000000000000000 0000000000000000 0000013ff69eda60 0000000000000001
0000000000000040 000000000000004c 0000013ff69edf28 0000013ff69edb80
--- Build ---
Source build 356e980
--- Error ---
Unhandled host exception: type=1 code=3221225477 pc=0x00007ffb4e38dc1a access=1 address=0x0000000000000018
in D:\a\KytyPS5\KytyPS5\src\loader\runtimeLinker.cpp:749

C:\Users\salvo\Desktop\KytyPS5>

**@⁠salvatorelobianco** on GitHub · 2026-10-11 13:33 UTC · [original](https://github.com/KytyPS5/KytyPS5/pull/959#issuecomment-6109573144) > Hi, I can help test this on real RDNA 1 hardware. > > My setup: > > * GPU: AMD Radeon RX 5700 XT (RDNA 1) > > * CPU: Ryzen 5 3600 > > * OS: Windows 11 > > > With the official build KytyPS5-2026-10-11-16a7fe6 the emulator exits at startup with: > > Could not find suitable device: AMD Radeon RX 5700 XT: fragmentShaderBarycentric is not supported in vulkanWindow.cpp:980 > > This is the same error as in #1340, #1364 and #1416. As far as I can tell, no one has tested this PR on an RDNA 1 GPU yet, so I'd be happy to try a build that includes it and report back with logs, both for startup and for any games that hit the shader fallback path. > > Is there an artifact or a branch I can test? Thanks! Update: I tested the Windows artifact from this PR's CI (source build 356e980) on real RDNA 1 hardware. Setup: - GPU: AMD Radeon RX 5700 XT (RDNA 1) - CPU: Ryzen 5 3600 - OS: Windows 11 Result: - The "Could not find suitable device ... fragmentShaderBarycentric is not supported" error is gone and the emulator now creates the device. - The expected warning is logged: "fragmentShaderBarycentric is unavailable. Pixel shaders that read raw vertex attributes will use interpolated values, which may cause rendering errors." - The Vulkan pipeline cache initializes, the title (PPSA21567) is detected, and shaders compile (3 VS, 2 PS, 15 CS at the point of failure). The emulator then crashes with an unhandled host exception (access violation, address 0x18, inside VCRUNTIME140.dll) at runtimeLinker.cpp:749. Right before it, there are four "Unresolved import stub called" lines for NpCppWebApi_v1. I don't see anything in the log pointing at shaders or barycentrics, so this looks unrelated to this PR, but I can't say for sure. Full log attached below. So the device-selection change works on RDNA 1. I haven't yet been able to check rendering on a game that gets further. I'll test other titles and report back. Initialized: Config Initialized: Log Initialized: Timer Initialized: Pthread Initialized: Profiler Initialized: Network Initialized: Memory Initialized: FileSystem Initialized: Controller Initialized: Audio WARNING: fragmentShaderBarycentric is unavailable. Pixel shaders that read raw vertex attributes will use interpolated values, which may cause rendering errors. Vulkan pipeline cache: initializing _PipelineCache\PPSA21567.bin Vulkan pipeline cache: initialized empty Initialized: Graphics Title ID: PPSA21567 version = 13 Unresolved import stub called: Y295ygEccqk[NpCppWebApi_v1][NpCppWebApi_v1.1][Func] Unresolved import stub called: 8x++mBOUeso[NpCppWebApi_v1][NpCppWebApi_v1.1][Func] Unresolved import stub called: UYPxv8MIzGo[NpCppWebApi_v1][NpCppWebApi_v1.1][Func] Unresolved import stub called: 52AlYvq+dmk[NpCppWebApi_v1][NpCppWebApi_v1.1][Func] Shaders: VS 0 | PS 0 | CS 1 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 0 | PS 0 | CS 2 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 0 | PS 1 | CS 2 | GS 0 | LS 0 | HS 0 | TES 0 Shader: emitted zero-position clip guard Shaders: VS 1 | PS 1 | CS 2 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 1 | PS 1 | CS 3 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 1 | PS 1 | CS 4 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 1 | PS 1 | CS 5 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 1 | PS 1 | CS 6 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 1 | PS 1 | CS 7 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 1 | PS 1 | CS 8 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 1 | PS 1 | CS 9 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 1 | PS 1 | CS 10 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 1 | PS 1 | CS 11 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 1 | PS 1 | CS 12 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 1 | PS 1 | CS 13 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 2 | PS 1 | CS 13 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 2 | PS 1 | CS 14 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 2 | PS 1 | CS 15 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 2 | PS 2 | CS 15 | GS 0 | LS 0 | HS 0 | TES 0 Shaders: VS 3 | PS 2 | CS 15 | GS 0 | LS 0 | HS 0 | TES 0 --- Guest fault context --- thread: (host thread) rax=0000013ff69eda60 rbx=0000013ff69ede70 rcx=0000013ff69eda60 rdx=0000000000000018 rsi=0000000000000018 rdi=0000013ff69eda98 rbp=0000000000000000 rsp=0000013ff69ed9c8 r8 =0000000000000004 r9 =00007ffb4e38dc1a r10=00007ffb4e370000 r11=0000000000000000 r12=0000000000000018 r13=000001400a732040 r14=000001400c6c48b0 r15=0000000000000000 module: C:\WINDOWS\SYSTEM32\VCRUNTIME140.dll+0x1dc1a code (pc-48 .. pc+48, fault at byte 48): 89 00 89 48 08 c3 8b 0a 44 0f b7 42 04 89 08 66 44 89 40 04 c3 8b 0a 44 0f b6 42 04 89 08 44 88 40 04 c3 48 8b 0a 48 89 08 c3 0f b6 0a 88 08 c3 8b 0a 89 08 c3 90 49 83 f8 20 77 17 f3 0f 6f 0a f3 42 0f 6f 54 02 f0 f3 0f 7f 09 f3 42 0f 7f 54 01 f0 c3 4e 8d 0c 02 48 3b ca 4c 0f 46 c9 49 3b stack: 0000000140a03d2e 0000000000000000 0000000000000000 0000000000000000 0000013ff69eda90 fffffffffffffffe 000001400c6c4820 0000013ff69edf28 0000013ff69edd40 0000000000000018 0000b3ee11d211d6 0000013ff69eda60 0000013ff69edf28 0000013ff69edd40 0000000140a304ed 0000014003cb4d70 0000014003cb44a0 000000000000008e 0000000000000060 0000000000000000 0000000000000000 0000000000440000 0000000000000000 0000000000000000 0000000000000000 0000000000000000 0000013ff69eda60 0000000000000001 0000000000000040 000000000000004c 0000013ff69edf28 0000013ff69edb80 --- Build --- Source build 356e980 --- Error --- Unhandled host exception: type=1 code=3221225477 pc=0x00007ffb4e38dc1a access=1 address=0x0000000000000018 in D:\a\KytyPS5\KytyPS5\src\loader\runtimeLinker.cpp:749 C:\Users\salvo\Desktop\KytyPS5>

Pull request closed

This discussion has been locked. Commenting is limited to contributors.
No description provided.