fix(agc): look up and attach draw recipes on the relocated donor entry #7369

Merged
Flamefusion merged 3 commits from upstream-pr/7369 into main 2026-11-08 09:58:56 +00:00
Flamefusion commented 2026-10-18 02:55:54 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by Flamefusion on 2026-10-18T02:55:54Z.


What

A draw that misses on its own register key and is served by a relocated draw entry (relocateDrawEntry, #4943) never uses or keeps a draw recipe, so every such draw is recorded in full (Graphics::Draw) instead of from the cached draw's recipe (DrawFromRecipe).

In Driver::draw (Execution/src/Driver/Draw/Draw.cpp):

  • relocateDrawEntry builds a fresh DrawEntry with per-draw copies of the donor's variants. That entry is not stored in drawCache under the draw's key.
  • findDrawRecipe and, after recording, attachDrawRecipe still look up the draw's own key in drawCache. They find nothing and return, so a relocated hit never finds the donor's recipe, and a recipe built while recording it is dropped. With APS5_TRACE_DRAW_CACHE this shows as "attaches 0".
  • The recipe records also compare stage identity against the per-draw copies, which are new objects on every draw, so even a stored record could never match.

Fix:

  • DrawEntry and DispatchVariant gain a donor pointer. relocateDrawEntry sets it on the relocated entry and on every copied variant, always to the original cached entry or variant (a copy of a copy points at the root), so the chain never grows.
  • Driver::draw keys the recipe stages on the donor variant when a matched variant is a relocation copy. It hands the donor entry to findDrawRecipe and attachDrawRecipe, also through commitDraw on the pipelined path. With a donor, both read and update the donor entry's recipe list directly instead of looking up the key; without one they behave as before.
  • Graphics::DrawWithRecipe rebuilds the push constant block from the current shaders (AssemblePushConstants plus the recorded patches) when the recipe has push constants. Relocation moves user words that land in push constants, so the donor's block must not be replayed as-is.

Found while profiling Hades (PPSA03355, discussion #3234), whose sprite draws move per-draw pointers on almost every draw. There, recipe attaches now succeed, but few of its draws build a recipe at all: most hold an address-based build's lease, so they are not reusable. This PR therefore claims no frame-rate change; it makes the relocated path consistent with the exact-key path.

Test: agc_driver_draw_cache_relocation gains RelocatedDrawsReuseTheirRecipe.

  • Its draws read a constant through a user pointer that moves on every draw to identical contents, so after four teaching draws every further draw is a relocated hit.
  • They render into a 64 KiB guest block with the SW_64KB_R_X swizzle mode. The 1 KiB linear target the other cases use is never resident, and a draw into a non-resident target is not recorded, so it would never build a recipe.
  • The case requires all six later draws to be draw-cache hits and all six to be recorded from the recipe.
  • VulkanDevice::DrawRecipeHits() exposes the draw recipe hit counter the [recipe] profile line already keeps, so the test can read it without APS5_PROFILE_DRAW.

Tested

Rebased on main 98346b748c (the branch was about 14,000 commits behind). Conflicts were textual: main had added valueWords/valueSlots/calleeWords/calleeReads next to donor in DispatchVariant and its relocated copy, DrawTraceContext next to DrawRecipeHits() in VulkanDevice, and defaulted trace/shape parameters to commitDraw; recipeDonor now comes before those, and both call sites pass it. findDrawRecipe and attachDrawRecipe on main still look up only the draw's own key.

Windows 11 Home (build 26200), WinLibs GCC 15.2.0 r7 (posix-seh, ucrt), Release, -DBUILD_TESTING=ON, Intel Core i7-14650HX, NVIDIA GeForce RTX 4050 Laptop GPU (driver 566.24), Vulkan SDK 1.4.363.0. ctest -R "draw_cache|address_passes|mesh_draw_relocation|linear_target_resident" -V with ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1 and VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation, 17 tests:

  • This PR: 17 of 17 pass.
  • main (the fix files from main, the test commit kept): agc_driver_draw_cache_relocation, _relocation_recipe_verify and _relocation_draw_pipeline fail with 0 of 6 draws served by a relocated entry were recorded from the cached draw's recipe, expected all; the other 14 pass.
  • Neither log contains was not found but was requested by env var VK_INSTANCE_LAYERS; both have 0 VUID- lines.
  • tools/check_conventions.py passes. tools/pr_overlap.py --branch now reports #6804 and #10678, which change the commitDraw signature and its call sites in Draw.cpp; neither implements the same thing.

Original run, before the rebase:

Windows 11 (build 26300), WinLibs GCC 15.2.0 (posix-seh, ucrt), Release, -DBUILD_TESTING=ON, Ryzen 7 7435HS / 16 GB, NVIDIA GeForce RTX 3050 Laptop GPU (driver 617.42, graphics pipeline libraries available), rebased on main b39d90bf1:

  • This PR: agc_driver_draw_cache_relocation passes, as do agc_driver_draw_cache_reuse and its _reuse_off, _reuse_verify and _reuse_inline variants. agc_driver_address_passes, agc_driver_address_passes_targets_split, agc_driver_mesh_draw_relocation and agc_driver_linear_target_resident also pass.
  • Negative control: with the fix commit reverted and the test commit kept, the new case fails with 0 of 6 draws served by a relocated entry were recorded from the cached draw's recipe, expected all.
  • Hades (PPSA03355), with the fix on a local branch that also carries other relocation work: draw recipe attaches in the [recipe] profile line go from 0 to non-zero, though only about 15 recipes are built per ~100,000 draws (see above). No frame-rate change.
  • tools/check_conventions.py --base origin/main passes.
  • tools/pr_overlap.py --branch reports four line overlaps, none implementing the same thing: #6454 (test includes and the MovedDataHitsTheCache end in DrawCacheRelocation.cpp), #6914 (the recipe block in Execution/.../Draw.cpp), and #7254 and #7256 (DrawWithRecipe in Graphics/src/Draw.cpp). Happy to rebase on whichever goes first.
  • Not run on lavapipe or without graphics pipeline libraries; like the other cases in this file, the new case skips without them unless APS5_NO_GPL is set.

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 (draw recipes on relocated draw-cache hits; found on PPSA03355 #3234, no stop there)
  • GPUs tested: NVIDIA GeForce RTX 4050 Laptop GPU, driver 566.24, Windows 11 (build 26200) (after the rebase); NVIDIA GeForce RTX 3050 Laptop GPU, driver 617.42, Windows 11 (build 26300) (before it)
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4905909605 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/7369). Originally posted by [Flamefusion](https://github.com/Flamefusion) on 2026-10-18T02:55:54Z. --- ### What A draw that misses on its own register key and is served by a relocated draw entry (`relocateDrawEntry`, #4943) never uses or keeps a draw recipe, so every such draw is recorded in full (`Graphics::Draw`) instead of from the cached draw's recipe (`DrawFromRecipe`). In `Driver::draw` (Execution/src/Driver/Draw/Draw.cpp): - `relocateDrawEntry` builds a fresh `DrawEntry` with per-draw copies of the donor's variants. That entry is not stored in `drawCache` under the draw's key. - `findDrawRecipe` and, after recording, `attachDrawRecipe` still look up the draw's own key in `drawCache`. They find nothing and return, so a relocated hit never finds the donor's recipe, and a recipe built while recording it is dropped. With `APS5_TRACE_DRAW_CACHE` this shows as "attaches 0". - The recipe records also compare stage identity against the per-draw copies, which are new objects on every draw, so even a stored record could never match. Fix: - `DrawEntry` and `DispatchVariant` gain a `donor` pointer. `relocateDrawEntry` sets it on the relocated entry and on every copied variant, always to the original cached entry or variant (a copy of a copy points at the root), so the chain never grows. - `Driver::draw` keys the recipe stages on the donor variant when a matched variant is a relocation copy. It hands the donor entry to `findDrawRecipe` and `attachDrawRecipe`, also through `commitDraw` on the pipelined path. With a donor, both read and update the donor entry's recipe list directly instead of looking up the key; without one they behave as before. - `Graphics::DrawWithRecipe` rebuilds the push constant block from the current shaders (`AssemblePushConstants` plus the recorded patches) when the recipe has push constants. Relocation moves user words that land in push constants, so the donor's block must not be replayed as-is. Found while profiling Hades (PPSA03355, discussion #3234), whose sprite draws move per-draw pointers on almost every draw. There, recipe attaches now succeed, but few of its draws build a recipe at all: most hold an address-based build's lease, so they are not reusable. This PR therefore claims no frame-rate change; it makes the relocated path consistent with the exact-key path. Test: `agc_driver_draw_cache_relocation` gains `RelocatedDrawsReuseTheirRecipe`. - Its draws read a constant through a user pointer that moves on every draw to identical contents, so after four teaching draws every further draw is a relocated hit. - They render into a 64 KiB guest block with the SW_64KB_R_X swizzle mode. The 1 KiB linear target the other cases use is never resident, and a draw into a non-resident target is not recorded, so it would never build a recipe. - The case requires all six later draws to be draw-cache hits and all six to be recorded from the recipe. - `VulkanDevice::DrawRecipeHits()` exposes the draw recipe hit counter the `[recipe]` profile line already keeps, so the test can read it without `APS5_PROFILE_DRAW`. ### Tested **Rebased on `main` `98346b748c`** (the branch was about 14,000 commits behind). Conflicts were textual: `main` had added `valueWords`/`valueSlots`/`calleeWords`/`calleeReads` next to `donor` in `DispatchVariant` and its relocated copy, `DrawTraceContext` next to `DrawRecipeHits()` in `VulkanDevice`, and defaulted `trace`/`shape` parameters to `commitDraw`; `recipeDonor` now comes before those, and both call sites pass it. `findDrawRecipe` and `attachDrawRecipe` on `main` still look up only the draw's own key. Windows 11 Home (build 26200), WinLibs GCC 15.2.0 r7 (posix-seh, ucrt), Release, `-DBUILD_TESTING=ON`, Intel Core i7-14650HX, NVIDIA GeForce RTX 4050 Laptop GPU (driver 566.24), Vulkan SDK 1.4.363.0. `ctest -R "draw_cache|address_passes|mesh_draw_relocation|linear_target_resident" -V` with `ANYPS5_REQUIRE_VULKAN=1`, `ANYPS5_NO_SHADER_CACHE=1` and `VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation`, 17 tests: - This PR: 17 of 17 pass. - `main` (the fix files from `main`, the test commit kept): `agc_driver_draw_cache_relocation`, `_relocation_recipe_verify` and `_relocation_draw_pipeline` fail with `0 of 6 draws served by a relocated entry were recorded from the cached draw's recipe, expected all`; the other 14 pass. - Neither log contains `was not found but was requested by env var VK_INSTANCE_LAYERS`; both have 0 `VUID-` lines. - `tools/check_conventions.py` passes. `tools/pr_overlap.py --branch` now reports #6804 and #10678, which change the `commitDraw` signature and its call sites in `Draw.cpp`; neither implements the same thing. Original run, before the rebase: Windows 11 (build 26300), WinLibs GCC 15.2.0 (posix-seh, ucrt), Release, `-DBUILD_TESTING=ON`, Ryzen 7 7435HS / 16 GB, NVIDIA GeForce RTX 3050 Laptop GPU (driver 617.42, graphics pipeline libraries available), rebased on `main` `b39d90bf1`: - This PR: `agc_driver_draw_cache_relocation` passes, as do `agc_driver_draw_cache_reuse` and its `_reuse_off`, `_reuse_verify` and `_reuse_inline` variants. `agc_driver_address_passes`, `agc_driver_address_passes_targets_split`, `agc_driver_mesh_draw_relocation` and `agc_driver_linear_target_resident` also pass. - Negative control: with the fix commit reverted and the test commit kept, the new case fails with `0 of 6 draws served by a relocated entry were recorded from the cached draw's recipe, expected all`. - Hades (PPSA03355), with the fix on a local branch that also carries other relocation work: draw recipe attaches in the `[recipe]` profile line go from 0 to non-zero, though only about 15 recipes are built per ~100,000 draws (see above). No frame-rate change. - `tools/check_conventions.py --base origin/main` passes. - `tools/pr_overlap.py --branch` reports four line overlaps, none implementing the same thing: #6454 (test includes and the `MovedDataHitsTheCache` end in `DrawCacheRelocation.cpp`), #6914 (the recipe block in `Execution/.../Draw.cpp`), and #7254 and #7256 (`DrawWithRecipe` in `Graphics/src/Draw.cpp`). Happy to rebase on whichever goes first. - Not run on lavapipe or without graphics pipeline libraries; like the other cases in this file, the new case skips without them unless `APS5_NO_GPL` is set. ### 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] Fixes: none - [x] Unblocks: none (draw recipes on relocated draw-cache hits; found on PPSA03355 #3234, no stop there) - [x] GPUs tested: NVIDIA GeForce RTX 4050 Laptop GPU, driver 566.24, Windows 11 (build 26200) (after the rebase); NVIDIA GeForce RTX 3050 Laptop GPU, driver 617.42, Windows 11 (build 26300) (before it) - [x] AI-assisted: yes
MarcZX10 commented 2026-10-18 02:58:54 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-18T02:58:54Z.

Code review location: core/libs/prx/libSceAgcDriver/Execution/src/Driver/Draw/DrawCache.cpp; line 220

@@ -214,9 +216,9 @@ std::shared_ptr<const DrawRecipe> Driver::findDrawRecipe(std::uint64_t key, cons
     return nullptr;
 }
 
-void Driver::attachDrawRecipe(std::uint64_t key, const std::vector<std::shared_ptr<DispatchVariant>>& stages, std::shared_ptr<const DrawRecipe> recipe) {
-    std::shared_ptr<DrawEntry> entry;
-    {
+void Driver::attachDrawRecipe(std::uint64_t key, const std::vector<std::shared_ptr<DispatchVariant>>& stages, std::shared_ptr<const DrawRecipe> recipe, const std::shared_ptr<DrawEntry>& donor) {
+    std::shared_ptr<DrawEntry> entry = donor;

This donor path lets relocated entries from different draw keys attach recipes to the same DrawEntry. The recipe update below is a load-copy-store sequence: if two completions load the same old vector, each builds a vector with only its own new record, and the later store drops the other attachment. AtomicSharedPtr makes each operation safe, but not this compound update. Could this use a compare-and-retry loop (or per-entry serialization) so parallel relocated draws do not discard each other’s cached recipes?

<!-- greyfinch-sync:boykopovar/AnyPS5:review-comment:4305496372 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/7369#discussion_r4305496372). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-18T02:58:54Z. **Code review location:** `core/libs/prx/libSceAgcDriver/Execution/src/Driver/Draw/DrawCache.cpp`; line 220 ~~~~diff @@ -214,9 +216,9 @@ std::shared_ptr<const DrawRecipe> Driver::findDrawRecipe(std::uint64_t key, cons return nullptr; } -void Driver::attachDrawRecipe(std::uint64_t key, const std::vector<std::shared_ptr<DispatchVariant>>& stages, std::shared_ptr<const DrawRecipe> recipe) { - std::shared_ptr<DrawEntry> entry; - { +void Driver::attachDrawRecipe(std::uint64_t key, const std::vector<std::shared_ptr<DispatchVariant>>& stages, std::shared_ptr<const DrawRecipe> recipe, const std::shared_ptr<DrawEntry>& donor) { + std::shared_ptr<DrawEntry> entry = donor; ~~~~ --- This donor path lets relocated entries from different draw keys attach recipes to the same `DrawEntry`. The recipe update below is a load-copy-store sequence: if two completions load the same old vector, each builds a vector with only its own new record, and the later store drops the other attachment. `AtomicSharedPtr` makes each operation safe, but not this compound update. Could this use a compare-and-retry loop (or per-entry serialization) so parallel relocated draws do not discard each other’s cached recipes?
Flamefusion commented 2026-10-18 03:10:44 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by Flamefusion on 2026-10-18T03:10:44Z.

Code review location: core/libs/prx/libSceAgcDriver/Execution/src/Driver/Draw/DrawCache.cpp; line 220

@@ -214,9 +216,9 @@ std::shared_ptr<const DrawRecipe> Driver::findDrawRecipe(std::uint64_t key, cons
     return nullptr;
 }
 
-void Driver::attachDrawRecipe(std::uint64_t key, const std::vector<std::shared_ptr<DispatchVariant>>& stages, std::shared_ptr<const DrawRecipe> recipe) {
-    std::shared_ptr<DrawEntry> entry;
-    {
+void Driver::attachDrawRecipe(std::uint64_t key, const std::vector<std::shared_ptr<DispatchVariant>>& stages, std::shared_ptr<const DrawRecipe> recipe, const std::shared_ptr<DrawEntry>& donor) {
+    std::shared_ptr<DrawEntry> entry = donor;

Good catch, thanks. The race was already possible on one key, but sharing the donor entry across keys makes it much more likely, and pipelined commits can attach in parallel.

Fixed in 090d66e6e: attachDrawRecipe now uses a compare_exchange_strong loop. If another attach replaced the list after the load, the new list is rebuilt from the list now stored and the exchange is retried, so both records are kept (still capped at dispatchVariants()). Both the AtomicSharedPtr fallback and std::atomic<std::shared_ptr> provide compare_exchange_strong.

The draw cache relocation and reuse tests (all variants), address passes, mesh draw relocation and linear target resident tests still pass.

<!-- greyfinch-sync:boykopovar/AnyPS5:review-comment:4305524015 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/7369#discussion_r4305524015). Originally posted by [Flamefusion](https://github.com/Flamefusion) on 2026-10-18T03:10:44Z. **Code review location:** `core/libs/prx/libSceAgcDriver/Execution/src/Driver/Draw/DrawCache.cpp`; line 220 ~~~~diff @@ -214,9 +216,9 @@ std::shared_ptr<const DrawRecipe> Driver::findDrawRecipe(std::uint64_t key, cons return nullptr; } -void Driver::attachDrawRecipe(std::uint64_t key, const std::vector<std::shared_ptr<DispatchVariant>>& stages, std::shared_ptr<const DrawRecipe> recipe) { - std::shared_ptr<DrawEntry> entry; - { +void Driver::attachDrawRecipe(std::uint64_t key, const std::vector<std::shared_ptr<DispatchVariant>>& stages, std::shared_ptr<const DrawRecipe> recipe, const std::shared_ptr<DrawEntry>& donor) { + std::shared_ptr<DrawEntry> entry = donor; ~~~~ --- Good catch, thanks. The race was already possible on one key, but sharing the donor entry across keys makes it much more likely, and pipelined commits can attach in parallel. Fixed in 090d66e6e: `attachDrawRecipe` now uses a `compare_exchange_strong` loop. If another attach replaced the list after the load, the new list is rebuilt from the list now stored and the exchange is retried, so both records are kept (still capped at `dispatchVariants()`). Both the `AtomicSharedPtr` fallback and `std::atomic<std::shared_ptr>` provide `compare_exchange_strong`. The draw cache relocation and reuse tests (all variants), address passes, mesh draw relocation and linear target resident tests still pass.
MarcZX10 commented 2026-10-18 03:14:47 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-18T03:14:47Z.


Thanks for the fix. The compare-and-retry rebuilds from the latest recipe list on contention, which addresses the lost-attachment race I flagged. The updated head is clean; I have not run the draw-cache tests locally.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6245086215 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/7369#issuecomment-6245086215). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-18T03:14:47Z. --- Thanks for the fix. The compare-and-retry rebuilds from the latest recipe list on contention, which addresses the lost-attachment race I flagged. The updated head is clean; I have not run the draw-cache tests locally.
blawesom commented 2026-10-19 08:50:57 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by blawesom on 2026-10-19T08:50:57Z.


Rebase handoff — rebased onto current main (all three commits, authorship unchanged). Test-file conflicts unioned (main's newer SRT-walker tests kept alongside your recipe-coverage tests).

Verified on Linux (CachyOS, kernel 7.2.9, GCC 16.2.1, Ninja, Release, BUILD_TESTING=ON, AMD RX 9070 XT / RADV): builds; the draw-cache tests pass (5/5); conventions pass; full suite green apart from the four known main regressions (#5444 Mesa, #7584 BDA, #7766, #7784), none from this PR.

To pick it up:

git fetch https://github.com/blawesom/AnyPS5 rebase/7369
git checkout <your branch>
git merge --ff-only FETCH_HEAD

Head is f08cae59a.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6263395535 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/7369#issuecomment-6263395535). Originally posted by [blawesom](https://github.com/blawesom) on 2026-10-19T08:50:57Z. --- **Rebase handoff** — rebased onto current `main` (all three commits, authorship unchanged). Test-file conflicts unioned (`main`'s newer SRT-walker tests kept alongside your recipe-coverage tests). Verified on Linux (CachyOS, kernel 7.2.9, GCC 16.2.1, Ninja, Release, `BUILD_TESTING=ON`, AMD RX 9070 XT / RADV): builds; the draw-cache tests pass (5/5); conventions pass; **full suite green apart from the four known `main` regressions** (#5444 Mesa, #7584 BDA, #7766, #7784), none from this PR. **To pick it up:** ``` git fetch https://github.com/blawesom/AnyPS5 rebase/7369 git checkout <your branch> git merge --ff-only FETCH_HEAD ``` Head is `f08cae59a`.
Flamefusion commented 2026-10-19 18:04:26 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by Flamefusion on 2026-10-19T18:04:26Z.


@adriadam10 do you need anything from my side for this pr ?

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6273857614 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/7369#issuecomment-6273857614). Originally posted by [Flamefusion](https://github.com/Flamefusion) on 2026-10-19T18:04:26Z. --- @adriadam10 do you need anything from my side for this pr ?
Flamefusion commented 2026-10-20 05:44:43 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by Flamefusion on 2026-10-20T05:44:43Z.


Rebased onto current main (87a32d145). New head is 562f9107f; the three commits are unchanged in intent.

Thanks @blawesom for the earlier rebase handoff. main had moved again since then, so I redid it on the latest tip:

  • Graphics/src/Draw.cpp: textual conflict with #7254 in DrawWithRecipe. I kept main's layered targetSlices line and the push-constant patching from this PR.
  • Execution/src/Driver/Draw/Draw.cpp: #6931 added a pipelined indirect commitDraw call with the old signature, which git did not flag. It now passes nullptr for the recipe donor. Indirect draws never take the recipe path, so this changes nothing in behaviour.

Verified on Windows 11, MinGW GCC 15.2, Ninja, Release, BUILD_TESTING=ON, NVIDIA RTX 3050 Laptop (driver 617.42):

  • builds
  • all 32 AGC draw-path tests pass, including the draw cache relocation/reuse variants, mesh draw relocation, linear target resident and pipelined indirect draws
  • check_conventions.py passes
<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6284306701 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/7369#issuecomment-6284306701). Originally posted by [Flamefusion](https://github.com/Flamefusion) on 2026-10-20T05:44:43Z. --- Rebased onto current `main` (`87a32d145`). New head is `562f9107f`; the three commits are unchanged in intent. Thanks @blawesom for the earlier rebase handoff. `main` had moved again since then, so I redid it on the latest tip: - **`Graphics/src/Draw.cpp`**: textual conflict with #7254 in `DrawWithRecipe`. I kept `main`'s layered `targetSlices` line and the push-constant patching from this PR. - **`Execution/src/Driver/Draw/Draw.cpp`**: #6931 added a pipelined indirect `commitDraw` call with the old signature, which git did not flag. It now passes `nullptr` for the recipe donor. Indirect draws never take the recipe path, so this changes nothing in behaviour. Verified on Windows 11, MinGW GCC 15.2, Ninja, Release, `BUILD_TESTING=ON`, NVIDIA RTX 3050 Laptop (driver 617.42): - builds - all 32 AGC draw-path tests pass, including the draw cache relocation/reuse variants, mesh draw relocation, linear target resident and pipelined indirect draws - `check_conventions.py` passes
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!7369
No description provided.