test(agc): accept a bindless table entry captured across a page boundary #123

Merged
oneandonlydean merged 1 commit from upstream-pr/123 into main 2026-09-30 15:11:18 +00:00
oneandonlydean commented 2026-09-29 00:31:03 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-09-29T00:31:03Z.


What

agc_shader_memory fails about once in 75 runs on main with "bindless: a table entry was not captured". This is probably what was seen on #55, and it has just failed CI on #122 too.

verifyBindlessTable keeps its T# table (heap, four 32-byte entries) on the stack. ShaderMemory captures guest memory per page, so an entry that straddles a page boundary is held by two adjacent regions. Instrumented failures always had the entry at page offset 4080, with regions ending at …ff0 +16 and starting at …000 +16. The test's covered helper required a single region to hold the whole entry. The capture is correct, so the check is the part that's wrong.

covered now walks the range across adjacent regions and fails only on an actual gap.

Tested

  • Linux (CachyOS): agc_shader_memory_tests on main failed 4 times in 300 runs. With this change it failed 0 times in 1500.
  • ctest: 57/57 pass.

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
  • New third-party code is a submodule built from source (none added)
  • Generic behaviour, not specific to one title
  • Depends on: none
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4670949972 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/123). Originally posted by [oneandonlydean](https://github.com/oneandonlydean) on 2026-09-29T00:31:03Z. --- ### What `agc_shader_memory` fails about once in 75 runs on `main` with "bindless: a table entry was not captured". This is probably what was seen on #55, and it has just failed CI on #122 too. `verifyBindlessTable` keeps its T# table (`heap`, four 32-byte entries) on the stack. `ShaderMemory` captures guest memory per page, so an entry that straddles a page boundary is held by two adjacent regions. Instrumented failures always had the entry at page offset 4080, with regions ending at `…ff0 +16` and starting at `…000 +16`. The test's `covered` helper required a single region to hold the whole entry. The capture is correct, so the check is the part that's wrong. `covered` now walks the range across adjacent regions and fails only on an actual gap. ### Tested - Linux (CachyOS): `agc_shader_memory_tests` on `main` failed 4 times in 300 runs. With this change it failed 0 times in 1500. - `ctest`: 57/57 pass. ### 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 - [x] Unimplemented paths throw (`NotImplemented_nid_no_patch`); silent stubs are listed in TechnicalDebt - [x] No notes, investigation `.md` files or images added to the repository - [x] New third-party code is a submodule built from source (none added) - [x] Generic behaviour, not specific to one title - [x] Depends on: none - [x] AI-assisted: yes
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!123
No description provided.