fix(agc): transition resident attachment subresources #6934

Merged
JJenkx merged 1 commit from upstream-pr/6934 into main 2026-10-19 19:16:30 +00:00
JJenkx commented 2026-10-16 20:01:20 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by JJenkx on 2026-10-16T20:01:20Z.


What

Immediate rendering to a resident mip or array-layer view transitions mip 0/layer 0 instead of the attachment subresource. APS5_SYNC_DRAWS=1 and target dumping can therefore issue VUID-vkCmdBeginRendering-pRenderingInfo-09592: the rendered subresource remains GENERAL while the attachment declares COLOR_ATTACHMENT_OPTIMAL.

Pass the selected mip and array-layer range to both immediate resident-image barriers. A 3D image still uses its single Vulkan array layer; its selected depth slices belong to that mip. Transient-image callers keep their existing default range. Only Draw.cpp changes, four lines replaced.

Tested

Current-main-only head 1b70ce290f on ea4cc112a0. Arch Linux 7.2.9-arch1-1, GCC 16.2.1 Release, Ryzen 9 7950X; RX 6650 XT / RADV Mesa 26.2.4-arch1.1 and lavapipe Mesa 26.2.4 / LLVM 23.1.1. Khronos validation layer 1.4.363, standard core checks; no explicit synchronization/GPU-assisted validation. Vulkan required, shader disk cache disabled, APS5_SYNC_DRAWS=1.

  • Full libs and the three existing execution test binaries build. agc_driver_array_layer_target, agc_driver_packed_mip_tail_target, agc_driver_layered_volume_draw: 3/3 pass on RADV and 3/3 on lavapipe, zero skips and zero validation errors/VUIDs. The volume case verifies that array-layer selection is not confused with 3D depth slices; its mesh subcase validates shaders only.
  • Production-only negative: replace only Draw.cpp with exact current-main source, keep the fixtures unchanged and rebuild. All three pixel tests still pass, but the array-target fixture reports two 09592 validation errors per driver, both on array layer 1 remaining in GENERAL. Restore/rebuild the fix: 3/3 pass with zero errors on both drivers again. The functional tests alone do not detect the API error; the validation logs do.
  • Native Override 2 PPSA01907 01.007.000 on integration c01f24339a1b (main b260d8d792 plus #6913/#862/#6781 and diagnostic readbacks): the preceding target-dump run reports ten capped instances of the same VUID on mip 1. With this fix, the repeated target-dump run exits 0 after 97.64 s with zero validation errors/VUIDs and restored settings. This integration is not isolated current-main title validation. Very dark 3D rendering remains unchanged; no visual or FPS improvement is claimed. Bring-up and exact source.
  • External composition evidence from @Amoenus: #7085 retains this exact 1b70ce290f3a2ef4d751c1f228540a589d3c1ff9 commit and declares it as a prerequisite. Their composition b605c6887 passes extra-mip, image-level, array-target and packed-tail fixtures 3/3 on RTX 5080 / driver 32.0.16.1062 and Radeon Graphics / driver 32.0.21036.18, Windows 11 Enterprise 26200, with Vulkan required, shader cache disabled, APS5_SYNC_DRAWS=1 and Khronos core 1.4.363: zero validation errors/warnings for those four groups. They also report Linux Mesa 25.2.8 llvmpipe 3/3 passes without explicitly enabled core validation. The layered-volume fixture passes 3/3 but emits ten WARNING-VkImageSubresourceRange-layerCount-compatibility warnings per physical run, including transfer barriers; these are not attributed solely to this change. These are attributed composition results, not standalone tests of this unchanged PR head.
  • External Apple-port evidence from @jotitadev: Apple M2 Max, macOS 27.2, x86-64 under Rosetta, MoltenVK 1.4.2 and Khronos validation 1.4.363, shader cache disabled and APS5_SYNC_DRAWS=1. On macos-port at b7eb6b6b plus ImportWatched, they applied this PR with the layer-range arguments adapted to one layer because that port lacks ColorTarget::layers. The array-target fixture passes pixel checks on both trees, but two layer-1 layout errors (VUID-vkCmdDraw-None-09600) on the unchanged port become zero with the adapted change. Packed-tail has no layout errors on either tree, so this does not validate the mip fix. Both trees retain the same twelve unrelated multisample-storage image-creation errors (00968). Their broader suite reports 14/433 failures, including a cross-workgroup case reproduced 5/5 on the unchanged port. This is attributed adapted-port evidence, not a clean-main macOS run or zero-error full suite.
  • Conventions against origin/main and whitespace pass. Required overlap check finds no confirmed overlap; its 22 conflicted shared-file heads were inspected at this helper and the resident barrier calls, with no selected-subresource implementation found. This is a scoped review, not a claim those whole branches combine cleanly.

Sanitized report, negative/restored validation logs and patch, assets prefixed resident-subresource or subresource-isolated. No new fixture, driver dependency or diagnostic code is included here. Standalone Windows/NVIDIA/macOS and full hosted builds have not been run by us; the external composition coverage above does not replace them. Full platform jobs require maintainer dispatch.

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
  • Unblocks: PPSA01907 #6933 (synchronous-path layout error only; dark rendering remains unresolved)
  • GPUs tested: AMD RX 6650 XT / RADV Mesa 26.2.4-arch1.1, Arch Linux 7.2.9; lavapipe Mesa 26.2.4 / LLVM 23.1.1 on the same host
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4893607775 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/6934). Originally posted by [JJenkx](https://github.com/JJenkx) on 2026-10-16T20:01:20Z. --- ### What Immediate rendering to a resident mip or array-layer view transitions mip 0/layer 0 instead of the attachment subresource. `APS5_SYNC_DRAWS=1` and target dumping can therefore issue `VUID-vkCmdBeginRendering-pRenderingInfo-09592`: the rendered subresource remains `GENERAL` while the attachment declares `COLOR_ATTACHMENT_OPTIMAL`. Pass the selected mip and array-layer range to both immediate resident-image barriers. A 3D image still uses its single Vulkan array layer; its selected depth slices belong to that mip. Transient-image callers keep their existing default range. Only `Draw.cpp` changes, four lines replaced. ### Tested Current-main-only head `1b70ce290f` on `ea4cc112a0`. Arch Linux 7.2.9-arch1-1, GCC 16.2.1 Release, Ryzen 9 7950X; RX 6650 XT / RADV Mesa 26.2.4-arch1.1 and lavapipe Mesa 26.2.4 / LLVM 23.1.1. Khronos validation layer 1.4.363, standard core checks; no explicit synchronization/GPU-assisted validation. Vulkan required, shader disk cache disabled, `APS5_SYNC_DRAWS=1`. - Full `libs` and the three existing execution test binaries build. `agc_driver_array_layer_target`, `agc_driver_packed_mip_tail_target`, `agc_driver_layered_volume_draw`: **3/3 pass on RADV and 3/3 on lavapipe, zero skips and zero validation errors/VUIDs**. The volume case verifies that array-layer selection is not confused with 3D depth slices; its mesh subcase validates shaders only. - Production-only negative: replace only `Draw.cpp` with exact current-main source, keep the fixtures unchanged and rebuild. All three pixel tests still pass, but the array-target fixture reports **two 09592 validation errors per driver**, both on array layer 1 remaining in `GENERAL`. Restore/rebuild the fix: 3/3 pass with zero errors on both drivers again. The functional tests alone do not detect the API error; the validation logs do. - Native Override 2 PPSA01907 01.007.000 on integration `c01f24339a1b` (main `b260d8d792` plus #6913/#862/#6781 and diagnostic readbacks): the preceding target-dump run reports ten capped instances of the same VUID on mip 1. With this fix, the repeated target-dump run exits 0 after 97.64 s with zero validation errors/VUIDs and restored settings. This integration is not isolated current-main title validation. Very dark 3D rendering remains unchanged; no visual or FPS improvement is claimed. [Bring-up and exact source](https://github.com/boykopovar/AnyPS5/discussions/6933). - External composition evidence from [@Amoenus](https://github.com/boykopovar/AnyPS5/pull/6934#issuecomment-6233056484): #7085 retains this exact `1b70ce290f3a2ef4d751c1f228540a589d3c1ff9` commit and declares it as a prerequisite. Their composition `b605c6887` passes extra-mip, image-level, array-target and packed-tail fixtures 3/3 on RTX 5080 / driver 32.0.16.1062 and Radeon Graphics / driver 32.0.21036.18, Windows 11 Enterprise 26200, with Vulkan required, shader cache disabled, `APS5_SYNC_DRAWS=1` and Khronos core 1.4.363: zero validation errors/warnings for those four groups. They also report Linux Mesa 25.2.8 llvmpipe 3/3 passes without explicitly enabled core validation. The layered-volume fixture passes 3/3 but emits ten `WARNING-VkImageSubresourceRange-layerCount-compatibility` warnings per physical run, including transfer barriers; these are not attributed solely to this change. These are attributed composition results, not standalone tests of this unchanged PR head. - External Apple-port evidence from [@jotitadev](https://github.com/boykopovar/AnyPS5/pull/6934#issuecomment-6251545031): Apple M2 Max, macOS 27.2, x86-64 under Rosetta, MoltenVK 1.4.2 and Khronos validation 1.4.363, shader cache disabled and `APS5_SYNC_DRAWS=1`. On `macos-port` at `b7eb6b6b` plus ImportWatched, they applied this PR with the layer-range arguments adapted to one layer because that port lacks `ColorTarget::layers`. The array-target fixture passes pixel checks on both trees, but two layer-1 layout errors (`VUID-vkCmdDraw-None-09600`) on the unchanged port become zero with the adapted change. Packed-tail has no layout errors on either tree, so this does not validate the mip fix. Both trees retain the same twelve unrelated multisample-storage image-creation errors (`00968`). Their broader suite reports 14/433 failures, including a cross-workgroup case reproduced 5/5 on the unchanged port. This is attributed adapted-port evidence, not a clean-main macOS run or zero-error full suite. - Conventions against `origin/main` and whitespace pass. Required overlap check finds no confirmed overlap; its 22 conflicted shared-file heads were inspected at this helper and the resident barrier calls, with no selected-subresource implementation found. This is a scoped review, not a claim those whole branches combine cleanly. [Sanitized report, negative/restored validation logs and patch](https://github.com/JJenkx/AnyPS5/releases/tag/game-library-checks-20261016), assets prefixed `resident-subresource` or `subresource-isolated`. No new fixture, driver dependency or diagnostic code is included here. Standalone Windows/NVIDIA/macOS and full hosted builds have not been run by us; the external composition coverage above does not replace them. Full platform jobs require maintainer dispatch. <!-- OS, title or homebrew, what was checked. "Not tested" is a valid answer. A performance change: the summary lines of main and of this PR from the same machine and scene, with the traces attached, captured as the Performance report issue form describes. --> ### 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] Unblocks: PPSA01907 #6933 (synchronous-path layout error only; dark rendering remains unresolved) - [x] GPUs tested: AMD RX 6650 XT / RADV Mesa 26.2.4-arch1.1, Arch Linux 7.2.9; lavapipe Mesa 26.2.4 / LLVM 23.1.1 on the same host - [x] AI-assisted: yes
github-actions[bot] commented 2026-10-16 20:10:53 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-16T20:10:53Z.


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 1191 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 1368 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 1395 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 4072 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 5431 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 5441 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 5499 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 5609 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 5925 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 6188 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 6202 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 6292 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 6539 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 6615 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 6636 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 6661 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 6683 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 6718 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 6727 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 6820 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 6946 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 6947 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 7256 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 7642 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
PR 7668 core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp
<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6223800858 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/6934#issuecomment-6223800858). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-10-16T20:10:53Z. --- <!-- pr-overlap --> 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 1191](https://www.github.com/boykopovar/AnyPS5/pull/1191) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 1368](https://www.github.com/boykopovar/AnyPS5/pull/1368) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 1395](https://www.github.com/boykopovar/AnyPS5/pull/1395) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 4072](https://www.github.com/boykopovar/AnyPS5/pull/4072) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 5431](https://www.github.com/boykopovar/AnyPS5/pull/5431) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 5441](https://www.github.com/boykopovar/AnyPS5/pull/5441) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 5499](https://www.github.com/boykopovar/AnyPS5/pull/5499) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 5609](https://www.github.com/boykopovar/AnyPS5/pull/5609) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 5925](https://www.github.com/boykopovar/AnyPS5/pull/5925) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 6188](https://www.github.com/boykopovar/AnyPS5/pull/6188) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 6202](https://www.github.com/boykopovar/AnyPS5/pull/6202) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 6292](https://www.github.com/boykopovar/AnyPS5/pull/6292) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 6539](https://www.github.com/boykopovar/AnyPS5/pull/6539) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 6615](https://www.github.com/boykopovar/AnyPS5/pull/6615) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 6636](https://www.github.com/boykopovar/AnyPS5/pull/6636) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 6661](https://www.github.com/boykopovar/AnyPS5/pull/6661) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 6683](https://www.github.com/boykopovar/AnyPS5/pull/6683) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 6718](https://www.github.com/boykopovar/AnyPS5/pull/6718) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 6727](https://www.github.com/boykopovar/AnyPS5/pull/6727) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 6820](https://www.github.com/boykopovar/AnyPS5/pull/6820) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 6946](https://www.github.com/boykopovar/AnyPS5/pull/6946) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 6947](https://www.github.com/boykopovar/AnyPS5/pull/6947) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 7256](https://www.github.com/boykopovar/AnyPS5/pull/7256) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 7642](https://www.github.com/boykopovar/AnyPS5/pull/7642) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` | | [PR 7668](https://www.github.com/boykopovar/AnyPS5/pull/7668) | `core/libs/prx/libSceAgcDriver/Graphics/src/Draw.cpp` |
Amoenus commented 2026-10-17 10:54:28 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by Amoenus on 2026-10-17T10:54:28Z.


Thanks for the resident-subresource correction. #7085 builds its extra guest-mip backing on your exact 1b70ce290f3a2ef4d751c1f228540a589d3c1ff9 commit, preserving authorship and declaring #6934 as a prerequisite. Our added Draw work maps the selected guest mip to its physical image/mip through your existing range-argument interface.

Composition b605c6887 passes the extra-mip, image-level, array-target and packed-tail fixtures 3/3 on RTX5080/driver32.0.16.1062 and Radeon Graphics/driver32.0.21036.18, Windows11 Enterprise26200, with APS5_SYNC_DRAWS=1, Vulkan required, shader cache disabled and Khronos core1.4.363: zero validation errors/warnings. The corresponding Linux Mesa25.2.8 llvmpipe runs pass3/3; its core layer was not explicitly enabled. These are composition results, not tests of your unchanged head.

One additional observation: agc_driver_layered_volume_draw passes3/3 on each device and has zero physical core errors, but each physical run logs ten WARNING-VkImageSubresourceRange-layerCount-compatibility warnings. The layer says 3D images with VK_IMAGE_CREATE_2D_ARRAY_COMPATIBLE_BIT and maintenance9 disabled currently interpret layerCount=1 as all depth slices; VK_REMAINING_ARRAY_LAYERS would keep that interpretation when maintenance9 is enabled. The count includes texture-transfer barriers as well as immediate-draw coverage, so it is not attributed solely to your patch. I retained the behavior and disclosed the warning in #7085 for a separately scoped follow-up.

AI-assisted: yes (Codex); author responsible.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6233056484 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/6934#issuecomment-6233056484). Originally posted by [Amoenus](https://github.com/Amoenus) on 2026-10-17T10:54:28Z. --- Thanks for the resident-subresource correction. [#7085](https://github.com/boykopovar/AnyPS5/pull/7085) builds its extra guest-mip backing on your exact `1b70ce290f3a2ef4d751c1f228540a589d3c1ff9` commit, preserving authorship and declaring #6934 as a prerequisite. Our added Draw work maps the selected guest mip to its physical image/mip through your existing range-argument interface. Composition `b605c6887` passes the extra-mip, image-level, array-target and packed-tail fixtures 3/3 on RTX5080/driver32.0.16.1062 and Radeon Graphics/driver32.0.21036.18, Windows11 Enterprise26200, with `APS5_SYNC_DRAWS=1`, Vulkan required, shader cache disabled and Khronos core1.4.363: zero validation errors/warnings. The corresponding Linux Mesa25.2.8 llvmpipe runs pass3/3; its core layer was not explicitly enabled. These are composition results, not tests of your unchanged head. One additional observation: `agc_driver_layered_volume_draw` passes3/3 on each device and has zero physical core errors, but each physical run logs ten `WARNING-VkImageSubresourceRange-layerCount-compatibility` warnings. The layer says 3D images with `VK_IMAGE_CREATE_2D_ARRAY_COMPATIBLE_BIT` and maintenance9 disabled currently interpret layerCount=1 as all depth slices; `VK_REMAINING_ARRAY_LAYERS` would keep that interpretation when maintenance9 is enabled. The count includes texture-transfer barriers as well as immediate-draw coverage, so it is not attributed solely to your patch. I retained the behavior and disclosed the warning in #7085 for a separately scoped follow-up. AI-assisted: yes (Codex); author responsible. <!-- codex-extra-mip-dependency-review-v1 -->
jotitadev commented 2026-10-18 15:14:42 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by jotitadev on 2026-10-18T15:14:42Z.


Apple GPU / MoltenVK run with the Khronos validation layer, since macOS was not run.

Machine: Apple M2 Max, macOS 27.2, x86-64 build under Rosetta. Head 1b70ce290. Method: macos-port @ b7eb6b6b + ImportWatched + PR diff, not main. The port has no ColorTarget::layers, so both new range arguments use one layer (what the port renders); otherwise the four Draw.cpp lines are the same. Driver: MoltenVK 1.4.2 (Vulkan SDK 1.4.363), VK_LAYER_KHRONOS_validation 1.4.363, APS5_SYNC_DRAWS=1, ANYPS5_NO_SHADER_CACHE=1.

Tree agc_driver_array_layer_target agc_driver_packed_mip_tail_target
port, Draw.cpp unchanged passes, 2 layout errors passes, no layout errors
port + this PR passes, 0 layout errors passes, no layout errors
  • On the port the layer reports the problem as VUID-vkCmdDraw-None-09600 at vkQueueSubmit, not as 09592, but it is the same subresource: arrayLayer = 1 expected in COLOR_ATTACHMENT_OPTIMAL while it is still GENERAL, and then the reverse on the way back. Both go away with the PR.
  • The pixel checks pass on both trees, as in your RADV/lavapipe run. So on Apple too, only the validation log shows the error.
  • The packed mip tail fixture has no layout error on the port even without the fix, so this run doesn't exercise the mip half of the change.
  • Both trees also show the same 12 VUID-VkImageCreateInfo-usage-00968 errors: a 4-sample image created with storage usage while shaderStorageImageMultisample is off (MoltenVK doesn't expose it). They are unrelated to this PR.

Full ^agc suite with the PR (SDK driver, -j1 --timeout 30, flip/display/lds_atomics64 excluded): 14 failures out of 433. These are the 13 known port-baseline failures plus agc_driver_cross_workgroup_flag, which also fails on the unchanged port on this machine today (intermittently, in streaks), so it isn't caused by this PR.

GPUs tested: Apple M2 Max (MoltenVK 1.4.2)

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

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6251545031 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/6934#issuecomment-6251545031). Originally posted by [jotitadev](https://github.com/jotitadev) on 2026-10-18T15:14:42Z. --- Apple GPU / MoltenVK run with the Khronos validation layer, since macOS was not run. Machine: Apple M2 Max, macOS 27.2, x86-64 build under Rosetta. Head 1b70ce290. Method: macos-port @ b7eb6b6b + ImportWatched + PR diff, not main. The port has no `ColorTarget::layers`, so both new range arguments use one layer (what the port renders); otherwise the four `Draw.cpp` lines are the same. Driver: MoltenVK 1.4.2 (Vulkan SDK 1.4.363), `VK_LAYER_KHRONOS_validation` 1.4.363, `APS5_SYNC_DRAWS=1`, `ANYPS5_NO_SHADER_CACHE=1`. | Tree | `agc_driver_array_layer_target` | `agc_driver_packed_mip_tail_target` | |---|---|---| | port, `Draw.cpp` unchanged | passes, **2 layout errors** | passes, no layout errors | | port + this PR | passes, **0 layout errors** | passes, no layout errors | - On the port the layer reports the problem as `VUID-vkCmdDraw-None-09600` at `vkQueueSubmit`, not as 09592, but it is the same subresource: `arrayLayer = 1` expected in `COLOR_ATTACHMENT_OPTIMAL` while it is still `GENERAL`, and then the reverse on the way back. Both go away with the PR. - The pixel checks pass on both trees, as in your RADV/lavapipe run. So on Apple too, only the validation log shows the error. - The packed mip tail fixture has no layout error on the port even without the fix, so this run doesn't exercise the mip half of the change. - Both trees also show the same 12 `VUID-VkImageCreateInfo-usage-00968` errors: a 4-sample image created with storage usage while `shaderStorageImageMultisample` is off (MoltenVK doesn't expose it). They are unrelated to this PR. Full `^agc` suite with the PR (SDK driver, `-j1 --timeout 30`, flip/display/lds_atomics64 excluded): 14 failures out of 433. These are the 13 known port-baseline failures plus `agc_driver_cross_workgroup_flag`, which also fails on the unchanged port on this machine today (intermittently, in streaks), so it isn't caused by this PR. GPUs tested: Apple M2 Max (MoltenVK 1.4.2) Written with AI assistance (Claude Code). I ran the builds and tests above on my machine.
adriadam10 commented 2026-10-19 19:18:13 +00:00 (Migrated from github.com)

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


Checked the diff: imageBarrier takes a subresource range (default unchanged for the transient callers) and both resident-image barriers in Draw now use binding.color.mip / arraySlice / layers, the same arguments AttachmentView is created with at line 2214; 3D images keep their single array layer. The 09592 negative/restored validation logs and the Windows (@Amoenus) and MoltenVK (@jotitadev) runs cover what the pixel fixtures can't; merged.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6275289355 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/6934#issuecomment-6275289355). Originally posted by [adriadam10](https://github.com/adriadam10) on 2026-10-19T19:18:13Z. --- Checked the diff: `imageBarrier` takes a subresource range (default unchanged for the transient callers) and both resident-image barriers in `Draw` now use `binding.color.mip` / `arraySlice` / `layers`, the same arguments `AttachmentView` is created with at line 2214; 3D images keep their single array layer. The 09592 negative/restored validation logs and the Windows (@Amoenus) and MoltenVK (@jotitadev) runs cover what the pixel fixtures can't; 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!6934
No description provided.