fix(shader): serve ds_ordered_count in wave launch order #12944

Open
ZSWolt wants to merge 23 commits from upstream-pr/12944 into main
ZSWolt commented 2026-10-29 15:42:29 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by ZSWolt on 2026-10-29T15:42:29Z.


What

Background. On AMD GCN/RDNA GPUs, GDS (global data share) is a small on-chip memory shared by all waves of a dispatch. ds_ordered_count is a GDS instruction that adds to, or swaps, a counter in GDS and returns the old value. Unlike an ordinary atomic, the hardware serves the waves in wavefront launch order: the first-launched wave gets the first value, the next wave the next, and so on. Shaders use it to give each wave a contiguous, ordered slice of an output buffer (stream compaction, particle lists, culling output). Because the order is guaranteed, the result is deterministic and the slices never overlap.

The bug. ds_ordered_count (ordered append on GDS) ran as a plain device atomic, so the waves of a dispatch added in whatever order the host ran them. The hardware hands the counter out in wavefront launch order. radeonsi's si_compute_prim_discard.c (mesa-20.3.0) describes it as "an atomic counter that is incremented in the wavefront launch order", with ORDER_MODE 0 launching in order. A title that turns the returned values into output offsets therefore got overlapping or shifted ranges, intermittently.

In compute shaders the ordered add and swap now run in launch order:

  • Launch index: each wave computes its launch index: the flattened workgroup ID times the waves per workgroup, plus the wave index in the workgroup.
  • Waiting for its turn: one lane per guest wave waits until a turn dword kept one dword past the 64 KiB GDS equals that index. The GDS binding grows by two dwords (RuntimeAbi::GdsMetadataDwords), the turn and a timeout count (Pm4::GdsBindingBytes). Ordinary GDS accesses stay bounded at 64 KiB; only the ordering code reaches the two dwords. The wait, the add and the release run inside one loop, so guest waves that share a host subgroup (wave32 code in a 64-lane subgroup) do not wait on each other.
  • Passing the turn on: it performs the add or swap, then, when offset1 bit 1 (wave done) is set, compare-exchanges the turn from its own index to the next (0 after the dispatch's last wave). Only the wave that holds the turn moves it.
  • Reset per dispatch: the compiled program records whether it orders (orderedAppend, disk cache format 70). For those programs only, the driver zeroes the turn in the buffer the dispatch binds, before the dispatch and before each chunk of a split one. It uses a COMPUTE_SHADER → TRANSFER barrier, a 4-byte vkCmdFillBuffer, then TRANSFER → COMPUTE_SHADER. A GDS copy the CPU made is created fillable, so it is reset the same way. Each chunk counts its own waves.
  • Bounded wait: a wave goes ahead after 2^20 reads of the turn (about 130 ms on an RX 9060 XT). It adds unordered (as on main), marks the turn abandoned so the rest of the dispatch runs unordered at once, and adds 1 to the timeout count, which the test checks. With one wave that never takes its turn, a 65536-group dispatch takes about 350 ms; without the mark it lost the device after 2 s.
  • Graphics stages keep the unordered add.

The wait relies on waves being launched in workgroup order and on earlier waves running while later ones spin. AMD hardware does this, but Vulkan does not guarantee it. This is recorded in docs/dev/debt/shader.md, which now describes the new behaviour in place of "not modeled".

Tested

Ubuntu 26.04.1 (Linux 7.0.0-38), GCC 15.2.0, Release, RX 9060 XT (RADV GFX1200, Mesa 26.0.8-1ubuntu0.3). Based on main 6d56eb813c (merged into the branch on Oct 30).

  • New cases in agc_driver_gds_append_consume, each checking every lane's value, the counter and a timeout count of 0:
    • 64 single-wave workgroups each add 1, and group g must get start + g. Runs 8 dispatches back to back.
    • The same with group 0 delayed by a scalar loop, so later waves reach the instruction first.
    • 16 groups of 4 waves, group 0 delayed.
    • 4 groups where group 1 skips ds_ordered_count: group 0 gets the start value, groups 2–3 time out and get the remaining values, and exactly 2 timeouts are counted.
    • A normal dispatch right after that one, with the turn left at 1: it is ordered only because of the per-dispatch reset.
    • On main bb04a4f1ea (with only this test file added) it fails: "64 single-wave groups, dispatch 1, ds_ordered_count: group 0 lane 0 returned 1025, expected 1000 (the counter in launch order)".
    • With this change it passes.
    • The existing single-workgroup ordered add and swap cases still pass.
  • Split-dispatch case (1 x 65537 single-wave groups, row 1 skips ds_ordered_count), in agc_driver_gds_append_consume and _copied. The RX 9060 XT on RADV reports maxComputeWorkGroupCount[1] = 65535, so the case takes the split path here: 2 chunks, row 0 gets the start value, 65533 waves of the first chunk run unordered, and the second chunk and the dispatch after it are ordered. It passes 3 of 3 in both registrations, with 0 VUID- messages.
    • On AMD's Windows driver (RX 9070 XT, reported by BunnyFl) row 0 got a value about 65,300 places late, which means it started after most of the dispatch. Vulkan does not guarantee that workgroups start in WorkgroupId order. For a row 0 served that late, the case skips only the row 0 value and the unordered count, and names the skip in its success line; the skipped row, the second chunk's order after its reset and the final counter are still checked. A row 0 served early but not first still fails. The debt entry names the assumption.
  • ctest -R '^agc_|^shader_|recompiler' -j4 on this branch: 1130 of 1132 pass. The 2 failures, agc_idle_publish_wait and agc_driver_native_multisample_depth, also fail on main on this machine (the second because a host import gets vkAllocateMemory -13 here).
  • Validation-layer compare: ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation ctest -V -R gds_append on the same machine and GPU, on main bb04a4f1ea and on this branch.
    • Neither log has the "was not found but was requested" line, and both have 0 VUID- messages.
    • On main the test fails only on the new case, as intended.
  • God of War Ragnarök (PPSA08329), title-screen fireplace scene. Plain main stops at startup in this title (sceHttp2SetResolveRetry not implemented), so this ran on my local integration build (main plus local branches) with and without this PR.
    • Before the change, a particle compute shader that uses ordered append (0x1038fb8200) intermittently produced overlapping particle records, drawn as long streaks. That was 1–9 corrupted frames per 8-minute run; with the change, 0 in 3 runs (Oct 23, first version of this PR).
    • A/B on the current head, tools/trace_digest.py, APS5_TRACE_SECONDS=200:60, order without, with, with, without:
      • presents 203 / 217 / 214 / 198;
      • frame p50 287.0 / 275.9 / 277.9 / 292.2 ms;
      • gpu_busy_ms_per_present 148.5 / 128.9 / 128.6 / 151.9. This metric spans each batch from its first to its last command, idle gaps included, so it is not shader time. I have not attributed the change to a phase.
    • Earlier versions of this description gave presents "851–857 against about 790" on main. That was wrong: those were runs of the integration build against a baseline from another day.
  • python3 tools/check_conventions.py --base origin/main: all conventions checks passed.
  • tools/pr_overlap.py --branch fix/recompiler-ordered-append: no open PR changes ds_ordered_count. The overlaps are on shared files only: Graphics/src/ShaderResources.cpp, SpirvMemoryInstructions.cpp, SpirvEmitterHelpers.cpp, Execution/src/Pm4.cpp and docs/dev/debt/shader.md (e.g. #10193, #11551, #10846).

Progress

PPSA08329 on this machine (RX 9060 XT, RADV), on main with this change and other local, unrelated fixes; this PR depends on none of them. Bring-up thread: #12128.

  • Streaks: the particle streaks from earlier runs are gone. Particle draws read records that compute shader 0x1038fb8200 writes through ds_ordered_count slots, and serving those slots in launch order removed every streak.
  • Gameplay reached: from a new game, the opening cutscene and the sled chase run through the first Freya fight, with the forest, rocks, snow ground and characters drawn. A 10-minute run from that save on Oct 29 showed the fight lit, with the forest and snow present.
  • Frame time, title-screen fireplace scene (Oct 29), A/B on the local build with and without this PR:
    • presents in 60 s: 203 / 198 without, 217 / 214 with;
    • gpu_busy_ms_per_present: 148.5 / 151.9 without, 128.9 / 128.6 with.
  • Still open, not addressed here: the CPU-bound packet thread (about 2 FPS in the chase).

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: PPSA08329 #12128 (God of War Ragnarök particle streaks)
  • GPUs tested: AMD Radeon RX 9060 XT, RADV GFX1200, Mesa 26.0.8, Ubuntu 26.04.1
  • AI-assisted: yes

🤖 Generated with Claude Code

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:5071089434 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944). Originally posted by [ZSWolt](https://github.com/ZSWolt) on 2026-10-29T15:42:29Z. --- ### What **Background.** On AMD GCN/RDNA GPUs, GDS (global data share) is a small on-chip memory shared by all waves of a dispatch. `ds_ordered_count` is a GDS instruction that adds to, or swaps, a counter in GDS and returns the old value. Unlike an ordinary atomic, the hardware serves the waves in **wavefront launch order**: the first-launched wave gets the first value, the next wave the next, and so on. Shaders use it to give each wave a contiguous, ordered slice of an output buffer (stream compaction, particle lists, culling output). Because the order is guaranteed, the result is deterministic and the slices never overlap. **The bug.** `ds_ordered_count` (ordered append on GDS) ran as a plain device atomic, so the waves of a dispatch added in whatever order the host ran them. The hardware hands the counter out in wavefront launch order. radeonsi's `si_compute_prim_discard.c` (mesa-20.3.0) describes it as "an atomic counter that is incremented in the wavefront launch order", with `ORDER_MODE 0` launching in order. A title that turns the returned values into output offsets therefore got overlapping or shifted ranges, intermittently. In compute shaders the ordered add and swap now run in launch order: - **Launch index:** each wave computes its launch index: the flattened workgroup ID times the waves per workgroup, plus the wave index in the workgroup. - **Waiting for its turn:** one lane per guest wave waits until a turn dword kept one dword past the 64 KiB GDS equals that index. The GDS binding grows by two dwords (`RuntimeAbi::GdsMetadataDwords`), the turn and a timeout count (`Pm4::GdsBindingBytes`). Ordinary GDS accesses stay bounded at 64 KiB; only the ordering code reaches the two dwords. The wait, the add and the release run inside one loop, so guest waves that share a host subgroup (wave32 code in a 64-lane subgroup) do not wait on each other. - **Passing the turn on:** it performs the add or swap, then, when `offset1` bit 1 (wave done) is set, compare-exchanges the turn from its own index to the next (0 after the dispatch's last wave). Only the wave that holds the turn moves it. - **Reset per dispatch:** the compiled program records whether it orders (`orderedAppend`, disk cache format 70). For those programs only, the driver zeroes the turn in the buffer the dispatch binds, before the dispatch and before each chunk of a split one. It uses a `COMPUTE_SHADER` → `TRANSFER` barrier, a 4-byte `vkCmdFillBuffer`, then `TRANSFER` → `COMPUTE_SHADER`. A GDS copy the CPU made is created fillable, so it is reset the same way. Each chunk counts its own waves. - **Bounded wait:** a wave goes ahead after 2^20 reads of the turn (about 130 ms on an RX 9060 XT). It adds unordered (as on `main`), marks the turn abandoned so the rest of the dispatch runs unordered at once, and adds 1 to the timeout count, which the test checks. With one wave that never takes its turn, a 65536-group dispatch takes about 350 ms; without the mark it lost the device after 2 s. - **Graphics stages** keep the unordered add. The wait relies on waves being launched in workgroup order and on earlier waves running while later ones spin. AMD hardware does this, but Vulkan does not guarantee it. This is recorded in `docs/dev/debt/shader.md`, which now describes the new behaviour in place of "not modeled". ### Tested Ubuntu 26.04.1 (Linux 7.0.0-38), GCC 15.2.0, Release, RX 9060 XT (RADV GFX1200, Mesa 26.0.8-1ubuntu0.3). Based on `main` 6d56eb813c (merged into the branch on Oct 30). - **New cases in `agc_driver_gds_append_consume`**, each checking every lane's value, the counter and a timeout count of 0: - 64 single-wave workgroups each add 1, and group g must get start + g. Runs 8 dispatches back to back. - The same with group 0 delayed by a scalar loop, so later waves reach the instruction first. - 16 groups of 4 waves, group 0 delayed. - 4 groups where group 1 skips `ds_ordered_count`: group 0 gets the start value, groups 2–3 time out and get the remaining values, and exactly 2 timeouts are counted. - A normal dispatch right after that one, with the turn left at 1: it is ordered only because of the per-dispatch reset. - On `main` bb04a4f1ea (with only this test file added) it fails: "64 single-wave groups, dispatch 1, ds_ordered_count: group 0 lane 0 returned 1025, expected 1000 (the counter in launch order)". - With this change it passes. - The existing single-workgroup ordered add and swap cases still pass. - **Split-dispatch case** (1 x 65537 single-wave groups, row 1 skips `ds_ordered_count`), in `agc_driver_gds_append_consume` and `_copied`. The RX 9060 XT on RADV reports `maxComputeWorkGroupCount[1] = 65535`, so the case takes the split path here: 2 chunks, row 0 gets the start value, 65533 waves of the first chunk run unordered, and the second chunk and the dispatch after it are ordered. It passes 3 of 3 in both registrations, with 0 `VUID-` messages. - On AMD's Windows driver (RX 9070 XT, reported by BunnyFl) row 0 got a value about 65,300 places late, which means it started after most of the dispatch. Vulkan does not guarantee that workgroups start in `WorkgroupId` order. For a row 0 served that late, the case skips only the row 0 value and the unordered count, and names the skip in its success line; the skipped row, the second chunk's order after its reset and the final counter are still checked. A row 0 served early but not first still fails. The debt entry names the assumption. - **`ctest -R '^agc_|^shader_|recompiler' -j4` on this branch:** 1130 of 1132 pass. The 2 failures, `agc_idle_publish_wait` and `agc_driver_native_multisample_depth`, also fail on `main` on this machine (the second because a host import gets `vkAllocateMemory` -13 here). - **Validation-layer compare:** `ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation ctest -V -R gds_append` on the same machine and GPU, on `main` bb04a4f1ea and on this branch. - Neither log has the "was not found but was requested" line, and both have 0 `VUID-` messages. - On `main` the test fails only on the new case, as intended. - **God of War Ragnarök (PPSA08329), title-screen fireplace scene.** Plain `main` stops at startup in this title (`sceHttp2SetResolveRetry not implemented`), so this ran on my local integration build (`main` plus local branches) with and without this PR. - Before the change, a particle compute shader that uses ordered append (`0x1038fb8200`) intermittently produced overlapping particle records, drawn as long streaks. That was 1–9 corrupted frames per 8-minute run; with the change, 0 in 3 runs (Oct 23, first version of this PR). - A/B on the current head, `tools/trace_digest.py`, `APS5_TRACE_SECONDS=200:60`, order without, with, with, without: - presents 203 / 217 / 214 / 198; - frame p50 287.0 / 275.9 / 277.9 / 292.2 ms; - `gpu_busy_ms_per_present` 148.5 / 128.9 / 128.6 / 151.9. This metric spans each batch from its first to its last command, idle gaps included, so it is not shader time. I have not attributed the change to a phase. - Earlier versions of this description gave presents "851–857 against about 790" on `main`. That was wrong: those were runs of the integration build against a baseline from another day. - `python3 tools/check_conventions.py --base origin/main`: all conventions checks passed. - `tools/pr_overlap.py --branch fix/recompiler-ordered-append`: no open PR changes `ds_ordered_count`. The overlaps are on shared files only: `Graphics/src/ShaderResources.cpp`, `SpirvMemoryInstructions.cpp`, `SpirvEmitterHelpers.cpp`, `Execution/src/Pm4.cpp` and `docs/dev/debt/shader.md` (e.g. #10193, #11551, #10846). ### Progress PPSA08329 on this machine (RX 9060 XT, RADV), on `main` with this change and other local, unrelated fixes; this PR depends on none of them. Bring-up thread: #12128. - **Streaks:** the particle streaks from earlier runs are gone. Particle draws read records that compute shader `0x1038fb8200` writes through `ds_ordered_count` slots, and serving those slots in launch order removed every streak. - **Gameplay reached:** from a new game, the opening cutscene and the sled chase run through the first Freya fight, with the forest, rocks, snow ground and characters drawn. A 10-minute run from that save on Oct 29 showed the fight lit, with the forest and snow present. - **Frame time, title-screen fireplace scene (Oct 29), A/B on the local build with and without this PR:** - presents in 60 s: 203 / 198 without, 217 / 214 with; - `gpu_busy_ms_per_present`: 148.5 / 151.9 without, 128.9 / 128.6 with. - **Still open, not addressed here:** the CPU-bound packet thread (about 2 FPS in the chase). ### 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: PPSA08329 #12128 (God of War Ragnarök particle streaks) - [x] GPUs tested: AMD Radeon RX 9060 XT, RADV GFX1200, Mesa 26.0.8, Ubuntu 26.04.1 - [x] AI-assisted: yes 🤖 Generated with [Claude Code](https://claude.com/claude-code)
CnRJay commented 2026-10-29 18:51:11 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by CnRJay on 2026-10-29T18:51:11Z.

Review: COMMENTED


The ordering fix is sound, and oneandonlydean's timeout points are addressed. One cost in recordDispatch is not covered yet and applies to every dispatch that binds the GDS, not just ordered ones.

The reset is gated on bindsGds, not on orderedAppend. bindsGds is true for any shader with a DescriptorRole::Gds binding, which includes plain append/consume and any other GDS user. Those shaders never read the turn dword, but they now get:

  1. vkCmdPipelineBarrier ALL_COMMANDS → TRANSFER
  2. vkCmdFillBuffer of 4 bytes
  3. vkCmdPipelineBarrier TRANSFER → COMPUTE_SHADER

ALL_COMMANDS as the source stage drains everything recorded before it: preceding draws, other dispatches and copies. Each such dispatch also becomes a hard sync point, so it can't overlap the work before it. The same is added before each chunk of a split dispatch. A title that issues many small GDS dispatches per frame (particle and culling passes are the typical case) pays a GPU drain for each one.

Carry the orderedAppend requirement into the compiled program, or the binding info, and reset only for programs that contain DataOrderedCount or DataOrderedSwap in a compute stage. Shaders that don't order then get exactly what main gives them.

The first barrier is wider than it needs to be. The only prior writer of the turn dword is an earlier ordered dispatch. A COMPUTE_SHADER → TRANSFER barrier with SHADER_WRITE|SHADER_READ → TRANSFER_WRITE covers that. ALL_COMMANDS / TRANSFER_WRITE also orders graphics work against the fill, which nothing needs.

Alternative that avoids the fill and both barriers. Have the shader own the reset. The wave holding the last launch index already compare-exchanges the turn to 0. With a launch-epoch dword that the host bumps once per dispatch through push constants, the compare-exchange targets epoch * stride + launch and no dispatch ever needs a zeroed turn. A timed-out dispatch then can't poison the next one either, and the fill and barriers go away.

CPU-copy path (zeroGuestBytes returning nullopt). The memset runs at record time, while the GPU may still be executing a previously submitted dispatch that uses the same CPU-made GDS copy. Two dispatches recorded back to back into one command buffer also both zero the turn before either runs. Please confirm that case can't happen, or say what guarantees it can't.

Wait loop. Each waiting wave does up to 2^20 device-scope acquire loads with no backoff. If one wave never issues the done operation (a divergent path where a whole guest wave skips it), every later wave in that dispatch spends the full budget. The test counts the timeouts (2 here), but nothing records how long a timeout costs on hardware that doesn't schedule groups strictly in order. On a 4090, include the time of the skipped-group case in the numbers; it matters for Windows TDR.

Measurement. The title numbers are the corrupted-frame counts and the present counts (851–857 against about 790). Please add tools/trace_digest.py summaries of main and of this change from the same machine and scene, with the frame time and the gpu_busy_ms_per_present of the GoW fireplace scene. Presents going up while a drain is added before every GDS dispatch is surprising, and the digest will show which phase moved.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5703268141 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5703268141). Originally posted by [CnRJay](https://github.com/CnRJay) on 2026-10-29T18:51:11Z. **Review:** COMMENTED --- The ordering fix is sound, and oneandonlydean's timeout points are addressed. One cost in `recordDispatch` is not covered yet and applies to every dispatch that binds the GDS, not just ordered ones. **The reset is gated on `bindsGds`, not on `orderedAppend`.** `bindsGds` is true for any shader with a `DescriptorRole::Gds` binding, which includes plain append/consume and any other GDS user. Those shaders never read the turn dword, but they now get: 1. `vkCmdPipelineBarrier` `ALL_COMMANDS` → `TRANSFER` 2. `vkCmdFillBuffer` of 4 bytes 3. `vkCmdPipelineBarrier` `TRANSFER` → `COMPUTE_SHADER` `ALL_COMMANDS` as the source stage drains everything recorded before it: preceding draws, other dispatches and copies. Each such dispatch also becomes a hard sync point, so it can't overlap the work before it. The same is added before each chunk of a split dispatch. A title that issues many small GDS dispatches per frame (particle and culling passes are the typical case) pays a GPU drain for each one. Carry the `orderedAppend` requirement into the compiled program, or the binding info, and reset only for programs that contain `DataOrderedCount` or `DataOrderedSwap` in a compute stage. Shaders that don't order then get exactly what `main` gives them. **The first barrier is wider than it needs to be.** The only prior writer of the turn dword is an earlier ordered dispatch. A `COMPUTE_SHADER` → `TRANSFER` barrier with `SHADER_WRITE|SHADER_READ` → `TRANSFER_WRITE` covers that. `ALL_COMMANDS` / `TRANSFER_WRITE` also orders graphics work against the fill, which nothing needs. **Alternative that avoids the fill and both barriers.** Have the shader own the reset. The wave holding the last launch index already compare-exchanges the turn to 0. With a launch-epoch dword that the host bumps once per dispatch through push constants, the compare-exchange targets `epoch * stride + launch` and no dispatch ever needs a zeroed turn. A timed-out dispatch then can't poison the next one either, and the fill and barriers go away. **CPU-copy path (`zeroGuestBytes` returning `nullopt`).** The `memset` runs at record time, while the GPU may still be executing a previously submitted dispatch that uses the same CPU-made GDS copy. Two dispatches recorded back to back into one command buffer also both zero the turn before either runs. Please confirm that case can't happen, or say what guarantees it can't. **Wait loop.** Each waiting wave does up to 2^20 device-scope acquire loads with no backoff. If one wave never issues the done operation (a divergent path where a whole guest wave skips it), every later wave in that dispatch spends the full budget. The test counts the timeouts (2 here), but nothing records how long a timeout costs on hardware that doesn't schedule groups strictly in order. On a 4090, include the time of the skipped-group case in the numbers; it matters for Windows TDR. **Measurement.** The title numbers are the corrupted-frame counts and the present counts (851–857 against about 790). Please add `tools/trace_digest.py` summaries of `main` and of this change from the same machine and scene, with the frame time and the `gpu_busy_ms_per_present` of the GoW fireplace scene. Presents going up while a drain is added before every GDS dispatch is surprising, and the digest will show which phase moved.
CnRJay commented 2026-11-01 19:32:14 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by CnRJay on 2026-11-01T19:32:14Z.

Review: COMMENTED


Thanks for the gate, the narrower barrier, the timing table and the correction of the present counts. One consequence of the CPU-copy change is not covered in your reply.

An abandoned mark is never cleared when the GDS binding is a CPU-made copy. The first wave that gives up stores 0xffffffff in the turn, and "the next ordering dispatch's reset clears the mark". For a CPU-made copy you no longer record a reset (FillTarget returns nothing), and you rely on the previous dispatch leaving 0. After a timeout it leaves 0xffffffff. The holder's compare-exchange cannot replace the mark, so every later ordering dispatch on that copy sees the mark at its first wait and runs unordered, with every wave counted as a timeout. That is main's behaviour, but it is permanent, and nothing in the log distinguishes it from a first timeout.

Please say which binding the GDS gets by default on the three platforms (import, GPU copy or CPU copy), since that decides how often this path is the one titles take. Then either:

  • clear the mark from the CPU side when a CPU copy is bound and the timeout count has moved, before the next dispatch is recorded and with the previous submission retired; or
  • refuse ordering programs on a CPU-made copy with a throw, so the gap is visible rather than a silent fallback.

A test that times out once and then runs a normal dispatch on a CPU-made binding would pin it. The existing "dispatch after a timeout" case runs on an import or GPU copy, where the reset covers it.

The frame-time table is what I asked for; gpu_busy_ms_per_present going from about 150 to about 129 ms with the change is a large move for a GDS-only fix, so it is worth a line saying which phase it comes from.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5729862888 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5729862888). Originally posted by [CnRJay](https://github.com/CnRJay) on 2026-11-01T19:32:14Z. **Review:** COMMENTED --- Thanks for the gate, the narrower barrier, the timing table and the correction of the present counts. One consequence of the CPU-copy change is not covered in your reply. **An abandoned mark is never cleared when the GDS binding is a CPU-made copy.** The first wave that gives up stores `0xffffffff` in the turn, and "the next ordering dispatch's reset clears the mark". For a CPU-made copy you no longer record a reset (`FillTarget` returns nothing), and you rely on the previous dispatch leaving 0. After a timeout it leaves `0xffffffff`. The holder's compare-exchange cannot replace the mark, so every later ordering dispatch on that copy sees the mark at its first wait and runs unordered, with every wave counted as a timeout. That is `main`'s behaviour, but it is permanent, and nothing in the log distinguishes it from a first timeout. Please say which binding the GDS gets by default on the three platforms (import, GPU copy or CPU copy), since that decides how often this path is the one titles take. Then either: - clear the mark from the CPU side when a CPU copy is bound and the timeout count has moved, before the next dispatch is recorded and with the previous submission retired; or - refuse ordering programs on a CPU-made copy with a throw, so the gap is visible rather than a silent fallback. A test that times out once and then runs a normal dispatch on a CPU-made binding would pin it. The existing "dispatch after a timeout" case runs on an import or GPU copy, where the reset covers it. The frame-time table is what I asked for; `gpu_busy_ms_per_present` going from about 150 to about 129 ms with the change is a large move for a GDS-only fix, so it is worth a line saying which phase it comes from.
XairRrR commented 2026-11-02 21:46:39 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by XairRrR on 2026-11-02T21:46:39Z.

Review: COMMENTED


Reviewed — comments

The PR merges, builds and passes every test that ran here, and the guest-GDS bound is confirmed by a negative control. The new ordered-append cases skip on lavapipe because its subgroups are only 8 lanes wide, so I could not check the launch-order behaviour on this machine, and I found nothing blocking in the code.

What I ran

Head 5332c91593adf637b534591b5207598c3a8eb369, main 9090972b7e91fd266819cbd77a8b058e177b5682, merged tree 9a5f6fc6852adaff5353a2dd7fd3f6d4f004e299. Debian 13 VM (Xeon Gold 6136, AVX2/FMA), GCC 14.2.0, Release, Ninja, lavapipe (Mesa 26.1.6, LLVM 19).

git diff --check 9090972b7e91fd266819cbd77a8b058e177b5682...5332c91593adf637b534591b5207598c3a8eb369
python3 tools/check_conventions.py --base 9090972b7e91fd266819cbd77a8b058e177b5682
env VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation ANYPS5_NO_SHADER_CACHE=1 ANYPS5_REQUIRE_VULKAN=1 \
  ctest --test-dir build -j8 --test-load 32 --output-on-failure -R "gds|agc_guarded_memory_loads|shader_disk_cache"
LP_NATIVE_VECTOR_WIDTH=1024 ctest --test-dir build -R "^agc_driver_gds_append_consume" --output-on-failure
# negative control
git show 9090972b7e91fd266819cbd77a8b058e177b5682:core/shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvBufferAccess.cpp > core/shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvBufferAccess.cpp
ninja -C build -j32 -l32 agc_guarded_memory_loads_tests
ctest --test-dir build --output-on-failure -R "^agc_guarded_memory_loads$"
git show 9a5f6fc6852adaff5353a2dd7fd3f6d4f004e299:core/shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvBufferAccess.cpp > core/shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvBufferAccess.cpp
ninja -C build -j32 -l32 agc_guarded_memory_loads_tests
ctest --test-dir build -R "^agc_guarded_memory_loads$"
git status --porcelain

Results

Check Result
git diff --check clean
check_conventions.py all conventions checks passed
Configure, build, libs (script) ok
Selected tests (script) 2102 run, 1983 passed, 112 skipped (all expected per check_skips.py), 0 new failures, 0 timeouts; the 7 failures also fail on main (agc_driver_division, agc_driver_f32_denormal_flush, agc_driver_f64_div_scale_denormal_modes, agc_driver_f64_fma_denormal_modes, agc_driver_mullit_f32_denormal_modes, unwrap_self, vector_constant_factor_tininess)
Validation-layer comparison (script) 758 tests, layer loaded in 757, 0 tests with new VUID- lines
agc_driver_gds_append_consume, agc_driver_gds_append_consume_copied skipped (exit 77): "the device's subgroups are narrower than a wave32 (8 lanes)"
agc_atomic_gds_size, agc_driver_gds_dma_fill, agc_driver_gds_dma_fill_private, agc_guarded_memory_loads, agc_shader_disk_cache* with the validation layer 7 of 7 pass
Forcing a 32-lane lavapipe (LP_NATIVE_VECTOR_WIDTH=1024) not usable: the test fails in the existing ds_append case, before any of the new code (wave32 32 threads, 32 active ds_append: lane 16 returned 1016, its wave's first active lane 1000). That is lavapipe misbehaving at this vector width, not this PR.
Worktree after the control git status --porcelain empty

Negative control

  • Guest GDS bound (oneandonlydean's point 1). I put main's SpirvBufferAccess.cpp back, so ordinary GDS accesses used the full binding length again, and rebuilt agc_guarded_memory_loads_tests. The test failed with "guarded memory loads: a guest load reached a location the guarded program could not". With the merged file back it passes. So the gdsGuestLength = OpArrayLength - GdsMetadataDwords change is exercised, and the fixture change in GuardedMemoryLoads.cpp doesn't hide it.
  • Ordering cases in GdsAppendConsume.cpp. I couldn't run a control for these: they skip here (see above). As JJenkx and jacknieland noted, the test file also doesn't build against main's driver, because it uses Pm4::GdsOrderedTimeoutsOffset. The author's description reports a red/green on main bb04a4f1ea with only the test added.

Findings

Blocking

None.

Non-blocking

  1. The ordering cases never run on lavapipe CI. core/libs/prx/libSceAgcDriver/tests/execution/GdsAppendConsume.cpp:461 skips when subgroups are narrower than 32 lanes. Lavapipe has 8 lanes here and at most 16 at AVX-512 width, so both registrations skip on every CI runner. Two things follow:

    • Nothing in CI exercises the emitted wait/CAS loop, the per-chunk reset, the abandoned marker or the CPU-copy fill path.
    • The validation-layer comparison (0 new VUIDs) doesn't cover the new vkCmdFillBuffer/barrier sequence either.

    The hardware runs in the thread are the only coverage. Of those, only TechLevelZero's RX 6300 run is on this head, and its summary doesn't show whether this test ran or skipped. Suggestions:

    • Have the ordering cases run, or at least compile and validate their shaders, when subgroups are narrower than 32 lanes, if the driver can express that.
    • Otherwise, add a host-only recompiler test that compiles OrderedGroupCode, SkippedGroupCode and ChunkSkipCode and checks that orderedAppend is set and the module passes SPIR-V validation.
  2. Chunk-relative launch index (a note, not a defect). The launch index uses the raw WorkgroupId/NumWorkgroups inputs (SpirvMemoryInstructions.cpp:1437), not the offset form that SpirvModuleEmitter.cpp:214-218 adds for split dispatches. So each chunk numbers its waves from 0. That matches the per-chunk reset at VulkanDevice.cpp:5458 and the description ("Each chunk counts its own waves"), and I found no bug in it. On hardware the order runs across the whole dispatch: with the reset and the barrier between chunks, the overall order is still kept as long as chunk N+1 starts after chunk N finishes, which the barrier at VulkanDevice.cpp:5456 (merged tree) ensures. One sentence in the order entry of docs/dev/debt/shader.md saying the chunks are ordered by the barrier, not by the turn, would make this explicit.

Earlier review points I checked against this head:

  • oneandonlydean's CAS release, per-dispatch reset and timeout count are in place (SpirvMemoryInstructions.cpp:1336-1378, VulkanDevice.cpp:5424-5430).
  • CnRJay's gating on orderedAppend is in place, with the narrower COMPUTE_SHADER → TRANSFER barrier.
  • The CPU-copy reset now goes through a fill target, and FillTarget throws for image mirrors.
  • The guest bound is restored, and confirmed by the negative control above.
  • The disk cache format 52 collision is still open, as the author acknowledged; I'm not repeating it.

Not verified

  • Launch-order behaviour, the timeout/abandon path, the split-dispatch recovery and the CPU-copy (APS5_NO_HOST_IMPORT=1 APS5_NO_SHARED_GDS=1) variant: all skip on lavapipe here. The validation layer therefore never saw the new fill and barriers either.
  • How long the 2^20-read wait takes, and its behaviour on GPUs that don't launch workgroups in order.
  • The God of War Ragnarök (PPSA08329) results and the frame-time A/B in the description: no title was run.
  • Whether the description's semantics (release on wave done, wave release ignored) match the hardware. The PR records this as unmeasured in docs/dev/debt/shader.md, as the rules require.

To get this to a good state

  • A maintainer or contributor should confirm that agc_driver_gds_append_consume and agc_driver_gds_append_consume_copied actually ran (not skipped) and passed on this head on at least one hardware GPU, and ideally that the split-dispatch case ran too (it needs maxComputeWorkGroupCount[1] below 65537).
  • Optionally, add CI-reachable coverage of the emitted ordering code (non-blocking finding 1).
  • Settle the disk cache format number before landing, as already agreed with oneandonlydean.
<!-- greyfinch-sync:boykopovar/AnyPS5:review:5743853291 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5743853291). Originally posted by [XairRrR](https://github.com/XairRrR) on 2026-11-02T21:46:39Z. **Review:** COMMENTED --- # Reviewed — comments The PR merges, builds and passes every test that ran here, and the guest-GDS bound is confirmed by a negative control. The new ordered-append cases skip on lavapipe because its subgroups are only 8 lanes wide, so I could not check the launch-order behaviour on this machine, and I found nothing blocking in the code. ## What I ran Head `5332c91593adf637b534591b5207598c3a8eb369`, `main` `9090972b7e91fd266819cbd77a8b058e177b5682`, merged tree `9a5f6fc6852adaff5353a2dd7fd3f6d4f004e299`. Debian 13 VM (Xeon Gold 6136, AVX2/FMA), GCC 14.2.0, Release, Ninja, lavapipe (Mesa 26.1.6, LLVM 19). ``` git diff --check 9090972b7e91fd266819cbd77a8b058e177b5682...5332c91593adf637b534591b5207598c3a8eb369 python3 tools/check_conventions.py --base 9090972b7e91fd266819cbd77a8b058e177b5682 env VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation ANYPS5_NO_SHADER_CACHE=1 ANYPS5_REQUIRE_VULKAN=1 \ ctest --test-dir build -j8 --test-load 32 --output-on-failure -R "gds|agc_guarded_memory_loads|shader_disk_cache" LP_NATIVE_VECTOR_WIDTH=1024 ctest --test-dir build -R "^agc_driver_gds_append_consume" --output-on-failure # negative control git show 9090972b7e91fd266819cbd77a8b058e177b5682:core/shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvBufferAccess.cpp > core/shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvBufferAccess.cpp ninja -C build -j32 -l32 agc_guarded_memory_loads_tests ctest --test-dir build --output-on-failure -R "^agc_guarded_memory_loads$" git show 9a5f6fc6852adaff5353a2dd7fd3f6d4f004e299:core/shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvBufferAccess.cpp > core/shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvBufferAccess.cpp ninja -C build -j32 -l32 agc_guarded_memory_loads_tests ctest --test-dir build -R "^agc_guarded_memory_loads$" git status --porcelain ``` ## Results | Check | Result | |---|---| | `git diff --check` | clean | | `check_conventions.py` | all conventions checks passed | | Configure, build, `libs` (script) | ok | | Selected tests (script) | 2102 run, 1983 passed, 112 skipped (all expected per `check_skips.py`), 0 new failures, 0 timeouts; the 7 failures also fail on `main` (`agc_driver_division`, `agc_driver_f32_denormal_flush`, `agc_driver_f64_div_scale_denormal_modes`, `agc_driver_f64_fma_denormal_modes`, `agc_driver_mullit_f32_denormal_modes`, `unwrap_self`, `vector_constant_factor_tininess`) | | Validation-layer comparison (script) | 758 tests, layer loaded in 757, 0 tests with new `VUID-` lines | | `agc_driver_gds_append_consume`, `agc_driver_gds_append_consume_copied` | **skipped** (exit 77): "the device's subgroups are narrower than a wave32 (8 lanes)" | | `agc_atomic_gds_size`, `agc_driver_gds_dma_fill`, `agc_driver_gds_dma_fill_private`, `agc_guarded_memory_loads`, `agc_shader_disk_cache*` with the validation layer | 7 of 7 pass | | Forcing a 32-lane lavapipe (`LP_NATIVE_VECTOR_WIDTH=1024`) | not usable: the test fails in the existing `ds_append` case, before any of the new code (`wave32 32 threads, 32 active ds_append: lane 16 returned 1016, its wave's first active lane 1000`). That is lavapipe misbehaving at this vector width, not this PR. | | Worktree after the control | `git status --porcelain` empty | ## Negative control - **Guest GDS bound (oneandonlydean's point 1).** I put `main`'s `SpirvBufferAccess.cpp` back, so ordinary GDS accesses used the full binding length again, and rebuilt `agc_guarded_memory_loads_tests`. The test failed with "guarded memory loads: a guest load reached a location the guarded program could not". With the merged file back it passes. So the `gdsGuestLength = OpArrayLength - GdsMetadataDwords` change is exercised, and the fixture change in `GuardedMemoryLoads.cpp` doesn't hide it. - **Ordering cases in `GdsAppendConsume.cpp`.** I couldn't run a control for these: they skip here (see above). As JJenkx and jacknieland noted, the test file also doesn't build against `main`'s driver, because it uses `Pm4::GdsOrderedTimeoutsOffset`. The author's description reports a red/green on `main` bb04a4f1ea with only the test added. ## Findings ### Blocking None. ### Non-blocking 1. **The ordering cases never run on lavapipe CI.** `core/libs/prx/libSceAgcDriver/tests/execution/GdsAppendConsume.cpp:461` skips when subgroups are narrower than 32 lanes. Lavapipe has 8 lanes here and at most 16 at AVX-512 width, so both registrations skip on every CI runner. Two things follow: - Nothing in CI exercises the emitted wait/CAS loop, the per-chunk reset, the abandoned marker or the CPU-copy fill path. - The validation-layer comparison (0 new VUIDs) doesn't cover the new `vkCmdFillBuffer`/barrier sequence either. The hardware runs in the thread are the only coverage. Of those, only TechLevelZero's RX 6300 run is on this head, and its summary doesn't show whether this test ran or skipped. Suggestions: - Have the ordering cases run, or at least compile and validate their shaders, when subgroups are narrower than 32 lanes, if the driver can express that. - Otherwise, add a host-only recompiler test that compiles `OrderedGroupCode`, `SkippedGroupCode` and `ChunkSkipCode` and checks that `orderedAppend` is set and the module passes SPIR-V validation. 2. **Chunk-relative launch index (a note, not a defect).** The launch index uses the raw `WorkgroupId`/`NumWorkgroups` inputs (`SpirvMemoryInstructions.cpp:1437`), not the offset form that `SpirvModuleEmitter.cpp:214-218` adds for split dispatches. So each chunk numbers its waves from 0. That matches the per-chunk reset at `VulkanDevice.cpp:5458` and the description ("Each chunk counts its own waves"), and I found no bug in it. On hardware the order runs across the whole dispatch: with the reset and the barrier between chunks, the overall order is still kept as long as chunk N+1 starts after chunk N finishes, which the barrier at `VulkanDevice.cpp:5456` (merged tree) ensures. One sentence in the order entry of `docs/dev/debt/shader.md` saying the chunks are ordered by the barrier, not by the turn, would make this explicit. Earlier review points I checked against this head: - oneandonlydean's CAS release, per-dispatch reset and timeout count are in place (`SpirvMemoryInstructions.cpp:1336-1378`, `VulkanDevice.cpp:5424-5430`). - CnRJay's gating on `orderedAppend` is in place, with the narrower `COMPUTE_SHADER` → `TRANSFER` barrier. - The CPU-copy reset now goes through a fill target, and `FillTarget` throws for image mirrors. - The guest bound is restored, and confirmed by the negative control above. - The disk cache format 52 collision is still open, as the author acknowledged; I'm not repeating it. ## Not verified - Launch-order behaviour, the timeout/abandon path, the split-dispatch recovery and the CPU-copy (`APS5_NO_HOST_IMPORT=1 APS5_NO_SHARED_GDS=1`) variant: all skip on lavapipe here. The validation layer therefore never saw the new fill and barriers either. - How long the 2^20-read wait takes, and its behaviour on GPUs that don't launch workgroups in order. - The God of War Ragnarök (PPSA08329) results and the frame-time A/B in the description: no title was run. - Whether the description's semantics (release on wave done, wave release ignored) match the hardware. The PR records this as unmeasured in `docs/dev/debt/shader.md`, as the rules require. ## To get this to a good state - A maintainer or contributor should confirm that `agc_driver_gds_append_consume` and `agc_driver_gds_append_consume_copied` actually ran (not skipped) and passed on this head on at least one hardware GPU, and ideally that the split-dispatch case ran too (it needs `maxComputeWorkGroupCount[1]` below 65537). - Optionally, add CI-reachable coverage of the emitted ordering code (non-blocking finding 1). - Settle the disk cache format number before landing, as already agreed with oneandonlydean. <!-- anyps5-bots job=2185 head=5332c91593adf637b534591b5207598c3a8eb369 -->
BunnyFl commented 2026-11-02 22:55:39 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by BunnyFl on 2026-11-02T22:55:39Z.

Review: COMMENTED


A data point from Windows that the other runs may not have covered: the split-dispatch case fails here.

Windows 11, WinLibs GCC 15.2.0, Release, AMD Radeon RX 9070 XT (vendor 0x1002, device 0x7550, AMD's Windows driver, subgroup 64), with this head merged onto current main. agc_atomic_gds_size, agc_driver_gds_append_consume_copied, agc_driver_gds_dma_fill, agc_driver_gds_dma_fill_private and agc_driver_pm4 pass, but agc_driver_gds_append_consume fails in CheckChunkedRecovery (tests/execution/GdsAppendConsume.cpp:320-347), 3 runs out of 3:

65537 single-wave groups along y in chunks of 65535, row 1 skips ds_ordered_count: row 0 returned 66278, expected 1000

The returned value differs each run (66340, 66278, 66119, 66345) and is never the start value. So the first-launched wave of the first chunk doesn't get the first turn here; about 65,300 values were handed out before it. This device reports maxComputeWorkGroupCount[1] = 65535 (the "chunks of 65535" in the message), so the case takes the split path; with a larger limit it prints "split-dispatch case skipped" instead (GdsAppendConsume.cpp:322-323). Your Tested section lists RADV only, and its case list doesn't include this one. I don't know whether it has run on a device that splits. On plain main the same test passes here, but main doesn't have this case. I haven't dug into the cause.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5744601725 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5744601725). Originally posted by [BunnyFl](https://github.com/BunnyFl) on 2026-11-02T22:55:39Z. **Review:** COMMENTED --- A data point from Windows that the other runs may not have covered: the split-dispatch case fails here. Windows 11, WinLibs GCC 15.2.0, Release, AMD Radeon RX 9070 XT (vendor `0x1002`, device `0x7550`, AMD's Windows driver, subgroup 64), with this head merged onto current `main`. `agc_atomic_gds_size`, `agc_driver_gds_append_consume_copied`, `agc_driver_gds_dma_fill`, `agc_driver_gds_dma_fill_private` and `agc_driver_pm4` pass, but `agc_driver_gds_append_consume` fails in `CheckChunkedRecovery` (`tests/execution/GdsAppendConsume.cpp:320-347`), 3 runs out of 3: ``` 65537 single-wave groups along y in chunks of 65535, row 1 skips ds_ordered_count: row 0 returned 66278, expected 1000 ``` The returned value differs each run (66340, 66278, 66119, 66345) and is never the start value. So the first-launched wave of the first chunk doesn't get the first turn here; about 65,300 values were handed out before it. This device reports `maxComputeWorkGroupCount[1] = 65535` (the "chunks of 65535" in the message), so the case takes the split path; with a larger limit it prints "split-dispatch case skipped" instead (`GdsAppendConsume.cpp:322-323`). Your Tested section lists RADV only, and its case list doesn't include this one. I don't know whether it has run on a device that splits. On plain `main` the same test passes here, but `main` doesn't have this case. I haven't dug into the cause.
XairRrR commented 2026-11-02 23:34:26 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by XairRrR on 2026-11-02T23:34:26Z.

Review: DISMISSED


Re-checked — changes still requested

The only new commit is a merge of main. It resolves the conflicts cleanly, and everything that runs here passes. One problem remains open: since my last review, BunnyFl reported that the new split-dispatch case fails on AMD's Windows driver, and there is still no fix or reply for it.

What changed since my last review

  • No new code. The previously reviewed commit 5332c91593 is still in the branch, and the PR's four own commits are unchanged (delta.patch is a no-op range-diff).

  • One new merge commit, 304e19c2a9, from main. It resolves conflicts with main's new scratchPoolSlotDwords in:

    • Recompiler.cpp and Recompiler.hpp;
    • SpirvEmitter.hpp and SpirvEmitter.cpp;
    • ShaderDiskCache.cpp;
    • the OpArrayLength fixture in GuardedMemoryLoads.cpp;
    • SpirvBufferAccess.cpp, where gdsGuestLength is kept next to the scratch-pool branch.

    I read the combined diff:

    • orderedAppend is encoded and decoded at the same position.
    • The designated initializers in materializeResult follow the member order of RecompileResult.
    • FormatVersion is 52 against main's 51.
  • New in the thread since my last review: BunnyFl's review on 5332c91593. On an RX 9070 XT with AMD's Windows driver, agc_driver_gds_append_consume fails 3 of 3 runs in CheckChunkedRecovery. The author has not replied, and the description is unchanged.

What I ran

Head 304e19c2a9715223ccd0a696ccfbba2560f68be3, main 5cb015caaaaf83f8ee431414ee6a457b5b307d49, merged tree 0bbee04f7f8c5ec30788a70a8d323136f3d5f908. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19).

git show --cc 304e19c2a9715223ccd0a696ccfbba2560f68be3
git diff --check 5cb015caaaaf83f8ee431414ee6a457b5b307d49...304e19c2a9715223ccd0a696ccfbba2560f68be3
python3 tools/check_conventions.py --base 5cb015caaaaf83f8ee431414ee6a457b5b307d49
ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build --output-on-failure -R "^agc_driver_image_sample_lod_clamp|^agc_driver_gds_append_consume"
# attribution check for the new failure: every non-test, non-doc file of the PR restored from main
git show 5cb015caaaaf83f8ee431414ee6a457b5b307d49:<path> > <path>   # for each of the 23 production files
ninja -C build -j32 -l32 agc_driver_image_sample_lod_clamp_tests libs
ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build --output-on-failure -R "^agc_driver_image_sample_lod_clamp_shader_lane$"
git show 0bbee04f7f8c5ec30788a70a8d323136f3d5f908:<path> > <path>   # for each of the same files
ninja -C build -j32 -l32 agc_driver_image_sample_lod_clamp_tests agc_driver_gds_append_consume_tests libs
git status --porcelain
Check Result
git diff --check clean
check_conventions.py all conventions checks passed
Configure, build, libs (script) ok
Selected tests (script) 2238 run, 2117 passed, 113 skipped (all expected), 0 timeouts
agc_driver_image_sample_lod_clamp_shader_lane (reported as new) Not from this PR. It was added on main after the baseline commit (fe18496c95, 4e2a028e43), and it fails the same way with the PR's production files restored from main ("thread 0 component 1 is 0.000000, expected 0.062500").
unwrap_self_..._destination_directory_group (reported as new) Not from this PR. It was added on main after the baseline, and it fails on os.chown with EINVAL in the sandbox. The PR does not touch tools/.
Validation-layer comparison (script) 760 tests, layer loaded in 759, 0 tests with new VUID- lines
agc_driver_gds_append_consume, _copied skipped (exit 77): the subgroups are 8 lanes, as before
Worktree after restoring git status --porcelain empty

No negative control for the ordering cases: they skip here, and the PR's tests have not changed since my last review. The guest-GDS-bound control from my last review still applies, because the merge keeps gdsGuestLength.

Previous findings

  • Non-blocking 1, ordering cases never run on lavapipe CI: still open. GdsAppendConsume.cpp:462 still skips below 32 lanes, so CI does not exercise the emitted loop, the reset, the abandon marker or the new fill/barrier sequence.
  • Non-blocking 2, chunks ordered by the barrier, not by the turn: still open.
    • The chunk loop at VulkanDevice.cpp:5584-5594 still resets per chunk.
    • The launch index still uses the raw WorkgroupId (SpirvMemoryInstructions.cpp:1437).
    • The order entry in docs/dev/debt/shader.md:205 still does not say this.
  • "Confirm the ordering tests ran on hardware on this head": answered, with a failure.
    • The RX 6300 (Linux) and RTX 2000 Ada (Linux) CI runs report 0 new failures on 5332c91593.
    • BunnyFl's RX 9070 XT run on Windows shows the test ran and failed (see below).
  • Disk cache format 52 collision (oneandonlydean): still open, as agreed. Format 52 is still one past main's 51, so it is correct against main today.

New findings

Blocking

  1. The split-dispatch case fails on AMD's Windows driver, with no fix and no reply. BunnyFl ran 5332c91593 on an RX 9070 XT (AMD Windows driver, subgroup 64), which reports maxComputeWorkGroupCount[1] = 65535. agc_driver_gds_append_consume failed 3 of 3 runs at core/libs/prx/libSceAgcDriver/tests/execution/GdsAppendConsume.cpp:347:

    row 0 returned 66278, expected 1000

    The value is different each run, and roughly 65,300 values were handed out before row 0. Head 304e19c2a9 carries the same code, so the report still applies. I could not reproduce it here, because lavapipe skips the test.

    Why it matters:

    • Row 0 holds launch index 0 in the first chunk (VulkanDevice.cpp:5594), and the turn is zeroed just before it (VulkanDevice.cpp:5557-5563). So row 0 should take the turn at once.
    • Getting a value that late means row 0 did its add only after another wave had used up the 2^20-read budget and abandoned the turn.
    • That points to the model's assumption (launch order matches gl_WorkGroupID order, and early waves make progress) not holding for a 65535-group dispatch on that driver.

    As merged, the PR would:

    • add a test that fails for contributors on Windows/AMD;
    • possibly leave large ordering dispatches unordered on that driver, plus about 130 ms of spinning each. Those large dispatches are the PR's target (PPSA08329 runs on AMD hardware).

    Suggested fix:

    • Find out why row 0 is late on that driver: log the timeout count and which wave abandoned first.
    • Then either fix the cause, or record the driver behaviour in the order debt entry and make the test detect it and report a skip with the reason, instead of failing.
    • The description's case list and "Tested" section also do not mention the split-dispatch case or any run of it on a device that splits. Please add where it ran and passed.

Non-blocking

None.

Not verified

  • The launch-order, abandon, split-dispatch and CPU-copy paths: they skip on lavapipe here, so the new fill/barrier sequence was not seen by the validation layer on this machine either.
  • BunnyFl's Windows failure: not reproduced, no matching hardware.
  • The PPSA08329 results and the frame-time A/B in the description: no title was run.

To get this to a good state

  • Address BunnyFl's split-dispatch failure on AMD's Windows driver: either a fix, or a documented driver limitation with a test that reports it as a skip. Then re-request a run on that driver.
  • Optionally, cover the emitted ordering code in a form that CI can reach, and add one sentence on chunk ordering to the debt entry (previous non-blocking findings).
  • Settle the disk cache format number before landing.
<!-- greyfinch-sync:boykopovar/AnyPS5:review:5744947725 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5744947725). Originally posted by [XairRrR](https://github.com/XairRrR) on 2026-11-02T23:34:26Z. **Review:** DISMISSED --- # Re-checked — changes still requested The only new commit is a merge of `main`. It resolves the conflicts cleanly, and everything that runs here passes. One problem remains open: since my last review, BunnyFl reported that the new split-dispatch case fails on AMD's Windows driver, and there is still no fix or reply for it. ## What changed since my last review - **No new code.** The previously reviewed commit `5332c91593` is still in the branch, and the PR's four own commits are unchanged (delta.patch is a no-op range-diff). - **One new merge commit, `304e19c2a9`, from `main`.** It resolves conflicts with `main`'s new `scratchPoolSlotDwords` in: - `Recompiler.cpp` and `Recompiler.hpp`; - `SpirvEmitter.hpp` and `SpirvEmitter.cpp`; - `ShaderDiskCache.cpp`; - the `OpArrayLength` fixture in `GuardedMemoryLoads.cpp`; - `SpirvBufferAccess.cpp`, where `gdsGuestLength` is kept next to the scratch-pool branch. I read the combined diff: - `orderedAppend` is encoded and decoded at the same position. - The designated initializers in `materializeResult` follow the member order of `RecompileResult`. - `FormatVersion` is 52 against `main`'s 51. - **New in the thread since my last review:** BunnyFl's review on `5332c91593`. On an RX 9070 XT with AMD's Windows driver, `agc_driver_gds_append_consume` fails 3 of 3 runs in `CheckChunkedRecovery`. The author has not replied, and the description is unchanged. ## What I ran Head `304e19c2a9715223ccd0a696ccfbba2560f68be3`, `main` `5cb015caaaaf83f8ee431414ee6a457b5b307d49`, merged tree `0bbee04f7f8c5ec30788a70a8d323136f3d5f908`. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19). ``` git show --cc 304e19c2a9715223ccd0a696ccfbba2560f68be3 git diff --check 5cb015caaaaf83f8ee431414ee6a457b5b307d49...304e19c2a9715223ccd0a696ccfbba2560f68be3 python3 tools/check_conventions.py --base 5cb015caaaaf83f8ee431414ee6a457b5b307d49 ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build --output-on-failure -R "^agc_driver_image_sample_lod_clamp|^agc_driver_gds_append_consume" # attribution check for the new failure: every non-test, non-doc file of the PR restored from main git show 5cb015caaaaf83f8ee431414ee6a457b5b307d49:<path> > <path> # for each of the 23 production files ninja -C build -j32 -l32 agc_driver_image_sample_lod_clamp_tests libs ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build --output-on-failure -R "^agc_driver_image_sample_lod_clamp_shader_lane$" git show 0bbee04f7f8c5ec30788a70a8d323136f3d5f908:<path> > <path> # for each of the same files ninja -C build -j32 -l32 agc_driver_image_sample_lod_clamp_tests agc_driver_gds_append_consume_tests libs git status --porcelain ``` | Check | Result | |---|---| | `git diff --check` | clean | | `check_conventions.py` | all conventions checks passed | | Configure, build, `libs` (script) | ok | | Selected tests (script) | 2238 run, 2117 passed, 113 skipped (all expected), 0 timeouts | | `agc_driver_image_sample_lod_clamp_shader_lane` (reported as new) | **Not from this PR.** It was added on `main` after the baseline commit (`fe18496c95`, `4e2a028e43`), and it fails the same way with the PR's production files restored from `main` ("thread 0 component 1 is 0.000000, expected 0.062500"). | | `unwrap_self_..._destination_directory_group` (reported as new) | **Not from this PR.** It was added on `main` after the baseline, and it fails on `os.chown` with `EINVAL` in the sandbox. The PR does not touch `tools/`. | | Validation-layer comparison (script) | 760 tests, layer loaded in 759, 0 tests with new `VUID-` lines | | `agc_driver_gds_append_consume`, `_copied` | skipped (exit 77): the subgroups are 8 lanes, as before | | Worktree after restoring | `git status --porcelain` empty | No negative control for the ordering cases: they skip here, and the PR's tests have not changed since my last review. The guest-GDS-bound control from my last review still applies, because the merge keeps `gdsGuestLength`. ## Previous findings - **Non-blocking 1, ordering cases never run on lavapipe CI: still open.** `GdsAppendConsume.cpp:462` still skips below 32 lanes, so CI does not exercise the emitted loop, the reset, the abandon marker or the new fill/barrier sequence. - **Non-blocking 2, chunks ordered by the barrier, not by the turn: still open.** - The chunk loop at `VulkanDevice.cpp:5584-5594` still resets per chunk. - The launch index still uses the raw `WorkgroupId` (`SpirvMemoryInstructions.cpp:1437`). - The order entry in `docs/dev/debt/shader.md:205` still does not say this. - **"Confirm the ordering tests ran on hardware on this head": answered, with a failure.** - The RX 6300 (Linux) and RTX 2000 Ada (Linux) CI runs report 0 new failures on `5332c91593`. - BunnyFl's RX 9070 XT run on Windows shows the test ran and failed (see below). - **Disk cache format 52 collision (oneandonlydean): still open, as agreed.** Format 52 is still one past `main`'s 51, so it is correct against `main` today. ## New findings ### Blocking 1. **The split-dispatch case fails on AMD's Windows driver, with no fix and no reply.** BunnyFl ran `5332c91593` on an RX 9070 XT (AMD Windows driver, subgroup 64), which reports `maxComputeWorkGroupCount[1] = 65535`. `agc_driver_gds_append_consume` failed 3 of 3 runs at `core/libs/prx/libSceAgcDriver/tests/execution/GdsAppendConsume.cpp:347`: > row 0 returned 66278, expected 1000 The value is different each run, and roughly 65,300 values were handed out before row 0. Head `304e19c2a9` carries the same code, so the report still applies. I could not reproduce it here, because lavapipe skips the test. Why it matters: - Row 0 holds launch index 0 in the first chunk (`VulkanDevice.cpp:5594`), and the turn is zeroed just before it (`VulkanDevice.cpp:5557-5563`). So row 0 should take the turn at once. - Getting a value that late means row 0 did its add only after another wave had used up the 2^20-read budget and abandoned the turn. - That points to the model's assumption (launch order matches `gl_WorkGroupID` order, and early waves make progress) not holding for a 65535-group dispatch on that driver. As merged, the PR would: - add a test that fails for contributors on Windows/AMD; - possibly leave large ordering dispatches unordered on that driver, plus about 130 ms of spinning each. Those large dispatches are the PR's target (PPSA08329 runs on AMD hardware). Suggested fix: - Find out why row 0 is late on that driver: log the timeout count and which wave abandoned first. - Then either fix the cause, or record the driver behaviour in the order debt entry and make the test detect it and report a skip with the reason, instead of failing. - The description's case list and "Tested" section also do not mention the split-dispatch case or any run of it on a device that splits. Please add where it ran and passed. ### Non-blocking None. ## Not verified - The launch-order, abandon, split-dispatch and CPU-copy paths: they skip on lavapipe here, so the new fill/barrier sequence was not seen by the validation layer on this machine either. - BunnyFl's Windows failure: not reproduced, no matching hardware. - The PPSA08329 results and the frame-time A/B in the description: no title was run. ## To get this to a good state - Address BunnyFl's split-dispatch failure on AMD's Windows driver: either a fix, or a documented driver limitation with a test that reports it as a skip. Then re-request a run on that driver. - Optionally, cover the emitted ordering code in a form that CI can reach, and add one sentence on chunk ordering to the debt entry (previous non-blocking findings). - Settle the disk cache format number before landing. <!-- anyps5-bots job=2819 head=304e19c2a9715223ccd0a696ccfbba2560f68be3 -->
XairRrR commented 2026-11-03 07:37:25 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by XairRrR on 2026-11-03T07:37:25Z.

Review: COMMENTED


Re-checked — comments

The new commit f30287c436 responds to BunnyFl's split-dispatch failure on AMD's Windows driver. When row 0 is served more than half a chunk late, the test now prints a skip line instead of failing, and the debt entry names the start-order assumption and says chunks are ordered by the barrier between them. The checks pass. Two things keep this at comments: nobody has yet confirmed the late-start explanation on that driver, and the early return also skips the second-chunk checks, which do not depend on row 0.

What changed since my last review

  • One new commit, f30287c436. It changes only GdsAppendConsume.cpp and docs/dev/debt/shader.md. The PR's earlier commits are unchanged (delta.patch).
    • CheckChunkedRecovery now prints split-dispatch case skipped: row 0 started late ... and returns when all three of these hold:

      • row 0's value is not the start value;
      • it is more than limit / 2 places late;
      • it is within the dispatch.

      The skip line gives the value, the row that got the first value, and the unordered count. If row 0 is wrong but early, the test still fails.

    • The debt entry for ds_ordered_count order now:

      • says the turn follows WorkgroupId and that start order is assumed;
      • cites the AMD Windows report;
      • says chunks are ordered by the barrier, not by the turn.
  • Author replies: an explanation of the late value (row 0 started after most of the dispatch), and a request to BunnyFl for a rerun with -V. Also a direct reply to CnRJay on CPU-copy reset and the default binding.
  • Description: now says the split case runs on RADV (the RX 9060 XT reports maxComputeWorkGroupCount[1] = 65535) and passes there 3 of 3 in both registrations. This is author-reported.

What I ran

Head f30287c43679db1778513d23be025090688db413, main d1ae628bc2f62459cce1e9872ba5632c938c71f2, merged tree 0817b9ad9ebd847b841b08c602a10e7560014bec. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19).

git show f30287c43679db1778513d23be025090688db413
git diff --check d1ae628bc2f62459cce1e9872ba5632c938c71f2...f30287c43679db1778513d23be025090688db413
python3 tools/check_conventions.py --base d1ae628bc2f62459cce1e9872ba5632c938c71f2
ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build --output-on-failure -V -R "^agc_driver_gds_append_consume"
git show d1ae628bc2f62459cce1e9872ba5632c938c71f2:core/shader/recompiler/ShaderDiskCache.hpp   # FormatVersion on main
Check Result
git diff --check clean
check_conventions.py all conventions checks passed
Configure, build, libs (script) ok
Selected tests (script) 2202 run, 2081 passed, 114 skipped (all expected), 0 new failures, 0 timeouts; 7 known failures also fail on main
Validation-layer comparison (script) 768 tests, layer loaded in 767, 0 tests with new VUID- lines
agc_driver_gds_append_consume, _copied skipped (exit 77): "the device's subgroups are narrower than a wave32 (8 lanes)"
Disk cache format 52 on the merged tree, 51 on main

Negative control: none. The only changed test is the split case, and it skips on lavapipe before it reaches the new branch.

Previous findings

  • Blocking 1, the split-dispatch case fails on AMD's Windows driver: resolved, as I suggested, but not yet confirmed. The driver behaviour is now in the debt entry (docs/dev/debt/shader.md:206), and the test detects it and reports it instead of failing (GdsAppendConsume.cpp:348-355). The late-start reading fits the value: row 0 holds index 0 and the turn is zeroed just before the chunk. But it is still a hypothesis until BunnyFl's rerun prints the skip line. The description's Tested section now covers the split case on RADV (author-reported).
  • Non-blocking 1, the ordering cases never run on lavapipe CI: still open. GdsAppendConsume.cpp:470-472 still skips below 32 lanes.
  • Non-blocking 2, chunks ordered by the barrier, not by the turn: resolved. The debt entry now says so.
  • Disk cache format 52 collision (oneandonlydean): still open, as agreed. 52 is one past main's 51.

New findings

Blocking

None.

Non-blocking

  1. The late-start skip also drops the checks that pin the per-chunk reset (core/libs/prx/libSceAgcDriver/tests/execution/GdsAppendConsume.cpp:354).
    • The early return skips three checks:
      • the skipped row is untouched (l.357);
      • the second chunk's rows are in launch order (l.358-361);
      • the final counter (l.362-363).
    • None of them depends on when row 0 started.
    • The second chunk is the one that tests the reset after an abandoned turn. The dispatch before this case leaves the turn wrapped to 0, so the first chunk does not exercise the reset.
    • So on the driver where the skip triggers, nothing in this case checks the reset any more.
    • Suggested fix: in the late-start branch, skip only the row-0 check and the unordered-count check, and keep the other three.
  2. The skip is printed, not reported as a skip (GdsAppendConsume.cpp:353-354).
    • The executable still exits 0, so ctest shows a pass.
    • check_skips.py and the CI summaries will not show that the split case was skipped on that driver. The line is visible only with -V.
    • Continuing with the other cases is reasonable, so this is not a request to exit 77. Consider printing it in a form the CI scripts already recognise, or mention it in the test's success line.
  3. The debt entry states the cause as fact (docs/dev/debt/shader.md:206).
    • "AMD's Windows driver starts row 0 of a 1 x 65535 dispatch late" rests on one report, and the author has asked for a rerun to confirm it.
    • Also, the case dispatches 1 x 65537 groups in chunks of 65535.
    • Suggested wording: "on AMD's Windows driver (RX 9070 XT) row 0 of the first 65535-row chunk is served about 65,300 places late, read as a late start". Then update it once BunnyFl's skip line confirms or refutes that reading.

Not verified

  • All ordering, abandon, split-dispatch and CPU-copy paths, including the new skip branch. They skip on lavapipe (8-lane subgroups). The fill and barrier sequence was therefore not seen by the validation layer here.
  • The late-start explanation on AMD's Windows driver. I have no matching hardware, and BunnyFl's rerun is not in the thread yet.
  • The RADV split-case pass (3 of 3, 0 VUID- lines). Author-reported.
  • PPSA08329 and the frame-time A/B. No title was run.

To get this to a good state

  • Get BunnyFl's rerun of agc_driver_gds_append_consume -V on the RX 9070 XT. The skip line (first-served row, unordered count) should support the late-start reading.
  • Keep the second-chunk, skipped-row and counter checks in the late-start branch, so the per-chunk reset stays covered on that driver.
  • Optionally:
    • make the skip visible outside -V;
    • word the debt sentence as an observation until the rerun confirms it.
  • Settle the disk cache format number before landing.
<!-- greyfinch-sync:boykopovar/AnyPS5:review:5748608193 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5748608193). Originally posted by [XairRrR](https://github.com/XairRrR) on 2026-11-03T07:37:25Z. **Review:** COMMENTED --- # Re-checked — comments The new commit `f30287c436` responds to BunnyFl's split-dispatch failure on AMD's Windows driver. When row 0 is served more than half a chunk late, the test now prints a skip line instead of failing, and the debt entry names the start-order assumption and says chunks are ordered by the barrier between them. The checks pass. Two things keep this at comments: nobody has yet confirmed the late-start explanation on that driver, and the early return also skips the second-chunk checks, which do not depend on row 0. ## What changed since my last review - **One new commit, `f30287c436`.** It changes only `GdsAppendConsume.cpp` and `docs/dev/debt/shader.md`. The PR's earlier commits are unchanged (delta.patch). - `CheckChunkedRecovery` now prints `split-dispatch case skipped: row 0 started late ...` and returns when all three of these hold: - row 0's value is not the start value; - it is more than `limit / 2` places late; - it is within the dispatch. The skip line gives the value, the row that got the first value, and the unordered count. If row 0 is wrong but early, the test still fails. - The debt entry for `ds_ordered_count` order now: - says the turn follows `WorkgroupId` and that start order is assumed; - cites the AMD Windows report; - says chunks are ordered by the barrier, not by the turn. - **Author replies:** an explanation of the late value (row 0 started after most of the dispatch), and a request to BunnyFl for a rerun with `-V`. Also a direct reply to CnRJay on CPU-copy reset and the default binding. - **Description:** now says the split case runs on RADV (the RX 9060 XT reports `maxComputeWorkGroupCount[1] = 65535`) and passes there 3 of 3 in both registrations. This is author-reported. ## What I ran Head `f30287c43679db1778513d23be025090688db413`, `main` `d1ae628bc2f62459cce1e9872ba5632c938c71f2`, merged tree `0817b9ad9ebd847b841b08c602a10e7560014bec`. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19). ``` git show f30287c43679db1778513d23be025090688db413 git diff --check d1ae628bc2f62459cce1e9872ba5632c938c71f2...f30287c43679db1778513d23be025090688db413 python3 tools/check_conventions.py --base d1ae628bc2f62459cce1e9872ba5632c938c71f2 ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build --output-on-failure -V -R "^agc_driver_gds_append_consume" git show d1ae628bc2f62459cce1e9872ba5632c938c71f2:core/shader/recompiler/ShaderDiskCache.hpp # FormatVersion on main ``` | Check | Result | |---|---| | `git diff --check` | clean | | `check_conventions.py` | all conventions checks passed | | Configure, build, `libs` (script) | ok | | Selected tests (script) | 2202 run, 2081 passed, 114 skipped (all expected), 0 new failures, 0 timeouts; 7 known failures also fail on `main` | | Validation-layer comparison (script) | 768 tests, layer loaded in 767, 0 tests with new `VUID-` lines | | `agc_driver_gds_append_consume`, `_copied` | skipped (exit 77): "the device's subgroups are narrower than a wave32 (8 lanes)" | | Disk cache format | 52 on the merged tree, 51 on `main` | **Negative control:** none. The only changed test is the split case, and it skips on lavapipe before it reaches the new branch. ## Previous findings - **Blocking 1, the split-dispatch case fails on AMD's Windows driver: resolved, as I suggested, but not yet confirmed.** The driver behaviour is now in the debt entry (`docs/dev/debt/shader.md:206`), and the test detects it and reports it instead of failing (`GdsAppendConsume.cpp:348-355`). The late-start reading fits the value: row 0 holds index 0 and the turn is zeroed just before the chunk. But it is still a hypothesis until BunnyFl's rerun prints the skip line. The description's Tested section now covers the split case on RADV (author-reported). - **Non-blocking 1, the ordering cases never run on lavapipe CI: still open.** `GdsAppendConsume.cpp:470-472` still skips below 32 lanes. - **Non-blocking 2, chunks ordered by the barrier, not by the turn: resolved.** The debt entry now says so. - **Disk cache format 52 collision (oneandonlydean): still open, as agreed.** 52 is one past `main`'s 51. ## New findings ### Blocking None. ### Non-blocking 1. **The late-start skip also drops the checks that pin the per-chunk reset** (`core/libs/prx/libSceAgcDriver/tests/execution/GdsAppendConsume.cpp:354`). - The early `return` skips three checks: - the skipped row is untouched (l.357); - the second chunk's rows are in launch order (l.358-361); - the final counter (l.362-363). - None of them depends on when row 0 started. - The second chunk is the one that tests the reset after an abandoned turn. The dispatch before this case leaves the turn wrapped to 0, so the first chunk does not exercise the reset. - So on the driver where the skip triggers, nothing in this case checks the reset any more. - Suggested fix: in the late-start branch, skip only the row-0 check and the unordered-count check, and keep the other three. 2. **The skip is printed, not reported as a skip** (`GdsAppendConsume.cpp:353-354`). - The executable still exits 0, so ctest shows a pass. - `check_skips.py` and the CI summaries will not show that the split case was skipped on that driver. The line is visible only with `-V`. - Continuing with the other cases is reasonable, so this is not a request to exit 77. Consider printing it in a form the CI scripts already recognise, or mention it in the test's success line. 3. **The debt entry states the cause as fact** (`docs/dev/debt/shader.md:206`). - "AMD's Windows driver starts row 0 of a 1 x 65535 dispatch late" rests on one report, and the author has asked for a rerun to confirm it. - Also, the case dispatches 1 x 65537 groups in chunks of 65535. - Suggested wording: "on AMD's Windows driver (RX 9070 XT) row 0 of the first 65535-row chunk is served about 65,300 places late, read as a late start". Then update it once BunnyFl's skip line confirms or refutes that reading. ## Not verified - **All ordering, abandon, split-dispatch and CPU-copy paths, including the new skip branch.** They skip on lavapipe (8-lane subgroups). The fill and barrier sequence was therefore not seen by the validation layer here. - **The late-start explanation on AMD's Windows driver.** I have no matching hardware, and BunnyFl's rerun is not in the thread yet. - **The RADV split-case pass (3 of 3, 0 `VUID-` lines).** Author-reported. - **PPSA08329 and the frame-time A/B.** No title was run. ## To get this to a good state - Get BunnyFl's rerun of `agc_driver_gds_append_consume -V` on the RX 9070 XT. The skip line (first-served row, unordered count) should support the late-start reading. - Keep the second-chunk, skipped-row and counter checks in the late-start branch, so the per-chunk reset stays covered on that driver. - Optionally: - make the skip visible outside `-V`; - word the debt sentence as an observation until the rerun confirms it. - Settle the disk cache format number before landing. <!-- anyps5-bots job=3169 head=f30287c43679db1778513d23be025090688db413 -->
XairRrR commented 2026-11-03 08:19:12 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by XairRrR on 2026-11-03T08:19:12Z.

Review: COMMENTED


Re-checked — comments

The new commit c9fe574f89 changes how the split-dispatch case handles a late row 0. It now skips only the row 0 check and the unordered-count check. It names the skip in the test's success line, and the debt sentence is now worded as an observation. That resolves my three non-blocking findings from last time. Nothing is blocking. I still can't approve, because every ordering path skips on lavapipe and the late-start reading has not been confirmed on AMD's Windows driver.

What changed since my last review

  • One new commit, c9fe574f89. It touches only GdsAppendConsume.cpp and docs/dev/debt/shader.md. The earlier commits are unchanged (delta.patch).
    • CheckChunkedRecovery now returns a note string. With a late row 0 (lateStart):
      • it skips the rowZero == start check and the unordered-count check;
      • it still checks that the skipped row is untouched, that the second chunk is in launch order after the reset, and the final counter.
    • The device-limit skip and the late-start skip are both appended to the success line gds append consume tests passed (...).
    • The debt entry for ds_ordered_count order now reads "on AMD's Windows driver (RX 9070 XT) row 0 of the first 65535-row chunk was served about 65,300 places late, read as a late start".
  • Author reply to oneandonlydean and me. The author reports a local negative control (a faked late row 0: the skip note is printed and the three remaining checks run). This is author-reported.
  • No rerun from BunnyFl yet.

What I ran

Head c9fe574f89eae4765a9db7ab63225b26184943af, main d1ae628bc2f62459cce1e9872ba5632c938c71f2, merged tree 8e61f4646df862fd981131230909b2d4df19de2d. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19).

git show c9fe574f89eae4765a9db7ab63225b26184943af
git diff --check d1ae628bc2f62459cce1e9872ba5632c938c71f2...c9fe574f89eae4765a9db7ab63225b26184943af
python3 tools/check_conventions.py --base d1ae628bc2f62459cce1e9872ba5632c938c71f2
ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build --output-on-failure -V -R "^agc_driver_gds_append_consume|^guest_job_manager_worker_spin$"
git show d1ae628bc2f62459cce1e9872ba5632c938c71f2:core/shader/recompiler/ShaderDiskCache.hpp   # FormatVersion
git status --porcelain
Check Result
git diff --check clean
check_conventions.py all conventions checks passed
Configure, build, libs (script) ok
Selected tests (script) 2202 run, 2080 passed, 114 skipped (all expected), 0 timeouts; 7 known failures also fail on main; 1 reported as new: guest_job_manager_worker_spin
guest_job_manager_worker_spin rerun passed (4.17 s). It is a CPU-time spin measurement in libSceJobManager, which this PR does not touch, so I read the script's failure as load noise, not as the PR's
Validation-layer comparison (script) 768 tests, layer loaded in 767, 0 tests with new VUID- lines
agc_driver_gds_append_consume, _copied skipped: "the device's subgroups are narrower than a wave32 (8 lanes)"
Disk cache format 52 on the merged tree, 51 on main
Worktree after checks clean

Negative control: none. The changed test is the split case, and it skips on lavapipe before it is reached.

Previous findings

  • The split case failed on AMD's Windows driver (resolved earlier, unconfirmed): still unconfirmed. The test reports the late start instead of failing, but no rerun on the RX 9070 XT has printed the new note yet.
  • The ordering cases never run on lavapipe CI (non-blocking): still open. GdsAppendConsume.cpp still skips below 32 lanes.
  • The late-start skip dropped the order-independent checks (non-blocking): resolved. In GdsAppendConsume.cpp L349-L357, only the row 0 check depends on lateStart. The skipped-row, second-chunk and counter checks run in both cases, and the unordered-count check is guarded at l.359. This also answers oneandonlydean's point.
  • The skip was visible only with -V (non-blocking): resolved. The note is now part of the success line, for the device-limit skip too. The note buffer (320 bytes) holds the longest possible message (302 characters).
  • The debt entry stated the cause as fact (non-blocking): resolved. The wording is now an observation (docs/dev/debt/shader.md:205).
  • Disk cache format 52 collision (oneandonlydean): still open, as agreed. 52 is one past main's 51.

New findings

Blocking

None.

Non-blocking

  1. The debt entry overstates what the split test skips (docs/dev/debt/shader.md:205).
    • It says "the split test then skips its order checks".
    • After this commit, the test still checks the second chunk's launch order and skips only the row 0 value and the unordered count.
    • Suggested wording: "the split test then skips its row 0 and unordered-count checks".

Not verified

  • All ordering, abandon, split-dispatch and CPU-copy paths, including the new lateStart branch. They skip on lavapipe (8-lane subgroups), so the validation layer did not see them here.
  • The late-start reading on AMD's Windows driver. I have no such hardware, and no rerun is in the thread.
  • The RADV passes (3 of 3, 0 VUID- lines) and the faked-late-row negative control. Both are author-reported.
  • PPSA08329 and the frame-time A/B. No title was run.

To get this to a good state

  • Get BunnyFl's rerun of agc_driver_gds_append_consume -V on the RX 9070 XT. The new success-line note should show the first-served row and the unordered count, and the second-chunk checks should pass there.
  • Optionally fix the debt wording above.
  • Settle the disk cache format number before landing.
<!-- greyfinch-sync:boykopovar/AnyPS5:review:5748990757 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5748990757). Originally posted by [XairRrR](https://github.com/XairRrR) on 2026-11-03T08:19:12Z. **Review:** COMMENTED --- # Re-checked — comments The new commit `c9fe574f89` changes how the split-dispatch case handles a late row 0. It now skips only the row 0 check and the unordered-count check. It names the skip in the test's success line, and the debt sentence is now worded as an observation. That resolves my three non-blocking findings from last time. Nothing is blocking. I still can't approve, because every ordering path skips on lavapipe and the late-start reading has not been confirmed on AMD's Windows driver. ## What changed since my last review - **One new commit, `c9fe574f89`.** It touches only `GdsAppendConsume.cpp` and `docs/dev/debt/shader.md`. The earlier commits are unchanged (delta.patch). - `CheckChunkedRecovery` now returns a note string. With a late row 0 (`lateStart`): - it skips the `rowZero == start` check and the unordered-count check; - it still checks that the skipped row is untouched, that the second chunk is in launch order after the reset, and the final counter. - The device-limit skip and the late-start skip are both appended to the success line `gds append consume tests passed (...)`. - The debt entry for `ds_ordered_count` order now reads "on AMD's Windows driver (RX 9070 XT) row 0 of the first 65535-row chunk was served about 65,300 places late, read as a late start". - **Author reply** to oneandonlydean and me. The author reports a local negative control (a faked late row 0: the skip note is printed and the three remaining checks run). This is author-reported. - **No rerun from BunnyFl yet.** ## What I ran Head `c9fe574f89eae4765a9db7ab63225b26184943af`, `main` `d1ae628bc2f62459cce1e9872ba5632c938c71f2`, merged tree `8e61f4646df862fd981131230909b2d4df19de2d`. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19). ``` git show c9fe574f89eae4765a9db7ab63225b26184943af git diff --check d1ae628bc2f62459cce1e9872ba5632c938c71f2...c9fe574f89eae4765a9db7ab63225b26184943af python3 tools/check_conventions.py --base d1ae628bc2f62459cce1e9872ba5632c938c71f2 ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build --output-on-failure -V -R "^agc_driver_gds_append_consume|^guest_job_manager_worker_spin$" git show d1ae628bc2f62459cce1e9872ba5632c938c71f2:core/shader/recompiler/ShaderDiskCache.hpp # FormatVersion git status --porcelain ``` | Check | Result | |---|---| | `git diff --check` | clean | | `check_conventions.py` | all conventions checks passed | | Configure, build, `libs` (script) | ok | | Selected tests (script) | 2202 run, 2080 passed, 114 skipped (all expected), 0 timeouts; 7 known failures also fail on `main`; 1 reported as new: `guest_job_manager_worker_spin` | | `guest_job_manager_worker_spin` rerun | passed (4.17 s). It is a CPU-time spin measurement in libSceJobManager, which this PR does not touch, so I read the script's failure as load noise, not as the PR's | | Validation-layer comparison (script) | 768 tests, layer loaded in 767, 0 tests with new `VUID-` lines | | `agc_driver_gds_append_consume`, `_copied` | skipped: "the device's subgroups are narrower than a wave32 (8 lanes)" | | Disk cache format | 52 on the merged tree, 51 on `main` | | Worktree after checks | clean | **Negative control:** none. The changed test is the split case, and it skips on lavapipe before it is reached. ## Previous findings - **The split case failed on AMD's Windows driver (resolved earlier, unconfirmed): still unconfirmed.** The test reports the late start instead of failing, but no rerun on the RX 9070 XT has printed the new note yet. - **The ordering cases never run on lavapipe CI (non-blocking): still open.** `GdsAppendConsume.cpp` still skips below 32 lanes. - **The late-start skip dropped the order-independent checks (non-blocking): resolved.** In [GdsAppendConsume.cpp L349-L357](https://github.com/boykopovar/AnyPS5/blob/c9fe574f89eae4765a9db7ab63225b26184943af/core/libs/prx/libSceAgcDriver/tests/execution/GdsAppendConsume.cpp#L349-L357), only the row 0 check depends on `lateStart`. The skipped-row, second-chunk and counter checks run in both cases, and the unordered-count check is guarded at l.359. This also answers oneandonlydean's point. - **The skip was visible only with `-V` (non-blocking): resolved.** The note is now part of the success line, for the device-limit skip too. The note buffer (320 bytes) holds the longest possible message (302 characters). - **The debt entry stated the cause as fact (non-blocking): resolved.** The wording is now an observation (`docs/dev/debt/shader.md:205`). - **Disk cache format 52 collision (oneandonlydean): still open, as agreed.** 52 is one past `main`'s 51. ## New findings ### Blocking None. ### Non-blocking 1. **The debt entry overstates what the split test skips** (`docs/dev/debt/shader.md:205`). - It says "the split test then skips its order checks". - After this commit, the test still checks the second chunk's launch order and skips only the row 0 value and the unordered count. - Suggested wording: "the split test then skips its row 0 and unordered-count checks". ## Not verified - **All ordering, abandon, split-dispatch and CPU-copy paths, including the new `lateStart` branch.** They skip on lavapipe (8-lane subgroups), so the validation layer did not see them here. - **The late-start reading on AMD's Windows driver.** I have no such hardware, and no rerun is in the thread. - **The RADV passes (3 of 3, 0 `VUID-` lines) and the faked-late-row negative control.** Both are author-reported. - **PPSA08329 and the frame-time A/B.** No title was run. ## To get this to a good state - Get BunnyFl's rerun of `agc_driver_gds_append_consume -V` on the RX 9070 XT. The new success-line note should show the first-served row and the unordered count, and the second-chunk checks should pass there. - Optionally fix the debt wording above. - Settle the disk cache format number before landing. <!-- anyps5-bots job=3187 head=c9fe574f89eae4765a9db7ab63225b26184943af -->
XairRrR commented 2026-11-03 08:45:59 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by XairRrR on 2026-11-03T08:45:59Z.

Review: COMMENTED


Re-checked — comments

Since my last review, two docs-only commits (b337c54562, ace6406bc7) reword the ds_ordered_count order debt entry, and that resolves my one non-blocking finding. Nothing is blocking. I still can't approve: every ordering path skips on lavapipe, and nobody has yet confirmed the late-start reading on AMD's Windows driver.

What changed since my last review

  • Two new commits, both touching only docs/dev/debt/shader.md. The earlier commits are unchanged (delta.patch).
    • The entry now says "(the split test then skips its row 0 and unordered-count checks)", which is the wording I suggested.
    • "past the 64 KiB guest GDS" is now "past the guest GDS". "A wave that waits" is now "A wave waiting", and "Graphics stages stay unordered" is now "Graphics stays unordered". These edits keep the entry inside the 1000-character limit, and check_conventions accepts it.
  • Author reply that points to these commits. There is no code change.
  • No rerun from BunnyFl on the RX 9070 XT yet.

What I ran

Head ace6406bc7b64bc6b37df87dd4b89f44678ffcf2, main 4f41f4c375f5abb487dbd184fbc150f31994d762, merged tree 4103160086b90619a4fc7ce6b8b7fcb78e6b8121. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19).

git diff c9fe574f89eae4765a9db7ab63225b26184943af ace6406bc7b64bc6b37df87dd4b89f44678ffcf2
git diff --check 4f41f4c375f5abb487dbd184fbc150f31994d762...ace6406bc7b64bc6b37df87dd4b89f44678ffcf2
python3 tools/check_conventions.py --base 4f41f4c375f5abb487dbd184fbc150f31994d762
ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build --output-on-failure -V -R "^agc_driver_gds_append_consume"
VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation ANYPS5_NO_SHADER_CACHE=1 ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx VK_LOADER_DEBUG=error,warn,layer ctest --test-dir build -V -R "^agc_driver_native_depth_uniform_planes$"
git diff --quiet 4f41f4c375f5abb487dbd184fbc150f31994d762 4103160086b90619a4fc7ce6b8b7fcb78e6b8121 -- core/libs/prx/libSceAgcDriver/tests/execution/NativeMultisampleDepth.cpp core/libs/prx/libSceAgcDriver/Graphics/src/DepthSurface.cpp
git status --porcelain
Check Result
git diff --check clean
check_conventions.py All conventions checks passed.
Configure, build, libs (script) ok
Selected tests (script) 2233 ran, 2111 passed, 115 skipped (all expected). 0 new failures, 0 timeouts. 7 tests failed that also fail on main.
agc_driver_gds_append_consume, _copied Both skipped: "the device's subgroups are narrower than a wave32 (8 lanes)"
Validation-layer comparison (script) 771 tests ran. The layer loaded in 770 and was missing in none. 1 test has VUID- lines that the baseline lacks: agc_driver_native_depth_uniform_planes. That test is not this PR's (see below).
Worktree after checks clean
The new VUID comes from `main`
Validation Error: [ VUID-vkCmdDispatch-groupCountX-00386 ] | MessageID = 0x8e927036
vkCmdDispatch(): groupCountX (69144) exceeds device limit maxComputeWorkGroupCount[0] (65535).
1/1 Test #1853: agc_driver_native_depth_uniform_planes ...   Passed    0.33 sec

main added this test after the validation baseline d1ae628bc2, in #14005, so the baseline has no run of it. The VUID comes from the test's own Fetch::Run helper (core/libs/prx/libSceAgcDriver/tests/execution/NativeMultisampleDepth.cpp:509-513), which calls vkCmdDispatch(commands, groups, 1u, 1u) with an X count it does not clamp. This PR leaves that file and DepthSurface.cpp unchanged (the git diff --quiet above found no difference). The PR's dispatch change in recordDispatch only adds the turn-reset barriers and fill, and does not change chunk sizes. So the VUID comes from main, and I don't count it against this PR.

Negative control: none. The new commits change no test or code.

Previous findings

  • The debt entry overstated what the split test skips (non-blocking): resolved. docs/dev/debt/shader.md:205 now says "skips its row 0 and unordered-count checks", which matches CheckChunkedRecovery.
  • The split case on AMD's Windows driver (late-start reading): still open, as unconfirmed. No RX 9070 XT run has printed the new success-line note yet.
  • The ordering cases never run on lavapipe CI (non-blocking): still open. Both registrations still skip on 8-lane subgroups. I re-ran them above to check.
  • Disk cache format 52 collision (oneandonlydean): still open, as agreed. The head did not change it.

New findings

Blocking

None.

Non-blocking

None.

Not verified

  • The ordering, abandon, split-dispatch and CPU-copy paths, including the lateStart branch. They skip on lavapipe, so the validation layer did not see them here.
  • The late-start reading on AMD's Windows driver. I have no such hardware.
  • The RADV passes and the faked-late-row negative control. Both are reported by the author only.
  • PPSA08329 and the frame-time A/B. I did not run a title.

To get this to a good state

  • Get BunnyFl's rerun of agc_driver_gds_append_consume -V on the RX 9070 XT. The success-line note should name the first-served row and the unordered count, and the second-chunk checks should pass.
  • Settle the disk cache format number before landing.
<!-- greyfinch-sync:boykopovar/AnyPS5:review:5749266005 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5749266005). Originally posted by [XairRrR](https://github.com/XairRrR) on 2026-11-03T08:45:59Z. **Review:** COMMENTED --- # Re-checked — comments Since my last review, two docs-only commits (`b337c54562`, `ace6406bc7`) reword the `ds_ordered_count` order debt entry, and that resolves my one non-blocking finding. Nothing is blocking. I still can't approve: every ordering path skips on lavapipe, and nobody has yet confirmed the late-start reading on AMD's Windows driver. ## What changed since my last review - **Two new commits, both touching only `docs/dev/debt/shader.md`.** The earlier commits are unchanged (delta.patch). - The entry now says "(the split test then skips its row 0 and unordered-count checks)", which is the wording I suggested. - "past the 64 KiB guest GDS" is now "past the guest GDS". "A wave that waits" is now "A wave waiting", and "Graphics stages stay unordered" is now "Graphics stays unordered". These edits keep the entry inside the 1000-character limit, and `check_conventions` accepts it. - **Author reply** that points to these commits. There is no code change. - **No rerun from BunnyFl on the RX 9070 XT yet.** ## What I ran Head `ace6406bc7b64bc6b37df87dd4b89f44678ffcf2`, `main` `4f41f4c375f5abb487dbd184fbc150f31994d762`, merged tree `4103160086b90619a4fc7ce6b8b7fcb78e6b8121`. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19). ``` git diff c9fe574f89eae4765a9db7ab63225b26184943af ace6406bc7b64bc6b37df87dd4b89f44678ffcf2 git diff --check 4f41f4c375f5abb487dbd184fbc150f31994d762...ace6406bc7b64bc6b37df87dd4b89f44678ffcf2 python3 tools/check_conventions.py --base 4f41f4c375f5abb487dbd184fbc150f31994d762 ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build --output-on-failure -V -R "^agc_driver_gds_append_consume" VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation ANYPS5_NO_SHADER_CACHE=1 ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx VK_LOADER_DEBUG=error,warn,layer ctest --test-dir build -V -R "^agc_driver_native_depth_uniform_planes$" git diff --quiet 4f41f4c375f5abb487dbd184fbc150f31994d762 4103160086b90619a4fc7ce6b8b7fcb78e6b8121 -- core/libs/prx/libSceAgcDriver/tests/execution/NativeMultisampleDepth.cpp core/libs/prx/libSceAgcDriver/Graphics/src/DepthSurface.cpp git status --porcelain ``` | Check | Result | |---|---| | `git diff --check` | clean | | `check_conventions.py` | All conventions checks passed. | | Configure, build, `libs` (script) | ok | | Selected tests (script) | 2233 ran, 2111 passed, 115 skipped (all expected). 0 new failures, 0 timeouts. 7 tests failed that also fail on `main`. | | `agc_driver_gds_append_consume`, `_copied` | Both skipped: "the device's subgroups are narrower than a wave32 (8 lanes)" | | Validation-layer comparison (script) | 771 tests ran. The layer loaded in 770 and was missing in none. 1 test has `VUID-` lines that the baseline lacks: `agc_driver_native_depth_uniform_planes`. That test is not this PR's (see below). | | Worktree after checks | clean | <details><summary>The new VUID comes from `main`</summary> ``` Validation Error: [ VUID-vkCmdDispatch-groupCountX-00386 ] | MessageID = 0x8e927036 vkCmdDispatch(): groupCountX (69144) exceeds device limit maxComputeWorkGroupCount[0] (65535). 1/1 Test #1853: agc_driver_native_depth_uniform_planes ... Passed 0.33 sec ``` `main` added this test after the validation baseline `d1ae628bc2`, in #14005, so the baseline has no run of it. The VUID comes from the test's own `Fetch::Run` helper (`core/libs/prx/libSceAgcDriver/tests/execution/NativeMultisampleDepth.cpp:509-513`), which calls `vkCmdDispatch(commands, groups, 1u, 1u)` with an X count it does not clamp. This PR leaves that file and `DepthSurface.cpp` unchanged (the `git diff --quiet` above found no difference). The PR's dispatch change in `recordDispatch` only adds the turn-reset barriers and fill, and does not change chunk sizes. So the VUID comes from `main`, and I don't count it against this PR. </details> **Negative control:** none. The new commits change no test or code. ## Previous findings - **The debt entry overstated what the split test skips (non-blocking): resolved.** `docs/dev/debt/shader.md:205` now says "skips its row 0 and unordered-count checks", which matches `CheckChunkedRecovery`. - **The split case on AMD's Windows driver (late-start reading): still open, as unconfirmed.** No RX 9070 XT run has printed the new success-line note yet. - **The ordering cases never run on lavapipe CI (non-blocking): still open.** Both registrations still skip on 8-lane subgroups. I re-ran them above to check. - **Disk cache format 52 collision (oneandonlydean): still open, as agreed.** The head did not change it. ## New findings ### Blocking None. ### Non-blocking None. ## Not verified - **The ordering, abandon, split-dispatch and CPU-copy paths, including the `lateStart` branch.** They skip on lavapipe, so the validation layer did not see them here. - **The late-start reading on AMD's Windows driver.** I have no such hardware. - **The RADV passes and the faked-late-row negative control.** Both are reported by the author only. - **PPSA08329 and the frame-time A/B.** I did not run a title. ## To get this to a good state - Get BunnyFl's rerun of `agc_driver_gds_append_consume -V` on the RX 9070 XT. The success-line note should name the first-served row and the unordered count, and the second-chunk checks should pass. - Settle the disk cache format number before landing. <!-- anyps5-bots job=3196 head=ace6406bc7b64bc6b37df87dd4b89f44678ffcf2 -->
XairRrR commented 2026-11-03 10:45:38 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by XairRrR on 2026-11-03T10:45:38Z.

Review: COMMENTED


Re-checked — comments

The only new commit is oneandonlydean's merge of main 4f41f4c375 (818557b1c1). It moves ShaderDiskCache::FormatVersion from 52 to 53, which settles the cache format collision. Nothing is blocking. I still can't approve, because the ordering cases skip on lavapipe and nobody has confirmed the late-start reading on AMD's Windows driver.

What changed since my last review

  • One merge commit, 818557b1c1, by oneandonlydean. It merges main 4f41f4c375, the same main my last review was merged onto. The PR's own commits are unchanged (delta.patch).
    • I compared the previous merged tree (4103160086) with the current one (36e65e60f9). The only difference is core/shader/recompiler/ShaderDiskCache.hpp: FormatVersion = 52 → 53.
    • main already uses 52 (#10000). The PR adds orderedAppend to encodeArtifact/decodeArtifact, so it needs its own number. 53 gives it one.
  • No new author replies, and the description is unchanged. BunnyFl has not rerun on the RX 9070 XT.

What I ran

Head 818557b1c15a17baf1635e6d6c8b4f36fd7ffc98, main 4f41f4c375f5abb487dbd184fbc150f31994d762, merged tree 36e65e60f92172345da50815b1f247bae32efd66. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19).

git diff --stat 4103160086b90619a4fc7ce6b8b7fcb78e6b8121 36e65e60f92172345da50815b1f247bae32efd66
git diff 4f41f4c375f5abb487dbd184fbc150f31994d762 818557b1c15a17baf1635e6d6c8b4f36fd7ffc98 -- core/shader/recompiler/ShaderDiskCache.hpp core/shader/recompiler/ShaderDiskCache.cpp
git diff --check 4f41f4c375f5abb487dbd184fbc150f31994d762...818557b1c15a17baf1635e6d6c8b4f36fd7ffc98
python3 tools/check_conventions.py --base 4f41f4c375f5abb487dbd184fbc150f31994d762
ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build -j8 --test-load 32 --output-on-failure -R "disk_cache|^agc_driver_gds_append_consume"
git status --porcelain
Check Result
Merged-tree delta since last review ShaderDiskCache.hpp only, 1 line (format 53)
git diff --check clean
check_conventions.py All conventions checks passed.
Configure, build, libs (script) ok
Selected tests (script) 2233 ran, 2111 passed, 115 skipped (all expected). 0 new failures, 0 timeouts. 7 failures are known on main.
agc_shader_disk_cache, _pack_ownership, _large_file pass
agc_driver_gds_append_consume, _copied skipped (subgroups narrower than wave32 on lavapipe)
Validation-layer comparison (script) The layer loaded in 770 of 771 tests and was missing in none. The only new VUID is in agc_driver_native_depth_uniform_planes. That test is not run in the baseline, and the VUID comes from main, as I explained last time. The tree change since then (the format number) cannot affect it.
Worktree after checks clean

Negative control: none. No test or production code changed except the format constant.

Previous findings

  • Disk cache format 52 collision (oneandonlydean): resolved. ShaderDiskCache.hpp:16 is now 53 on the head, and main is at 52. The disk cache tests pass.
  • Split case on AMD's Windows driver, late-start reading: still open, as unconfirmed. There is still no RX 9070 XT run that prints the success-line note.
  • The ordering cases never run on lavapipe CI (non-blocking): still open. Both registrations still skip here.

New findings

Blocking

None.

Non-blocking

None.

Not verified

  • The ordering, abandon, split-dispatch and CPU-copy paths, including the lateStart branch. They skip on lavapipe.
  • The late-start reading on AMD's Windows driver. I have no such hardware.
  • The RADV passes and the faked-late-row negative control. Both are reported by the author only.
  • PPSA08329 and the frame-time A/B. I did not run a title.

To get this to a good state

  • Get BunnyFl's rerun of agc_driver_gds_append_consume -V on the RX 9070 XT. The success-line note should name the first-served row and the unordered count, and the second-chunk checks should pass.
<!-- greyfinch-sync:boykopovar/AnyPS5:review:5750792147 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5750792147). Originally posted by [XairRrR](https://github.com/XairRrR) on 2026-11-03T10:45:38Z. **Review:** COMMENTED --- # Re-checked — comments The only new commit is oneandonlydean's merge of `main` `4f41f4c375` (`818557b1c1`). It moves `ShaderDiskCache::FormatVersion` from 52 to 53, which settles the cache format collision. Nothing is blocking. I still can't approve, because the ordering cases skip on lavapipe and nobody has confirmed the late-start reading on AMD's Windows driver. ## What changed since my last review - **One merge commit, `818557b1c1`, by oneandonlydean.** It merges `main` `4f41f4c375`, the same `main` my last review was merged onto. The PR's own commits are unchanged (delta.patch). - I compared the previous merged tree (`4103160086`) with the current one (`36e65e60f9`). The only difference is `core/shader/recompiler/ShaderDiskCache.hpp`: `FormatVersion = 52` → `53`. - `main` already uses 52 (#10000). The PR adds `orderedAppend` to `encodeArtifact`/`decodeArtifact`, so it needs its own number. 53 gives it one. - No new author replies, and the description is unchanged. BunnyFl has not rerun on the RX 9070 XT. ## What I ran Head `818557b1c15a17baf1635e6d6c8b4f36fd7ffc98`, `main` `4f41f4c375f5abb487dbd184fbc150f31994d762`, merged tree `36e65e60f92172345da50815b1f247bae32efd66`. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19). ``` git diff --stat 4103160086b90619a4fc7ce6b8b7fcb78e6b8121 36e65e60f92172345da50815b1f247bae32efd66 git diff 4f41f4c375f5abb487dbd184fbc150f31994d762 818557b1c15a17baf1635e6d6c8b4f36fd7ffc98 -- core/shader/recompiler/ShaderDiskCache.hpp core/shader/recompiler/ShaderDiskCache.cpp git diff --check 4f41f4c375f5abb487dbd184fbc150f31994d762...818557b1c15a17baf1635e6d6c8b4f36fd7ffc98 python3 tools/check_conventions.py --base 4f41f4c375f5abb487dbd184fbc150f31994d762 ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build -j8 --test-load 32 --output-on-failure -R "disk_cache|^agc_driver_gds_append_consume" git status --porcelain ``` | Check | Result | |---|---| | Merged-tree delta since last review | `ShaderDiskCache.hpp` only, 1 line (format 53) | | `git diff --check` | clean | | `check_conventions.py` | All conventions checks passed. | | Configure, build, `libs` (script) | ok | | Selected tests (script) | 2233 ran, 2111 passed, 115 skipped (all expected). 0 new failures, 0 timeouts. 7 failures are known on `main`. | | `agc_shader_disk_cache`, `_pack_ownership`, `_large_file` | pass | | `agc_driver_gds_append_consume`, `_copied` | skipped (subgroups narrower than wave32 on lavapipe) | | Validation-layer comparison (script) | The layer loaded in 770 of 771 tests and was missing in none. The only new VUID is in `agc_driver_native_depth_uniform_planes`. That test is not run in the baseline, and the VUID comes from `main`, as I explained last time. The tree change since then (the format number) cannot affect it. | | Worktree after checks | clean | **Negative control:** none. No test or production code changed except the format constant. ## Previous findings - **Disk cache format 52 collision (oneandonlydean): resolved.** `ShaderDiskCache.hpp:16` is now 53 on the head, and `main` is at 52. The disk cache tests pass. - **Split case on AMD's Windows driver, late-start reading: still open, as unconfirmed.** There is still no RX 9070 XT run that prints the success-line note. - **The ordering cases never run on lavapipe CI (non-blocking): still open.** Both registrations still skip here. ## New findings ### Blocking None. ### Non-blocking None. ## Not verified - **The ordering, abandon, split-dispatch and CPU-copy paths, including the `lateStart` branch.** They skip on lavapipe. - **The late-start reading on AMD's Windows driver.** I have no such hardware. - **The RADV passes and the faked-late-row negative control.** Both are reported by the author only. - **PPSA08329 and the frame-time A/B.** I did not run a title. ## To get this to a good state - Get BunnyFl's rerun of `agc_driver_gds_append_consume -V` on the RX 9070 XT. The success-line note should name the first-served row and the unordered count, and the second-chunk checks should pass. <!-- anyps5-bots job=3286 head=818557b1c15a17baf1635e6d6c8b4f36fd7ffc98 -->
XairRrR commented 2026-11-03 12:03:22 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by XairRrR on 2026-11-03T12:03:22Z.

Review: COMMENTED


Re-checked — comments

No new commits since 818557b1c1. What changed is the author's replies at 11:45–11:46 and the description, which now says cache format 53. The author's answer on lavapipe is correct, so I'm withdrawing that point. Nothing is blocking. The split case on AMD's Windows driver still needs BunnyFl's rerun.

What changed since my last review

  • Code: none. All 8 PR commits are identical (delta.patch), and the head is still 818557b1c1.
  • Description: now names disk cache format 53, which matches the head.
  • Author replies:
    • Lavapipe can't run the ordering cases because its subgroups are 8 lanes and the guest program is wave32.
    • BunnyFl is asked to rerun on the RX 9070 XT.
    • A summary of the negative controls the author ran locally (reported by the author; I did not reproduce them).

What I ran

Head 818557b1c15a17baf1635e6d6c8b4f36fd7ffc98, main 4f41f4c375f5abb487dbd184fbc150f31994d762, merged tree 246a0c121745326fb6f920555cd7a3bec307a38c. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19).

git diff --check 4f41f4c375f5abb487dbd184fbc150f31994d762...818557b1c15a17baf1635e6d6c8b4f36fd7ffc98
python3 tools/check_conventions.py --base 4f41f4c375f5abb487dbd184fbc150f31994d762
git show 4f41f4c375f5abb487dbd184fbc150f31994d762:core/libs/prx/libSceAgcDriver/tests/execution/GdsAppendConsume.cpp | grep -n subgroupSize
ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build -j8 --test-load 32 -V -R "^agc_driver_gds_append_consume"
git status --porcelain
Check Result
git diff --check clean
check_conventions.py All conventions checks passed.
Configure, build, libs (script) ok
Selected tests (script) 2233 ran, 2111 passed, 115 skipped (all expected). 0 new failures, 0 timeouts. The 7 failures also fail on main.
agc_driver_gds_append_consume, _copied Both skipped: "the device's subgroups are narrower than a wave32 (8 lanes)"
Validation-layer comparison (script) The layer loaded in 770 of 771 tests and was missing in none. One test has a new VUID: agc_driver_native_depth_uniform_planes (VUID-vkCmdDispatch-groupCountX-00386). That test was not run in the baseline, and the VUID comes from main, as I said in an earlier review. This PR's tree has not changed since then.
Worktree after checks clean

Negative control: none. No test or production code changed since my last review.

Previous findings

  • The ordering cases never run on lavapipe CI (non-blocking): no longer applies. I concede this point.
    • The subgroupSize < 32 skip that fires here is already on main, at GdsAppendConsume.cpp#L235-L238. It covers the whole executable, including main's own ordered add and swap cases.
    • Lavapipe reports 8 lanes here, so this is an existing device limitation, not a gap this PR adds.
    • The NVIDIA and RADV CI runs on GPUs with wider subgroups cover these cases.
  • Split case on AMD's Windows driver, late-start reading: still open, still unconfirmed. BunnyFl has been asked again but has not rerun yet. Until then, nobody has shown the success-line note (first-served row and unordered count) on the driver where the case failed.

New findings

Blocking

None.

Non-blocking

None.

Not verified

  • The ordering, abandon, split-dispatch and CPU-copy paths, including the late-start branch. They skip on lavapipe because of the existing wave32 guard.
  • The late-start reading on AMD's Windows driver. I have no such hardware.
  • The RADV passes and the author's local negative controls (1025 vs 1000, 1037 vs 1000, the 30583 bounds read, a forced-late row 0). These are reported by the author only.
  • PPSA08329 and the frame-time A/B. I did not run a title.

To get this to a good state

  • Get BunnyFl's rerun of agc_driver_gds_append_consume -V on the RX 9070 XT at the current head. The success line should name the first-served row and the unordered count, and the second-chunk checks should pass.
<!-- greyfinch-sync:boykopovar/AnyPS5:review:5751841959 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5751841959). Originally posted by [XairRrR](https://github.com/XairRrR) on 2026-11-03T12:03:22Z. **Review:** COMMENTED --- # Re-checked — comments No new commits since `818557b1c1`. What changed is the author's replies at 11:45–11:46 and the description, which now says cache format 53. The author's answer on lavapipe is correct, so I'm withdrawing that point. Nothing is blocking. The split case on AMD's Windows driver still needs BunnyFl's rerun. ## What changed since my last review - **Code:** none. All 8 PR commits are identical (delta.patch), and the head is still `818557b1c1`. - **Description:** now names disk cache format 53, which matches the head. - **Author replies:** - Lavapipe can't run the ordering cases because its subgroups are 8 lanes and the guest program is wave32. - BunnyFl is asked to rerun on the RX 9070 XT. - A summary of the negative controls the author ran locally (reported by the author; I did not reproduce them). ## What I ran Head `818557b1c15a17baf1635e6d6c8b4f36fd7ffc98`, `main` `4f41f4c375f5abb487dbd184fbc150f31994d762`, merged tree `246a0c121745326fb6f920555cd7a3bec307a38c`. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19). ``` git diff --check 4f41f4c375f5abb487dbd184fbc150f31994d762...818557b1c15a17baf1635e6d6c8b4f36fd7ffc98 python3 tools/check_conventions.py --base 4f41f4c375f5abb487dbd184fbc150f31994d762 git show 4f41f4c375f5abb487dbd184fbc150f31994d762:core/libs/prx/libSceAgcDriver/tests/execution/GdsAppendConsume.cpp | grep -n subgroupSize ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build -j8 --test-load 32 -V -R "^agc_driver_gds_append_consume" git status --porcelain ``` | Check | Result | |---|---| | `git diff --check` | clean | | `check_conventions.py` | All conventions checks passed. | | Configure, build, `libs` (script) | ok | | Selected tests (script) | 2233 ran, 2111 passed, 115 skipped (all expected). 0 new failures, 0 timeouts. The 7 failures also fail on `main`. | | `agc_driver_gds_append_consume`, `_copied` | Both skipped: "the device's subgroups are narrower than a wave32 (8 lanes)" | | Validation-layer comparison (script) | The layer loaded in 770 of 771 tests and was missing in none. One test has a new VUID: `agc_driver_native_depth_uniform_planes` (`VUID-vkCmdDispatch-groupCountX-00386`). That test was not run in the baseline, and the VUID comes from `main`, as I said in an earlier review. This PR's tree has not changed since then. | | Worktree after checks | clean | **Negative control:** none. No test or production code changed since my last review. ## Previous findings - **The ordering cases never run on lavapipe CI (non-blocking): no longer applies. I concede this point.** - The `subgroupSize < 32` skip that fires here is already on `main`, at [GdsAppendConsume.cpp#L235-L238](https://github.com/boykopovar/AnyPS5/blob/4f41f4c375f5abb487dbd184fbc150f31994d762/core/libs/prx/libSceAgcDriver/tests/execution/GdsAppendConsume.cpp#L235-L238). It covers the whole executable, including `main`'s own ordered add and swap cases. - Lavapipe reports 8 lanes here, so this is an existing device limitation, not a gap this PR adds. - The NVIDIA and RADV CI runs on GPUs with wider subgroups cover these cases. - **Split case on AMD's Windows driver, late-start reading: still open, still unconfirmed.** BunnyFl has been asked again but has not rerun yet. Until then, nobody has shown the success-line note (first-served row and unordered count) on the driver where the case failed. ## New findings ### Blocking None. ### Non-blocking None. ## Not verified - **The ordering, abandon, split-dispatch and CPU-copy paths, including the late-start branch.** They skip on lavapipe because of the existing wave32 guard. - **The late-start reading on AMD's Windows driver.** I have no such hardware. - **The RADV passes and the author's local negative controls** (1025 vs 1000, 1037 vs 1000, the 30583 bounds read, a forced-late row 0). These are reported by the author only. - **PPSA08329 and the frame-time A/B.** I did not run a title. ## To get this to a good state - Get BunnyFl's rerun of `agc_driver_gds_append_consume -V` on the RX 9070 XT at the current head. The success line should name the first-served row and the unordered count, and the second-chunk checks should pass. <!-- anyps5-bots job=3317 head=818557b1c15a17baf1635e6d6c8b4f36fd7ffc98 -->
XairRrR commented 2026-11-03 16:53:10 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by XairRrR on 2026-11-03T16:53:10Z.

Review: APPROVED


Re-checked — approved

No code changed since 818557b1c1. What's new is BunnyFl's rerun on the RX 9070 XT at this head, where the split-dispatch case passes in full, and the author's reply to it. That closes the last open item from my previous review.

What changed since my last review

  • Code: none. delta.patch shows all 8 PR commits unchanged, and the head is still 818557b1c1.
  • BunnyFl's rerun (14:51). Setup: head 818557b1c1, Windows 11, AMD Radeon RX 9070 XT, AMD driver 32.0.32015.12012, validation layer loaded.
    • agc_driver_gds_append_consume and _copied passed 20 of 20 runs.
    • The other GDS tests and agc_driver_pm4 passed 3 of 3.
    • Every run printed the plain success line, so the strict path ran: row 0 got the start value, and the unordered count was exactly limit - 2.
    • No VUID- lines.
    • The late-row-0 skip never fired. BunnyFl cannot say whether the change of driver or the change of tree explains the earlier failure.
  • Author reply (16:23). The author attributes the difference most likely to the driver update. They offer to reword the debt sentence and leave the tree as it is otherwise.

What I ran

Head 818557b1c15a17baf1635e6d6c8b4f36fd7ffc98, main 4f41f4c375f5abb487dbd184fbc150f31994d762, merged tree 88f3e0e71c32fb2d40e6a7d07bd4d45d90963c48. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19).

git diff --check 4f41f4c375f5abb487dbd184fbc150f31994d762...818557b1c15a17baf1635e6d6c8b4f36fd7ffc98
python3 tools/check_conventions.py --base 4f41f4c375f5abb487dbd184fbc150f31994d762
ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build -j8 --test-load 32 -V -R "^agc_driver_gds_append_consume"
git status --porcelain
Check Result
git diff --check clean
check_conventions.py All conventions checks passed.
Configure, build, libs (script) ok
Selected tests (script) 2217 ran, 2095 passed, 115 skipped (all expected). 0 new failures, 0 timeouts. The 7 failures also fail on main.
Validation-layer comparison (script) The layer loaded in 770 of 771 tests and was missing in none. 0 tests have new VUID- lines.
agc_driver_gds_append_consume, _copied Both skipped: "the device's subgroups are narrower than a wave32 (8 lanes)". This skip already exists on main.
Worktree after checks clean

Negative control: none. No test or production code changed since my last review.

Previous findings

  • Split case on AMD's Windows driver, late-start reading: Resolved.
    • At this head on the RX 9070 XT, the case passes on its strict path, 20 of 20 runs across both registrations. That covers row 0 equal to the start value and the exact unordered count. The checks are at GdsAppendConsume.cpp#L349-L358.
    • Where row 0 does start late, the skip path still runs the checks that don't depend on start order: the skipped row, the second chunk's order and the final counter. So the earlier failure cannot come back as a silent pass.
    • The late-start explanation is still unconfirmed, as BunnyFl and the author both say.
    • On the offered debt rewording: BunnyFl wrote that the failing run did not log its driver. If the sentence is changed, it should not name …7029 as the driver the failure was seen on.

New findings

Blocking

None.

Non-blocking

None.

Not verified

  • The ordering, abandon, split-dispatch and CPU-copy paths. On lavapipe they skip because of the existing wave32 guard. The evidence that they pass at this head comes from others' runs, which I did not reproduce:

    • TechLevelZero's NVIDIA RTX 2000 Ada run;
    • BunnyFl's RX 9070 XT run;
    • the author's RADV runs.

    The AMD RX 6300 CI run was on ace6406, which differs from this head only by the merge from main.

  • The author's local negative controls (1025 vs 1000, 1037 vs 1000, the 30583 bounds read, a forced-late row 0). These are reported by the author only.

  • PPSA08329 and the frame-time A/B. I did not run a title.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5756227611 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5756227611). Originally posted by [XairRrR](https://github.com/XairRrR) on 2026-11-03T16:53:10Z. **Review:** APPROVED --- # Re-checked — approved No code changed since `818557b1c1`. What's new is BunnyFl's rerun on the RX 9070 XT at this head, where the split-dispatch case passes in full, and the author's reply to it. That closes the last open item from my previous review. ## What changed since my last review - **Code:** none. delta.patch shows all 8 PR commits unchanged, and the head is still `818557b1c1`. - **BunnyFl's rerun (14:51).** Setup: head `818557b1c1`, Windows 11, AMD Radeon RX 9070 XT, AMD driver 32.0.32015.12012, validation layer loaded. - `agc_driver_gds_append_consume` and `_copied` passed 20 of 20 runs. - The other GDS tests and `agc_driver_pm4` passed 3 of 3. - Every run printed the plain success line, so the strict path ran: row 0 got the start value, and the unordered count was exactly `limit - 2`. - No `VUID-` lines. - The late-row-0 skip never fired. BunnyFl cannot say whether the change of driver or the change of tree explains the earlier failure. - **Author reply (16:23).** The author attributes the difference most likely to the driver update. They offer to reword the debt sentence and leave the tree as it is otherwise. ## What I ran Head `818557b1c15a17baf1635e6d6c8b4f36fd7ffc98`, `main` `4f41f4c375f5abb487dbd184fbc150f31994d762`, merged tree `88f3e0e71c32fb2d40e6a7d07bd4d45d90963c48`. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19). ``` git diff --check 4f41f4c375f5abb487dbd184fbc150f31994d762...818557b1c15a17baf1635e6d6c8b4f36fd7ffc98 python3 tools/check_conventions.py --base 4f41f4c375f5abb487dbd184fbc150f31994d762 ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build -j8 --test-load 32 -V -R "^agc_driver_gds_append_consume" git status --porcelain ``` | Check | Result | |---|---| | `git diff --check` | clean | | `check_conventions.py` | All conventions checks passed. | | Configure, build, `libs` (script) | ok | | Selected tests (script) | 2217 ran, 2095 passed, 115 skipped (all expected). 0 new failures, 0 timeouts. The 7 failures also fail on `main`. | | Validation-layer comparison (script) | The layer loaded in 770 of 771 tests and was missing in none. 0 tests have new `VUID-` lines. | | `agc_driver_gds_append_consume`, `_copied` | Both skipped: "the device's subgroups are narrower than a wave32 (8 lanes)". This skip already exists on `main`. | | Worktree after checks | clean | **Negative control:** none. No test or production code changed since my last review. ## Previous findings - **Split case on AMD's Windows driver, late-start reading: Resolved.** - At this head on the RX 9070 XT, the case passes on its strict path, 20 of 20 runs across both registrations. That covers row 0 equal to the start value and the exact unordered count. The checks are at [GdsAppendConsume.cpp#L349-L358](https://github.com/boykopovar/AnyPS5/blob/818557b1c15a17baf1635e6d6c8b4f36fd7ffc98/core/libs/prx/libSceAgcDriver/tests/execution/GdsAppendConsume.cpp#L349-L358). - Where row 0 does start late, the skip path still runs the checks that don't depend on start order: the skipped row, the second chunk's order and the final counter. So the earlier failure cannot come back as a silent pass. - The late-start explanation is still unconfirmed, as BunnyFl and the author both say. - On the offered debt rewording: BunnyFl wrote that the failing run did not log its driver. If the sentence is changed, it should not name `…7029` as the driver the failure was seen on. ## New findings ### Blocking None. ### Non-blocking None. ## Not verified - **The ordering, abandon, split-dispatch and CPU-copy paths.** On lavapipe they skip because of the existing wave32 guard. The evidence that they pass at this head comes from others' runs, which I did not reproduce: - TechLevelZero's NVIDIA RTX 2000 Ada run; - BunnyFl's RX 9070 XT run; - the author's RADV runs. The AMD RX 6300 CI run was on `ace6406`, which differs from this head only by the merge from `main`. - **The author's local negative controls** (1025 vs 1000, 1037 vs 1000, the 30583 bounds read, a forced-late row 0). These are reported by the author only. - **PPSA08329 and the frame-time A/B.** I did not run a title. <!-- anyps5-bots job=3450 head=818557b1c15a17baf1635e6d6c8b4f36fd7ffc98 -->
XairRrR commented 2026-11-03 19:59:42 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by XairRrR on 2026-11-03T19:59:42Z.

Review: APPROVED


Re-checked — approved

The only new commit is 390b05a599, which merges main 086c0686c8 into the branch. The PR's own changes come through it unchanged apart from line offsets, so my approval of 818557b1c1 still holds.

What changed since my last review

  • Code: delta.patch shows the 8 PR commits are the same as before. The only new commit is the merge 390b05a599.
    • I compared git diff 4f41f4c375 818557b1c1 with git diff 086c0686c8 390b05a599. The added and removed lines are the same in both; only hunk offsets and context lines differ.
    • For example, the GdsBindingBytes import check in the VulkanDevice constructor now sits after main's new oversizedBuffer lines. The resetOrderedTurn lambda and the per-chunk reset in recordDispatch are unchanged.
  • Cache format: main at 086c0686c8 has ShaderDiskCache FormatVersion = 52. The merged tree has 53, so the format is still distinct from main's.
  • Interaction with main: the 141 files main changed since 4f41f4c375 add or remove no lines that mention GdsBytes, GdsAddress, DataOrdered*, OpArrayLength or gdsLength.
  • Description and discussion: nothing new since the author's 16:23 reply, which my previous review already covered.

What I ran

Head 390b05a599a13176b5b4add8cfc2856ba2eb5519, main 086c0686c8adff3ee648fdbe34e0b0b647e1d511, merged tree 8ef8ee6a829c5ddb2e120b9437c451ad1e991804. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19).

git diff 4f41f4c375f5abb487dbd184fbc150f31994d762 818557b1c15a17baf1635e6d6c8b4f36fd7ffc98
git diff 086c0686c8adff3ee648fdbe34e0b0b647e1d511 390b05a599a13176b5b4add8cfc2856ba2eb5519
git diff --check 086c0686c8adff3ee648fdbe34e0b0b647e1d511...390b05a599a13176b5b4add8cfc2856ba2eb5519
python3 tools/check_conventions.py --base 086c0686c8adff3ee648fdbe34e0b0b647e1d511
ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build -j8 --test-load 32 -V -R "^agc_driver_gds_append_consume|^agc_atomic_gds_size|^agc_driver_gds_dma_fill|^agc_guarded_memory_loads"
git status --porcelain
Check Result
git diff --check clean
check_conventions.py All conventions checks passed.
Configure, build, libs (script) ok
Selected tests (script) 2242 ran, 2119 passed, 116 skipped (all expected). 0 new failures, 0 timeouts. The 7 failures also fail on main.
agc_atomic_gds_size, agc_driver_gds_dma_fill, _private, agc_guarded_memory_loads pass
agc_driver_gds_append_consume, _copied Both skipped: "the device's subgroups are narrower than a wave32 (8 lanes)". This guard already exists on main.
Validation-layer comparison (script) The layer loaded in 783 of 784 tests and was missing in none. One test has new VUID- lines: agc_driver_image_gather_volume (VUID-VkSamplerCreateInfo-addressModeU-01079 and others). They come from main, not this PR: the test's source tests/execution/ImageGatherVolume.cpp is in main 086c0686c8 but not in the baseline 1e658521a0, and this PR doesn't touch it.
Worktree after checks clean

Negative control: none. No test or production code changed since my last review.

Previous findings

My previous review had no open findings: the AMD Windows split-dispatch item was already resolved. Nothing in the merge reopens it, because the PR's diff to the test and the driver paths is unchanged.

New findings

Blocking

None.

Non-blocking

None.

Not verified

  • The ordering, abandon, split-dispatch and CPU-copy paths. They still skip on lavapipe because of the wave32 guard. The evidence that they pass comes from other people's runs on earlier heads with the same PR diff, which I did not reproduce: TechLevelZero's NVIDIA and AMD RX 6300 runs, BunnyFl's RX 9070 XT run, and the author's RADV runs. No hardware run at 390b05a599 has been posted yet.
  • The author's local negative controls, reported by the author only.
  • PPSA08329 and the frame-time A/B. I did not run a title.
<!-- greyfinch-sync:boykopovar/AnyPS5:review:5758679590 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5758679590). Originally posted by [XairRrR](https://github.com/XairRrR) on 2026-11-03T19:59:42Z. **Review:** APPROVED --- # Re-checked — approved The only new commit is `390b05a599`, which merges `main` `086c0686c8` into the branch. The PR's own changes come through it unchanged apart from line offsets, so my approval of `818557b1c1` still holds. ## What changed since my last review - **Code:** delta.patch shows the 8 PR commits are the same as before. The only new commit is the merge `390b05a599`. - I compared `git diff 4f41f4c375 818557b1c1` with `git diff 086c0686c8 390b05a599`. The added and removed lines are the same in both; only hunk offsets and context lines differ. - For example, the `GdsBindingBytes` import check in the `VulkanDevice` constructor now sits after `main`'s new `oversizedBuffer` lines. The `resetOrderedTurn` lambda and the per-chunk reset in `recordDispatch` are unchanged. - **Cache format:** `main` at `086c0686c8` has `ShaderDiskCache` `FormatVersion = 52`. The merged tree has 53, so the format is still distinct from `main`'s. - **Interaction with `main`:** the 141 files `main` changed since `4f41f4c375` add or remove no lines that mention `GdsBytes`, `GdsAddress`, `DataOrdered*`, `OpArrayLength` or `gdsLength`. - **Description and discussion:** nothing new since the author's 16:23 reply, which my previous review already covered. ## What I ran Head `390b05a599a13176b5b4add8cfc2856ba2eb5519`, `main` `086c0686c8adff3ee648fdbe34e0b0b647e1d511`, merged tree `8ef8ee6a829c5ddb2e120b9437c451ad1e991804`. Debian 13 VM (Xeon Gold 6136), GCC 14.2.0, Release, lavapipe (Mesa 26.1.6, LLVM 19). ``` git diff 4f41f4c375f5abb487dbd184fbc150f31994d762 818557b1c15a17baf1635e6d6c8b4f36fd7ffc98 git diff 086c0686c8adff3ee648fdbe34e0b0b647e1d511 390b05a599a13176b5b4add8cfc2856ba2eb5519 git diff --check 086c0686c8adff3ee648fdbe34e0b0b647e1d511...390b05a599a13176b5b4add8cfc2856ba2eb5519 python3 tools/check_conventions.py --base 086c0686c8adff3ee648fdbe34e0b0b647e1d511 ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx ctest --test-dir build -j8 --test-load 32 -V -R "^agc_driver_gds_append_consume|^agc_atomic_gds_size|^agc_driver_gds_dma_fill|^agc_guarded_memory_loads" git status --porcelain ``` | Check | Result | |---|---| | `git diff --check` | clean | | `check_conventions.py` | All conventions checks passed. | | Configure, build, `libs` (script) | ok | | Selected tests (script) | 2242 ran, 2119 passed, 116 skipped (all expected). 0 new failures, 0 timeouts. The 7 failures also fail on `main`. | | `agc_atomic_gds_size`, `agc_driver_gds_dma_fill`, `_private`, `agc_guarded_memory_loads` | pass | | `agc_driver_gds_append_consume`, `_copied` | Both skipped: "the device's subgroups are narrower than a wave32 (8 lanes)". This guard already exists on `main`. | | Validation-layer comparison (script) | The layer loaded in 783 of 784 tests and was missing in none. One test has new `VUID-` lines: `agc_driver_image_gather_volume` (`VUID-VkSamplerCreateInfo-addressModeU-01079` and others). They come from `main`, not this PR: the test's source `tests/execution/ImageGatherVolume.cpp` is in `main` `086c0686c8` but not in the baseline `1e658521a0`, and this PR doesn't touch it. | | Worktree after checks | clean | **Negative control:** none. No test or production code changed since my last review. ## Previous findings My previous review had no open findings: the AMD Windows split-dispatch item was already resolved. Nothing in the merge reopens it, because the PR's diff to the test and the driver paths is unchanged. ## New findings ### Blocking None. ### Non-blocking None. ## Not verified - **The ordering, abandon, split-dispatch and CPU-copy paths.** They still skip on lavapipe because of the wave32 guard. The evidence that they pass comes from other people's runs on earlier heads with the same PR diff, which I did not reproduce: TechLevelZero's NVIDIA and AMD RX 6300 runs, BunnyFl's RX 9070 XT run, and the author's RADV runs. No hardware run at `390b05a599` has been posted yet. - **The author's local negative controls**, reported by the author only. - **PPSA08329 and the frame-time A/B.** I did not run a title. <!-- anyps5-bots job=3566 head=390b05a599a13176b5b4add8cfc2856ba2eb5519 -->
BunnyFl commented 2026-11-06 14:10:22 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by BunnyFl on 2026-11-06T14:10:22Z.

Review: APPROVED


@ZSWolt approving at c95587e63b. My only formal review here is the 11-02 comment on 5332c91593 about the late row 0. The split-dispatch case now reports that case instead of failing, and my 11-06 rerun at this head passed. This adds the gated run with a negative control that I hadn't done.

What I ran. This head merged onto main 1ff0fe98aa (merge 98ea5d2326, clean), Windows 11 Pro, WinLibs GCC, Release, AMD Radeon RX 9070 XT (vulkaninfo: driverInfo 26.10.2 (LLPC), driverVersion 2.0.416), with ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1, VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation and ctest -V:

  • agc_atomic_gds_size, agc_driver_gds_append_consume, agc_driver_gds_append_consume_copied, agc_driver_gds_dma_fill, agc_driver_gds_dma_fill_private, agc_driver_pm4 and agc_guarded_memory_loads: 7 of 7 pass, none unbuilt or skipped. Both append-consume tests print the plain gds append consume tests passed, the empty-note branch at GdsAppendConsume.cpp:533-534; neither skip note fired.
  • No missing-layer line, no VUID- and no SYNC-HAZARD ids.
  • Negative control: the same merge with only core/shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvMemoryInstructions.cpp taken from main fails both append-consume tests, with group 0 lane 0 returned 1032, expected 1000 (the counter in launch order) and returned 1012 for the copied registration. The other five still pass.

Overlap, checked with tools/pr_overlap.py --branch at this head:

  • core/shader/recompiler/ShaderDiskCache.hpp L16 (the cache format number) is shared with 13 open pull requests; whichever lands later takes the next number, as with your earlier merges.
  • #6146 changes GuestBufferMemory.hpp L607 on main, which this branch also changes. Both are in the review queue; one of you will need to merge after the other lands.
  • #12840 shares VulkanDevice.cpp L5904 and ShaderResources.hpp L265, and #14247 shares docs/dev/debt/shader.md L210-211.
  • 94 more pull requests touch the same files but conflict with main and could not be compared.

Approving.

AI-assisted: yes (Claude Code)

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5801252799 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5801252799). Originally posted by [BunnyFl](https://github.com/BunnyFl) on 2026-11-06T14:10:22Z. **Review:** APPROVED --- @ZSWolt approving at `c95587e63b`. My only formal review here is the 11-02 comment on `5332c91593` about the late row 0. The split-dispatch case now reports that case instead of failing, and my 11-06 rerun at this head passed. This adds the gated run with a negative control that I hadn't done. **What I ran.** This head merged onto `main` `1ff0fe98aa` (merge `98ea5d2326`, clean), Windows 11 Pro, WinLibs GCC, Release, AMD Radeon RX 9070 XT (`vulkaninfo`: driverInfo `26.10.2 (LLPC)`, driverVersion `2.0.416`), with `ANYPS5_REQUIRE_VULKAN=1`, `ANYPS5_NO_SHADER_CACHE=1`, `VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation` and `ctest -V`: - `agc_atomic_gds_size`, `agc_driver_gds_append_consume`, `agc_driver_gds_append_consume_copied`, `agc_driver_gds_dma_fill`, `agc_driver_gds_dma_fill_private`, `agc_driver_pm4` and `agc_guarded_memory_loads`: 7 of 7 pass, none unbuilt or skipped. Both append-consume tests print the plain `gds append consume tests passed`, the empty-note branch at `GdsAppendConsume.cpp:533-534`; neither skip note fired. - No missing-layer line, no `VUID-` and no `SYNC-HAZARD` ids. - Negative control: the same merge with only `core/shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvMemoryInstructions.cpp` taken from `main` fails both append-consume tests, with `group 0 lane 0 returned 1032, expected 1000 (the counter in launch order)` and `returned 1012` for the copied registration. The other five still pass. **Overlap**, checked with `tools/pr_overlap.py --branch` at this head: - `core/shader/recompiler/ShaderDiskCache.hpp` L16 (the cache format number) is shared with 13 open pull requests; whichever lands later takes the next number, as with your earlier merges. - #6146 changes `GuestBufferMemory.hpp` L607 on `main`, which this branch also changes. Both are in the review queue; one of you will need to merge after the other lands. - #12840 shares `VulkanDevice.cpp` L5904 and `ShaderResources.hpp` L265, and #14247 shares `docs/dev/debt/shader.md` L210-211. - 94 more pull requests touch the same files but conflict with `main` and could not be compared. Approving. AI-assisted: yes (Claude Code)
BunnyFl commented 2026-11-06 18:34:42 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by BunnyFl on 2026-11-06T18:34:42Z.

Review: APPROVED


@ZSWolt re-checked at 3f6d916dd5, and my approval stands.

3f6d916dd5 merges main (cefc546c86) onto c95587e63b, the head I approved. The PR's own +/- lines are identical at both heads in every file it changes.

What I ran

Windows 11 Pro 10.0.26300, WinLibs GCC 15.2.0, Release, this head merged onto current main (merge cefe4daece). The GPU is an AMD Radeon RX 9070 XT (0x1002:0x7550, Vulkan API 0x404167, as the test logs report it). Windows reports driver 32.0.32015.12012, read right after the runs; the logs don't print it. ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation, ctest -V, with the same seven tests as at my approval:

  • PR: agc_atomic_gds_size, agc_driver_gds_append_consume, agc_driver_gds_append_consume_copied, agc_driver_gds_dma_fill, agc_driver_gds_dma_fill_private, agc_driver_pm4 and agc_guarded_memory_loads: 7 of 7 pass.
  • Negative control: the same tree with main's core/shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvMemoryInstructions.cpp. agc_driver_gds_append_consume and agc_driver_gds_append_consume_copied fail; 5 of 7 pass.
  • Neither log reports was not found but was requested by env var VK_INSTANCE_LAYERS. Both have no VUID- and no SYNC-HAZARD IDs.
  • tools/check_conventions.py --base upstream/main --head on this head: all checks pass.

Overlap

tools/pr_overlap.py --branch on this head:

  • #6146 still conflicts at Graphics/include/GuestBufferMemory.hpp L607, as at my approval.
  • New since then: #12840 conflicts at Execution/src/VulkanDevice.cpp L5904 and Graphics/include/ShaderResources.hpp L265.
  • 14 PRs change the same line of core/shader/recompiler/ShaderDiskCache.hpp (L16), the shader cache format number.

AI-assisted: yes (Claude Code)

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5805098787 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5805098787). Originally posted by [BunnyFl](https://github.com/BunnyFl) on 2026-11-06T18:34:42Z. **Review:** APPROVED --- @ZSWolt re-checked at `3f6d916dd5`, and my approval stands. `3f6d916dd5` merges `main` (`cefc546c86`) onto `c95587e63b`, the head I approved. The PR's own +/- lines are identical at both heads in every file it changes. ## What I ran Windows 11 Pro 10.0.26300, WinLibs GCC 15.2.0, Release, this head merged onto current `main` (merge `cefe4daece`). The GPU is an AMD Radeon RX 9070 XT (`0x1002:0x7550`, Vulkan API `0x404167`, as the test logs report it). Windows reports driver 32.0.32015.12012, read right after the runs; the logs don't print it. `ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation`, `ctest -V`, with the same seven tests as at my approval: - PR: `agc_atomic_gds_size`, `agc_driver_gds_append_consume`, `agc_driver_gds_append_consume_copied`, `agc_driver_gds_dma_fill`, `agc_driver_gds_dma_fill_private`, `agc_driver_pm4` and `agc_guarded_memory_loads`: 7 of 7 pass. - Negative control: the same tree with `main`'s `core/shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvMemoryInstructions.cpp`. `agc_driver_gds_append_consume` and `agc_driver_gds_append_consume_copied` fail; 5 of 7 pass. - Neither log reports `was not found but was requested by env var VK_INSTANCE_LAYERS`. Both have no `VUID-` and no `SYNC-HAZARD` IDs. - `tools/check_conventions.py --base upstream/main --head` on this head: all checks pass. ## Overlap `tools/pr_overlap.py --branch` on this head: - #6146 still conflicts at `Graphics/include/GuestBufferMemory.hpp` L607, as at my approval. - New since then: #12840 conflicts at `Execution/src/VulkanDevice.cpp` L5904 and `Graphics/include/ShaderResources.hpp` L265. - 14 PRs change the same line of `core/shader/recompiler/ShaderDiskCache.hpp` (L16), the shader cache format number. AI-assisted: yes (Claude Code)
gabichuuuuu commented 2026-11-08 11:50:01 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by gabichuuuuu on 2026-11-08T11:50:01Z.

Review: COMMENTED


Ran 3f6d916dd5 merged on main 302864d48c on Windows 11 x64 (WinLibs GCC 15.2), on an NVIDIA laptop GPU (Turing, driver 621) and an Intel iGPU (driver 101.70xx), with ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1 and VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation (Khronos validation layer 1.4.368), ctest -R '^(agc_guarded_memory_loads|agc_driver_gds_append_consume)' -V.

On the Intel iGPU the change breaks agc_driver_gds_append_consume, which passes on main:

main change, run 1 change, run 2
NVIDIA 2/2 3/3 3/3
Intel 2/2 1/3 1/3

On Intel, both runs fail the same way:

  • agc_driver_gds_append_consume stops with "read-write alias of shared guest memory 0x200000000+0x14000: a page extends past the end of its file". On main, the same test on the same GPU passes.
  • The new agc_driver_gds_append_consume_copied fails with "65538 single-wave groups along y in chunks of 65536, row 1 skips ds_ordered_count: row 65537 in the second chunk returned 0, expected 66536 (the second chunk is ordered after the reset)".

On NVIDIA, all three pass both times. The layer was inserted in every test that opens a device (agc_guarded_memory_loads doesn't open one). No log has was not found but was requested by env var VK_INSTANCE_LAYERS, and no log on either side has a VUID-, so neither Intel failure comes with a validation error.

The description's run is on RADV only, so this is the first run on an Intel driver.

AI-assisted: yes.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5817758153 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5817758153). Originally posted by [gabichuuuuu](https://github.com/gabichuuuuu) on 2026-11-08T11:50:01Z. **Review:** COMMENTED --- Ran `3f6d916dd5` merged on `main` 302864d48c on Windows 11 x64 (WinLibs GCC 15.2), on an NVIDIA laptop GPU (Turing, driver 621) and an Intel iGPU (driver 101.70xx), with `ANYPS5_REQUIRE_VULKAN=1`, `ANYPS5_NO_SHADER_CACHE=1` and `VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation` (Khronos validation layer 1.4.368), `ctest -R '^(agc_guarded_memory_loads|agc_driver_gds_append_consume)' -V`. **On the Intel iGPU the change breaks `agc_driver_gds_append_consume`, which passes on `main`:** | | `main` | change, run 1 | change, run 2 | |---|---|---|---| | NVIDIA | 2/2 | 3/3 | 3/3 | | Intel | 2/2 | 1/3 | 1/3 | On Intel, both runs fail the same way: - `agc_driver_gds_append_consume` stops with "read-write alias of shared guest memory 0x200000000+0x14000: a page extends past the end of its file". On `main`, the same test on the same GPU passes. - The new `agc_driver_gds_append_consume_copied` fails with "65538 single-wave groups along y in chunks of 65536, row 1 skips ds_ordered_count: row 65537 in the second chunk returned 0, expected 66536 (the second chunk is ordered after the reset)". On NVIDIA, all three pass both times. The layer was inserted in every test that opens a device (`agc_guarded_memory_loads` doesn't open one). No log has `was not found but was requested by env var VK_INSTANCE_LAYERS`, and no log on either side has a `VUID-`, so neither Intel failure comes with a validation error. The description's run is on RADV only, so this is the first run on an Intel driver. AI-assisted: yes.
MarcZX10 commented 2026-11-16 21:58:49 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-16T21:58:49Z.

Review: COMMENTED


Reviewed — comments

The inspected code includes launch-order assumptions that the PR documents, but this review did not cover every changed file or run checks, so a formal approval is not justified.

What I ran

Head: 9d2d569f180e22993baeb08004d046c3e2dc1fe8. No commands or tests were run. I read the review description, commit list, manifest and diff, then inspected targeted source ranges.

Results

Check Result Note
Source inspection not run Targeted review only
Tests and prechecks not run No execution environment available

Findings

Blocking

None in the inspected code.

Non-blocking

None.

Not verified

I read Execution/include/Pm4.hpp, Execution/src/Pm4.cpp, targeted ranges of Execution/src/VulkanDevice.cpp, Graphics/include/GuestBufferMemory.hpp, Graphics/include/ShaderResources.hpp, targeted ranges of Graphics/src/GuestBufferMemory.cpp and Graphics/src/ShaderResources.cpp, tests/Pm4.cpp, tests/cmake/agc_driver_graphics_tests.cmake, tests/execution/GdsAppendConsume.cpp, shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvMemoryInstructions.cpp, shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvEmitterHelpers.cpp, and the review documents. Other changed files listed in the manifest were not read, including the remaining recompiler changes, GuardedMemoryLoads.cpp, the new CMake test registration, and docs/dev/debt/shader.md. Runtime behavior, test results, validation output, and performance claims were not independently verified.

To get this to a good state

Nothing is required. Optional: complete review of the unread changed files and run the relevant checks before a formal approval.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5928501765 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5928501765). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-11-16T21:58:49Z. **Review:** COMMENTED --- # Reviewed — comments The inspected code includes launch-order assumptions that the PR documents, but this review did not cover every changed file or run checks, so a formal approval is not justified. ## What I ran Head: `9d2d569f180e22993baeb08004d046c3e2dc1fe8`. No commands or tests were run. I read the review description, commit list, manifest and diff, then inspected targeted source ranges. ## Results | Check | Result | Note | |---|---|---| | Source inspection | not run | Targeted review only | | Tests and prechecks | not run | No execution environment available | ## Findings ### Blocking None in the inspected code. ### Non-blocking None. ## Not verified I read `Execution/include/Pm4.hpp`, `Execution/src/Pm4.cpp`, targeted ranges of `Execution/src/VulkanDevice.cpp`, `Graphics/include/GuestBufferMemory.hpp`, `Graphics/include/ShaderResources.hpp`, targeted ranges of `Graphics/src/GuestBufferMemory.cpp` and `Graphics/src/ShaderResources.cpp`, `tests/Pm4.cpp`, `tests/cmake/agc_driver_graphics_tests.cmake`, `tests/execution/GdsAppendConsume.cpp`, `shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvMemoryInstructions.cpp`, `shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvEmitterHelpers.cpp`, and the review documents. Other changed files listed in the manifest were not read, including the remaining recompiler changes, `GuardedMemoryLoads.cpp`, the new CMake test registration, and `docs/dev/debt/shader.md`. Runtime behavior, test results, validation output, and performance claims were not independently verified. ## To get this to a good state Nothing is required. Optional: complete review of the unread changed files and run the relevant checks before a formal approval.
MarcZX10 commented 2026-11-19 19:38:33 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-19T19:38:33Z.

Review: APPROVED


Reviewed — looks good

Nothing blocks this change; the ordering path, metadata bounds, per-chunk reset, and added coverage are supported by the code inspected.

What I ran

Reviewed head 294347f4dc5e12f6ce0be825679b32e5180a02aa using the prepared diff and repo_read.py at the pinned head. No build or tests were run. Read the changed code and its relevant callers for the ordered SPIR-V emission, input declarations, GDS resource preparation and fill target, dispatch reset, and disk cache format; also read the added append/consume test code and GDS range helpers. The entire files at the head were not read.

Results

Check Result Note
Diff and manifest review passed Changed paths and hunks inspected
Targeted code review passed Relevant paths and callers read
Build and tests not run Author-reported results not independently verified

Findings

Blocking

None.

Non-blocking

None.

Not verified

Did not run a build, tests, validation layers, or console/game checks. Author-reported test and hardware results were not independently verified. Files listed as excluded in files.json were not read in full; relevant changed hunks in VulkanDevice.cpp, GuestBufferMemory.cpp, and ShaderResources.cpp were read through the pinned reader.

To get this to a good state

Nothing is required.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5982022944 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-5982022944). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-11-19T19:38:33Z. **Review:** APPROVED --- # Reviewed — looks good Nothing blocks this change; the ordering path, metadata bounds, per-chunk reset, and added coverage are supported by the code inspected. ## What I ran Reviewed head `294347f4dc5e12f6ce0be825679b32e5180a02aa` using the prepared diff and `repo_read.py` at the pinned head. No build or tests were run. Read the changed code and its relevant callers for the ordered SPIR-V emission, input declarations, GDS resource preparation and fill target, dispatch reset, and disk cache format; also read the added append/consume test code and GDS range helpers. The entire files at the head were not read. ## Results | Check | Result | Note | |---|---|---| | Diff and manifest review | passed | Changed paths and hunks inspected | | Targeted code review | passed | Relevant paths and callers read | | Build and tests | not run | Author-reported results not independently verified | ## Findings ### Blocking None. ### Non-blocking None. ## Not verified Did not run a build, tests, validation layers, or console/game checks. Author-reported test and hardware results were not independently verified. Files listed as excluded in `files.json` were not read in full; relevant changed hunks in `VulkanDevice.cpp`, `GuestBufferMemory.cpp`, and `ShaderResources.cpp` were read through the pinned reader. ## To get this to a good state Nothing is required.
mihiii1337 commented 2026-11-23 01:55:45 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by mihiii1337 on 2026-11-23T01:55:45Z.

Review: CHANGES_REQUESTED


I re-audited the still-open Intel A78B split-dispatch result on exact head 294347f4dc5e12f6ce0be825679b32e5180a02aa before repeating it on the updated driver. The fixture itself runs and reads one row beyond ChunkOutput when the device reports a Y workgroup limit of 65,536, so my earlier row 65537 returned 0 report cannot establish a reset/order defect. Details are inline.

I did not run a new build or hardware test after finding this; the fixture needs to be made in-bounds first.

AI-assisted: yes.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:6015760350 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-6015760350). Originally posted by [mihiii1337](https://github.com/mihiii1337) on 2026-11-23T01:55:45Z. **Review:** CHANGES_REQUESTED --- I re-audited the still-open Intel A78B split-dispatch result on exact head `294347f4dc5e12f6ce0be825679b32e5180a02aa` before repeating it on the updated driver. The fixture itself runs and reads one row beyond `ChunkOutput` when the device reports a Y workgroup limit of 65,536, so my earlier `row 65537 returned 0` report cannot establish a reset/order defect. Details are inline. I did not run a new build or hardware test after finding this; the fixture needs to be made in-bounds first. AI-assisted: yes.
ligmaSec commented 2026-12-03 22:54:31 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by ligmaSec on 2026-12-03T22:54:31Z.

Review: COMMENTED


The trial merge conflicts across the device, shader resources, recompiler and shader-cache schema. Please retain a regression that deliberately has wave arrival order differ from launch order and checks the value returned to each wave, alongside a mixed workload that still uses the unordered path. Those controls cover the ordering guarantee and whether the new state leaks across draws or dispatches. Please put the shader debt edit in a fragment. I have no paired GPU result for this conflicted head.

AI-assisted: yes.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:6180073722 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12944#pullrequestreview-6180073722). Originally posted by [ligmaSec](https://github.com/ligmaSec) on 2026-12-03T22:54:31Z. **Review:** COMMENTED --- The trial merge conflicts across the device, shader resources, recompiler and shader-cache schema. Please retain a regression that deliberately has wave arrival order differ from launch order and checks the value returned to each wave, alongside a mixed workload that still uses the unordered path. Those controls cover the ordering guarantee and whether the new state leaks across draws or dispatches. Please put the shader debt edit in a fragment. I have no paired GPU result for this conflicted head. AI-assisted: yes.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/12944:upstream-pr/12944'
git switch 'upstream-pr/12944'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/12944'
git switch 'upstream-pr/12944'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/12944'
git switch 'upstream-pr/12944'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/12944'
git switch 'main'
git merge --squash 'upstream-pr/12944'
git switch 'main'
git merge --ff-only 'upstream-pr/12944'
git switch 'main'
git merge 'upstream-pr/12944'
git push origin 'main'
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!12944
No description provided.