docs(debt): record the CMASK clear pass fault on AMD without pipeline libraries #7875

Merged
xXPBSXx merged 2 commits from upstream-pr/7875 into main 2026-10-19 17:59:14 +00:00
xXPBSXx commented 2026-10-19 11:57:15 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by xXPBSXx on 2026-10-19T11:57:15Z.


What

agc_driver_cmask_fast_clear (#5150) loses the Vulkan device on AMD's Windows driver when pipeline libraries are off (APS5_NO_GPL=1). Adds a debt entry under Functional, next to the existing CMASK fast-clear entry, that says what is unverified and what is measured; no code changes.

Measured on an AMD Radeon RX 6400 (driver 32.0.21033.3005, Windows 10 19045), main fd423f9b2 and 676d42396, ANYPS5_GPU=Radeon, ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1:

  • ctest -R '^agc_driver_cmask_fast_clear$' --repeat until-fail:5 with APS5_NO_GPL=1 fails on the first run (about 1 s): [device-fault] result 0: GPU fault, read invalid at 0xbeefdeadc000 (precision 0x1000), then vkQueueSubmit recorder: Vulkan result -4 (amd_cmask_run1.txt, lines 54-58).
  • Without APS5_NO_GPL, 5 of 5 pass on the same GPU; on an NVIDIA GeForce RTX 4080 SUPER 5 of 5 pass in both modes.
  • With the linear pass skipped locally, the SW_64KB_R_X pass fails the same way; with cmaskAddress set to 0 locally, no GPU fault occurs. That points at DispatchCmaskClear, which only runs for a target with a resident image (the linear pass has none).

What is not known: which read in that pass hits the address, and why pipeline libraries matter. No fix is claimed.

Tested

Documentation only. tools/check_conventions.py --base upstream/main: all checks passed (the entry is 886 characters). The measurements above were made with local, uncommitted diagnostics in the test; the local diagnostics were discarded.

Checklist

  • Based on current main; no other open PR implements the same functions (#5150 is the issue; #7351 and #7376 concern robustBufferAccess2 on this driver)
  • One topic per PR
  • No comments in code except technical debt
  • Unimplemented paths throw; no new stubs
  • No notes, investigation .md files or images added
  • No new dependencies
  • Generic behaviour, not specific to one title
  • Depends on: none
  • Fixes: none (refs #5150)
  • Unblocks: none
  • GPUs tested: AMD Radeon RX 6400 (32.0.21033.3005, Windows 10 19045) and NVIDIA GeForce RTX 4080 SUPER; documentation only
  • AI-assisted: yes

AI-assisted (Claude Code).

🤖 Generated with Claude Code

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4920541941 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/7875). Originally posted by [xXPBSXx](https://github.com/xXPBSXx) on 2026-10-19T11:57:15Z. --- ### What `agc_driver_cmask_fast_clear` (#5150) loses the Vulkan device on AMD's Windows driver when pipeline libraries are off (`APS5_NO_GPL=1`). Adds a debt entry under Functional, next to the existing CMASK fast-clear entry, that says what is unverified and what is measured; no code changes. Measured on an AMD Radeon RX 6400 (driver 32.0.21033.3005, Windows 10 19045), `main` `fd423f9b2` and `676d42396`, `ANYPS5_GPU=Radeon`, `ANYPS5_REQUIRE_VULKAN=1`, `ANYPS5_NO_SHADER_CACHE=1`: - `ctest -R '^agc_driver_cmask_fast_clear$' --repeat until-fail:5` with `APS5_NO_GPL=1` fails on the first run (about 1 s): `[device-fault] result 0: GPU fault`, `read invalid at 0xbeefdeadc000 (precision 0x1000)`, then `vkQueueSubmit recorder: Vulkan result -4` (`amd_cmask_run1.txt`, lines 54-58). - Without `APS5_NO_GPL`, 5 of 5 pass on the same GPU; on an NVIDIA GeForce RTX 4080 SUPER 5 of 5 pass in both modes. - With the linear pass skipped locally, the `SW_64KB_R_X` pass fails the same way; with `cmaskAddress` set to 0 locally, no GPU fault occurs. That points at `DispatchCmaskClear`, which only runs for a target with a resident image (the linear pass has none). What is not known: which read in that pass hits the address, and why pipeline libraries matter. No fix is claimed. ### Tested Documentation only. `tools/check_conventions.py --base upstream/main`: all checks passed (the entry is 886 characters). The measurements above were made with local, uncommitted diagnostics in the test; the local diagnostics were discarded. ### Checklist - [x] Based on current `main`; no other open PR implements the same functions (#5150 is the issue; #7351 and #7376 concern `robustBufferAccess2` on this driver) - [x] One topic per PR - [x] No comments in code except technical debt - [x] Unimplemented paths throw; no new stubs - [x] No notes, investigation `.md` files or images added - [x] No new dependencies - [x] Generic behaviour, not specific to one title - [x] Depends on: none - [x] Fixes: none (refs #5150) - [x] Unblocks: none - [x] GPUs tested: AMD Radeon RX 6400 (32.0.21033.3005, Windows 10 19045) and NVIDIA GeForce RTX 4080 SUPER; documentation only - [x] AI-assisted: yes AI-assisted (Claude Code). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
github-actions[bot] commented 2026-10-19 12:10:03 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-19T12:10:03Z.


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

Pull request Conflicting files (lines on main) Same exports Same new files
PR 7668 docs/dev/debt/libSceAgcDriver.md L131

Some comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap.

Pull request Shared files not compared
PR 2434 docs/dev/debt/libSceAgcDriver.md
PR 4448 docs/dev/debt/libSceAgcDriver.md
PR 5058 docs/dev/debt/libSceAgcDriver.md
PR 5499 docs/dev/debt/libSceAgcDriver.md
PR 5925 docs/dev/debt/libSceAgcDriver.md
PR 6146 docs/dev/debt/libSceAgcDriver.md
PR 6194 docs/dev/debt/libSceAgcDriver.md
PR 6223 docs/dev/debt/libSceAgcDriver.md
PR 6252 docs/dev/debt/libSceAgcDriver.md
PR 6280 docs/dev/debt/libSceAgcDriver.md
PR 6300 docs/dev/debt/libSceAgcDriver.md
PR 6457 docs/dev/debt/libSceAgcDriver.md
PR 6479 docs/dev/debt/libSceAgcDriver.md
PR 6548 docs/dev/debt/libSceAgcDriver.md
PR 6549 docs/dev/debt/libSceAgcDriver.md
PR 6636 docs/dev/debt/libSceAgcDriver.md
PR 6683 docs/dev/debt/libSceAgcDriver.md
PR 6727 docs/dev/debt/libSceAgcDriver.md
PR 6730 docs/dev/debt/libSceAgcDriver.md
PR 6808 docs/dev/debt/libSceAgcDriver.md
PR 6867 docs/dev/debt/libSceAgcDriver.md
PR 6868 docs/dev/debt/libSceAgcDriver.md
PR 6946 docs/dev/debt/libSceAgcDriver.md
PR 6947 docs/dev/debt/libSceAgcDriver.md
PR 6977 docs/dev/debt/libSceAgcDriver.md
PR 7085 docs/dev/debt/libSceAgcDriver.md
PR 7256 docs/dev/debt/libSceAgcDriver.md
PR 7332 docs/dev/debt/libSceAgcDriver.md
PR 7446 docs/dev/debt/libSceAgcDriver.md
PR 7449 docs/dev/debt/libSceAgcDriver.md
PR 7505 docs/dev/debt/libSceAgcDriver.md
PR 7604 docs/dev/debt/libSceAgcDriver.md
PR 7642 docs/dev/debt/libSceAgcDriver.md
PR 7659 docs/dev/debt/libSceAgcDriver.md
PR 7800 docs/dev/debt/libSceAgcDriver.md
<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6266869257 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/7875#issuecomment-6266869257). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-10-19T12:10:03Z. --- <!-- pr-overlap --> Other open pull requests touch the same code. Merging one will break the other, or both implement the same thing. If this one builds on them, list them in **Depends on**. | Pull request | Conflicting files (lines on `main`) | Same exports | Same new files | |---|---|---|---| | [PR 7668](https://www.github.com/boykopovar/AnyPS5/pull/7668) | `docs/dev/debt/libSceAgcDriver.md` [L131](https://github.com/boykopovar/AnyPS5/blob/8444508241a9e4a6f5d5604d007451ce62d39cc0/docs/dev/debt/libSceAgcDriver.md#L131) | | | Some comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap. | Pull request | Shared files not compared | |---|---| | [PR 2434](https://www.github.com/boykopovar/AnyPS5/pull/2434) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 4448](https://www.github.com/boykopovar/AnyPS5/pull/4448) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 5058](https://www.github.com/boykopovar/AnyPS5/pull/5058) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 5499](https://www.github.com/boykopovar/AnyPS5/pull/5499) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 5925](https://www.github.com/boykopovar/AnyPS5/pull/5925) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6146](https://www.github.com/boykopovar/AnyPS5/pull/6146) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6194](https://www.github.com/boykopovar/AnyPS5/pull/6194) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6223](https://www.github.com/boykopovar/AnyPS5/pull/6223) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6252](https://www.github.com/boykopovar/AnyPS5/pull/6252) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6280](https://www.github.com/boykopovar/AnyPS5/pull/6280) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6300](https://www.github.com/boykopovar/AnyPS5/pull/6300) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6457](https://www.github.com/boykopovar/AnyPS5/pull/6457) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6479](https://www.github.com/boykopovar/AnyPS5/pull/6479) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6548](https://www.github.com/boykopovar/AnyPS5/pull/6548) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6549](https://www.github.com/boykopovar/AnyPS5/pull/6549) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6636](https://www.github.com/boykopovar/AnyPS5/pull/6636) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6683](https://www.github.com/boykopovar/AnyPS5/pull/6683) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6727](https://www.github.com/boykopovar/AnyPS5/pull/6727) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6730](https://www.github.com/boykopovar/AnyPS5/pull/6730) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6808](https://www.github.com/boykopovar/AnyPS5/pull/6808) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6867](https://www.github.com/boykopovar/AnyPS5/pull/6867) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6868](https://www.github.com/boykopovar/AnyPS5/pull/6868) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6946](https://www.github.com/boykopovar/AnyPS5/pull/6946) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6947](https://www.github.com/boykopovar/AnyPS5/pull/6947) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 6977](https://www.github.com/boykopovar/AnyPS5/pull/6977) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 7085](https://www.github.com/boykopovar/AnyPS5/pull/7085) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 7256](https://www.github.com/boykopovar/AnyPS5/pull/7256) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 7332](https://www.github.com/boykopovar/AnyPS5/pull/7332) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 7446](https://www.github.com/boykopovar/AnyPS5/pull/7446) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 7449](https://www.github.com/boykopovar/AnyPS5/pull/7449) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 7505](https://www.github.com/boykopovar/AnyPS5/pull/7505) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 7604](https://www.github.com/boykopovar/AnyPS5/pull/7604) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 7642](https://www.github.com/boykopovar/AnyPS5/pull/7642) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 7659](https://www.github.com/boykopovar/AnyPS5/pull/7659) | `docs/dev/debt/libSceAgcDriver.md` | | [PR 7800](https://www.github.com/boykopovar/AnyPS5/pull/7800) | `docs/dev/debt/libSceAgcDriver.md` |
fogydes commented 2026-10-19 12:23:52 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by fogydes on 2026-10-19T12:23:52Z.

Review: COMMENTED


Verified the documentation entry in docs/dev/debt/libSceAgcDriver.md:

  • Conventions: Validated formatting against tools/check_conventions.py --base origin/main; passes cleanly with 0 findings.
  • Content: Accurately records the unverified DispatchCmaskClear behavior on AMD Windows drivers when APS5_NO_GPL=1 is set, linking the SW_64KB_R_X fault at 0xbeefdeadc000 to issue #5150 and specifying clear criteria for closure.
<!-- greyfinch-sync:boykopovar/AnyPS5:review:5571473846 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/7875#pullrequestreview-5571473846). Originally posted by [fogydes](https://github.com/fogydes) on 2026-10-19T12:23:52Z. **Review:** COMMENTED --- Verified the documentation entry in `docs/dev/debt/libSceAgcDriver.md`: - **Conventions**: Validated formatting against `tools/check_conventions.py --base origin/main`; passes cleanly with 0 findings. - **Content**: Accurately records the unverified `DispatchCmaskClear` behavior on AMD Windows drivers when `APS5_NO_GPL=1` is set, linking the `SW_64KB_R_X` fault at `0xbeefdeadc000` to issue #5150 and specifying clear criteria for closure.
LeandroLP23 commented 2026-10-19 12:33:03 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by LeandroLP23 on 2026-10-19T12:33:03Z.


A second AMD generation, where it fails differently. AMD Radeon 860M (RDNA 3.5, 1002:1114), driver 32.0.13058.8001, Windows 11, WinLibs GCC 15.2.0, Release, ANYPS5_NO_SHADER_CACHE=1. main b106f6f8c.

agc_driver_cmask_fast_clear, 5 runs each:

  • With APS5_NO_GPL=1: fails 5 of 5, but there is no GPU fault and no device loss. The check fails on the contents instead: SW_64KB_R_X fast-cleared target drawn over its left part: texel (0, 0) holds 1515870810 (0x5A5A5A5A). No [device-fault] line and no -4.
  • Without it: passes 5 of 5.

So on RDNA 3.5 the same pass gives wrong contents instead of a read at 0xbeefdeadc000. That still fits the entry's DispatchCmaskClear lead, and it shows the symptom depends on the GPU. The entry could say that the RX 6400 loses the device and the 860M reads back wrong contents.

AI-assisted: yes (Claude Code)

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6267296798 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/7875#issuecomment-6267296798). Originally posted by [LeandroLP23](https://github.com/LeandroLP23) on 2026-10-19T12:33:03Z. --- A second AMD generation, where it fails differently. AMD Radeon 860M (RDNA 3.5, `1002:1114`), driver 32.0.13058.8001, Windows 11, WinLibs GCC 15.2.0, Release, `ANYPS5_NO_SHADER_CACHE=1`. `main` b106f6f8c. `agc_driver_cmask_fast_clear`, 5 runs each: - With `APS5_NO_GPL=1`: fails 5 of 5, but there is no GPU fault and no device loss. The check fails on the contents instead: `SW_64KB_R_X fast-cleared target drawn over its left part: texel (0, 0) holds 1515870810` (`0x5A5A5A5A`). No `[device-fault]` line and no `-4`. - Without it: passes 5 of 5. So on RDNA 3.5 the same pass gives wrong contents instead of a read at `0xbeefdeadc000`. That still fits the entry's `DispatchCmaskClear` lead, and it shows the symptom depends on the GPU. The entry could say that the RX 6400 loses the device and the 860M reads back wrong contents. AI-assisted: yes (Claude Code)
xXPBSXx commented 2026-10-19 12:52:35 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by xXPBSXx on 2026-10-19T12:52:35Z.


Thanks, both. Added the Radeon 860M observation to the debt entry (2368691a9, documentation only): on that GPU the same pass leaves 0x5A5A5A5A in the target without a device loss, while the RX 6400 loses the device. I dropped the sentence that the pass does not fault without a CMASK to keep the entry under 1000 characters (987).

The symptom depends on the GPU, which fits the DispatchCmaskClear lead from the entry; the cause itself is still unknown. On the RX 6400, with cmaskAddress set to 0 locally, no GPU fault occurs; I did not check what the target holds in that case.

AI-assisted (Claude Code).

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6267658496 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/7875#issuecomment-6267658496). Originally posted by [xXPBSXx](https://github.com/xXPBSXx) on 2026-10-19T12:52:35Z. --- Thanks, both. Added the Radeon 860M observation to the debt entry (`2368691a9`, documentation only): on that GPU the same pass leaves `0x5A5A5A5A` in the target without a device loss, while the RX 6400 loses the device. I dropped the sentence that the pass does not fault without a CMASK to keep the entry under 1000 characters (987). The symptom depends on the GPU, which fits the `DispatchCmaskClear` lead from the entry; the cause itself is still unknown. On the RX 6400, with `cmaskAddress` set to 0 locally, no GPU fault occurs; I did not check what the target holds in that case. AI-assisted (Claude Code).
adriadam10 commented 2026-10-19 18:00:13 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-19T18:00:13Z.


Checked that DispatchCmaskClear is the pass named (TextureDetiler.cpp, called from Draw.cpp), that the entry sits next to the CMASK fast-clear entry rather than at the end of the section, and that it states what is unverified and when it closes. Docs only; merged.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6273779846 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/7875#issuecomment-6273779846). Originally posted by [adriadam10](https://github.com/adriadam10) on 2026-10-19T18:00:13Z. --- Checked that `DispatchCmaskClear` is the pass named (`TextureDetiler.cpp`, called from `Draw.cpp`), that the entry sits next to the CMASK fast-clear entry rather than at the end of the section, and that it states what is unverified and when it closes. Docs only; merged.
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!7875
No description provided.