test(agc): cover padded D16 cube rows #5467

Merged
Sanjaysrinivas merged 3 commits from upstream-pr/5467 into main 2026-10-14 20:50:08 +00:00
Sanjaysrinivas commented 2026-10-13 20:33:13 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by Sanjaysrinivas on 2026-10-13T20:33:13Z.


What

Add a synthetic 320×320 D16 UNORM cube regression for padded depth-plane copies. Face 0 comes from a live depth surface; faces 1–5 come from guest tiled memory. Check rows 0, 1, 127 and 319 on all six faces, then overwrite guest face 3 and check the last row of every face again: 960 texel comparisons.

This is a test-only follow-up to alfalfa-star's #4722. The fixture requires a 1024-byte detiled row pitch and 393216-byte tiled face stride, and supplies the requested row through s13. It supplements the dependency's 128×128 integer-view case with normalized sampling and later-row coverage. No production implementation from #4722 is included here. Keep this draft until that dependency lands; this regression intentionally fails on current main.

Tested

Fresh Release build on Windows 11 Pro / MinGW-w64, SPIRV-Tools disabled, native NVIDIA Vulkan with Khronos validation and shader cache disabled. The new test on main a0f5916a293067ca840e835e58a8a55a0b764b4b fails at the expected depth-plane geometry guard (0.895 s). Applying only the production patch from #4722 head 68ab4fd53594adecf624cf7c5f2e5bc93fa1981f makes the complete depth-plane sampling executable pass, including the 960 new comparisons and existing array/integer/refusal cases (0.865 s). Neither run skipped cases or reported Vulkan validation errors.

The author patch was a local validation overlay and was restored before committing. The public branch contains only this regression. Linux/lavapipe and other hardware vendors have not been tested.

Checklist

  • Based on current main; no other open PR implements the same functions (this adds later-row and normalized-view coverage; related #4722 is the dependency)
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw; no new stubs
  • No notes, investigation .md files or images added to the repository
  • New third-party code is a submodule built from source (no new dependencies)
  • Generic behaviour, not specific to one title
  • Depends on: #4722
  • Unblocks: none (regression coverage)
  • GPUs tested: NVIDIA GeForce RTX 4070 Laptop GPU, Windows driver 32.0.16.1692, Windows 11 Pro 10.0.26300
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4849121024 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5467). Originally posted by [Sanjaysrinivas](https://github.com/Sanjaysrinivas) on 2026-10-13T20:33:13Z. --- ### What Add a synthetic 320×320 D16 UNORM cube regression for padded depth-plane copies. Face 0 comes from a live depth surface; faces 1–5 come from guest tiled memory. Check rows 0, 1, 127 and 319 on all six faces, then overwrite guest face 3 and check the last row of every face again: 960 texel comparisons. This is a test-only follow-up to alfalfa-star's #4722. The fixture requires a 1024-byte detiled row pitch and 393216-byte tiled face stride, and supplies the requested row through s13. It supplements the dependency's 128×128 integer-view case with normalized sampling and later-row coverage. No production implementation from #4722 is included here. Keep this draft until that dependency lands; this regression intentionally fails on current main. ### Tested Fresh Release build on Windows 11 Pro / MinGW-w64, SPIRV-Tools disabled, native NVIDIA Vulkan with Khronos validation and shader cache disabled. The new test on main `a0f5916a293067ca840e835e58a8a55a0b764b4b` fails at the expected depth-plane geometry guard (0.895 s). Applying only the production patch from #4722 head `68ab4fd53594adecf624cf7c5f2e5bc93fa1981f` makes the complete depth-plane sampling executable pass, including the 960 new comparisons and existing array/integer/refusal cases (0.865 s). Neither run skipped cases or reported Vulkan validation errors. The author patch was a local validation overlay and was restored before committing. The public branch contains only this regression. Linux/lavapipe and other hardware vendors have not been tested. ### Checklist - [x] Based on current `main`; no other open PR implements the same functions (this adds later-row and normalized-view coverage; related #4722 is the dependency) - [x] One topic per PR; follow-ups go in a new 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 to the repository - [x] New third-party code is a submodule built from source (no new dependencies) - [x] Generic behaviour, not specific to one title - [x] Depends on: #4722 - [x] Unblocks: none (regression coverage) - [x] GPUs tested: NVIDIA GeForce RTX 4070 Laptop GPU, Windows driver 32.0.16.1692, Windows 11 Pro 10.0.26300 - [x] AI-assisted: yes
adriadam10 commented 2026-10-14 20:02:37 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-14T20:02:37Z.


Rebased onto main and fixed up the test, since main now has its own padded-cube cases in DepthPlaneSampling.cpp:

  • Kept your 320×320 D16 cube (rows 0/1/127/319 on all faces, then the face-3 rewrite) and the row argument of Load (s13).
  • Placed it at its own LargeCubeOffset so it doesn't overlap SmallCubeOffset, and raised BlockBytes to 8 MiB: 6 faces of 393216 bytes at 0x200000 don't fit in 4 MiB (the test's own Require caught it).
  • Dropped the comments on the lines the s13 change edits (Conventions: comments only for technical debt).
    Checked: scoped build and tests of libSceAgcDriver green (agc_driver_tessellation segfaults on unrelated PRs too); mutating the face-3 expectation makes the test fail at "face 3 row 319". Merging once the full Build is green.
<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6177209169 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/5467#issuecomment-6177209169). Originally posted by [adriadam10](https://github.com/adriadam10) on 2026-10-14T20:02:37Z. --- Rebased onto main and fixed up the test, since main now has its own padded-cube cases in `DepthPlaneSampling.cpp`: - Kept your 320×320 D16 cube (rows 0/1/127/319 on all faces, then the face-3 rewrite) and the `row` argument of `Load` (s13). - Placed it at its own `LargeCubeOffset` so it doesn't overlap `SmallCubeOffset`, and raised `BlockBytes` to 8 MiB: 6 faces of 393216 bytes at 0x200000 don't fit in 4 MiB (the test's own `Require` caught it). - Dropped the comments on the lines the `s13` change edits (Conventions: comments only for technical debt). Checked: scoped build and tests of libSceAgcDriver green (`agc_driver_tessellation` segfaults on unrelated PRs too); mutating the face-3 expectation makes the test fail at "face 3 row 319". Merging once the full Build is green.
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!5467
No description provided.