Skip to content

feat(agc): honour the DEPTH row pitch of linear 2D textures as RDNA2 does - #11280

Merged
oneandonlydean merged 3 commits into
boykopovar:mainfrom
Michael-KD:feat/linear-texture-custom-pitch
Nov 2, 2026
Merged

oneandonlydean merged 3 commits into
boykopovar:mainfrom
Michael-KD:feat/linear-texture-custom-pitch

Conversation

@Michael-KD

@Michael-KD Michael-KD commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

What

A linear 2D T# whose DEPTH field (word 4) named a row pitch other than its default threw guest 2D linear texture descriptor sets a custom pitch other than its default pitch, which is not implemented. RDNA2 hardware uses that field as the row pitch, so such textures now decode and read with the measured layout instead of stopping the guest.

The rule, measured with the hardware oracle: the row pitch is DEPTH + 1 elements, raised to the width and rounded up to 256 bytes. A DEPTH that rounds to the default pitch, including any below the width, now decodes as the default pitch; before, only DEPTH = default pitch − 1 was accepted.

  • GuestTextureResource: a new linearPitch field, in elements. DecodeTextureResource sets it for a single-level, uncompressed linear 2D T# with no base array, and only when the pitch differs from the default, so every descriptor accepted before decodes as before. Block-compressed, mipmapped and base-array surfaces with a DEPTH pitch still throw (not measured). EncodeTextureResource refuses a resource with a custom pitch rather than dropping it.
  • ComputeLinearMipLayout and ComputeMipLayout take the pitch; DescribeSurface and the texture cache pass it, so pitchBytes, blocksPerRow and the guest size follow it.
  • Texture::CanCopyFrom and StorageTexture::SameSurfaceShape compare the pitch, so a storage or sampled texture of one pitch does not serve another. The texture cache keys on the descriptor words, which hold DEPTH.
  • PS4 (GCN) guests keep main's rule: a linear 2D T# decodes only its default pitch and throws otherwise, since the pitch rule is measured on RDNA2 only.
  • docs/dev/debt/libSceAgcDriver.md: a new "Linear 2D texture pitch" entry for what stays open (gfx1013; compressed, mipmapped and base-array surfaces; PS4 guests).

Overlap: tools/pr_overlap.py lists #9891, #9892, #9893 and #9895 (PS4 support; heads 375f5630ba, 545e2b5b3f, 781ffafe9f, 3e32049166). No order is needed and none is a prerequisite. Each conflicts with this PR in three adjacent additions that keep both sides: the #include <array> they add next to RdnaDecoder/RdnaInstructionDecoder.hpp in GuestTextureResource.cpp, their if (gcn) { result.gcnPitch ... } block beside result.linearPitch there, and their Require(!IsGcnTiled(tileMode), ...) line beside this PR's ComputeLinearMipLayout(..., 0u) call in ComputeElementMipLayout. Their DescribeSurface returns through describeGcnSurface for a PS4 surface before the RDNA layout that reads linearPitch, and a PS4 guest's linear 2D T# keeps main's default-pitch rule here (GcnGuestShaders()), so this PR changes nothing for PS4 guests either way. #9891's head merged into this branch with that resolution passes agc_driver_graphics, agc_driver_gcn_detile and agc_driver_linear_texture_pitch on both GPUs below with the validation layer and no VUID- lines. No PR it could not compare changes the custom-pitch check.

Measurement:

  • GPU: AMD Radeon integrated graphics of a Ryzen 7 9800X3D (gfx1036, RDNA2), AMD Windows driver 32.0.21030.31, through HIP/comgr; wave32; IEEE 0, DX10_CLAMP 1.
  • Kernel: image_load (DIM 2D, data mask 1) through a linear 2D T# (TYPE 9, height 4, one level) over a buffer whose element at offset o encodes o (for 8-bit texels, two runs with the low and the high byte of the offset). Each lane loads (x, y) for 16 x values and y 0 to 3, and the element it reads gives the row pitch the hardware used.
  • 135 kernels: 32_UINT at widths 16, 64 and 100 with pitches 1, 4, 8, 16, 32, 63, 64, 65, 96, 100, 127, 128, 129, 192, 256, 320 and 1024; then 8_UINT (widths 16, 300; pitches 1 to 2048), 16_UINT (16, 200; 1 to 1024), 32_UINT (16, 100; 1 to 1024) and 32_32_UINT (16, 40; 1 to 512).
  • Result: every kernel reads row y at y × pitch, with pitch = max(DEPTH + 1, width) rounded up to 256 / bytes per element. For example, width 16 32_UINT: DEPTH 0 to 63 give 64, 64 to 127 give 128, 128 gives 192, 1023 gives 1024. No lane read anything the rule doesn't explain.

Tested

Windows 11 Pro 26200, WinLibs GCC 15.2.0 r7, Release.

  • agc_driver_linear_texture_pitch (new): 128 threads image_load a 16×8 32_UINT linear 2D texture, whose element i holds 0xa0000000 | i, with DEPTH 15, 63, 64, 127, 128 and 255 in turn over the same memory, and check every texel against the measured pitch (64, 64, 128, 128, 192, 256). On main it fails at its first case, DEPTH 15, a pitch below the width that the hardware treats as the default: guest 2D linear texture descriptor sets a custom pitch other than its default pitch, which is not implemented (format 20, 16x8x16, type 9, tile 0, mips 0..0 of 1). With this change it passes.
  • agc_driver_graphics (GuestTextureResource.cpp cases updated): the decoded pitch for 32-bit and 8-bit formats, rounding, a pitch below the width, the surface layout, encoding with the default pitch, and the mipmapped refusal.

ctest --test-dir build -R '^agc_driver_(graphics|linear_texture_pitch|gcn_detile)$' -V with ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1, VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation (Vulkan SDK 1.4.363.0, insertion confirmed with VK_LOADER_DEBUG=layer) and ANYPS5_GPU set to each device, on this PR's head 2baa6d8d40 and on its base main bb04a4f1ea. agc_driver_gcn_detile is included because the rebase onto the PS4 (GCN) texture path in 0bec339021 touched the same decode and layout code; PS4 descriptors carry their pitch in word 7 and never set linearPitch. The main arm builds every file this PR changes from main, including tests/GuestTextureResource.cpp, so agc_driver_graphics runs main's own test source; it keeps only the new LinearTexturePitch.cpp, so the new test runs on both sides:

Test main, RTX 5070 Ti main, Radeon iGPU this PR, RTX 5070 Ti this PR, Radeon iGPU
agc_driver_linear_texture_pitch Failed Failed Passed Passed
agc_driver_graphics Passed Passed Passed Passed
agc_driver_gcn_detile Passed Passed Passed Passed

No log contains was not found but was requested by env var VK_INSTANCE_LAYERS, no log has a VUID- line, and each log names the selected GPU.

Full ctest -j8 with this change, before the rebase onto bb04a4f1ea (on main 48c160c58b): 2394 of 2396 pass. The two failures, agc_host_import_cut_lifetime (#10746) and agc_driver_depth_plane_partial_store (#10664), also fail with the change reverted.

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source
  • Generic behaviour, not specific to one title
  • Depends on: none
  • Fixes: none
  • Unblocks: none
  • GPUs tested: NVIDIA GeForce RTX 5070 Ti, driver 617.42, Windows 11 Pro 26200; AMD Radeon Graphics (Ryzen 7 9800X3D, gfx1036), Windows driver 32.0.21030.31 (Vulkan driver 2.0.353), Windows 11 Pro 26200
  • AI-assisted: yes

🤖 Generated with Claude Code

@MarcZX10

Copy link
Copy Markdown
Contributor

Reviewed the exact diff and the reported hardware probe/test setup. The linearPitch value is propagated through descriptor decode, layout, cache construction, and storage/sampled compatibility checks; I did not find a code-path omission in those changes. One contribution-rule item needs clarification: #9891, #9892, #9893 and #9895 are still open, and your overlap note says each inserts a result. assignment at the same GuestTextureResource.cpp location. Please record the agreed order and put any actual prerequisites in Depends on (or explain with the current exact heads why these edits can merge in any order). The described hardware validation is author-reported; I did not independently reproduce the GPU probes, and hosted product jobs are skipped under the PR path policy.

@Michael-KD

Copy link
Copy Markdown
Contributor Author

Thanks for the review. No order is needed and none of them is a prerequisite, so Depends on stays none. Checked against the current heads: #9891 375f5630ba, #9892 545e2b5b3f, #9893 781ffafe9f, #9895 3e32049166. All four merge cleanly into main.

Each one conflicts with this PR in three places. All three are additions next to each other, resolved by keeping both sides:

  • GuestTextureResource.cpp includes: both add RdnaDecoder/RdnaInstructionDecoder.hpp, which git merges; theirs also adds <array> next to it.
  • GuestTextureResource.cpp, after result.samples: this PR adds result.linearPitch = linearPitch; and theirs adds the if (gcn) { result.gcnPitch ... } block.
  • TextureTiling.cpp, ComputeElementMipLayout: their Require(!IsGcnTiled(tileMode), ...) line goes before this PR's ComputeLinearMipLayout(..., 0u) call.

The two paths don't interact. In those PRs, DescribeSurface returns through describeGcnSurface when gcnPitch != 0, before the RDNA layout that reads linearPitch. To make the order irrelevant in behaviour as well, bf4b9e17d6 keeps main's rule for PS4 guests (GcnGuestShaders()): their linear 2D T# still decodes only the default pitch and throws otherwise. So this PR changes nothing for PS4 guests whichever lands first.

I merged #9891's head into this branch with that resolution and ran agc_driver_graphics, agc_driver_gcn_detile and agc_driver_linear_texture_pitch on the RTX 5070 Ti and the Radeon iGPU with the validation layer on. All pass, with no VUID- lines. The PR description's overlap note now says the same.

@MarcZX10 MarcZX10 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I reviewed the updated exact head bf4b9e17d6433887e05143f09a93cd3834a565f1. The revised overlap explanation addresses the earlier question: it identifies the three adjacent insertions and describes why the PS4 GCN path does not consume linearPitch.

One required validation result is still missing. CONTRIBUTING.md requires the same focused AGC tests on main and the change, with validation enabled, on each reported GPU. The report shows agc_driver_graphics as n/a on main; only agc_driver_linear_texture_pitch is shown there. Please run the baseline agc_driver_graphics test (using the baseline test source if the new assertions depend on linearPitch) on both listed GPUs with the same validation settings, and add its outcome alongside the PR result. The hosted Linux/Windows product checks are skipped for this change, so CI does not supply that baseline evidence. I have not independently run these hardware tests.

@Michael-KD

Copy link
Copy Markdown
Contributor Author

Ran the baseline. I built main acb900c194 (this PR's base) for every file the PR changes, including tests/GuestTextureResource.cpp, so agc_driver_graphics runs main's own test source. Only the new LinearTexturePitch.cpp was kept. Same settings on both sides: ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1, VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation, VK_LOADER_DEBUG=layer, and ANYPS5_GPU set to each device. The PR side is head bf4b9e17d6.

Test main, RTX 5070 Ti main, Radeon iGPU this PR, RTX 5070 Ti this PR, Radeon iGPU
agc_driver_linear_texture_pitch Failed Failed Passed Passed
agc_driver_graphics Passed Passed Passed Passed

The validation layer was inserted in all four runs. No log has was not found but was requested by env var VK_INSTANCE_LAYERS or a VUID- line, and each log names its GPU. The description's table now includes the main column.

@MarcZX10 MarcZX10 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The exact-head report now includes the missing baseline run on both listed GPUs, plus the same focused tests on the change, with validation-layer insertion confirmed and no new output. The prior baseline-evidence blocker is resolved. The current conventions check passes; hosted product tests remain path-skipped, and the GPU runs are author-reported rather than independently reproduced by me.

@MarcZX10

Copy link
Copy Markdown
Contributor

Clarification to my approval: the previously missing test was agc_driver_graphics. The updated report shows it on main and this PR for both the RTX 5070 Ti and Radeon iGPU; it also shows the new agc_driver_linear_texture_pitch test failing on main and passing on the PR for both GPUs. The author reports validation-layer insertion and no VUID errors. These hardware results are author-reported; I did not independently rerun them.

@github-actions

github-actions Bot commented Oct 26, 2026 •

Copy link
Copy Markdown

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 1368 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 1395 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 2434 docs/dev/debt/libSceAgcDriver.md
PR 5609 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 5925 docs/dev/debt/libSceAgcDriver.md
PR 6186 docs/dev/debt/libSceAgcDriver.md
PR 6187 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 6188 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 6192 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 6194 docs/dev/debt/libSceAgcDriver.md
PR 6197 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 6209 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 6223 docs/dev/debt/libSceAgcDriver.md
PR 6273 docs/dev/debt/libSceAgcDriver.md
PR 6280 core/libs/prx/libSceAgcDriver/Graphics/include/TextureTiling.hpp
core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
core/libs/prx/libSceAgcDriver/Graphics/src/TextureTiling.cpp
docs/dev/debt/libSceAgcDriver.md
PR 6412 docs/dev/debt/libSceAgcDriver.md
PR 6481 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 6548 docs/dev/debt/libSceAgcDriver.md
PR 6808 docs/dev/debt/libSceAgcDriver.md
PR 6987 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 6989 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 6995 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 7002 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 7085 core/libs/prx/libSceAgcDriver/Graphics/include/TextureTiling.hpp
core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
core/libs/prx/libSceAgcDriver/Graphics/src/TextureTiling.cpp
docs/dev/debt/libSceAgcDriver.md
PR 7256 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 7449 docs/dev/debt/libSceAgcDriver.md
PR 7514 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 7604 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 7642 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 8246 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 8484 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 8592 docs/dev/debt/libSceAgcDriver.md
PR 8707 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 9020 core/libs/prx/libSceAgcDriver/Graphics/src/GuestTextureResource.cpp
docs/dev/debt/libSceAgcDriver.md
PR 9318 core/libs/prx/libSceAgcDriver/Graphics/include/TextureTiling.hpp
core/libs/prx/libSceAgcDriver/Graphics/src/TextureTiling.cpp
docs/dev/debt/libSceAgcDriver.md
PR 9335 core/libs/prx/libSceAgcDriver/Graphics/src/GuestTextureResource.cpp
docs/dev/debt/libSceAgcDriver.md
PR 9356 docs/dev/debt/libSceAgcDriver.md
PR 9387 docs/dev/debt/libSceAgcDriver.md
PR 9508 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 9592 docs/dev/debt/libSceAgcDriver.md
PR 9672 docs/dev/debt/libSceAgcDriver.md
PR 9673 docs/dev/debt/libSceAgcDriver.md
PR 9675 docs/dev/debt/libSceAgcDriver.md
PR 9700 docs/dev/debt/libSceAgcDriver.md
PR 9748 core/libs/prx/libSceAgcDriver/Graphics/src/GuestTextureResource.cpp
docs/dev/debt/libSceAgcDriver.md
PR 9884 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 9891 core/libs/prx/libSceAgcDriver/Graphics/include/TextureTiling.hpp
core/libs/prx/libSceAgcDriver/Graphics/src/GuestTextureResource.cpp
core/libs/prx/libSceAgcDriver/Graphics/src/TextureTiling.cpp
core/libs/prx/libSceAgcDriver/tests/GuestTextureResource.cpp
docs/dev/debt/libSceAgcDriver.md
PR 9892 core/libs/prx/libSceAgcDriver/Graphics/include/GuestTextureResource.hpp
docs/dev/debt/libSceAgcDriver.md
PR 9895 core/libs/prx/libSceAgcDriver/Graphics/include/GuestTextureResource.hpp
core/libs/prx/libSceAgcDriver/Graphics/src/GuestTextureResource.cpp
docs/dev/debt/libSceAgcDriver.md
PR 9898 docs/dev/debt/libSceAgcDriver.md
PR 9915 docs/dev/debt/libSceAgcDriver.md
PR 9950 docs/dev/debt/libSceAgcDriver.md
PR 10049 docs/dev/debt/libSceAgcDriver.md
PR 10064 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 10193 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 10233 core/libs/prx/libSceAgcDriver/Graphics/src/GuestTextureResource.cpp
core/libs/prx/libSceAgcDriver/tests/GuestTextureResource.cpp
docs/dev/debt/libSceAgcDriver.md
PR 10249 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 10256 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 10359 docs/dev/debt/libSceAgcDriver.md
PR 10556 core/libs/prx/libSceAgcDriver/Graphics/include/GuestTextureResource.hpp
core/libs/prx/libSceAgcDriver/Graphics/src/GuestTextureResource.cpp
core/libs/prx/libSceAgcDriver/tests/GuestTextureResource.cpp
PR 10743 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 11485 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 11825 docs/dev/debt/libSceAgcDriver.md
PR 11998 docs/dev/debt/libSceAgcDriver.md
PR 12120 docs/dev/debt/libSceAgcDriver.md
PR 12568 docs/dev/debt/libSceAgcDriver.md
PR 12746 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 12840 docs/dev/debt/libSceAgcDriver.md
PR 12921 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 13251 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 13599 docs/dev/debt/libSceAgcDriver.md
PR 13707 docs/dev/debt/libSceAgcDriver.md
PR 13793 docs/dev/debt/libSceAgcDriver.md
PR 13796 core/libs/prx/libSceAgcDriver/Graphics/include/GuestTextureResource.hpp
core/libs/prx/libSceAgcDriver/Graphics/src/GuestTextureResource.cpp
core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
core/libs/prx/libSceAgcDriver/tests/GuestTextureResource.cpp
PR 13809 docs/dev/debt/libSceAgcDriver.md
PR 13858 docs/dev/debt/libSceAgcDriver.md
PR 13863 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 13920 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 13928 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 13929 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 13963 docs/dev/debt/libSceAgcDriver.md
PR 14005 docs/dev/debt/libSceAgcDriver.md
PR 14212 docs/dev/debt/libSceAgcDriver.md
PR 14261 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 14262 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
PR 14302 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 14311 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 14344 docs/dev/debt/libSceAgcDriver.md
PR 14871 core/libs/prx/libSceAgcDriver/Graphics/include/GuestTextureResource.hpp
core/libs/prx/libSceAgcDriver/Graphics/src/GuestTextureResource.cpp
PR 14943 core/libs/prx/libSceAgcDriver/Graphics/src/Texture.cpp
docs/dev/debt/libSceAgcDriver.md
PR 14944 docs/dev/debt/libSceAgcDriver.md

@github-actions github-actions Bot added docs agc libSceAgc* labels Oct 26, 2026
@oneandonlydean oneandonlydean self-assigned this Oct 26, 2026
@MarcZX10

Copy link
Copy Markdown
Contributor

The reported baseline/change GPU matrix addresses the original evidence gap: on both listed GPUs, agc_driver_linear_texture_pitch fails on main and passes with this change, while agc_driver_graphics passes on both; the author also reports validation-layer insertion without VUID output. I have not independently run those hardware tests. Current main is 204c6747d0a1cbaf932def3dea0778810cc3935e; this head is 2 commits ahead and 273 behind. git merge-tree previews a clean merge and main has not changed the touched implementation/test paths since the PR base, but the integration evidence predates current main. Please refresh the branch and rerun the focused texture-pitch test on current main and this head on the same GPU before merge; the broad graphics suite need only be repeated if the rebase changes its relevant paths.

@babyhuey

Copy link
Copy Markdown
Contributor

Linux run of this head bf4b9e17d64, merged onto main 442c43a574d (clean merge, local only), with the selection CI's skipped Linux product job uses: anyps5-build CI image (Ubuntu 24.04, GCC 13, Release, BUILD_TESTING=ON), lavapipe with ANYPS5_REQUIRE_VULKAN=1 GALLIUM_OVERRIDE_CPU_CAPS=avx. The tree was configured fresh after the merge and built in full, then select_tests.py select / ninja -f select.ninja selected / --target libs / select_tests.py ctest --timeout 120.

  • Selected 1,468 tests: all pass. (main itself passes its full suite in this container.)

AI-assisted: yes (Claude Code)

@Michael-KD
Michael-KD force-pushed the feat/linear-texture-custom-pitch branch from bf4b9e1 to 1a12086 Compare October 26, 2026 17:27
@Michael-KD

Copy link
Copy Markdown
Contributor Author

Rebased onto current main 48c160c58b; the head is now 1a120867c4. The rebase applied without conflicts. main had changed TextureCache.cpp and other files this PR touches since the old base, so I reran agc_driver_graphics as well as the pitch test.

I used the same settings as before on both GPUs: ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1, VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation and VK_LOADER_DEBUG=layer. The main arm builds every file this PR changes from main 48c160c58b, except the new LinearTexturePitch.cpp.

Test main, RTX 5070 Ti main, Radeon iGPU this PR, RTX 5070 Ti this PR, Radeon iGPU
agc_driver_linear_texture_pitch Failed Failed Passed Passed
agc_driver_graphics Passed Passed Passed Passed

On main, both GPUs fail with guest 2D linear texture descriptor sets a custom pitch other than its default pitch, which is not implemented (format 20, 16x8x16, type 9, tile 0, mips 0..0 of 1). The validation layer was inserted in all four runs. No log has was not found but was requested by env var VK_INSTANCE_LAYERS or a VUID- line, and each log names its GPU. I've updated the hashes in the description.

@oneandonlydean

Copy link
Copy Markdown
Collaborator

@Michael-KD one test change before this can merge: please drop the new bool encoded / try EncodeTextureResource / catch / Require(!encoded) block for the valid custom-pitch resource in GuestTextureResource.cpp. It pins an encoding form that isn't implemented yet to throw, and our tests shouldn't fix that as the expected result. Keep the production guard against dropping the pitch, and the positive decode, geometry and default-pitch encoding checks. No new encoding implementation is needed.

@Michael-KD

Copy link
Copy Markdown
Contributor Author

@oneandonlydean Addressed in 3773b49609. The bool encoded / try EncodeTextureResource / catch / Require(!encoded) block is gone. The production guard in EncodeTextureResource stays, and so do the decode, geometry and default-pitch encoding checks. agc_driver_graphics and agc_driver_linear_texture_pitch still pass on the RTX 5070 Ti and the Radeon iGPU, with the same validation settings and no VUID- lines. The description now lists the tests that changed.

@jotitadev jotitadev left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NVIDIA run on Linux for head 3773b4960.

Linux run: Ubuntu 26.04, GCC 15.2, Release. RTX 3070 (NVIDIA 595.99.02) and lavapipe (Mesa 26.0.3), one at a time via VK_DRIVER_FILES. Khronos validation layer 1.4.341 with ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1; VK_LOADER_DEBUG=layer shows the layer inserted, no "was not found but was requested", 0 VUID- lines.

Base main 808a557ac; the merge is clean.

  • Red: main + only LinearTexturePitch.cpp: agc_driver_linear_texture_pitch fails on both devices with guest 2D linear texture descriptor sets a custom pitch other than its default pitch, which is not implemented (format 20, 16x8x16 ...).
  • Green: agc_driver_linear_texture_pitch, agc_driver_graphics and agc_driver_linear_target_* (14 tests) pass 3/3 on each device. On lavapipe linear_target_direct_write_completion skips, as on main. 0 VUID-.
  • ^agc suite (no flip/display/lds64, -j1): 3070 1053/1053, lavapipe 1052/1053. The one failure is agc_driver_multisample_retirement, which also fails on main.
  • Builds on Linux/GCC; public_headers passes.

GPUs tested: NVIDIA RTX 3070 (Linux), lavapipe.

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

@github-actions github-actions Bot added the needs rebase Conflicts with main, rebase needed label Oct 29, 2026
@TechLevelZero

Copy link
Copy Markdown
Contributor

✅ NVIDIA GPU test: passed

PR head 3773b49 merged onto main 52c09d5 · tested 2026-10-29 09:59 UTC · 28 min

GPU NVIDIA RTX 2000 Ada Generation, driver 595.99.02, Vulkan 1.4.329
Host Ubuntu 26.04.1 LTS, kernel 7.0.0-38-generic, container ubuntu:24.04
Logs build and test logs for this run
Build ✅ passed (Release, -DANYPS5_ENABLE_SPIRV_TOOLS=ON)
Tests ✅ 2,203 passed · 6 failed (0 new, 5 also fail on main, 1 unstable on main) · 39 skipped (ANYPS5_REQUIRE_VULKAN=1)
Test setup CPU-only tests without a GPU; GPU tests (and any CPU-only test that failed or skipped without one) once on the GPU with VK_LAYER_KHRONOS_validation and ANYPS5_NO_SHADER_CACHE=1; main ran the same way
Test selection 2,248 of 2,873 tests run: the ones this change can reach, chosen by tools/select_tests.py from main's build graph
Vulkan validation ✅ no new validation IDs vs main (858 tests run on the GPU)
Slow tests (>30 s, GPU tests timed with validation layers) ⚠️ agc_driver_pipeline_journal 48.0 s
Unstable on main (1, these also failed in recent main runs on this machine; not counted against this PR)
agc_driver_submit_progress: failed in 2 of the last 4 main runs
Failing on main too (5, not counted against this PR)
agc_compute_pipeline_inspection
agc_submit_progress
agc_submit_progress_no_timeline
guest_mmap_executable
guest_socket_options_multicast
Validation IDs already present on main (4 IDs in 407 tests)
VUID-VkDeviceCreateInfo-pNext-pNext (407 tests): agc_compute_pipeline_replay, agc_driver, agc_driver_address_passes, agc_driver_address_passes_draw_transitions, agc_driver_address_passes_targets_split, agc_driver_alpha_to_coverage, agc_driver_array_layer_target_cpu, agc_driver_bc_block_copy, and 399 more
VUID-vkCmdCopyImage-srcImage-01548 (11 tests): agc_driver_depth_clear_hle, agc_driver_depth_plane_buffer_memory, agc_driver_depth_plane_cpu_write_after_memo, agc_driver_depth_plane_cpu_write_after_page_unwatch, agc_driver_depth_plane_cpu_write_after_partial_unwatch, agc_driver_depth_plane_partial_store, agc_driver_depth_plane_partial_store_unimported, agc_driver_depth_storage_dispatch, and 3 more
VUID-vkCmdCopyImage-srcImage-01551 (11 tests): agc_driver_depth_clear_hle, agc_driver_depth_plane_buffer_memory, agc_driver_depth_plane_cpu_write_after_memo, agc_driver_depth_plane_cpu_write_after_page_unwatch, agc_driver_depth_plane_cpu_write_after_partial_unwatch, agc_driver_depth_plane_partial_store, agc_driver_depth_plane_partial_store_unimported, agc_driver_depth_storage_dispatch, and 3 more
VUID-VkPipelineColorBlendStateCreateInfo-pAttachments-00605 (2 tests): agc_driver_prepared_exports, agc_driver_srgb8_color_target
Skipped (39)
agc_driver_bda_reads_shadowed_results: skipped, the device reports watched host memory written when it imports or reads it
agc_driver_bda_reads_shadowed_results_per_build: skipped, the device reports watched host memory written when it imports or reads it
agc_driver_msaa_dcc_compared_import_2: skipped, the device reports host imports that keep write protection, so the write-watch probe compares none of them
agc_driver_msaa_dcc_compared_import_4: skipped, the device reports host imports that keep write protection, so the write-watch probe compares none of them
agc_driver_msaa_dcc_compared_import_8: skipped, the device reports host imports that keep write protection, so the write-watch probe compares none of them
agc_driver_sample_order_grid_reference: skipped, the device does not keep depth drawn at custom sample locations at those locations, even after a transition that names them: the composite of uniform renders holds the guest's depth in 0 of 3005 sloped samples, so no path can be compared with it bit for bit
agc_driver_sparse_dma_buf_import: skipped, host imports are unavailable: /dev/udmabuf is not accessible
agc_driver_stencil_ref_export: skipped, the device lacks VK_EXT_shader_stencil_export
agc_host_import_sparse: skipped, host imports are unavailable: /dev/udmabuf is not accessible
agc_import_settle_initial_dcc: skipped, the device has no deferred settle of host imports: imports under 1 MiB wait for one only on Windows
agc_unit_shadow_completion_store: skipped, the device reports watched host memory written when it imports or reads it
guest_net_ctl: skipped, the host has no IPv4 address
guest_video_out_color_space: skipped, no display or Vulkan device: SDL_InitSubSystem(VIDEO | GAMECONTROLLER) failed: wayland,x11 not available
guest_video_out_hdr: skipped, no display or Vulkan device: SDL_InitSubSystem(VIDEO | GAMECONTROLLER) failed: wayland,x11 not available
guest_video_out_high_frame_rate: skipped, no display or Vulkan device: SDL_InitSubSystem(VIDEO | GAMECONTROLLER) failed: wayland,x11 not available
guest_video_out_output_mode: skipped, no display or Vulkan device: SDL_InitSubSystem(VIDEO | GAMECONTROLLER) failed: wayland,x11 not available
guest_video_out_resolution_status: skipped, no display or Vulkan device: SDL_InitSubSystem(VIDEO | GAMECONTROLLER) failed: wayland,x11 not available
guest_video_out_wqhd_detection: skipped, no display or Vulkan device: SDL_InitSubSystem(VIDEO | GAMECONTROLLER) failed: wayland,x11 not available
video_out_flip_controls: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_cpuflip: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_cpuflip_in_order: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_eop: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_eop_aftergpu: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_eop_main: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_fresh: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_labels: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SD
Reproduce
git fetch origin 3773b496092dc8fdcb83594d7ba0af35e41f5d81 52c09d567d2fa453494dd720fcf53a98149468e4
git checkout 52c09d567d2fa453494dd720fcf53a98149468e4 && git merge --no-ff 3773b496092dc8fdcb83594d7ba0af35e41f5d81
git submodule update --init --recursive
cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTING=ON -DANYPS5_ENABLE_SPIRV_TOOLS=ON
cmake --build build && cmake --build build --target libs
VK_DRIVER_FILES=/nonexistent/icd.json ctest --test-dir build -E '^(agc|shader|recompiler|videoout|video_out|guest_video_out|vulkan)|gpu' --timeout 120 --parallel 32 --output-on-failure
ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation \
  ctest --test-dir build -R '^(agc|shader|recompiler|videoout|video_out|guest_video_out|vulkan)|gpu' --timeout 120 --parallel 4 --output-on-failure
# failures are then re-run alone: --timeout 360 --parallel 2; new validation IDs: the test alone, twice, --parallel 1

Automated build and test on a contributor's NVIDIA machine; it does not replace upstream CI. A new comment is posted for each new push. Full logs.

Michael-KD and others added 3 commits October 29, 2026 11:01
…does

A linear 2D T# whose DEPTH field named a row pitch other than its default
threw. On RDNA2 (gfx1036, hardware oracle, 135 image_load kernels over 8,
16, 32 and 64-bit texels) the row pitch is DEPTH + 1 elements, raised to
the width and rounded up to 256 bytes. A single-level uncompressed linear
2D texture now records that pitch and lays its rows out with it; the
texture cache, storage-to-sampled copies and surface shape checks keep
textures of different pitches apart. Block-compressed, mipmapped and
base-array surfaces with a pitch still throw.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…uests

The DEPTH row pitch was measured on RDNA2 only. A PS4 (GCN) guest's
linear 2D T# keeps the rule main had: only the default pitch decodes,
any other pitch throws. Its layout comes from its own descriptor
fields, so the RDNA pitch does not apply to it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Michael-KD
Michael-KD force-pushed the feat/linear-texture-custom-pitch branch from 3773b49 to 2baa6d8 Compare October 29, 2026 18:09
@github-actions github-actions Bot removed the needs rebase Conflicts with main, rebase needed label Oct 29, 2026
@TechLevelZero

TechLevelZero commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

✅ NVIDIA GPU test: passed

PR head 2baa6d8 merged onto main 93dbd0f · tested 2026-11-02 07:23 UTC · 27 min

GPU NVIDIA RTX 2000 Ada Generation, driver 595.99.02, Vulkan 1.4.329
Host Ubuntu 26.04.1 LTS, kernel 7.0.0-38-generic, container ubuntu:24.04
Logs build and test logs for this run
Build ✅ passed (Release, -DANYPS5_ENABLE_SPIRV_TOOLS=ON)
Tests ✅ 2,447 passed · 6 failed (0 new, 3 also fail on main, 3 unstable on main) · 45 skipped (ANYPS5_REQUIRE_VULKAN=1)
Test setup CPU-only tests without a GPU; GPU tests (and any CPU-only test that failed or skipped without one) once on the GPU with VK_LAYER_KHRONOS_validation and ANYPS5_NO_SHADER_CACHE=1; main ran the same way
Test selection 2,498 of 3,165 tests run: the ones this change can reach, chosen by tools/select_tests.py from main's build graph
Vulkan validation ✅ no new validation IDs vs main (931 tests run on the GPU)
Slow tests (>30 s, GPU tests timed with validation layers) ⚠️ agc_driver_pipeline_journal 120.2 s, ⚠️ agc_driver_graphics_maps_fallback 33.9 s, ⚠️ agc_driver_graphics 33.5 s
Unstable on main (3, these also failed in recent main runs on this machine; not counted against this PR)
agc_driver_pipeline_journal: failed in 1 of the last 10 main runs
agc_submit_progress: failed in 6 of the last 10 main runs
agc_submit_progress_no_timeline: failed in 7 of the last 10 main runs
Failing on main too (3, not counted against this PR)
agc_driver_image_table
guest_mmap_executable
guest_socket_options_multicast
Validation IDs already present on main (5 IDs in 484 tests)
VUID-VkDeviceCreateInfo-pNext-pNext (484 tests): agc_driver, agc_driver_address_passes, agc_driver_alias_copy_label, agc_driver_alpha_to_coverage, agc_driver_array_layer_target, agc_driver_bc_block_copy, agc_driver_bda_anchor_reads, agc_driver_bda_span_reads, and 476 more
VUID-vkCmdCopyImage-srcImage-01548 (7 tests): agc_driver_depth_clear_hle, agc_driver_depth_plane_buffer_memory, agc_driver_depth_plane_partial_store, agc_driver_depth_plane_sampling, agc_driver_depth_storage_dispatch, agc_driver_depth_surface_from_storage, agc_driver_dispatch_move_depth
VUID-vkCmdCopyImage-srcImage-01551 (7 tests): agc_driver_depth_clear_hle, agc_driver_depth_plane_buffer_memory, agc_driver_depth_plane_partial_store, agc_driver_depth_plane_sampling, agc_driver_depth_storage_dispatch, agc_driver_depth_surface_from_storage, agc_driver_dispatch_move_depth
VUID-VkPipelineColorBlendStateCreateInfo-pAttachments-00605 (1 test): agc_driver_prepared_exports
VUID-VkShaderModuleCreateInfo-pCode-08737 (1 test): agc_driver_image_sample_derivatives
Skipped (45)
agc_driver_bda_reads_shadowed_results: skipped, the device reports watched host memory written when it imports or reads it
agc_driver_bda_reads_shadowed_results_per_build: skipped, the device reports watched host memory written when it imports or reads it
agc_driver_sample_order_grid_reference: skipped, the device does not keep depth drawn at custom sample locations at those locations, even after a transition that names them: the composite of uniform renders holds the guest's depth in 0 of 3005 sloped samples, so no path can be compared with it bit for bit
agc_host_import_sparse: skipped, host imports are unavailable: /dev/udmabuf is not accessible
agc_import_settle_initial_dcc: skipped, the device has no deferred settle of host imports: imports under 1 MiB wait for one only on Windows
agc_unit_shadow_completion_store: skipped, the device reports watched host memory written when it imports or reads it
guest_http_uri_locale: 
guest_net_ctl: skipped, the host has no IPv4 address
guest_video_out_color_space: skipped, no display or Vulkan device: SDL_InitSubSystem(VIDEO | GAMECONTROLLER) failed: wayland,x11 not available
guest_video_out_hdr: skipped, no display or Vulkan device: SDL_InitSubSystem(VIDEO | GAMECONTROLLER) failed: wayland,x11 not available
guest_video_out_high_frame_rate: skipped, no display or Vulkan device: SDL_InitSubSystem(VIDEO | GAMECONTROLLER) failed: wayland,x11 not available
guest_video_out_output_mode: skipped, no display or Vulkan device: SDL_InitSubSystem(VIDEO | GAMECONTROLLER) failed: wayland,x11 not available
guest_video_out_resolution_status: skipped, no display or Vulkan device: SDL_InitSubSystem(VIDEO | GAMECONTROLLER) failed: wayland,x11 not available
guest_video_out_wqhd_detection: skipped, no display or Vulkan device: SDL_InitSubSystem(VIDEO | GAMECONTROLLER) failed: wayland,x11 not available
video_out_flip_aftergpu: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_backtoback: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_controls: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_cpuflip: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_cpuflip_in_order: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_dcc: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_deferred: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_eop: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_eop_aftergpu: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_eop_main: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_out_flip_fps_limit: skipped, no display or Vulkan device: DisplayWindow: Vulkan support is either not configured in SDL or not available in current SDL video driver (offscreen) or platform
video_o
Reproduce
git fetch origin 2baa6d8d407e8b79192f3e2a272cfe17c12ca9d3 93dbd0f82aea684e95f15f06e7d42c0064af18cf
git checkout 93dbd0f82aea684e95f15f06e7d42c0064af18cf && git merge --no-ff 2baa6d8d407e8b79192f3e2a272cfe17c12ca9d3
git submodule update --init --recursive
cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTING=ON -DANYPS5_ENABLE_SPIRV_TOOLS=ON
cmake --build build && cmake --build build --target libs
VK_DRIVER_FILES=/nonexistent/icd.json ctest --test-dir build -E '^(agc|shader|recompiler|videoout|video_out|guest_video_out|vulkan)|gpu' --timeout 120 --parallel 32 --output-on-failure
ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation \
  ctest --test-dir build -R '^(agc|shader|recompiler|videoout|video_out|guest_video_out|vulkan)|gpu' --timeout 120 --parallel 4 --output-on-failure
# failures are then re-run alone: --timeout 360 --parallel 2; new validation IDs: the test alone, twice, --parallel 1

Automated build and test on a contributor's NVIDIA machine; it does not replace upstream CI. A new comment is posted for each new push. Full logs.

@MarcZX10 MarcZX10 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-checked — new head, looks good

The rebased head carries the measured RDNA2 linear 2D row pitch through decoding, surface sizing, and texture compatibility checks, and the reported exact-head GPU tests pass.

What I ran

Reviewed PR head 2baa6d8d407e8b79192f3e2a272cfe17c12ca9d3 against base bb04a4f1ea0175e9e4f149f0359a764d62ff3296; refreshed current main is f46f453a56f91d77e29ce0cbd7fe5bfb2fb69834. The merge preview with current main is clean (tree a434269dc23e81758c5b2eca46693f30da0e3ba0). Environment: Linux 6.1.0-54-amd64 x86_64; no local compiler, build, or tests run.

git diff --check upstream/main...refs/review/pr-11280-current
python3 tools/check_conventions.py --base upstream/main
git merge-tree --write-tree upstream/main refs/review/pr-11280-current
gh pr checks 11280 --repo boykopovar/AnyPS5

Results

Check Result
Diff whitespace check Pass; exit 0, no output.
Repository conventions Pass.
Merge preview with current main Clean.
Hosted Windows job Pass on this exact head.
Other hosted jobs Conventions, eligibility, labels, and report pass; Linux and specialized jobs skipped.
Focused GPU tests The author reports baseline/current-head tests on an NVIDIA RTX 5070 Ti and an AMD Radeon iGPU, including the new row-pitch test, graphics and GCN-detile tests with validation enabled and no new VUIDs. These are author-run results, not local runs.
Unedited output from local and hosted checks
$ git diff --check upstream/main...refs/review/pr-11280-current
(exit 0; no output)
$ python3 tools/check_conventions.py --base upstream/main
All conventions checks passed.
$ git merge-tree --write-tree upstream/main refs/review/pr-11280-current
a434269dc23e81758c5b2eca46693f30da0e3ba0
$ gh pr checks 11280 --repo boykopovar/AnyPS5
conventions	pass	17s	https://github.com/boykopovar/AnyPS5/actions/runs/40928209377/job/123639355169
labels	pass	9s	https://github.com/boykopovar/AnyPS5/actions/runs/40928209684/job/123639334925
windows	pass	13m9s	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639266398
linux	skipping	0	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639268895
register-context	skipping	0	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639269091
relinker	skipping	0	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639269270
relinker-asan	skipping	0	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639269526
write-watch	skipping	0	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639269795
eligibility	pass	5s	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639199466
report	pass	49s	https://github.com/boykopovar/AnyPS5/actions/runs/40928272820/job/123639197837

The hosted results above are the recorded output of gh pr checks; the hardware runs are author-reported in the PR description.

Negative control

Assertion Change to code under test Did the new test fail?
A non-default DEPTH pitch is decoded and used for row addressing The author reports running the new test against base bb04a4f, before this change. Yes; it failed at the first case with the expected unsupported-custom-pitch error.

Findings

Blocking

None found in the reviewed head. The custom pitch is accepted only for uncompressed, single-level linear 2D surfaces without a base array; it is rounded using the element size and propagated into layout and compatibility checks. PS4 GCN descriptors retain their separate pitch handling.

Non-blocking

The measured hardware rule is reported for RDNA2; the PR leaves PS5 gfx1013 and unsupported compressed, mipmapped, and base-array cases documented as unverified or unsupported.

Sources

Not verified

I did not build or run tests locally, independently reproduce the two GPU reports, or verify the behavior on PS5 hardware. Linux and specialized hosted jobs were skipped.

@MarcZX10

MarcZX10 commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

Correction — hosted-check job links

Two job URLs in my October 29 review transcript were transcribed incorrectly; the exact gh pr checks output below has the correct job IDs.

What I ran

gh pr checks 11280 --repo boykopovar/AnyPS5

Results

The recorded output is reproduced exactly:

Unedited hosted-check output
conventions	pass	17s	https://github.com/boykopovar/AnyPS5/actions/runs/40928209377/job/123639355169
labels	pass	9s	https://github.com/boykopovar/AnyPS5/actions/runs/40928209684/job/123639334925
windows	pass	13m9s	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639266398
linux	skipping	0	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639268895
register-context	skipping	0	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639269091
relinker	skipping	0	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639269270
relinker-asan	skipping	0	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639269219
write-watch	skipping	0	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639268473
eligibility	pass	5s	https://github.com/boykopovar/AnyPS5/actions/runs/40928172880/job/123639199466
report	pass	49s	https://github.com/boykopovar/AnyPS5/actions/runs/40928272820/job/123639197837

@CnRJay CnRJay left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Withdrawn. The validation comparison this review asked for is already in the PR's Tested section: main vs this head on both GPUs with ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1, VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation, no VUID-. The PR also has no title to name; Unblocks: none is correct.

@Michael-KD

Copy link
Copy Markdown
Contributor Author

@CnRJay Thanks for looking at this.

Title: I have no title ID or log line to add. I have no PS5 or dumps, and this PR doesn't come from a title. It implements a field that main refuses with guest 2D linear texture descriptor sets a custom pitch other than its default pitch, which is not implemented, using the behaviour measured on RDNA2 (135 kernels, described under Measurement). So Unblocks: none is correct, and CONTRIBUTING.md only asks for a title when a PR fixes one. If a maintainer would rather hold it until a title reaches this refusal, that's their call.

Validation comparison: this is already in Tested. It has the same focused tests on main bb04a4f1ea and head 2baa6d8d40, on each of the two GPUs, with ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1 and VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation. Layer insertion was confirmed with VK_LOADER_DEBUG=layer. No log has was not found but was requested by env var VK_INSTANCE_LAYERS, and none of the logs on either side has a VUID- line. agc_driver_linear_texture_pitch fails on main and passes here; agc_driver_graphics and agc_driver_gcn_detile pass on both.

Separately, the NVIDIA bot's run of this head above found no new failures and no new validation IDs against main.

@oneandonlydean
oneandonlydean merged commit 54746cb into boykopovar:main Nov 2, 2026
11 of 12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agc libSceAgc* docs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants