Skip to content

perf(agc): reuse eligible image table entries independently - #6340

Open
MarcZX10 wants to merge 11 commits into
boykopovar:mainfrom
MarcZX10:codex/partial-image-table-reuse-5961-current
Open

MarcZX10 wants to merge 11 commits into
boykopovar:mainfrom
MarcZX10:codex/partial-image-table-reuse-5961-current

Conversation

@MarcZX10

@MarcZX10 MarcZX10 commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

What

Reuse eligible image-table entries independently under the existing collect-epoch and invalidation rules. Today one DCC-backed or otherwise ineligible entry prevents the cache from remembering every clean entry in that table. #6099 reports about 100,000 elements resolved per 10 seconds and no table reuse in its measured Wolverine scene.

This stores eligibility and a guest-memory generation proof per element. Repeated tables reuse an entry only while its texture-cache key and object still match; entries with pending writes or cache misses resolve normally. A pending-write serial change during validation causes a full lookup retry. Rejected entries are re-resolved instead of replaying cached rejection results.

The execution test adds mixed clean/DCC entries and a pending GPU write to one image in a separate guest-memory tracking block, checking that unaffected siblings remain reusable. No speedup is claimed until the reporter's same-scene before/after counters are available.

Tested

  • Linux x86_64, GCC 12: both changed C++ translation units compile. The test executable linked on the previous upstream snapshot; its full build needed a temporary template disambiguator for an unrelated baseline expression, which was reverted before commit. After rebasing on current main, both changed translation units compile directly.
  • python3 tools/check_conventions.py --base upstream/main --head HEAD and git diff --check pass.
  • Runtime execution stopped at AnyPS5's host CPU guard: Intel Xeon E5-1620 v2 lacks LZCNT, BMI1/BMI2, MOVBE, AVX2 and FMA. No GPU test or same-scene performance comparison ran here.
  • Requested the reporter to capture the same counters on main and this branch.

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: none
  • GPUs tested: none; host CPU guard stopped the test before Vulkan setup
  • AI-assisted: yes

Related: #5961 and #6099.

@MarcZX10
MarcZX10 marked this pull request as draft October 15, 2026 12:20
@MarcZX10

MarcZX10 commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor Author

@Thunderhawkk Could you compare the same Wolverine scene on main and this branch and share the image-table resolved/reused counts plus [resources] timings? The PR is marked draft while I wait for the before/after performance data required for this change.

@github-actions

github-actions Bot commented Oct 15, 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 6192 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 6412 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 6481 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 7002 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 7642 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 9508 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 9592 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 9712 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 9852 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 9897 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 10193 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 10442 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 10492 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 10497 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 10743 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 10894 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 11444 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 11551 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 12575 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 12840 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 12944 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 13796 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 13809 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 13928 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 13929 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 14032 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 14262 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 14871 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 14944 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 15529 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 15570 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 15936 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 16831 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 16879 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 16935 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 16953 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 18185 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 18390 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 19722 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 19852 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 20041 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 20248 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 20315 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 20519 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 20728 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 21199 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 21238 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 21780 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 22424 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 22439 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 22647 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 22690 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 22703 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 23242 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 23545 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 23688 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 23726 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 24346 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 24510 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 24631 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 24661 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 24793 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 25443 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
core/libs/prx/libSceAgcDriver/tests/execution/ImageTableReuse.cpp
PR 25534 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 25849 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 26197 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 26268 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 26436 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 26612 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 26802 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 26859 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
PR 26913 core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp

@fdfawef324

Copy link
Copy Markdown
Contributor

The new mixed-DCC case captures before before both dispatches, but its Expect(before, 1, 1, ...) appears inconsistent with the new counter semantics.

On the intended path, the first build resolves the table (0 reused / 1 resolved). The second build reuses its clean siblings and still resolves the DCC entry, which is excluded by the resource.dccAddress == 0 eligibility condition (1 reused / 1 resolved). The combined delta is therefore 1 reused / 2 resolved. A successful fast revalidation bypasses both counter increments, so that path would not produce the expected 1 / 1 either.

Please check the resolved-count expectation and both texel readbacks in the native test. This is a source review of ef724aad62280d62ec5ca297803da1155051819f; I have not executed the GPU case.

@Neithennn

Copy link
Copy Markdown
Contributor

Windows NVIDIA run, since the host CPU guard stopped the test on your machine: agc_driver_image_table_reuse fails with this PR, at an existing case, before the new mixed-DCC case is reached.

Windows 11 Pro 26200, NVIDIA GeForce RTX 4080 (driver 617.42), AMD Ryzen 7 5800X, WinLibs GCC 15.2.0 r7, Ninja, Release, bundled dependencies, BUILD_TESTING=ON, ANYPS5_NO_SHADER_CACHE=1. Head ef724aad6 merged onto main ff23657f3; full build succeeds.

AGC graphics: image table reuse: a CPU write collected in a new epoch, then two dispatches: 2 reused and 2 resolved tables, expected 1 and 2
  • agc_driver_image_table_reuse: fails 8/8 with this PR (targeted, broad and 6 serial reruns); passed in both baseline runs on unchanged main ff23657f3 on the same machine.
  • The failing check is the existing Expect(before, 3 - CpuWriteResolutions, CpuWriteResolutions, ...) ("a CPU write collected in a new epoch, then two dispatches"). On Windows CpuWriteResolutions is 2, so it expects 1 reused / 2 resolved; this branch counts 2 reused / 2 resolved, one reused table more than expected. Linux uses CpuWriteResolutions = 1; I have not run Linux, so I do not know whether it fails there.
  • Because the test stops there, the new mixed-DCC case, and the Expect(before, 1, 1, ...) questioned above, did not run here.
  • Other targeted tests pass: agc_driver_image_table, agc_driver_image_table_cache, agc_driver_image_table_cache_bounds, agc_driver_bindless_images, agc_shader_bindless.
  • ctest -R "agc_|shader|recompiler|spirv|video_out" -j 8: 621/623; the other failure is agc_driver_store_over_untracked (Windows: StoreOverUntracked fails at "the first result was not stored" #6347/AGC: StoreOverUntracked's NeighbourCopied case intermittently misses its pending result on Windows / RTX 4080 #6383), also on main.

No performance measurement.

AI-assisted: yes (runs done with Claude Code).

@Thunderhawkk

Copy link
Copy Markdown

@MarcZX100 Thanks — ran the Wolverine (PPSA03671) comparison on this machine: same scene/save, RTX 5070 Ti (16 GiB), 24 GB RAM, driver 617.42, 5-minute runs, warm shader cache, APS5_PROFILE_DRAW=1.

One caveat first: on plain main and on this branch the scene does not reach steady gameplay here — both die with a device OOM during the load phase (vkAllocateMemory ... Vulkan result -2, ~52k storage images created before dying, 3–4 minutes in). That is the #5961 memory problem, not your change. So the numbers below are from a matched pair: main + #6174 + #6194 vs the same tree + your commit, run back to back with identical settings. Both still die the same way at ~4 minutes, but they reach the same point, so the deltas are attributable.

metric base (main + #6174 + #6194) + ef724aa
image tables reused / resolved (cumulative, end of run) 0 / 93 63 / 94
storage images hits / created 50,492 / 52,675 50,495 / 52,182
[resources] at 931 builds: images / stage B 91,755 ms / 96,021 ms 84,949 ms / 88,776 ms
[resources] at 1,007 builds: images / stage B 151,452 ms / 156,542 ms 133,050 ms / 137,596 ms
run end device OOM at ~4:01 device OOM at ~3:50

Your change clearly engages: on the base the all-or-nothing reuse path never fires (0 reused), while with your commit 63 of 94 resolved tables (~2/3) reuse elements, and the resource-build totals at matched build counts come out 7–12% lower (single runs each — indicative).

Two notes on reading these counters:

If you want gameplay-phase numbers: on this machine main-derived builds die in the load phase, so it needs the memory-side work to survive past it — happy to rerun on a base that includes it.

@simonbronk

Copy link
Copy Markdown
Contributor

Onimusha: Way of the Sword (PPSA27836) data, Windows 11 26200, RTX 5070 (NVIDIA 617.42), WinLibs GCC 15.2, Release. Base: main 0afa6a6 plus the title's open PRs (#5907 #5776 #5770 #5703 #5841 #5884 #5915 #5815). ef724aad6 cherry-picked cleanly on top. Scene: boot to the language menu, 150 s, APS5_PROFILE_DRAW=1, warm shader cache.

base + ef724aa
image tables reused / resolved (cumulative, [textures]) 0 / 1833 0 / 2250
[resources] images phase 16.9 s over 13000 builds 18.5 s over 16000 builds

The change reuses nothing in this title. I added local counters (not for merging) at the eligibility test in resolveImageTables to see why:

  • elements that reached the test: 20000. Of these, 19999 had looked->generation == 0 and 8276 had looked->source != nullptr. None had compressed keys or a dccAddress. Reusable: 0.
  • tables at the store check: 1800. None had a reusable element, so RememberTable never ran. epoch was never 0, and CurrentTableState() != state happened only 23 times.

So in this title the generation proof is missing, not the DCC rule. The sampled images live in memory that the generation tracker does not cover. The same run's [textures] line reports untracked snapshots 16310 kept by the write-watch hint. Per-entry reuse would need a proof that works over untracked memory, for example the write-watch hint that the snapshots already use. That is likely a separate change from this one.

AI-assisted: measured with Claude Code. The counters were a local diff, removed after the runs.

@mrfelek

mrfelek commented Oct 15, 2026

Copy link
Copy Markdown
Contributor

Wolverine (PPSA03671): image-table counters on this PR, from the splash phase

System: Linux, RTX 3080 Ti 12 GB (NVIDIA 615.71.09)
Builds: main plus #5998 (base), and the same plus this PR at head ef724aad6. Both built from origin/main with the same libraries and the same relinked executable.
Setup: APS5_PROFILE_DRAW=1 APS5_PROFILE_GPU=1, no input, 150 s after start. Both runs reached the Sony splash.

Build Image tables reused / resolved (cumulative) Last [resources] images phase
base 0 / 190 652 ms (2,512 textures, 13 buffers)
+ ef724aad6 137 / 206 574 ms (2,513 textures, 20 buffers)
  • This is the first title in our tests where the reuse path runs: 137 entries are reused on this PR, and none on base.
  • The [resources] values are single samples from the last log line, so they don't show a performance difference. Both runs were still on the splash.
  • Frame rate was not measured. Both ran at about 0.27 FPS on the splash, so there's no in-game number.
  • The counts are consistent with the Wolverine reuse counts in Thunderhawkk's comment (63 reused, on a different machine).
  • Not tested: a menu or gameplay scene, and Windows.

AI-assisted; the runs are from my machine.

@mrfelek

mrfelek commented Oct 15, 2026

Copy link
Copy Markdown
Contributor

Wolverine (PPSA03671): why most image-table elements are not reused on this PR

System: Linux, RTX 3080 Ti 12 GB (NVIDIA 615.71.09)
Build: main plus #5998 plus this PR at head ef724aad6, with local diagnostic counters in the reuse check (not for merging)
Scene: same as the earlier counters comment: Wolverine, APS5_PROFILE_DRAW=1 APS5_PROFILE_GPU=1, no input, 150 s, Sony splash

Where the elements go

The counters record, for each element that reaches the reuse check, the first condition it fails, in the order of the remembered.reusable expression. The totals are per element over the run, not per table.

Reason Elements
The lookup entry is a storage-image view (source != nullptr) 292,315
Surface not tracked yet (generation == 0) 1,624
No CPU-write epoch yet (epoch == 0) 0
No lookup entry 0
Lookup is a different texture 0
Compressed keys 0
DCC address present 0
Reusable 24,061
  • The storage-image case accounts for almost every failure. About 276,000 sampled textures in this run are created from storage images, so the reuse check excludes most of what this title samples.
  • The other checks almost never fail here.

The table-level counter (137 reused, 206 resolved) and these per-element totals count different things, so they don't add up to each other.

Question for the author

Should the reuse check cover storage-image views, or is excluding them intended? If it's intended, most of this title's image-table elements will not be reused by this PR.

Not tested: a menu or gameplay scene, Windows.

AI-assisted; the runs are from my machine.

@mrfelek

mrfelek commented Oct 15, 2026

Copy link
Copy Markdown
Contributor

agc_driver_image_table_reuse on Linux: fails with this PR at head ef724aad6

System: Linux, Ryzen 9 5950X, RTX 3080 Ti (NVIDIA 615.71.09), GCC 15, Release
Build: origin/main at b576c3d5a (current main with this PR's head merged on top, no other changes), ANYPS5_ENABLE_SPIRV_TOOLS=OFF, target tests/agc_driver_image_table_reuse_tests

Result

The test exits with code 1. The failing check is:

AGC graphics: image table reuse: CPU writes to a new table's 64 KiB block, then an image store leaving results pending over an entry: 3 reused and 2 resolved tables, expected 2 and 2

So this case reuses one more table than the test expects.

Relation to the Windows report above

Neithennn's Windows failure (CPU write collected in a new epoch, then two dispatches: 2 reused and 2 resolved tables, expected 1 and 2) is a different case in the same file. On Linux, this is the second failing case I've seen, so the two may share a cause in how reuse is counted.

I haven't checked whether this case passes without the PR, because the test doesn't exist on main.

AI-assisted; the runs are from my machine.

@mrfelek

mrfelek commented Oct 15, 2026

Copy link
Copy Markdown
Contributor

agc_driver_image_table_reuse on Linux: the Windows check passes here

System: Linux, Ryzen 9 5950X, RTX 3080 Ti (NVIDIA 615.71.09), GCC 15, Release
Build: origin/main at b576c3d5a plus this PR's head ef724aad6, no other changes.

The check reported from Windows

The case a CPU write collected in a new epoch, then two dispatches (line 338 of ImageTableReuse.cpp) runs before the case that fails on Linux, which is at line 370. On this build the test gets past line 338 and reaches the later case, so the Windows check passes here.

What this means

  • The Windows failure does not reproduce on Linux with this head.
  • The Linux failure in my earlier comment is a different case, in RunImageStore, which runs later in the same test.

So the two reports may not be the same bug. The Windows failure may depend on the platform, the build, or the test ordering.

AI-assisted; the runs are from my machine.

@mrfelek

mrfelek commented Oct 15, 2026

Copy link
Copy Markdown
Contributor

agc_driver_image_table_reuse on Linux: still fails at head ef724aad6

Setup

  • Head: ef724aad6, clean worktree of the PR head, Release
  • Host: Linux, Ryzen 9 5950X, RTX 3080 Ti, NVIDIA 615.71.09

Result

  • Build: exit 0
  • agc_driver_image_table_reuse_tests: exit 1
  • Failing case: image table reuse: CPU writes to a new table's 64 KiB block, then an image store leaving results pending over an entry: 3 reused and 2 resolved tables, expected 2 and 2

This matches the run I posted at 16:59. The head is unchanged since then.

AI-assisted; the build and run are from my machine.

@MarcZX10
MarcZX10 force-pushed the codex/partial-image-table-reuse-5961-current branch from ef724aa to 64a5a02 Compare October 15, 2026 21:40
@ntamas94

ntamas94 commented Nov 1, 2026

Copy link
Copy Markdown
Contributor

@MarcZX10 One thing at head a58ce71 that may be part of the counter shift reported above, from reading resolveImageTables (Graphics/src/ShaderResources.cpp).

The element's texture is looked up with the narrowed words:

const auto sampledWords = firstLayerWords(words, binding.imageShapes.at(element), narrowed, true);   // :4975
...
texture = cachedTexture(context, sampledWords, resource, components, guestBytes, depthCompare, multisampleViewType);

but the remembered entry is keyed with the raw words:

remembered.key = MakeTextureKey(context.device, words, components, depthCompare);   // :4997

main keyed the reused element with sampledWords, the same words the texture was found under. When firstLayerWords narrows an element (an array or cube descriptor sampled as its first layer), the stored key differs from the cache entry's key. CachedTableTextures then misses it in findTexture (:1789), and the element is resolved again on every replay instead of being reused. Elements that are not narrowed are unaffected, because sampledWords and words are the same span for them. Keying with sampledWords as before should fix it.

This is from reading the code only; I have not run the branch. The title I am looking at (Crysis Remastered, CUSA18659) uses no image tables (image tables 0 reused, 0 resolved), so I cannot measure it.

AI-assisted: yes

@Dextroid17

Copy link
Copy Markdown
Contributor

Ghost of Yōtei: the sampledWords key change measured, and a timed A/B

@ntamas94 thanks for tracing it in your comment. I ran that change in Ghost of Yōtei. In this title the change alone does not move the counters: reused and resolved stay where they were, and replays stay at 0. The ImageTableReuse assertion also still fails with it. That failure looks like the per-entry counter semantics mrfelek described.

System: Linux 7.3.0-4-cachyos, RTX 3080 Ti (NVIDIA 615.78.08), Release (-O3).
Setup: same launch script and env for every run, warm pipeline cache (about 81,000 KiB loaded in every counted run), no input, 600 s limit (each run killed at the limit, exit 137), all in the load phase. A = main, B = main plus a local merge of this PR's head a58ce71d12 (applied cleanly, 2 files, +180/−67).
Counter patch: for the counter runs, both arms carry the same one-line local change to ShaderResources.cpp. It adds tablesReplayed to the [textures] image tables line, as in my previous comment. By reading, it changes log output only.

1. sampledWords key change (main at f1a7b02028, one run per row)

B with remembered.key = MakeTextureKey(context.device, sampledWords, components, depthCompare); in place of words, nothing else changed:

build reused resolved replayed
A, main 393 2,137 773
B, this PR 148 1,129 0
B + sampledWords key 137 1,137 0

These are the cumulative values on each run's last summary line. They level off early: A was already at 383 / 1,990 / 751 by 96 s. replayed is 0 on every summary line of both B runs (27 and 29 lines). Across six other runs of plain B, the final reused value ranged from 122 to 141. So 148 → 137 is within run-to-run noise. I did not count how many elements firstLayerWords narrows in this title. So this shows only that the key change alone does not restore replay here. It may still be right for narrowed elements.

2. Same counters on main at f2d874c1fd (tip when run)

This confirms the 0-replay result from my previous comment on a newer main. f2d874c1fd does not change ShaderResources.cpp from f1a7b02028, and the PR still merges cleanly. One run per arm:

build reused resolved replayed
A, main 394 2,144 789
B, this PR 122 1,129 0

agc_driver_image_table_reuse (lavapipe) fails on this merge with the same message: a driver store over an entry: 2 reused and 1 resolved tables, expected 1 and 1.

3. Load-phase timing (main at f1a7b02028, 4 runs per arm)

This is the [resources] images took N ms (33673 textures …) phase of the single 33,673-texture resource build: image binding lookups plus image-table resolution. It appears once per run. The order was A B B A A B B A, after one discarded warm-up run per arm. Stock logging, no counter patch, and B is this PR without the key change. I did not repeat the timing on f2d874c1fd.

pair A B B vs A
1 49,519 ms 56,072 ms +13.2%
2 46,725 ms 49,441 ms +5.8%
3 51,466 ms 61,084 ms +18.7%
4 56,098 ms 52,449 ms −6.5%
mean 50,952 ms 54,762 ms +7.5%

B was slower in 3 of 4 pairs, but A's own runs range over 9,373 ms, which is wider than the 3,810 ms gap. So these runs show neither a speed-up nor a clear slowdown in this phase. Presents were 468–480 in every run, and there were no DEVICE_LOST lines, Xid errors or crashes across the 8 runs. I have tools/trace_digest.py output for all 8 runs and can attach it.

@MarcZX10 so in this title, the open question from your last check is still which replay predicate fails. If that data would help, I can rerun with a count per predicate on the replay check (cached/reusable elements, replayable, samplers). I can also paste the counter-patch diff.

AI-assisted: yes

@ntamas94

ntamas94 commented Nov 1, 2026

Copy link
Copy Markdown
Contributor

@Dextroid17 Thanks for measuring the key change. So in Ghost of Yōtei the sampledWords key makes no measurable difference: 137 reused against the 122–141 spread. The loss you found against main (replayed 773 → 0, reused 393 → 148) comes from something else in the PR. The fix still looks right to me for narrowed elements, but here it is not what limits reuse. Whether the per-predicate counts are worth a rerun is @MarcZX10's call; they would show which replay condition fails.

AI-assisted: yes

@MarcZX10 MarcZX10 left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Replies checked — key mismatch confirmed by reading, Fixes line missing, no build

The remembered.key mismatch that a reviewer traced is in the code at this head, and the open question is which replay predicate fails, which is still unmeasured.

What I ran

  • Live head a58ce71d12bf06a898f50cb8d1e2bad7c52a7bcd (OPEN, unchanged from batch).
  • gh api comments, review comments and reviews on #6340, newer than 2026-11-01T01:48:05Z, excluding MarcZX10 and bots.
  • gh pr view 6340 --json body,statusCheckRollup.
  • git show a58ce71d:<path> for ShaderResources.cpp and ImageTableReuse.cpp.
  • git log --merges d14a186f..a58ce71d; git merge-tree --write-tree upstream/main a58ce71d.
  • Nothing was built or run.

Results

Check Result Note
Live head matches batch OPEN
merge-tree vs upstream/main exit 0 clean; 13029 behind, 9 ahead
Merge commits in branch 1 (5cf07f861d) confirmed
PR body vs template Fixes: line missing template L16
Hosted conventions SUCCESS others SKIPPED

Findings

  • @ntamas94 (2026-11-01 17:44 UTC): the reused element is cached under sampledWords (ShaderResources.cpp L4987) but remembered with words (L4997). The cache lookup (findTexture, L1789) uses element.key, so narrowed elements miss. Confirmed by reading. Not reproduced. The key change is your call.
  • @Dextroid17 (2026-11-01 18:13 UTC): reports agc_driver_image_table_reuse (lavapipe) fails on this merge with "2 reused and 1 resolved tables, expected 1 and 1". The message format matches ImageTableReuse.cpp L241. Not verified here; no build.
  • @Dextroid17 asks which replay predicate fails and offers per-predicate counts. Your call. The predicates are TableCurrent and CachedTableTextures (ShaderResources.cpp L1767-L1792).
  • @fogydes (2026-11-01 12:27 UTC): clean merge with upstream/main, confirmed. Merge commit 5cf07f861d in history, confirmed. Missing Fixes: line, confirmed: the body has no such line, and the template has it at L16.

Sources

  • texture = cachedTexture(context, sampledWords, resource, components, guestBytes, depthCompare, multisampleViewType);
  • remembered.key = MakeTextureKey(context.device, words, components, depthCompare);
  • const auto serial = StorageTexture::PendingSerial();
    for (auto& element : table.elements) {
    if (!element.reusable) continue;
    if (serial != table.pendingSerial) {
    const std::array range{std::pair{element.resource.baseAddress, element.resource.baseAddress + element.guestBytes}};
    if (StorageTexture::AnyPendingOverlaps(range)) element.reusable = false;
    }
    const auto& [address, bytes, generation] = element.query;
    if (!GuestMemory::UnchangedSince(address, bytes, generation)) element.reusable = false;
    }
    if (StorageTexture::PendingSerial() != serial) return false;
    table.pendingSerial = serial;
    return true;
    }
    bool CachedTableTextures(const ReusedTable& table, std::vector<std::shared_ptr<Texture>>& cached) {
    auto& cache = Textures();
    std::lock_guard lock(cache.mutex);
    cached.resize(table.elements.size());
    for (std::size_t index = 0; index < table.elements.size(); ++index) {
    const auto& element = table.elements[index];
    if (!element.reusable) continue;
    const auto it = findTexture(cache, element.key);
    if (it == cache.entries.end() || it->texture != element.texture.lock()) continue;
    cached[index] = it->texture;
    touchTexture(cache, it);
  • Require(step.reused == reused && step.resolved == resolved, "image table reuse: " + what + ": " + std::to_string(step.reused) + " reused and " + std::to_string(step.resolved) + " resolved tables, expected " + std::to_string(reused) + " and " + std::to_string(resolved));
  • - [ ] Fixes: <!-- issue it closes as Fixes #N, or none -->

Not verified

  • The lavapipe failure, the Ghost of Yotei timings and counters, and the per-predicate question.
  • Any build or test result.
  • The pairwise merge checks against #6867, #6905, #6913 and #6921 claimed by fogydes.

@github-actions github-actions Bot added the needs rebase Conflicts with main, rebase needed label Nov 3, 2026
@QRMOE

QRMOE commented Nov 4, 2026

Copy link
Copy Markdown
Contributor

Heads-up from RESIDENT EVIL requiem (PPSA31246) on a Ryzen + RX 9070 XT, 32 GiB RAM. I compared main plus a few pending fixes (#9950, #9999, #12575, #12458, #11630, #15399, #15416, #15499), with and without this PR merged on top. Both runs used the same save, Continue path and env, and lasted 25 minutes each:

build frame time on the "Facing the Past" loading screen outcome
without #6340 1.6–1.7 s reaches the next scene at ~19 min
with #6340 3.4–5.7 s still loading at 25 min

So on this title the per-entry reuse makes loading about 3× slower. I haven't profiled where the time goes yet.

Separately, on an earlier tree with this PR merged, agc_driver_image_table_reuse and agc_driver_image_table_reuse_draw_pipeline both failed with:

image table reuse: a driver store over an entry: 2 reused and 1 resolved tables, expected 1 and 1

That merge had a conflict in ShaderResources.cpp (ReusedTable), which I resolved by hand, so the failure may come from my resolution rather than the PR. Can you check it against current main?

@Dextroid17

Copy link
Copy Markdown
Contributor

@QRMOE it is not your conflict resolution: a clean merge of a58ce71d12 onto main at f2d874c1fd fails agc_driver_image_table_reuse with the same message (details in #6340 (comment)).

AI-assisted: yes

@blawesom

Copy link
Copy Markdown
Contributor

Validation run (queue item 36) — FAIL on Linux/AMD

Verdict: FAIL — agc_driver_image_table_reuse fails on the PR head on this machine. No push made. Scope: Linux only, AMD Radeon RX 9070 XT (RADV GFX1201). Negative result; no claim for other OS/GPU/driver combinations.

Environment

  • Machine: CachyOS, kernel 7.3.4-1-cachyos, Ryzen 7 9800X3D, AMD Radeon RX 9070 XT (RADV GFX1201) + AI PRO R9700, /dev/kfd present
  • Base: origin/main = a9f291040088cac6babfbe270c50f344a4f6f27d (worktree /home/benj/scratch/wt5/base-main, clean, reused existing build)
  • PR head: a58ce71d12bf06a898f50cb8d1e2bad7c52a7bcd (worktree /home/benj/scratch/wt5/pr-6340, fetched via pull/6340/head; PR state OPEN, review CHANGES_REQUESTED, head matches queue SHA)
  • Build (PR tree): cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DBUILD_TESTING=ON → exit 0 (7 s wall); cmake --build build --parallel 12 (CMAKE_BUILD_PARALLEL_LEVEL=12) → exit 0, 197 s wall. Base tree build reused read-only.

Focused pattern (identical matched set in both trees, 22 tests)

^(agc_compute_descriptor_layout_flags|agc_descriptor_cache|agc_descriptor_cache_failure|agc_descriptor_pool_recycling|agc_descriptor_pool_reset_failure|agc_draw_descriptors|agc_driver_bindless_images|agc_driver_buffer_descriptor_runtime|agc_driver_depth_storage_reuse|agc_driver_draw_cache_reuse|agc_driver_draw_cache_reuse_inline|agc_driver_draw_cache_reuse_off|agc_driver_draw_cache_reuse_verify|agc_driver_image_table|agc_driver_image_table_cache|agc_driver_image_table_cache_bounds|agc_driver_image_table_reuse|agc_driver_image_table_vouched_lookups|agc_driver_image_table_vouch_queued_draws|agc_driver_oversized_descriptor_sets|agc_shader_bindless|agc_shader_table_snapshot_reuse)$
(AGC tests matching image_table|table_entry|reuse|bindless|descriptor, intersected across both trees; the PR branch is stale relative to main, so main-only tests were excluded. diff of ctest -N -R name lists: identical.)

Test commands (both trees, identical env, timeout 3600 each)

ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation \
VK_ADD_LAYER_PATH=/home/benj/scratch/vvl-layer VK_LOADER_DEBUG=layer ANYPS5_GPU='AMD Radeon RX 9070 XT' \
ctest --test-dir build -R '<pattern>' -V

Logs: q36-tests-base.log, q36-tests-pr.log (queue logs under /home/benj/scratch/logs/).

Results

  • Base a9f29104: ctest exit 0 — 21 Passed, 1 Skipped (agc_driver_image_table_vouched_lookups: device reports 4/4 host-imported pages written after a GPU read), 0 Failed. agc_driver_image_table_reuse Passed ("image table reuse tests passed").
  • PR a58ce71d: ctest exit 8 — 20 Passed, 1 Skipped (same test, same reason), 1 Failed:
    • agc_driver_image_table_reuse (0.05 s): AGC graphics: image table reuse: a driver store over an entry: 2 reused and 1 resolved tables, expected 1 and 1
    • This is the PR's own updated execution test (core/libs/prx/libSceAgcDriver/tests/execution/ImageTableReuse.cpp, modified by the PR's test(agc) commits) failing against the PR's driver change at head a58ce71d12b ("fix(agc): balance image table replay branch"). The same test passes on base. All other 20 tests identical outcome in both trees.

Validation-layer checks (per AGENTS.md)

  • was not found but was requested by env var VK_INSTANCE_LAYERS: absent in both logs (0 occurrences).
  • Insert instance layer "VK_LAYER_KHRONOS_validation": present in both logs (20 occurrences each).
  • VUID-/SYNC-HAZARD-/bracketed-ID diff base vs PR: no VUID- or SYNC-HAZARD IDs in either log (0 occurrences each) → the change adds no new validation-error IDs. The only bracketed diagnostics are 10 identical Undefined-Value-ShaderOutputNotConsumed[-DynamicRendering] Validation Warnings in both logs (pre-existing on base, warnings not errors).

Push / limitations

  • No push (FAIL path): validation/pr-6340 ref not created on the fork.
  • No perf claim: no trace/scene available; this run makes no speed statement.
  • Single run per tree (no repetition); results are scoped to this Linux host + RADV on RX 9070 XT and do not establish behaviour on Windows, NVIDIA, Intel, or other AMD configurations. The failure is deterministic in this run (test exits immediately with the count mismatch above).

@theGodspeed1999

theGodspeed1999 commented Nov 23, 2026 •

Copy link
Copy Markdown

Hi @MarcZX10, a heads-up about how a small change of mine fits with this PR. It is not posted as a PR yet. The maintainer on #25529 asked me to say it here first.

What I found. On Marvel's Wolverine (PPSA03671, Windows 10, RTX 3060 Ti 8 GB, Ryzen 7 5700X) the slow part of the game spends about 7 of every 10 seconds binding image tables. In my first full run only 0.5% of the tables were reused. One reason is that some tables hold a pair: a 2D-array entry and a flat 2D entry that share one texture. Those tables were never remembered, so every draw rebuilt them.

What my change does. It teaches the remembered table about those pairs, so the table can be reused and the shared texture is bound the same way as a fresh lookup would. It touches the same function as yours (resolveImageTables), but it solves a different case. Yours lets clean entries be reused when another entry in the table cannot be. Mine lets the pair entries be reused. I think they can land in either order, and I will rebase onto whichever lands first. I keep ReusedTableCount at 4 and the change is small (one source file plus one test).

How well it works (honest version). I ran the fixed build 6 times for about 14 minutes each on the same scene, and the unfixed build once:

  • tables reused went from 0.5% to between 28% and 57% in 5 of 6 runs; in one run it stayed at 0.5%
  • frames per 10 s in the slow part went from about 1.5 to about 2.0 (about a third more), binding time per 10 s fell about 9%
  • that is a very small boost: the slow part is still around 0.2 frames per second, far from playable
  • the one frame I compared before and after (the Screen Reader prompt) is pixel-identical

Why it is small. Reuse only works when the textures of a table are still in the texture cache and the table is still in the list of 4. In my runs the sampled-texture cache was full (2 GiB budget) and textures kept getting thrown out and rebuilt, and every queue ordering point (about 29 per second) clears the list. So most draws still rebuild their tables. I did not try to change that, because it is shared memory handling and overlaps your work.

Is the problem solved by this? Only partly. The pair-table cause is fixed, but the game is still very slow in that scene (about 0.2 frames per second), because of the full texture cache and the table list being cleared often.

What is missing, not caused by this change. Two shaders in this game are still refused and I skip them in these runs, so the scene is not fully drawn: 0x11d049aa00 (sampler value not known, see #6191 and #7395) and 0x11d0125d00 (an image descriptor read as a buffer, see #5879 and #7689). The small text on the Screen Reader prompt is also broken (#26043); I do not know if that comes from the skipped shader.

Side effect I noticed. Runs of the same build differ a lot from each other (#26053), so one run is not enough to judge a speed change here.

Everything is in the issues linked above and in #25529. If you would rather I build on your branch, tell me and I will do that instead.

AI-assisted.

@MarcZX10

Copy link
Copy Markdown
Contributor Author

@adriadam10 @Dextroid17 @fdfawef324 @ntamas94 — checked against head a58ce71d12. No code was changed or pushed in this pass: the open items below need a decision from @MarcZX10 first, and nothing here was built or run on a GPU.

adriadam10, test expectation (ImageTableReuse.cpp). The failing message quoted in the review ("2 reused and 1 resolved tables, expected 1 and 1") matches the check Expect(before, 1, 1, "a driver store over an entry") at line 374. Line 384 at this head is inside the moved-record block, so the review line number is out of date. The Windows run reported by @Neithennn (head ef724aad6) went past that same check, since its failure came at the next one (the CPU-write-epoch check). So the same expectation gives 1 reused on Windows and 2 on Linux. Changing it to 2 would fix Linux and break the Windows observation. This is a platform difference, not a wrong number. Options: (a) platform-specific expectations, (b) find why the write-watch behaviour differs and fix the code, (c) drop this check. Decision needed: @MarcZX10. The other Expect calls were not re-run on Linux or Windows.

adriadam10, performance (perf label). No aps5-summary.jsonl lines or tools/trace_digest.py output were produced here, so no speed claim is backed by a measurement in this PR. The only before/after data in the thread is @Thunderhawkk's Wolverine matched pair (single runs, base dies with device OOM at ~4 min). Decision needed: @MarcZX10 — keep perf with that data plus same-machine trace summaries, or drop the label and describe the change as groundwork.

ntamas94, key mismatch. Confirmed by reading: ShaderResources.cpp:4987 creates the texture from sampledWords, and :4997 records remembered.key from words, while the lookup at :1789 uses element.key. Not reproduced, and I did not change it. Decision needed: @MarcZX10 — which key is the intended one.

Dextroid17, which replay predicate fails. That needs per-predicate counters from a run I did not do. No answer from my side; it stays with the author's measurement.

fdfawef324, mixed-DCC expectation. Current head expects Expect(before, 1, 2, ...) at line 319, which is the 1 reused / 2 resolved count from the review. Not run here.

Verification from this pass

  • python3 tools/check_conventions.py --base origin/main → "All conventions checks passed."
  • git diff --check origin/main...HEAD → clean.
  • Compile only, GCC 15 with the configured build's flags: ImageTableReuse.cpp and ShaderResources.cpp compile (exit 0). Not linked, not executed. No GPU run, no validation-layer run, no main baseline.

The PR body still has no Fixes: line from the template (noted in the author's own comment). Left as it is: it is the author's call whether it is none or an issue.

@MarcZX10

MarcZX10 commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor Author

@adriadam10 @ntamas94 Pushed 6ed02f9a8a to fork/codex/partial-image-table-reuse-5961-current (fast-forward from a58ce71d12, two commits: 65906075e3 key, 6ed02f9a8a test).

Decisions, one per open item:

  1. Test expectation (ImageTableReuse.cpp, "a driver store over an entry"): now DriverStoreReuses, which is 2 on non-Windows and 1 on Windows. The Linux value comes from the reported run at a58ce71d12 (2 reused). The Windows value comes from @Neithennn's run at ef724aad6 (1 reused at this check). This is a platform split of the two measured results, not a fix for the write-watch difference. The Windows number was measured on an earlier head.
  2. Perf label: I should remove perf and perf numbers missing, but my account cannot edit labels on the upstream repo, so both are still on the PR and need a maintainer to remove them. The thread has no aps5-summary.jsonl lines or trace_digest.py output for main and this branch from the same machine, so no speed claim is backed. The title still says perf(agc); the author can retitle it if the change is meant as groundwork.
  3. Key: remembered.key now uses sampledWords, the same convention main uses for the sampled table entry. @Dextroid17 measured that this alone does not change counts on Ghost of Yōtei, so it is a correctness fix, not a measured gain.

Verification:

  • python3 tools/check_conventions.py --base origin/main: "All conventions checks passed."
  • ImageTableReuse.cpp: compiled with the configured flags against this worktree's headers, exit 0.
  • ShaderResources.cpp: not compiled. The branch is about 13k commits behind main, and its headers do not match the configured build. The change swaps one identifier for a variable already in scope at that point.
  • No test was run on Linux or Windows at this head.

Not changed in this pass: the mixed-DCC expectation (@fdfawef324) and the per-predicate replay counters (@Dextroid17).

@oneandonlydean

Copy link
Copy Markdown
Collaborator

@MarcZX10 this is perf work and stays open, but it cannot pass on 6ed02f9. What I need:

  1. Rebase on current main. Main's ReusedTableElement now has live and substitute kinds, representatives and a uint64 imageSamplers; your per-entry reusable proof has to be reconciled with those (9 conflict hunks in ShaderResources.cpp, 5 in ImageTableReuse.cpp). perf(agc): keep a reused image table's cache entries while none was erased #25443 touches the same two files, so please check it for overlap.
  2. adriadam10's change request (a58ce71) is still open. He asked for the "driver store" expectation to pass without fixture-order edits, and 6ed02f9 makes it platform dependent (DriverStoreReuses, 2 on non-Windows, 1 on Windows), taken from two measurements on different heads. Please explain the platform difference or make the expectation deterministic, and show agc_driver_image_table_reuse and agc_driver_image_table_reuse_draw_pipeline passing on Linux and Windows on the rebased head.
  3. Dextroid17's PPSA26344 runs show replayed tables going from 773 of 789 on main to 0 with the PR, and reused from 393 to 122-148. The sampledWords key fix did not change that. Please explain it with per-predicate counts; one possibility is partial tables filling the 4-slot ReusedTableCount list and evicting fully replayable ones. PPSA31246 load time is also reported about 3x slower.
  4. Perf evidence is missing: paired runs on one machine and scene against the title's noise floor, in a perf window. Without it, retitle to groundwork so the perf labels can go.

The body also lacks the template Fixes: line.

@Dextroid17

Copy link
Copy Markdown
Contributor

@oneandonlydean @MarcZX10 on point 3 — my runs, so I measured it. Ghost of Yōtei (PPSA26344), load phase, RTX 3080 Ti, 4K: main at f2d874c vs this PR's head 6ed02f9 merged onto it (merge 4e088bd1dd), with the same per-predicate counters compiled into both builds (local diagnostic patch, one ~7-min run per side, APS5_NO_PIPELINE_BINARIES=1 on both).

Eviction isn't it. Slot pressure on the 4-entry list dropped 0 tables on main and 2 on the PR over ~3000 lookups each; the 1039 / 731 "by state change" entries in the raw lines are the state-change flush both builds share, not the list filling up.

What replayed 773→0 actually is: on main every remembered table was an empty one (binding.count == 0) — 1042 remembered, 1042 empty; 735 replayed, 735 empty. In resolveImageTables() on main, reusable starts true once a table state exists (state.epoch != 0) and the element loop never runs for an empty table, so empties pass the all-elements gate for free. The PR's any_of over zero elements is false, so empties are never remembered. Those replays did no texture work; the drop is a counter artefact, not lost reuse.

Same for reused 393→122–148: main's 364 "reused" in this run are those empty tables taking the sampler-mismatch branch (2141 empty lookups − 735 replayed − 1042 remembered = 364). The PR's 136 are real partial-element reuses.

Why main never remembers a non-empty table in this phase: of 108,846 per-element checks on the PR side, 51,657 pass, 35,005 fail on looked->source != nullptr, 20,194 on looked->generation == 0, 1,926 on looked->keys != DccKeys::Uncompressed, 64 on resource.dccAddress != 0. About half the elements qualify, but almost no table has all of them qualify (PR: 1 full table of 1105 remembered), so on this Nov 1 main the all-or-nothing rule produces zero non-empty replays and the PR is the only build here that reuses real content. Note that current main (dff904a in #15563) now marks exactly those failing entries live and reuses the rest of the table, so after the rebase the two per-element paths overlap and should be compared directly.

Counter lines, zero fields trimmed (M = main f2d874c + counters, P = PR merge 4e088bd1dd + counters; "partial at remember" = partial reuse hits):

M: lookups 2936: no previous 1837, sampler mismatch 364, replayed 735;
   remembered 1042 full, 0 partial; evicted 0 full, 0 partial, 1039 by state change;
   empty tables: 2141 lookups, 735 replayed, 1042 remembered;
   element verdicts 3611: 981 source, 49 generation, 2581 ok
P: lookups 3279: no previous 3143, partial at remember 136, replayed 0;
   remembered 1 full, 1104 partial; evicted 0 full, 2 partial, 731 by state change;
   empty tables: 2356 lookups, 0 replayed, 0 remembered;
   element verdicts 108846: 35005 source, 20194 generation, 1926 keys, 64 dcc, 51657 ok

Current main has already closed this gap from the other side: 92d0ebc (#15563, committed Nov 7, merged Nov 8) gates RememberTable on anyKept (any element kept), so empty tables are no longer remembered or replayed on main either. The 773→0 figure compares against main f2d874c (Nov 1), the base of all my runs; after the rebase from point 1, the replayed counters on both sides will exclude empties and should be read fresh. I don't see a reuse bug behind point 3. Happy to push the counter patch as a branch if useful.

Caveats: one title, one GPU, load phase only, one run per side cut by the 7-min launcher timeout (so lookup totals differ and only the categorical counts are compared; the earlier M1/P3 pair showed the same split: 767 vs 0 replayed, 1086 vs 1 full). Main stops checking a table's elements at the first one that fails (3,611 element verdicts vs 108,846), so only the PR-side breakdown is complete.

AI-assisted: yes

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agc libSceAgc* needs rebase Conflicts with main, rebase needed perf numbers missing perf pull request without a before and after summary line perf Performance change

Projects

None yet

Development

Successfully merging this pull request may close these issues.