fix(agc): build a pipeline with a fragment shader interlock whole, not from libraries #9185

Merged
janzezno merged 2 commits from upstream-pr/9185 into main 2026-10-24 14:29:57 +00:00
janzezno commented 2026-10-21 14:37:25 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by janzezno on 2026-10-21T14:37:25Z.


What

agc_driver_pixel_interlock fails now and then when the test suite runs in parallel. With 12 copies at once on an RX 7900 GRE (RADV, Mesa 26.2.5), 14 of 240 runs failed. Every failure was the first draw of the process: wave64 pass 0: pixel N counted 63 of 64 overlapping read-modify-writes, with N always on an 8x8 tile corner. So one whole wave64 tile lost one increment.

The first draw is the one that uses the fast-linked graphics-pipeline-library pipeline. After it, the background LINK_TIME_OPTIMIZATION relink takes over. The pipeline modes give:

Mode Failed runs
APS5_NO_PIPELINE_LTO=1 (every draw fast-linked) 108 of 120, every pass and both wave sizes
APS5_NO_GPL=1 (whole pipelines) 0 of 240

RADV_DEBUG=shaders,epilogs shows the difference. In the whole pipeline, ACO puts s_waitcnt_vscnt null, 0x0 between the counter buffer_store_b32 and the final exp mrt0 ... done. On GFX11 that done export ends the primitive-ordered section, so the store lands before the next overlapping wave is let in. In the fragment-shader library, ACO moves the export into a separate PS epilog. The main part stores and then jumps to the epilog (s_setpc_b64) without the wait, and the epilog is only exp mrt0 ... done and s_endpgm. The next wave covering the same pixels then reads the count before the store lands. This is a driver bug: a pipeline linked from libraries must behave like the whole pipeline. It is reported upstream as mesa#16653. The workaround below can be removed once the fix has shipped. The fix is in review as mesa!45546: with its revision d71ecb1, ACO waits for the store before the jump to the epilog, and the loaded runs of main's test (without this change) fail 0 of 120 fast-linked and 0 of 240 by default.

This change builds a pipeline whole when its fragment shader declares a fragment shader interlock capability. FragmentInterlock in Pipeline.cpp reads the module's leading OpCapability words, and libraryKeys declines such pipelines, as it already does for rect lists, per-face depth bias and barycentric patches. These pipelines lose the fast link on every driver and are compiled whole at the draw. Primitive-ordered pixel shaders are rare, so this costs one whole compile per such pipeline. A new debt entry, "Fragment shader interlock pipelines", records the reason, the cost and which drivers' fast links are measured.

The test now also requires that none of its pipelines was linked from libraries when the device uses them. Without the Pipeline.cpp change, that check fails on every run, loaded or not, so the regression no longer depends on load.

Overlap: on main 24c6cc33f0, pr_overlap paired this change with #7888, and on b7d1d47a5f also with #9489. #7888 has since merged; the rebase onto e13027a1f3 keeps its functionLdsBuffer condition and this change's condition on the same libraryKeys line. The remaining overlaps are only textual:

  • #9489 adds #include <string> where this change adds #include <spirv/unified1/spirv.hpp>; the merged list keeps both. Its libraryKeys change is to the key contents, not to which pipelines use libraries.
  • #10046 (opened after the last pr_overlap run) adds (state.stages.tessellation && !context.tessellationPipelineCache) to the same libraryKeys line. It is independent of this change, and the merged line keeps both conditions. Its other Pipeline.cpp hunk, the pipeline cache choice in the constructor, merges cleanly. The order is agreed in its thread: no Depends on either way, and the one that merges second rebases.

Neither depends on this change or this change on them, so the one that merges second rebases, as @mazen320 agreed for #7888 (comment). @jotitadev agreed to the same for #10046 (comment); it is proposed in #9489, without an answer yet. If this change merges first, #9489's rebase keeps both includes. If #9489 merges first, I rebase this change onto it and rerun the loaded agc_driver_pixel_interlock runs and the validation-layer comparison before it merges. Of the pull requests pr_overlap could not compare:

  • #8014 edits the top of main in PixelInterlock.cpp, while this change adds one line after the draw loop.
  • In Pipeline.cpp, only #7642 touches library handling, and it changes the pipeline layout flags, not whether a pipeline is built from libraries. #6612, #6639 and #6801, new in the list, change point and tessellation drawing there. #5925 and #7803 touch graphics pipeline libraries only in tests (a mock device in tests/Graphics.cpp and a test pass in tests/Recorder.cpp).
  • In the debt file, this change only adds a new entry.

Tested

Arch Linux, AMD Radeon RX 7900 GRE (RADV NAVI31, Mesa 26.2.5), Release, on main caa089fd73.

  • agc_driver_pixel_interlock, 12 copies at once, with MESA_SHADER_CACHE_DISABLE=true so every process compiles its pipelines:

    Mode main this change
    default 98 of 240 failed 0 of 240
    APS5_NO_PIPELINE_LTO=1 (every draw fast-linked) 104 of 120 failed 0 of 120

    With the driver's shader cache disabled the background relink lands later, so more draws use the fast-linked pipeline than the 14 of 240 failures first measured with the cache on.

  • With only the test change (no Pipeline.cpp change), the test failed 3 of 3 runs alone, each at the new check.

  • ctest --test-dir build -R 'agc|shader|recompiler' -V -j6 with ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation, on main and on this change: both 884 of 885, with the same failure, the agc_driver_tessellation segfault (#5444). Both logs have the same four VUIDs with the same counts, so the change adds no validation errors, and neither log reports the validation layer missing.

  • NVIDIA GeForce RTX 4090 (driver 617.42, Windows 11), tested by @MaxLikesCode in this comment: agc_driver_pixel_interlock passed on main and on this change, with and without the validation layer and with no VUID-; 12 copies at once failed 0 of 240 runs on both, by default and with APS5_NO_PIPELINE_LTO=1. NVIDIA's fast link keeps the ordering, and the debt entry now says so. The workaround still applies on every driver: NVIDIA never relinks with link-time optimization, so a whole pipeline also avoids the fast link's extra vertex-stage VGPRs there, and AMDVLK, AMD on Windows and ANV are not measured.

  • python3 tools/check_conventions.py --base upstream/main passes.

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 under Silent stubs in their library's technical debt file
  • 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
  • Fixes: none
  • Unblocks: none
  • GPUs tested: AMD Radeon RX 7900 GRE (RADV NAVI31, Mesa 26.2.5), Arch Linux; NVIDIA GeForce RTX 4090 (driver 617.42), Windows 11, by @MaxLikesCode
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4953372174 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/9185). Originally posted by [janzezno](https://github.com/janzezno) on 2026-10-21T14:37:25Z. --- ### What `agc_driver_pixel_interlock` fails now and then when the test suite runs in parallel. With 12 copies at once on an RX 7900 GRE (RADV, Mesa 26.2.5), 14 of 240 runs failed. Every failure was the first draw of the process: `wave64 pass 0: pixel N counted 63 of 64 overlapping read-modify-writes`, with `N` always on an 8x8 tile corner. So one whole wave64 tile lost one increment. The first draw is the one that uses the fast-linked graphics-pipeline-library pipeline. After it, the background `LINK_TIME_OPTIMIZATION` relink takes over. The pipeline modes give: | Mode | Failed runs | | --- | --- | | `APS5_NO_PIPELINE_LTO=1` (every draw fast-linked) | 108 of 120, every pass and both wave sizes | | `APS5_NO_GPL=1` (whole pipelines) | 0 of 240 | `RADV_DEBUG=shaders,epilogs` shows the difference. In the whole pipeline, ACO puts `s_waitcnt_vscnt null, 0x0` between the counter `buffer_store_b32` and the final `exp mrt0 ... done`. On GFX11 that `done` export ends the primitive-ordered section, so the store lands before the next overlapping wave is let in. In the fragment-shader library, ACO moves the export into a separate PS epilog. The main part stores and then jumps to the epilog (`s_setpc_b64`) without the wait, and the epilog is only `exp mrt0 ... done` and `s_endpgm`. The next wave covering the same pixels then reads the count before the store lands. This is a driver bug: a pipeline linked from libraries must behave like the whole pipeline. It is reported upstream as [mesa#16653](https://gitlab.freedesktop.org/mesa/mesa/-/work_items/16653). The workaround below can be removed once the fix has shipped. The fix is in review as [mesa!45546](https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/45546): with its revision `d71ecb1`, ACO waits for the store before the jump to the epilog, and the loaded runs of `main`'s test (without this change) fail 0 of 120 fast-linked and 0 of 240 by default. This change builds a pipeline whole when its fragment shader declares a fragment shader interlock capability. `FragmentInterlock` in `Pipeline.cpp` reads the module's leading `OpCapability` words, and `libraryKeys` declines such pipelines, as it already does for rect lists, per-face depth bias and barycentric patches. These pipelines lose the fast link on every driver and are compiled whole at the draw. Primitive-ordered pixel shaders are rare, so this costs one whole compile per such pipeline. A new debt entry, "Fragment shader interlock pipelines", records the reason, the cost and which drivers' fast links are measured. The test now also requires that none of its pipelines was linked from libraries when the device uses them. Without the `Pipeline.cpp` change, that check fails on every run, loaded or not, so the regression no longer depends on load. Overlap: on `main` `24c6cc33f0`, `pr_overlap` paired this change with #7888, and on `b7d1d47a5f` also with #9489. #7888 has since merged; the rebase onto `e13027a1f3` keeps its `functionLdsBuffer` condition and this change's condition on the same `libraryKeys` line. The remaining overlaps are only textual: - #9489 adds `#include <string>` where this change adds `#include <spirv/unified1/spirv.hpp>`; the merged list keeps both. Its `libraryKeys` change is to the key contents, not to which pipelines use libraries. - #10046 (opened after the last `pr_overlap` run) adds `(state.stages.tessellation && !context.tessellationPipelineCache)` to the same `libraryKeys` line. It is independent of this change, and the merged line keeps both conditions. Its other `Pipeline.cpp` hunk, the pipeline cache choice in the constructor, merges cleanly. The order is [agreed in its thread](https://github.com/boykopovar/AnyPS5/pull/10046#issuecomment-6368423053): no `Depends on` either way, and the one that merges second rebases. Neither depends on this change or this change on them, so the one that merges second rebases, as @mazen320 agreed for #7888 ([comment](https://github.com/boykopovar/AnyPS5/pull/7888#issuecomment-6344701521)). @jotitadev agreed to the same for #10046 ([comment](https://github.com/boykopovar/AnyPS5/pull/10046#issuecomment-6368423053)); it is proposed in #9489, without an answer yet. If this change merges first, #9489's rebase keeps both includes. If #9489 merges first, I rebase this change onto it and rerun the loaded `agc_driver_pixel_interlock` runs and the validation-layer comparison before it merges. Of the pull requests `pr_overlap` could not compare: - #8014 edits the top of `main` in `PixelInterlock.cpp`, while this change adds one line after the draw loop. - In `Pipeline.cpp`, only #7642 touches library handling, and it changes the pipeline layout flags, not whether a pipeline is built from libraries. #6612, #6639 and #6801, new in the list, change point and tessellation drawing there. #5925 and #7803 touch graphics pipeline libraries only in tests (a mock device in `tests/Graphics.cpp` and a test pass in `tests/Recorder.cpp`). - In the debt file, this change only adds a new entry. ### Tested Arch Linux, AMD Radeon RX 7900 GRE (RADV NAVI31, Mesa 26.2.5), Release, on `main` `caa089fd73`. - `agc_driver_pixel_interlock`, 12 copies at once, with `MESA_SHADER_CACHE_DISABLE=true` so every process compiles its pipelines: | Mode | `main` | this change | | --- | --- | --- | | default | 98 of 240 failed | 0 of 240 | | `APS5_NO_PIPELINE_LTO=1` (every draw fast-linked) | 104 of 120 failed | 0 of 120 | With the driver's shader cache disabled the background relink lands later, so more draws use the fast-linked pipeline than the 14 of 240 failures first measured with the cache on. - With only the test change (no `Pipeline.cpp` change), the test failed 3 of 3 runs alone, each at the new check. - `ctest --test-dir build -R 'agc|shader|recompiler' -V -j6` with `ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation`, on `main` and on this change: both 884 of 885, with the same failure, the `agc_driver_tessellation` segfault (#5444). Both logs have the same four VUIDs with the same counts, so the change adds no validation errors, and neither log reports the validation layer missing. - NVIDIA GeForce RTX 4090 (driver 617.42, Windows 11), tested by @MaxLikesCode in [this comment](https://github.com/boykopovar/AnyPS5/pull/9185#issuecomment-6321175489): `agc_driver_pixel_interlock` passed on `main` and on this change, with and without the validation layer and with no `VUID-`; 12 copies at once failed 0 of 240 runs on both, by default and with `APS5_NO_PIPELINE_LTO=1`. NVIDIA's fast link keeps the ordering, and the debt entry now says so. The workaround still applies on every driver: NVIDIA never relinks with link-time optimization, so a whole pipeline also avoids the fast link's extra vertex-stage VGPRs there, and AMDVLK, AMD on Windows and ANV are not measured. - `python3 tools/check_conventions.py --base upstream/main` passes. ### Checklist <!-- Rules behind each item: https://github.com/boykopovar/AnyPS5/blob/main/CONTRIBUTING.md --> - [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 under Silent stubs in their library's [technical debt](https://github.com/boykopovar/AnyPS5/tree/main/docs/dev/debt) file - [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] Fixes: none - [x] Unblocks: none - [x] GPUs tested: AMD Radeon RX 7900 GRE (RADV NAVI31, Mesa 26.2.5), Arch Linux; NVIDIA GeForce RTX 4090 (driver 617.42), Windows 11, by @MaxLikesCode - [x] AI-assisted: yes
MaxLikesCode commented 2026-10-21 16:35:26 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MaxLikesCode on 2026-10-21T16:35:26Z.


RTX 4090 (Ada) on Windows, head fc8af7938 merged onto main cecb540a6 (clean):

  • agc_driver_pixel_interlock: main and this PR each pass 3 of 3 without and 3 of 3 with the validation layer, no VUID-.
  • 12 copies of agc_driver_pixel_interlock_tests.exe at once, each in its own working directory, 240 runs per row:
Mode main this PR
default 0 failed 0 failed
APS5_NO_PIPELINE_LTO=1 (every draw fast-linked) 0 failed 0 failed

So on NVIDIA's driver the ordering held in pipelines linked from libraries: with every draw fast-linked, main passed 240 of 240 here, where RADV failed 108 of 120. The workaround is harmless on NVIDIA, but it is only needed on RADV; if you want whole pipelines only where they are needed, it could be limited to VK_DRIVER_ID_MESA_RADV, the way #7888 limits its buffer to VK_DRIVER_ID_NVIDIA_PROPRIETARY.

NVIDIA GeForce RTX 4090, driver 617.42, Windows 11 Pro 26200, WinLibs GCC 15.2.0 r7, Release, BUILD_TESTING=ON, ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1, ctest --test-dir build -R <tests> -V. Validation runs add VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation (Vulkan-ValidationLayers vulkan-sdk-1.4.363.0, implicit layers disabled); the loader log shows the layer inserted in every Vulkan test process, and no log has was not found but was requested by env var VK_INSTANCE_LAYERS.

AI-assisted: yes (Claude Code)

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6321175489 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/9185#issuecomment-6321175489). Originally posted by [MaxLikesCode](https://github.com/MaxLikesCode) on 2026-10-21T16:35:26Z. --- RTX 4090 (Ada) on Windows, head `fc8af7938` merged onto `main` `cecb540a6` (clean): - `agc_driver_pixel_interlock`: `main` and this PR each pass 3 of 3 without and 3 of 3 with the validation layer, no `VUID-`. - 12 copies of `agc_driver_pixel_interlock_tests.exe` at once, each in its own working directory, 240 runs per row: | Mode | `main` | this PR | |---|---|---| | default | 0 failed | 0 failed | | `APS5_NO_PIPELINE_LTO=1` (every draw fast-linked) | 0 failed | 0 failed | So on NVIDIA's driver the ordering held in pipelines linked from libraries: with every draw fast-linked, `main` passed 240 of 240 here, where RADV failed 108 of 120. The workaround is harmless on NVIDIA, but it is only needed on RADV; if you want whole pipelines only where they are needed, it could be limited to `VK_DRIVER_ID_MESA_RADV`, the way #7888 limits its buffer to `VK_DRIVER_ID_NVIDIA_PROPRIETARY`. NVIDIA GeForce RTX 4090, driver 617.42, Windows 11 Pro 26200, WinLibs GCC 15.2.0 r7, Release, `BUILD_TESTING=ON`, `ANYPS5_REQUIRE_VULKAN=1`, `ANYPS5_NO_SHADER_CACHE=1`, `ctest --test-dir build -R <tests> -V`. Validation runs add `VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation` (Vulkan-ValidationLayers `vulkan-sdk-1.4.363.0`, implicit layers disabled); the loader log shows the layer inserted in every Vulkan test process, and no log has `was not found but was requested by env var VK_INSTANCE_LAYERS`. AI-assisted: yes (Claude Code)
janzezno commented 2026-10-21 17:07:29 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by janzezno on 2026-10-21T17:07:29Z.


Thanks for the NVIDIA runs, especially the APS5_NO_PIPELINE_LTO=1 row; that confirms the ordering bug is RADV's fast link, not something every driver does. I'd still like to keep whole pipelines for interlock shaders on every driver. On VK_DRIVER_ID_NVIDIA_PROPRIETARY, PipelineLinkTimeOptimizationUsable is false, so the fast link is never replaced by an optimized relink, and these pipelines would keep the fast-linked vertex stage's extra VGPRs for the whole run. Building them whole costs one compile at the first draw, and these shaders are rare. It also keeps the drivers nobody has measured yet (AMDVLK, AMD on Windows, ANV) safe without a driver check that needs a version limit once mesa#16653 ships. I've added your result to the debt entry so the unmeasured list is accurate. If the first-draw compile ever shows up in a trace, limiting it to RADV is an easy follow-up.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6321860510 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/9185#issuecomment-6321860510). Originally posted by [janzezno](https://github.com/janzezno) on 2026-10-21T17:07:29Z. --- Thanks for the NVIDIA runs, especially the APS5_NO_PIPELINE_LTO=1 row; that confirms the ordering bug is RADV's fast link, not something every driver does. I'd still like to keep whole pipelines for interlock shaders on every driver. On VK_DRIVER_ID_NVIDIA_PROPRIETARY, PipelineLinkTimeOptimizationUsable is false, so the fast link is never replaced by an optimized relink, and these pipelines would keep the fast-linked vertex stage's extra VGPRs for the whole run. Building them whole costs one compile at the first draw, and these shaders are rare. It also keeps the drivers nobody has measured yet (AMDVLK, AMD on Windows, ANV) safe without a driver check that needs a version limit once mesa#16653 ships. I've added your result to the debt entry so the unmeasured list is accurate. If the first-draw compile ever shows up in a trace, limiting it to RADV is an easy follow-up.
jotitadev commented 2026-10-21 22:45:37 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by jotitadev on 2026-10-21T22:45:37Z.

Review: COMMENTED


A Metal / MoltenVK data point for the "drivers nobody has measured yet" list in the debt entry.

Machine: Apple M2 Max, macOS 27.2, x86_64 under Rosetta 2. MoltenVK 1.4.2 (Vulkan SDK 1.4.363.0). Release, BUILD_TESTING=ON.

Base/method: PR #8658 feat/macos-port @ 4ebe71f2e5 (current main 0c6a5bd593 + the macOS port), not main. This PR applied on top, clean.

On MoltenVK the device reports pipelineLibrary=0, so graphicsPipelineLibrary is off and libraryKeys() already returns false for every pipeline. The new FragmentInterlock() branch therefore changes nothing here (no pipeline is ever linked from libraries), and the new Require(!device->GraphicsPipelineLibraries() || ...) is satisfied by the left operand. So the change is a no-op on this host and the RADV fast-link ordering bug this PR fixes cannot occur on MoltenVK — Metal is not a vendor that can exercise the regression.

It is also worth noting that agc_driver_pixel_interlock itself does not pass on MoltenVK, with or without this PR, for an unrelated reason: SPIRV-Cross emits MSL that Metal rejects at pipeline creation —

error: type 'const constant spvDescriptorSetBuffer0 &' is not valid for attribute 'buffer'
note: field with illegal attribute 'raster_order_group' declared here
    coherent device _17* buffers_coherent [[id(2), raster_order_group(0)]][1];

so the interlock test is blocked on Metal before this PR's path is reached. No regression from this PR on Apple.

GPUs tested: Apple M2 Max (MoltenVK 1.4.2).

Written with AI assistance (Claude Code). I ran the builds and tests above on my machine.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5607144139 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/9185#pullrequestreview-5607144139). Originally posted by [jotitadev](https://github.com/jotitadev) on 2026-10-21T22:45:37Z. **Review:** COMMENTED --- A Metal / MoltenVK data point for the "drivers nobody has measured yet" list in the debt entry. **Machine:** Apple M2 Max, macOS 27.2, x86_64 under Rosetta 2. MoltenVK 1.4.2 (Vulkan SDK 1.4.363.0). Release, `BUILD_TESTING=ON`. **Base/method:** PR #8658 `feat/macos-port` @ `4ebe71f2e5` (current `main` `0c6a5bd593` + the macOS port), not `main`. This PR applied on top, clean. On MoltenVK the device reports `pipelineLibrary=0`, so `graphicsPipelineLibrary` is off and `libraryKeys()` already returns false for every pipeline. The new `FragmentInterlock()` branch therefore changes nothing here (no pipeline is ever linked from libraries), and the new `Require(!device->GraphicsPipelineLibraries() || ...)` is satisfied by the left operand. So the change is a no-op on this host and the RADV fast-link ordering bug this PR fixes cannot occur on MoltenVK — Metal is not a vendor that can exercise the regression. It is also worth noting that `agc_driver_pixel_interlock` itself does not pass on MoltenVK, with or without this PR, for an unrelated reason: SPIRV-Cross emits MSL that Metal rejects at pipeline creation — ``` error: type 'const constant spvDescriptorSetBuffer0 &' is not valid for attribute 'buffer' note: field with illegal attribute 'raster_order_group' declared here coherent device _17* buffers_coherent [[id(2), raster_order_group(0)]][1]; ``` so the interlock test is blocked on Metal before this PR's path is reached. No regression from this PR on Apple. GPUs tested: Apple M2 Max (MoltenVK 1.4.2). Written with AI assistance (Claude Code). I ran the builds and tests above on my machine.
janzezno commented 2026-10-21 22:52:14 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by janzezno on 2026-10-21T22:52:14Z.


Thanks for checking on Apple. You're right that it's a no-op there: with graphicsPipelineLibrary off, libraryKeys returns false before it reaches FragmentInterlock, so no pipeline is fast-linked and the RADV ordering bug can't happen. I'll leave the debt entry as it is. "Other drivers are not measured" only covers drivers that actually fast-link from libraries, and MoltenVK doesn't.

The Metal compile failure (raster_order_group on an argument buffer field) is already tracked for the macOS port: it's in the #8658 body and in the issue #1 thread, and @shanto462 took it there. So I'll keep it out of this PR.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6328326142 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/9185#issuecomment-6328326142). Originally posted by [janzezno](https://github.com/janzezno) on 2026-10-21T22:52:14Z. --- Thanks for checking on Apple. You're right that it's a no-op there: with `graphicsPipelineLibrary` off, `libraryKeys` returns false before it reaches `FragmentInterlock`, so no pipeline is fast-linked and the RADV ordering bug can't happen. I'll leave the debt entry as it is. "Other drivers are not measured" only covers drivers that actually fast-link from libraries, and MoltenVK doesn't. The Metal compile failure (`raster_order_group` on an argument buffer field) is already tracked for the macOS port: it's in the #8658 body and in the issue #1 thread, and @shanto462 took it there. So I'll keep it out of this PR.
MarcZX10 commented 2026-10-22 07:53:25 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-22T07:53:25Z.

Review: DISMISSED


The reproduction and evidence are unusually useful here: the report isolates the failure to the fast-linked library path, the regression check fails without the production change, and the described main/change validation-layer runs show matching VUID counts. I could not independently run the GPU test in this environment because it has no Vulkan device or tools; the hosted product jobs are skipped, so I’m treating the GPU results as author-reported. Before this is merge-ready, please address the repository process items: - The branch is 599 commits behind current upstream main (2 commits ahead). CONTRIBUTING requires keeping PR branches current. Please update to current main, rerun the focused validation-layer A/B suite on that base, and refresh the overlap report. - The overlap report identifies open PR #7888 changing the same libraryKeys condition and #9489 touching the same Pipeline.cpp include area. Your description explains how to preserve both #7888 conditions, but the PR discussion does not record an agreed order; CONTRIBUTING asks authors to coordinate overlapping work and declare the dependency/order in the checklist. Please coordinate with both authors and update Depends on to match whichever must land first. My local current-main convention check and git diff --check pass, and the merge-tree is clean. Hosted conventions, eligibility, labels and report pass; Linux, Windows and product-test jobs are skipped. I’m requesting changes for the stale base and overlap coordination only; I did not find a separate code correctness defect in this diff.

I’ve noticed that holding this PR because of #5239 isn’t necessary. It’s fine for PRs to keep coming in; they’ll be handled in due course. Please disregard my earlier request to hold or defer it.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5610897024 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/9185#pullrequestreview-5610897024). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-22T07:53:25Z. **Review:** DISMISSED --- The reproduction and evidence are unusually useful here: the report isolates the failure to the fast-linked library path, the regression check fails without the production change, and the described main/change validation-layer runs show matching VUID counts. I could not independently run the GPU test in this environment because it has no Vulkan device or tools; the hosted product jobs are skipped, so I’m treating the GPU results as author-reported. Before this is merge-ready, please address the repository process items: - The branch is 599 commits behind current upstream `main` (2 commits ahead). CONTRIBUTING requires keeping PR branches current. Please update to current `main`, rerun the focused validation-layer A/B suite on that base, and refresh the overlap report. - The overlap report identifies open PR #7888 changing the same `libraryKeys` condition and #9489 touching the same `Pipeline.cpp` include area. Your description explains how to preserve both #7888 conditions, but the PR discussion does not record an agreed order; CONTRIBUTING asks authors to coordinate overlapping work and declare the dependency/order in the checklist. Please coordinate with both authors and update `Depends on` to match whichever must land first. My local current-main convention check and `git diff --check` pass, and the merge-tree is clean. Hosted conventions, eligibility, labels and report pass; Linux, Windows and product-test jobs are skipped. I’m requesting changes for the stale base and overlap coordination only; I did not find a separate code correctness defect in this diff. I’ve noticed that holding this PR because of #5239 isn’t necessary. It’s fine for PRs to keep coming in; they’ll be handled in due course. Please disregard my earlier request to hold or defer it.
janzezno commented 2026-10-22 15:32:58 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by janzezno on 2026-10-22T15:32:58Z.


@MarcZX10 rebased onto b7d1d47a5f (no conflicts). The validation-layer comparison, the loaded agc_driver_pixel_interlock runs and the check without the Pipeline.cpp change were redone on that base, and check_conventions and pr_overlap too; the description has the results. The overlaps with #7888 and #9489 are textual only (the same libraryKeys line, and neighbouring includes). I've proposed in both threads that neither declares a dependency and the one that merges second rebases, and I'll record their answers in the description.

On mesa#16653: the first fix in the issue thread doesn't cover the fast-linked path yet (92 of 120 fast-linked runs still failed with it), so the workaround is still needed.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6344648197 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/9185#issuecomment-6344648197). Originally posted by [janzezno](https://github.com/janzezno) on 2026-10-22T15:32:58Z. --- @MarcZX10 rebased onto `b7d1d47a5f` (no conflicts). The validation-layer comparison, the loaded `agc_driver_pixel_interlock` runs and the check without the `Pipeline.cpp` change were redone on that base, and `check_conventions` and `pr_overlap` too; the description has the results. The overlaps with #7888 and #9489 are textual only (the same `libraryKeys` line, and neighbouring includes). I've proposed in both threads that neither declares a dependency and the one that merges second rebases, and I'll record their answers in the description. On mesa#16653: the first fix in the issue thread doesn't cover the fast-linked path yet (92 of 120 fast-linked runs still failed with it), so the workaround is still needed.
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!9185
No description provided.