fix(recompiler): hold 64 images in a sampled image heap #2347

Merged
Pipodi merged 2 commits from upstream-pr/2347 into main 2026-10-10 08:23:24 +00:00
Pipodi commented 2026-10-09 16:06:28 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by Pipodi on 2026-10-09T16:06:28Z.


What

A typed sampled-image heap holds SampledHeapCapacity = 16 images. A compute program of PPSA26344 (Ghost of Yōtei) binds 29 sampled 3D images of one class, and the shader fails with:

ShaderRecompiler::Recompile: shader image heap capacity exceeded

SampledHeapCapacity goes to 64. A shader reported in review binds 40 sampled images of one class, so 32 would still be short. Heap arrays are declared with their compact length (binding.count), and the capacity enters neither ShaderData nor the runtime ABI structs, so every shader that fitted before gets the same layout and SPIR-V. Version is unchanged.

ResourceMaterializer::BindlessSlots() returned the same constant. It sizes the bindless image tables, and each table takes slots - 1 extra image entries against ShaderInfo::MaxImages, so tying it to the heap would double their cost. It now returns BindlessTableSlots = 16, the previous value.

Related open PRs: #2141 raises the sampler heap to 32, and #2282 raises the storage heap to 16 (splitting out StorageMipSlots). Neither touches the sampled heap, and none of the three conflict beyond adjacent lines in RuntimeAbi.hpp.

Tested

Windows 11, MinGW-w64 GCC 15.2.0, RTX 4090 (driver 617.42).

  • agc_shader_device_profile:
    • A sampled heap now holds 40 images of one class and a full class of SampledHeapCapacity, and bindless tables keep 16 slots.
    • With SampledHeapCapacity = 32 the new check fails with "shader image heap capacity exceeded".
  • Full ctest: 507/507 passed (one test skipped without Vulkan).
  • PPSA26344 on an integration branch: the program above dispatches, and the title reaches its first presented frames. That also needed other changes, listed in discussion #675.

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 in TechnicalDebt
  • 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
  • AI-assisted: yes

🤖 Generated with Claude Code

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4802898799 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/2347). Originally posted by [Pipodi](https://github.com/Pipodi) on 2026-10-09T16:06:28Z. --- ### What A typed sampled-image heap holds `SampledHeapCapacity` = 16 images. A compute program of PPSA26344 (Ghost of Yōtei) binds 29 sampled 3D images of one class, and the shader fails with: ``` ShaderRecompiler::Recompile: shader image heap capacity exceeded ``` `SampledHeapCapacity` goes to 64. A shader reported in review binds 40 sampled images of one class, so 32 would still be short. Heap arrays are declared with their compact length (`binding.count`), and the capacity enters neither `ShaderData` nor the runtime ABI structs, so every shader that fitted before gets the same layout and SPIR-V. `Version` is unchanged. `ResourceMaterializer::BindlessSlots()` returned the same constant. It sizes the bindless image tables, and each table takes `slots - 1` extra image entries against `ShaderInfo::MaxImages`, so tying it to the heap would double their cost. It now returns `BindlessTableSlots` = 16, the previous value. Related open PRs: #2141 raises the sampler heap to 32, and #2282 raises the storage heap to 16 (splitting out `StorageMipSlots`). Neither touches the sampled heap, and none of the three conflict beyond adjacent lines in `RuntimeAbi.hpp`. ### Tested Windows 11, MinGW-w64 GCC 15.2.0, RTX 4090 (driver 617.42). - `agc_shader_device_profile`: - A sampled heap now holds 40 images of one class and a full class of `SampledHeapCapacity`, and bindless tables keep 16 slots. - With `SampledHeapCapacity` = 32 the new check fails with "shader image heap capacity exceeded". - Full ctest: 507/507 passed (one test skipped without Vulkan). - PPSA26344 on an integration branch: the program above dispatches, and the title reaches its first presented frames. That also needed other changes, listed in discussion #675. ### Checklist - [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 in [TechnicalDebt](https://github.com/boykopovar/AnyPS5/blob/main/docs/dev/TechnicalDebt.md#silent-stubs) - [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] AI-assisted: yes 🤖 Generated with [Claude Code](https://claude.com/claude-code)
MarcZX10 commented 2026-10-09 17:08:39 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-09T17:08:39Z.


I reviewed the complete three-file diff. The sampled-heap cap and bindless-table slot count have distinct roles here, and the Windows full-suite report covers the reported failure. The upstream PR checks currently show Conventions only; the Linux and Windows Build jobs did not run. Could an authorized collaborator dispatch the full Build matrix on this PR head before merge? The overlap with #2282 is limited to RuntimeAbi.hpp; #2282 changes the separate storage-image capacity, so the objectives are distinct and both updates need to be preserved. AI-assisted review.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6085603014 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/2347#issuecomment-6085603014). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-09T17:08:39Z. --- I reviewed the complete three-file diff. The sampled-heap cap and bindless-table slot count have distinct roles here, and the Windows full-suite report covers the reported failure. The upstream PR checks currently show Conventions only; the Linux and Windows Build jobs did not run. Could an authorized collaborator dispatch the full Build matrix on this PR head before merge? The overlap with #2282 is limited to `RuntimeAbi.hpp`; #2282 changes the separate storage-image capacity, so the objectives are distinct and both updates need to be preserved. AI-assisted review.
Kikoarl commented 2026-10-09 17:32:49 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by Kikoarl on 2026-10-09T17:32:49Z.


Linux run: Linux 7.2 (x86_64), GCC 16.2.1, Release, -DBUILD_TESTING=ON, #2347 (edf4855f) tested on current main (0fdda7be).

  • tests/agc_shader_device_profile_tests: passes cleanly (shader runtime ABI and device profile tests passed).
  • tools/check_conventions.py: passes cleanly.
  • No regressions observed across shader recompiler runtime ABI and device profiles.
<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6085977540 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/2347#issuecomment-6085977540). Originally posted by [Kikoarl](https://github.com/Kikoarl) on 2026-10-09T17:32:49Z. --- Linux run: Linux 7.2 (x86_64), GCC 16.2.1, Release, `-DBUILD_TESTING=ON`, #2347 (`edf4855f`) tested on current `main` (`0fdda7be`). - `tests/agc_shader_device_profile_tests`: passes cleanly (`shader runtime ABI and device profile tests passed`). - `tools/check_conventions.py`: passes cleanly. - No regressions observed across shader recompiler runtime ABI and device profiles.
Dextroid17 commented 2026-10-09 19:08:36 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by Dextroid17 on 2026-10-09T19:08:36Z.

Review: COMMENTED


Verified on Linux (gcc 16.2.1), base f8c2f072, this PR's head edf4855f. The change does what it says, the test bites, and the layout claim holds — the compiler enforces it.

Arm A — the PR:

cmake --build b --target agc_shader_device_profile_tests      # builds clean
ctest -R agc_shader_device_profile                            # Test #89 Passed (0.00 s)

Arm B — only the implementation reverted (RuntimeAbi.hpp and ResourceMaterializer.cpp at upstream/main), test kept, rebuilt — the binary exits 1 with:

shader image heap capacity exceeded

(ctest wraps that as a Failed test, exit 8.) So the new Require(… FindBinding(allocate(image, 32u) …).resources.size() == 32u …) genuinely bites: with SampledHeapCapacity back at 16 the 32-image heap is rejected and the test reports it.

The "no layout change" claim is verified by the compiler, not just by reading. ShaderData sizes its image array by ImageCapacity (256), not SampledHeapCapacity (RuntimeAbi.hpp:58), and the same header carries static_assert(sizeof(ShaderData) == 13760u) plus the field-offset asserts (lines 78–81). If raising the capacity to 32 moved the struct or a table, the build would fail — it does not. Version stays 10.

The wall this lifts is real, and I hit it independently. A PPSA26344 run (exp/yotei-757 + the decode-deferral) logged, for shader 0x8000332100:

ShaderRecompiler::Recompile: shader image heap capacity exceeded

That message is BindingAllocator.cpp:146 — imageGroups[i].size() > RuntimeAbi::HeapCapacity(…) — so the title is named and the log line matches a run I made before reading this PR.

BindlessSlots() → BindlessTableSlots (16) is the right half of the fix. Leaving it tied to the heap would have doubled the bindless tables' slots - 1 extra image entries, exactly as the body says.

Regression sweep over the affected area (ctest -R 'agc|shader|device_profile|bindless|sampl', 260 tests): 259 passed, 1 failed — agc_driver_dcc_keys_first_write, an unchanged pending image was uploaded again. That failure is pre-existing and unrelated: it fails identically on a pristine f8c2f072 build with this PR absent.

Two test-hygiene notes (not blocking):

  • Line 143 hard-codes 32u twice, while the adjacent Reject on line 142 uses RuntimeAbi::SampledHeapCapacity. Expressing the expectation through the constant would let the test follow a future capacity change instead of silently pinning 32.
  • Line 144 compares against the literal 16u rather than RuntimeAbi::BindlessTableSlots, so it asserts the value but not the decoupling that is the point of the change. Comparing against the constant (and asserting the two differ) would fail if they were ever re-tied.

Not verified here: the "29 sampled 3D images of one class" count (that is from your run — I confirmed the title reaches the wall, not the count), and Windows.

One note for the maintainer: #2141 edits the same RuntimeAbi.hpp constant block (sampler heap → 32), so the two conflict on rebase; the body already flags it as related.

Written with AI assistance.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5474288404 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/2347#pullrequestreview-5474288404). Originally posted by [Dextroid17](https://github.com/Dextroid17) on 2026-10-09T19:08:36Z. **Review:** COMMENTED --- Verified on Linux (gcc 16.2.1), base `f8c2f072`, this PR's head `edf4855f`. The change does what it says, the test bites, and the layout claim holds — the compiler enforces it. **Arm A — the PR:** ``` cmake --build b --target agc_shader_device_profile_tests # builds clean ctest -R agc_shader_device_profile # Test #89 Passed (0.00 s) ``` **Arm B — only the implementation reverted** (`RuntimeAbi.hpp` and `ResourceMaterializer.cpp` at `upstream/main`), test kept, rebuilt — the binary exits **1** with: ``` shader image heap capacity exceeded ``` (ctest wraps that as a Failed test, exit 8.) So the new `Require(… FindBinding(allocate(image, 32u) …).resources.size() == 32u …)` genuinely bites: with `SampledHeapCapacity` back at 16 the 32-image heap is rejected and the test reports it. **The "no layout change" claim is verified by the compiler, not just by reading.** `ShaderData` sizes its image array by `ImageCapacity` (256), not `SampledHeapCapacity` (`RuntimeAbi.hpp:58`), and the same header carries `static_assert(sizeof(ShaderData) == 13760u)` plus the field-offset asserts (lines 78–81). If raising the capacity to 32 moved the struct or a table, the build would fail — it does not. `Version` stays 10. **The wall this lifts is real, and I hit it independently.** A PPSA26344 run (`exp/yotei-757` + the decode-deferral) logged, for shader `0x8000332100`: ``` ShaderRecompiler::Recompile: shader image heap capacity exceeded ``` That message is `BindingAllocator.cpp:146` — `imageGroups[i].size() > RuntimeAbi::HeapCapacity(…)` — so the title is named *and* the log line matches a run I made before reading this PR. **`BindlessSlots()` → `BindlessTableSlots` (16) is the right half of the fix.** Leaving it tied to the heap would have doubled the bindless tables' `slots - 1` extra image entries, exactly as the body says. **Regression sweep** over the affected area (`ctest -R 'agc|shader|device_profile|bindless|sampl'`, 260 tests): 259 passed, 1 failed — `agc_driver_dcc_keys_first_write`, `an unchanged pending image was uploaded again`. That failure is **pre-existing and unrelated**: it fails identically on a pristine `f8c2f072` build with this PR absent. **Two test-hygiene notes** (not blocking): - Line 143 hard-codes `32u` twice, while the adjacent `Reject` on line 142 uses `RuntimeAbi::SampledHeapCapacity`. Expressing the expectation through the constant would let the test follow a future capacity change instead of silently pinning 32. - Line 144 compares against the literal `16u` rather than `RuntimeAbi::BindlessTableSlots`, so it asserts the value but not the decoupling that is the point of the change. Comparing against the constant (and asserting the two differ) would fail if they were ever re-tied. Not verified here: the "29 sampled 3D images of one class" count (that is from your run — I confirmed the title reaches the wall, not the count), and Windows. One note for the maintainer: #2141 edits the same `RuntimeAbi.hpp` constant block (sampler heap → 32), so the two conflict on rebase; the body already flags it as related. Written with AI assistance.
Dextroid17 commented 2026-10-09 20:24:06 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by Dextroid17 on 2026-10-09T20:24:06Z.


Verified on Linux (gcc 16.2.1), base f8c2f072, this PR's head edf4855f. The change does what it says, the test bites, and the layout claim holds — the compiler enforces it.

Arm A — the PR:

cmake --build b --target agc_shader_device_profile_tests      # builds clean
ctest -R agc_shader_device_profile                            # Test #89 Passed (0.00 s)

Arm B — only the implementation reverted (RuntimeAbi.hpp and ResourceMaterializer.cpp at upstream/main), test kept, rebuilt — the binary exits 1 with:

shader image heap capacity exceeded

(ctest wraps that as a Failed test, exit 8.) So the new Require(… FindBinding(allocate(image, 32u) …).resources.size() == 32u …) genuinely bites: with SampledHeapCapacity back at 16 the 32-image heap is rejected and the test reports it.

The "no layout change" claim is verified by the compiler, not just by reading. ShaderData sizes its image array by ImageCapacity (256), not SampledHeapCapacity (RuntimeAbi.hpp:58), and the same header carries static_assert(sizeof(ShaderData) == 13760u) plus the field-offset asserts (lines 78–81). If raising the capacity to 32 moved the struct or a table, the build would fail — it does not. Version stays 10.

The wall this lifts is real, and I hit it independently. A PPSA26344 run (exp/yotei-757 + the decode-deferral) logged, for shader 0x8000332100:

ShaderRecompiler::Recompile: shader image heap capacity exceeded

That message is BindingAllocator.cpp:146 — imageGroups[i].size() > RuntimeAbi::HeapCapacity(…) — so the title is named and the log line matches a run I made before reading this PR.

BindlessSlots() → BindlessTableSlots (16) is the right half of the fix. Leaving it tied to the heap would have doubled the bindless tables' slots - 1 extra image entries, exactly as the body says.

Regression sweep over the affected area (ctest -R 'agc|shader|device_profile|bindless|sampl', 260 tests): 259 passed, 1 failed — agc_driver_dcc_keys_first_write, an unchanged pending image was uploaded again. That failure is pre-existing and unrelated to this PR: it reproduces identically on a pristine f8c2f072 build. For completeness it is also device-specific rather than universal — it fails on this machine's NVIDIA driver and passes on lavapipe, which is the device CI installs. So it should not be read as a regression, nor as something a reviewer needs to chase.

Two test-hygiene notes (not blocking):

  • Line 143 hard-codes 32u twice, while the adjacent Reject on line 142 uses RuntimeAbi::SampledHeapCapacity. Expressing the expectation through the constant would let the test follow a future capacity change instead of silently pinning 32.
  • Line 144 compares against the literal 16u rather than RuntimeAbi::BindlessTableSlots, so it asserts the value but not the decoupling that is the point of the change. Comparing against the constant (and asserting the two differ) would fail if they were ever re-tied.

Not verified here: the "29 sampled 3D images of one class" count (that is from your run — I confirmed the title reaches the wall, not the count), and Windows.

One note for the maintainer: #2141 edits the same RuntimeAbi.hpp constant block (sampler heap → 32), so the two conflict on rebase; the body already flags it as related.

Written with AI assistance.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6088649541 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/2347#issuecomment-6088649541). Originally posted by [Dextroid17](https://github.com/Dextroid17) on 2026-10-09T20:24:06Z. --- Verified on Linux (gcc 16.2.1), base `f8c2f072`, this PR's head `edf4855f`. The change does what it says, the test bites, and the layout claim holds — the compiler enforces it. **Arm A — the PR:** ``` cmake --build b --target agc_shader_device_profile_tests # builds clean ctest -R agc_shader_device_profile # Test #89 Passed (0.00 s) ``` **Arm B — only the implementation reverted** (`RuntimeAbi.hpp` and `ResourceMaterializer.cpp` at `upstream/main`), test kept, rebuilt — the binary exits **1** with: ``` shader image heap capacity exceeded ``` (ctest wraps that as a Failed test, exit 8.) So the new `Require(… FindBinding(allocate(image, 32u) …).resources.size() == 32u …)` genuinely bites: with `SampledHeapCapacity` back at 16 the 32-image heap is rejected and the test reports it. **The "no layout change" claim is verified by the compiler, not just by reading.** `ShaderData` sizes its image array by `ImageCapacity` (256), not `SampledHeapCapacity` (`RuntimeAbi.hpp:58`), and the same header carries `static_assert(sizeof(ShaderData) == 13760u)` plus the field-offset asserts (lines 78–81). If raising the capacity to 32 moved the struct or a table, the build would fail — it does not. `Version` stays 10. **The wall this lifts is real, and I hit it independently.** A PPSA26344 run (`exp/yotei-757` + the decode-deferral) logged, for shader `0x8000332100`: ``` ShaderRecompiler::Recompile: shader image heap capacity exceeded ``` That message is `BindingAllocator.cpp:146` — `imageGroups[i].size() > RuntimeAbi::HeapCapacity(…)` — so the title is named *and* the log line matches a run I made before reading this PR. **`BindlessSlots()` → `BindlessTableSlots` (16) is the right half of the fix.** Leaving it tied to the heap would have doubled the bindless tables' `slots - 1` extra image entries, exactly as the body says. **Regression sweep** over the affected area (`ctest -R 'agc|shader|device_profile|bindless|sampl'`, 260 tests): 259 passed, 1 failed — `agc_driver_dcc_keys_first_write`, `an unchanged pending image was uploaded again`. That failure is pre-existing and unrelated to this PR: it reproduces identically on a pristine `f8c2f072` build. For completeness it is also device-specific rather than universal — it fails on this machine's NVIDIA driver and passes on lavapipe, which is the device CI installs. So it should not be read as a regression, nor as something a reviewer needs to chase. **Two test-hygiene notes** (not blocking): - Line 143 hard-codes `32u` twice, while the adjacent `Reject` on line 142 uses `RuntimeAbi::SampledHeapCapacity`. Expressing the expectation through the constant would let the test follow a future capacity change instead of silently pinning 32. - Line 144 compares against the literal `16u` rather than `RuntimeAbi::BindlessTableSlots`, so it asserts the value but not the decoupling that is the point of the change. Comparing against the constant (and asserting the two differ) would fail if they were ever re-tied. Not verified here: the "29 sampled 3D images of one class" count (that is from your run — I confirmed the title reaches the wall, not the count), and Windows. One note for the maintainer: #2141 edits the same `RuntimeAbi.hpp` constant block (sampler heap → 32), so the two conflict on rebase; the body already flags it as related. Written with AI assistance.
oneandonlydean commented 2026-10-09 22:34:38 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-09T22:34:38Z.


One shader I tested binds 40 sampled images of one class, so 32 is still short for it (shader image heap capacity exceeded). Could the sampled cap go to 64? It's a cap, not part of the ShaderData layout, so no version bump. A case with 40 images in the test would cover it.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6090387295 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/2347#issuecomment-6090387295). Originally posted by [oneandonlydean](https://github.com/oneandonlydean) on 2026-10-09T22:34:38Z. --- One shader I tested binds 40 sampled images of one class, so 32 is still short for it (`shader image heap capacity exceeded`). Could the sampled cap go to 64? It's a cap, not part of the ShaderData layout, so no version bump. A case with 40 images in the test would cover it.
Pipodi commented 2026-10-10 06:44:40 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by Pipodi on 2026-10-10T06:44:40Z.


@oneandonlydean done in c9aa70fe: SampledHeapCapacity is 64. The test now allocates 40 images of one class, and a full class through the constant (which also covers @Dextroid17's note about the hard-coded 32). With the cap back at 32, it fails with "shader image heap capacity exceeded". No layout or Version change, as you said. Full ctest 507/507 on Windows 11, MinGW-w64 GCC 15.2.0, RTX 4090. The title and description are updated.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6094773442 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/2347#issuecomment-6094773442). Originally posted by [Pipodi](https://github.com/Pipodi) on 2026-10-10T06:44:40Z. --- @oneandonlydean done in `c9aa70fe`: `SampledHeapCapacity` is 64. The test now allocates 40 images of one class, and a full class through the constant (which also covers @Dextroid17's note about the hard-coded 32). With the cap back at 32, it fails with "shader image heap capacity exceeded". No layout or `Version` change, as you said. Full ctest 507/507 on Windows 11, MinGW-w64 GCC 15.2.0, RTX 4090. The title and description are updated.
oneandonlydean commented 2026-10-10 08:06:28 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-10T08:06:28Z.


Could you rebase? RuntimeAbi.hpp conflicts with main now (the storage and sampler heap lines next to SampledHeapCapacity changed). The 64 cap and the 40-image case cover what I asked.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6095515917 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/2347#issuecomment-6095515917). Originally posted by [oneandonlydean](https://github.com/oneandonlydean) on 2026-10-10T08:06:28Z. --- Could you rebase? `RuntimeAbi.hpp` conflicts with main now (the storage and sampler heap lines next to `SampledHeapCapacity` changed). The 64 cap and the 40-image case cover what I asked.
EdouardSence commented 2026-10-10 08:12:35 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by EdouardSence on 2026-10-10T08:12:35Z.


Astro Bot (PPSA21567), the title in #1789, gets past the heap wall with this.

Linux (CachyOS, GCC, Release), RX 9070 XT, RADV / Mesa 26.2.4, headless gamescope, scripted input.

  • main a29bae31: stops about 72 s in on ShaderRecompiler::Recompile: shader image heap capacity exceeded. With APS5_HOST_IMPORT_MIB=64, two more runs stop the same way at about 60 s.
  • main a29bae31 + this PR (c9aa70fe): no heap error. The run goes on to about 76 s and stops on sceAgcDcbResetQueue: unsupported op bit 0x40, which is unrelated (details on #1581).

For your rebase: I resolved the RuntimeAbi.hpp conflict locally by keeping main's StorageMipSlots = 4, StorageHeapCapacity = 16 and SamplerHeapCapacity = 32, and this PR's SampledHeapCapacity = 64 and BindlessTableSlots = 16. Full ctest then passes, apart from import_audit, which fails in my git-worktree build tree.

Tested and written by Claude (AI assistant) on a contributor's machine.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6095563138 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/2347#issuecomment-6095563138). Originally posted by [EdouardSence](https://github.com/EdouardSence) on 2026-10-10T08:12:35Z. --- Astro Bot (PPSA21567), the title in #1789, gets past the heap wall with this. Linux (CachyOS, GCC, Release), RX 9070 XT, RADV / Mesa 26.2.4, headless gamescope, scripted input. - **`main` a29bae31:** stops about 72 s in on `ShaderRecompiler::Recompile: shader image heap capacity exceeded`. With `APS5_HOST_IMPORT_MIB=64`, two more runs stop the same way at about 60 s. - **`main` a29bae31 + this PR (c9aa70fe):** no heap error. The run goes on to about 76 s and stops on `sceAgcDcbResetQueue: unsupported op bit 0x40`, which is unrelated (details on #1581). For your rebase: I resolved the `RuntimeAbi.hpp` conflict locally by keeping `main`'s `StorageMipSlots = 4`, `StorageHeapCapacity = 16` and `SamplerHeapCapacity = 32`, and this PR's `SampledHeapCapacity = 64` and `BindlessTableSlots = 16`. Full ctest then passes, apart from `import_audit`, which fails in my git-worktree build tree. *Tested and written by Claude (AI assistant) on a contributor's machine.*
adriadam10 commented 2026-10-10 08:18:40 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-10T08:18:40Z.


Rebased onto current main as @oneandonlydean asked; the only conflict was RuntimeAbi.hpp (kept main's StorageMipSlots, StorageHeapCapacity = 16 and SamplerHeapCapacity = 32 next to SampledHeapCapacity = 64 and BindlessTableSlots = 16). No logic change.

Checked on Linux: libSceAgc/libSceAgcDriver build + ctest 333/333, and agc_shader_device_profile fails with the RuntimeAbi.hpp/ResourceMaterializer.cpp change reverted. Merging once CI is green.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6095608616 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/2347#issuecomment-6095608616). Originally posted by [adriadam10](https://github.com/adriadam10) on 2026-10-10T08:18:40Z. --- Rebased onto current `main` as @oneandonlydean asked; the only conflict was `RuntimeAbi.hpp` (kept main's `StorageMipSlots`, `StorageHeapCapacity = 16` and `SamplerHeapCapacity = 32` next to `SampledHeapCapacity = 64` and `BindlessTableSlots = 16`). No logic change. Checked on Linux: libSceAgc/libSceAgcDriver build + ctest 333/333, and `agc_shader_device_profile` fails with the `RuntimeAbi.hpp`/`ResourceMaterializer.cpp` change reverted. Merging once CI is green.
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5!2347
No description provided.