test(agc): account for unknown pending DCC key writes #5883

Merged
AnzouBelilita merged 3 commits from upstream-pr/5883 into main 2026-10-27 03:50:39 +00:00
AnzouBelilita commented 2026-10-14 14:41:08 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by AnzouBelilita on 2026-10-14T14:41:08Z.


What

Update the recorder key-proof test to match the current pending-DCC-write behavior. A generic pending write has no known key value, so ProvedClearKeys must synchronize before it can cache a stable proof. Known pending key fills are already covered by pendingKeyStoreTests.

The old assertion expected repeated unstable scans for an unknown pending write; on current main that expectation fails because PendingStoreKeys correctly waits when it cannot infer the value. This is the same baseline recorder-test failure noted in #5497; this PR changes only the stale test expectation, not the pending-fill implementation.

Tested

  • agc_driver_visual_test --verify on Radeon RX 580 (Windows): passed.
  • agc_driver_recorder_tests on Radeon RX 580 (Windows): exit code 0.
  • Composition #5883 + #6155 + #6642 passed agc_driver_recorder 3/3 on RTX 3070 and lavapipe (see #6642).
  • python3 tools/check_conventions.py --base origin/main: passed.

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 (#6155 is merged; #6642 depends on this PR)
  • Fixes: none
  • Unblocks: none
  • GPUs tested: AMD Radeon RX 580 (Windows), NVIDIA RTX 3070 and lavapipe (Linux, via #6642)
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4859615555 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5883). Originally posted by [AnzouBelilita](https://github.com/AnzouBelilita) on 2026-10-14T14:41:08Z. --- ### What Update the recorder key-proof test to match the current pending-DCC-write behavior. A generic pending write has no known key value, so `ProvedClearKeys` must synchronize before it can cache a stable proof. Known pending key fills are already covered by `pendingKeyStoreTests`. The old assertion expected repeated unstable scans for an unknown pending write; on current `main` that expectation fails because `PendingStoreKeys` correctly waits when it cannot infer the value. This is the same baseline recorder-test failure noted in #5497; this PR changes only the stale test expectation, not the pending-fill implementation. ### Tested - `agc_driver_visual_test --verify` on Radeon RX 580 (Windows): passed. - `agc_driver_recorder_tests` on Radeon RX 580 (Windows): exit code 0. - Composition #5883 + #6155 + #6642 passed `agc_driver_recorder` 3/3 on RTX 3070 and lavapipe (see #6642). - `python3 tools/check_conventions.py --base origin/main`: passed. ### Checklist - [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 (#6155 is merged; #6642 depends on this PR) - [x] Fixes: none - [x] Unblocks: none - [x] GPUs tested: AMD Radeon RX 580 (Windows), NVIDIA RTX 3070 and lavapipe (Linux, via #6642) - [x] AI-assisted: yes
Dextroid17 commented 2026-10-15 01:22:08 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by Dextroid17 on 2026-10-15T01:22:08Z.


I ran this on Linux because my #6155 depends on it (its test run stops at your (9) check without your change).

Setup: main ab9a47684 with this PR's change (one hunk in Recorder.cpp) applied; the PR head is 478 commits behind current main. Default CMake build (CMAKE_BUILD_TYPE empty, unoptimized), ANYPS5_NO_SHADER_CACHE=1, lavapipe (Mesa 26.2.4 llvmpipe, LLVM 23.1.1). agc_driver_recorder_tests with no arguments, 3 runs each:

  • main alone: 3 of 3 exit 1 at "(9) a scan under a pending write was kept".
  • main plus this change: 3 of 3 get past (9) and stop later at "second draw observed overwritten input".
  • main plus this change plus #6155 (which adds the missing MarkWritten calls after the test's direct writes): 3 of 3 exit 0, "Recorder read tracking and label tests passed".

So on lavapipe the new expectations match main's current behaviour and clear the (9) stop. Whether synchronizing before caching a proof is the intended behaviour I did not check. I did not check the RX 580 run or Windows.

The red conventions check has 4 errors. I reproduced all 4 locally with main's tools/check_conventions.py against the same base (f3434892b), passing this PR's title and body:

  • Recorder.cpp:1171: the new // An unknown pending write cannot supply DCC keys... line counts as a code comment, which needs a change to docs/dev/TechnicalDebt.md or docs/dev/debt/ in the same PR. With only that line deleted, the checker no longer reports it.
  • 'What', 'Tested' and 'Checklist' are reported missing because the checker only matches ### headings with those exact names, and the description uses ## and "Tested locally". With ### What and ### Tested, those two clear. The checker then wants a ### Checklist section with no unticked boxes, "Depends on" filled with #N or none, and "AI-assisted" answered yes or no; the template's checklist covers this.

The template checks only run locally when --title or --body is passed, which may be why a plain local run passed.

AI-assisted: yes

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6182195976 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5883#issuecomment-6182195976). Originally posted by [Dextroid17](https://github.com/Dextroid17) on 2026-10-15T01:22:08Z. --- I ran this on Linux because my #6155 depends on it (its test run stops at your (9) check without your change). Setup: main ab9a47684 with this PR's change (one hunk in Recorder.cpp) applied; the PR head is 478 commits behind current main. Default CMake build (CMAKE_BUILD_TYPE empty, unoptimized), ANYPS5_NO_SHADER_CACHE=1, lavapipe (Mesa 26.2.4 llvmpipe, LLVM 23.1.1). agc_driver_recorder_tests with no arguments, 3 runs each: - main alone: 3 of 3 exit 1 at "(9) a scan under a pending write was kept". - main plus this change: 3 of 3 get past (9) and stop later at "second draw observed overwritten input". - main plus this change plus #6155 (which adds the missing MarkWritten calls after the test's direct writes): 3 of 3 exit 0, "Recorder read tracking and label tests passed". So on lavapipe the new expectations match main's current behaviour and clear the (9) stop. Whether synchronizing before caching a proof is the intended behaviour I did not check. I did not check the RX 580 run or Windows. The red conventions check has 4 errors. I reproduced all 4 locally with main's tools/check_conventions.py against the same base (f3434892b), passing this PR's title and body: - Recorder.cpp:1171: the new `// An unknown pending write cannot supply DCC keys...` line counts as a code comment, which needs a change to docs/dev/TechnicalDebt.md or docs/dev/debt/ in the same PR. With only that line deleted, the checker no longer reports it. - 'What', 'Tested' and 'Checklist' are reported missing because the checker only matches `###` headings with those exact names, and the description uses `##` and "Tested locally". With `### What` and `### Tested`, those two clear. The checker then wants a `### Checklist` section with no unticked boxes, "Depends on" filled with #N or none, and "AI-assisted" answered yes or no; the template's checklist covers this. The template checks only run locally when --title or --body is passed, which may be why a plain local run passed. AI-assisted: yes
adriadam10 commented 2026-10-15 14:20:53 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-15T14:20:53Z.

Review: DISMISSED


Checked on Linux (lavapipe, PR merged onto current main): agc_driver_recorder_tests now gets past check (9) but still exits 1 at "AGC graphics: second draw observed overwritten input", so the test is not green with this PR alone (same as @Dextroid17 reported; they say it needs the MarkWritten calls from #6155). The target is EXCLUDE_FROM_ALL and not in ctest, so CI will not show it either.

  • Land the fix for the later failure together with this one (or make this PR depend on #6155 and list it under "Depends on"), so the recorder test passes end to end.
  • core/libs/prx/libSceAgcDriver/tests/Recorder.cpp:1327: the new // line counts as a code comment and the conventions check requires a TechnicalDebt change for it; drop the comment.
  • PR body: the headings must be ### What, ### Tested and ### Checklist (the checklist fully ticked, "Depends on" filled, "AI-assisted" yes/no); the conventions job is red on these.
<!-- greyfinch-sync:boykopovar/AnyPS5:review:5534660610 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5883#pullrequestreview-5534660610). Originally posted by [adriadam10](https://github.com/adriadam10) on 2026-10-15T14:20:53Z. **Review:** DISMISSED --- Checked on Linux (lavapipe, PR merged onto current main): `agc_driver_recorder_tests` now gets past check (9) but still exits 1 at "AGC graphics: second draw observed overwritten input", so the test is not green with this PR alone (same as @Dextroid17 reported; they say it needs the `MarkWritten` calls from #6155). The target is `EXCLUDE_FROM_ALL` and not in ctest, so CI will not show it either. - Land the fix for the later failure together with this one (or make this PR depend on #6155 and list it under "Depends on"), so the recorder test passes end to end. - `core/libs/prx/libSceAgcDriver/tests/Recorder.cpp:1327`: the new `//` line counts as a code comment and the conventions check requires a TechnicalDebt change for it; drop the comment. - PR body: the headings must be `### What`, `### Tested` and `### Checklist` (the checklist fully ticked, "Depends on" filled, "AI-assisted" yes/no); the conventions job is red on these.
MarcZX10 commented 2026-10-16 18:45:26 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-16T18:45:26Z.


One dependency-order detail from the recorder work: #6155 currently lists #5883 as its dependency, while the review here suggests waiting for #6155 to clear the later recorder failure. Reversing that edge would make the two PRs depend on each other. The exact composition of current heads (#5883 + #6155 + #6642) passed agc_driver_recorder 3/3 on both RTX 3070 and lavapipe, as documented in #6642. Please coordinate the intended merge order or combined change with maintainers; the composition result supports the combined behavior, but does not resolve the current dependency cycle.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6222394984 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5883#issuecomment-6222394984). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-16T18:45:26Z. --- One dependency-order detail from the recorder work: #6155 currently lists #5883 as its dependency, while the review here suggests waiting for #6155 to clear the later recorder failure. Reversing that edge would make the two PRs depend on each other. The exact composition of current heads (#5883 + #6155 + #6642) passed `agc_driver_recorder` 3/3 on both RTX 3070 and lavapipe, as documented in #6642. Please coordinate the intended merge order or combined change with maintainers; the composition result supports the combined behavior, but does not resolve the current dependency cycle.
THEMANnt commented 2026-10-26 13:51:04 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by THEMANnt on 2026-10-26T13:51:04Z.

Review: APPROVED


Reviewed 1b3f2e098260 against merge base 28b6f1987917. Recommend approval for the test-only expectation update.

A generic unknown pending write cannot provide DCC key bytes, so ProvedClearKeys synchronizes before creating and reusing a proof. The revised assertions match that behavior: nonzero generation, one scan, no unstable scan and an incremented proof count. Production code is unchanged.

Validation: Built the exact baseline recorder target on Windows with GCC 15.3 and RTX 5070 Ti, driver 616.92, with Vulkan required. The full recorder executable fails at the old assertion. Applying only the PR's sole test-file patch, rebuilding and rerunning the same executable succeeds. This validates the test-only behavioral delta. The narrower --pending-key-stores-only smoke test also passes, but does not reach the changed assertion.

Scope: No Linux/lavapipe or RX580 reproduction. Shader-cache settings and a Vulkan validation-layer comparison are not established by the saved report; hosted product jobs were skipped.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5653010712 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5883#pullrequestreview-5653010712). Originally posted by [THEMANnt](https://github.com/THEMANnt) on 2026-10-26T13:51:04Z. **Review:** APPROVED --- Reviewed `1b3f2e098260` against merge base `28b6f1987917`. Recommend approval for the test-only expectation update. A generic unknown pending write cannot provide DCC key bytes, so `ProvedClearKeys` synchronizes before creating and reusing a proof. The revised assertions match that behavior: nonzero generation, one scan, no unstable scan and an incremented proof count. Production code is unchanged. **Validation:** Built the exact baseline recorder target on Windows with GCC 15.3 and RTX 5070 Ti, driver 616.92, with Vulkan required. The full recorder executable fails at the old assertion. Applying only the PR's sole test-file patch, rebuilding and rerunning the same executable succeeds. This validates the test-only behavioral delta. The narrower `--pending-key-stores-only` smoke test also passes, but does not reach the changed assertion. **Scope:** No Linux/lavapipe or RX580 reproduction. Shader-cache settings and a Vulkan validation-layer comparison are not established by the saved report; hosted product jobs were skipped.
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!5883
No description provided.