fix(agc): restore versioned draw queue defaults on reset #22535
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/22535"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by JJenkx on 2026-11-17T19:36:52Z.
What
Replace the draw reset's unconditional
CLEAR_STATEwith the SDK reset envelope and requested versioned context/shader/user-config loads, instance/index/indirect resets, flushes and counter-control event. PPSA14408 requests version 10, flags0x3ff, instance 0. On the original baseline, restoring its requested defaults corrected its inverted Terms/Game Selection screens while preserving genuine driver fresh-queue/CLEAR_STATE defaults.The linear refresh builds on included dependencies #20512 and #21653. B-Howell’s #22465 counter-event consumer and enabled-counter-pair fix are now merged into main, so the remaining production delta is confined to libSceAgc. The additional PM4 read-range regression verifies that predication never reads disabled counter blocks. The original implementation and protocol provenance below are retained.
Protocol provenance: 31 independent firmware-13.60 state-0 single-bit goldens from #1581, plus static analysis of the user's bundled PPSA06652 compatibility module (NID
TRO721eVt4g, SHA-256124a637bb17080d4e754d07d73f3320531d3b5c6e384ae2a81c364c44d17abbd). The 61-word composite fixture is reference-derived, not a supplied full console transcript. Proprietary modules/disassembly are excluded. Unknown flag0x400and non-active instances >=2 retain the standard refusal; remaining gaps are in the debt fragment.Each draw and ACB reset retains one initial host-state snapshot across buffer growth. Concurrent or growth-reentrant initialization timing remains unmeasured on console.
Tested
Current Linux qualification at
299eb324cab8: 36/36 focused CPU tests passed. Both updated ACB fixtures failed on the new refusal assertion when bound to the prior9410c7f98d37library. The same four Vulkan cases passed on main7d3d015fee3eand this head, with seven Khronos validation layer insertions per arm and no VUIDs or synchronization errors on RX 6650 XT / RADV Mesa 26.3.1. The candidate merged cleanly withfc294cbbb539. The console behavior of flag0x400remains unverified. Test evidence and reviewer follow-upEarlier Linux qualification at
9410c7f98d37on main7d3d015fee3ewith #21653 and #22667. All 36 focused CPU tests passed, including the draw packet oracle, staged growth, upward-only capacity, snapshot and concurrent allocator tests. Stock and change each passed 4/4 matched Vulkan tests with KHRONOS validation active on Radeon RX 6650 XT/RADV Mesa 26.3.1 and zero VUID or synchronization errors.Fresh Metal Gear launcher profiles on stock (ticket 13806) and change (ticket 13814) both showed upright Terms and Game Selection at 1920×1080 and closed normally. This pass covers the launcher, and the historic title findings remain tied to their original test bases.
Earlier ACB snapshot qualification (2026-11-22), head
b1b0d4c75c7581efbb5ca174f9fdc1fcd496e36d: preserve Dean's production fix8340713d78ecd36097981b083da97a3add498c04. The new commit adds only six ACB growth-callback regression modes and their registrations. It does not replace or duplicate the maintainer's fix.The callback initializes version 13 while reset packet storage grows. Four empty-context cases exercise capacity 0/1 before the prefix and 4/5 before the event/restore. Two initialized version-8 cases exercise growth before the prefix or event while version 13 becomes active. Tests compare complete packets, return values and tail guards against a no-callback reference and verify the next active context is published.
15733cccd41b016e9eb617cbb1b0d4c75c75Both initialized-context cases pass on old and updated providers. All 33 old/updated executable hashes and arguments are identical. The same four physical-GPU fixture binaries run across all three providers, with seven validation-layer insertions per arm, zero skips/VUIDs, unchanged SDK/fixture hashes and exact CTest-property round trips apart from recorded private-directory/path remapping. The updated 33 cases comprise 29 CPU/protocol checks and four physical GPU checks. Baseline main's relevant AGC/driver/recompiler/libc/kernel trees are unchanged through checked main
3073cdeeb2a335d9d45b322d243e6e003104e970.Incremental SDK libraries, relinker and focused target builds pass at
b1b0d4c75c75; conventions and the merge preview with checked main pass. Linux 7.3.5, GCC 16.2.1, AMD Radeon RX 6650 XT / RADV Mesa 26.3.1, validation layer 1.4.363. All GPU harnesses used the shared FIFO, required Vulkan, shader cache disabled, requested validation layer and loader logging, andctest -V. This is host callback-consistency evidence; console initialization timing remains unmeasured. Earlier native-title, Windows/NVIDIA and console results retain their original pins below; hosted checks for this new head are separate.Build/test logs, JUnit, maintainer/regression patches, provider/fixture manifests and CTest-property proof, SHA-256
c25257a7b36d5e6b2f933a0e4f25632ea369952acd7b62cbdce2af187e6208b3. Downloaded again and all 48 payload hashes verified. No SDK binaries, game assets, saves or shader inputs/caches are included. Older evidence links remain unchanged.Earlier draw-snapshot qualification (2026-11-22), head
016e9eb617cb8ad1218a0ce1c6e2456d7b34d80c: address MarcZX10's snapshot review. Capture the selected host state once before any buffer growth and reuse its version and context/shader/user-config views. No lock is held across callbacks. Published backing remains retained. Concurrent or growth-reentrant initialization timing on console is still unmeasured and is stated in technical debt.The eight new deterministic callback-initialization tests cover seven packet-growth boundaries and an already initialized active context. They compare complete output packets and tail guards, and verify that the callback still publishes the next active context. The same fixtures built from the final source give:
15733cccd41bd64411f38f23016e9eb617cbThe later-growth boundaries 19/24 and initialized active-context case pass on both old and new providers. All 27 old and updated executable hashes and arguments match. The four fixture binaries that run on the GPU also match across all three providers: seven validation-layer insertions per arm, zero skips/VUIDs, unchanged SDK/fixture hashes and preserved CTest properties. Main uses only unchanged public-ABI reset negative controls; the new snapshot modes are compared against the previous PR SDK.
Full updated SDK/relinker build and conventions pass. Linux 7.3.5, GCC 16.2.1, AMD Radeon RX 6650 XT / RADV Mesa 26.3.1, Khronos validation 1.4.363; required Vulkan, shader cache disabled, layer and loader logging enabled. The main/old SDK banks were reused from the preceding qualification and retested with the new fixtures. Focused AGC/driver/shader/libc/kernel subtrees are unchanged on later main
608ea9172811, and this head merges cleanly with it. This qualification covers host snapshot consistency. Console timing during concurrent initialization remains unmeasured.Build/test logs, JUnit, source patch, provider/fixture manifests and property proof, SHA-256
91bdf203d1cf4ee126dfc86e5b0d6d41520444c4f6847d2af4a4e6a43a5e19a4. The uploaded archive was downloaded again and all 53 payload hashes verified. No SDK binaries, game assets, saves or shader inputs/caches are included. Archived hosted CI refers to the earlier016e9eb617cbhead, not the current qualification.Earlier qualification (original pins retained):
Main refresh (2026-11-19): head
adfe7c4b1c81150b10549b9bb0f873fa75dbf67bis one linear commit on main23786c4e4f7715f07407938ef3611b7f9c1e2de3. #22465 is merged into this base; its driver production changes are therefore absent from the remaining diff. The nine remaining AGC production-file deltas preserve the reviewed implementation; the PM4 conflict retains the additional enabled-counter read guard. Dependencies #20512 and #21653 remain included.Same frozen GPU/PM4 fixture executables against each arm’s independently built SDK: current main passes all five shared checks and fails exactly the two reset negative controls (
uninitializedACB and empty DCB) through unchanged public ABIs. The refreshed branch passes 19/19: four real GPU execution cases and fifteen CPU/PM4/reset cases, including Init(0), version 8/10/13 restores, range and capacity checks. The four GPU cases create seven validation-backed device instances per arm; every case shows AMD selection and layer insertion, with 0 skips/VUIDs. Required Vulkan, shader cache off, RX6650XT/RADV Mesa26.2.7, Linux, KHR1.4.363. The changed four-argument flat-state API is only exercised on the candidate, never called through the old main declaration. Both full SDK/relinker builds pass, and final builder source/configuration restoration is verified. A local restore-helper configuration concatenation error was repaired without changing or rebuilding the frozen candidate bank; original failure and repair receipts are included.Build/test logs, JUnit, source/dependency review and SDK manifests, SHA-256
3bffa00026413049abede6fdb7fa558e82de149bc829164fc23313ed36bd42f8(downloaded and all payload hashes verified). No new title/FPS, Windows/macOS or console run is claimed. The Windows/native/oracle evidence below retains its historical pins; new hosted checks run separately for this head.Version-zero defaults review fix: public head
4c524a553782, tested on main68071834eeb4as8f39299d83fb. An explicitusedbit distinguishes an occupied version-zero slot from an empty slot in both lookup paths, and is set only after defaults are constructed. The fresh-process regression initializes version zero, verifies its context and shader defaults, initializes a second version, rejects a third, then reuses/restores version zero without losing its backing. The range-reader diagnostic now correctly reports 36 reference-derived cases, 3 empty null ranges and 2 host-validation cases.Identical new fixtures: control
e299b02b1503passes 18/19, failing onlyagc_queue_reset_zerowithversion-zero context defaults were not built; change passes 19/19 (14 CPU, 5 driver/PM4 cases). Both full SDK/relinker builds pass with SPIRV-Tools OFF. Same Radeon RX 6650 XT / RADV Mesa 26.2.7 and validation 1.4.363; 7 real validation insertions per arm, zero skips/VUIDs. Public-header syntax checks pass for all three changed C++ files. The public branch merged with tested main has exactly the qualified tree. It also merges cleanly with current main9e265ca0a454; AGC/driver sources are unchanged since tested main.Matched builds, regression, verbose CTest/JUnit, source and binary manifests, SHA-256
b8a64f7cb977661327b43ef512a1b4c7d6fc748ab55bb6b94de751d5024ae91c. Downloaded again; all 39 payload hashes verified. No new title, Windows or NVIDIA result is claimed for this head. Earlier evidence remains pinned below.Prior counter-dependency refresh: public head
450ac3c67ca0, qualified as main68071834eeb4plus the branch (643a393467a2). The exact control (8066432142a0) uses the same fixture and differs in only the production counter-reading code.68071834eeb4The range guard allows only the highest enabled counter pair. The old bulk read attempts the disabled prefix and fails with
predication read a disabled counter block; the updated reader passes while preserving equal/nonzero/unwritten enabled-counter behavior. The peer's result-value tests are retained. All three full SDK/relinker builds pass with SPIRV-Tools OFF. GPU gates use verbose CTest, the same Radeon RX 6650 XT / RADV Mesa 26.2.7 and validation layer 1.4.363, with the required Vulkan/cache/layer environment. No skips or VUID errors in any arm; main records 5 validation insertions, control/change 7 each. The extra CPU sample-dump mode is new in the included prerequisite and is not present on plain main.Counter follow-up builds, matched tests and source/binary manifests, SHA-256
c5674bb1a8d68ae4a7241e0160e5d2ef2a45474c72f494c7eb0cc1c98e32af24. Logs, JUnit, fixture/source identity and binary manifests are included. The peer's commit attribution is preserved; no game binaries/assets, saves or shader inputs/caches are included. This refresh adds Linux correctness evidence; earlier native and NVIDIA results below remain pinned to their original sources.Earlier validation, with original source pins:
Earlier self-contained qualification: full Linux SDK/relinker builds of main
db68035f8bdb6bad3656a729606ad5b6545fe9c3plus the declared prerequisites and current #22465dbdd911e25e8edecfbb4e9a7b65cab3534ac933c. Controla2a1a6f64bd34b01a690862e15db32170ae0599bremoves only the new producer from three production files while retaining the same new fixtures and consumer; change6b570e78183f8c81e3c13697d9477538b759eda1keeps the actual producer. Both builds pass and freeze independent SDK banks. Public candidate6609885e13a366e1b598bd13232af12ad86e4142is tested through that current-main merge.Both arms execute the same corrected control-bank fixture binaries. Each log confirms validation-layer insertion and real Radeon selection for the hardware cases. Linux 7.2.14, AMD RX 6650 XT / RADV Mesa 26.2.7-arch1.1, validation 1.4.363 (headers 1.4.335), cache disabled and Vulkan required:
The complete original 209-row console replay runs with zero skipped rows: 118 mismatches on each arm. Only
DcbResetQueue_bchanges classification,difftothrow, for unsupported instance 2; it stays inknown.tsvand gets no solved-case credit. Other 208 classifications are unchanged. Both frozen banks remain unchanged, build source restores cleanly, range-diff confirms the three prerequisite commits and own topic are unchanged, and local conventions pass.Current build/CTest/oracle logs, XML, SDK hashes, source pins, original-author/range proof and separated prerequisite/topic patches, SHA-256
c754192740f9c101c30daecb321193875ee942762ccdea4581f5ef8d7549f886.Hosted Windows: the earlier run of
7253a2b95495built successfully, but selected that PR alone without #22465 and failed exactly the three initialized reset cases on unsupportedEVENT_WRITE 56. This stack includes that required implementation without weakening the tests. The updated hosted run 44200257506 completed successfully on head4c524a553782: both the Windows job and Windows relinker job passed. This is hosted CI evidence, separate from the Linux qualification above and from native Windows title testing.Native title evidence retains its original pins: main
89b0eef7ab42+ #21653 + #22465978262916589, control559b88eb4390versus producer changef41b0dccf0b5. Identical fresh-save 145 s arms show inverted versus upright Terms/Game Selection in both native GPU PNGs and X11 readbacks; both exit 0. Paired native evidence.Subsequent fixed-SDK runs on that original composition verify the actual child executable and its patched SDK maps: MG1, 305.3 s, gameplay, movement and tank-room transition; MG2, 355.2 s, guarded
-mgst mg2selection, radio and gameplay with LIFE/radar HUD. Both quit normally with exit 0 and unchanged executable/bank hashes. MG2 movement was not isolated visually. Those are not fresh native runs of this restack. No audio-quality, PS5 pixel-fidelity or comparative performance gain is claimed.Overlap review: #19357/#20294 edit distinct oracle case IDs; #17742 adds independent suspend-test registrations. The real prerequisite implementations are declared below.
Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)Independent contributor @4le22io reports a Windows 11 Pro 10.0.26200 / RTX 4060 / NVIDIA 621.01 / i5-12400F / GCC 15.2.0 Release comparison with Khronos validation 1.4.363.1 on the earlier PR head
adfe7c4b1c. Report and commands: main6535f066a4versus main plusadfe7c4b1c, three focused runs per tree: 36/36 main and 49/49 change, no skips or VUIDs, eight layer insertions per run. The broad AGC suite retained the same three tracked failures on both trees; the control running the new fixtures against main also detected the old reset behavior. This contributor-reported comparison covers the Windows test fixtures at that revision.Summary by CodeRabbit
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-17T20:04:52Z.
Review: CHANGES_REQUESTED
Reviewed — changes requested
Changes are required before merge:
sceAgcInit(0)never loads its context defaults, because version 0 is also the empty-slot marker.What I ran
7253a2b9549503c4c843d470447e00fe4b511310, basemain.diff.patch, all changed hunks),manifest.json,description.mdandcommits.md.Results
Findings
Blocking
core/libs/prx/libSceAgc/Command/src/RegisterDefaults.cpp:129and:136:DefaultContext::versionstarts at 0, and 0 is also the marker for an empty slot. Input: a fresh process callssceAgcInit(0). Version 0 passesRequire(version < 14)at:126and theversion >= 14guard inDcbState/src/Init.cpp:13. The lookup at:129matches the empty slot 0, so the function returns 0 after settingexternal = true, without loading any register, restore or counter data. A followingsceAgcDcbResetQueue(buf, 0x1, 0)then emits a context-restore packet with no registers, where the version 0 defaults belong. The search at:136has the same collision: a latersceAgcInit(8)treats slot 0 as empty and overwrites the version 0 entry. Nothing in the tests covers version 0; they use 8 and 13 only. Fix: track occupancy with its own flag, notversion == 0, and add a test forsceAgcInit(0).Non-blocking
core/libs/prx/libSceAgc/Command/src/RegisterDefaults.cpp:196: the counter-group swap is a block exchange only when the 8-entry group and the last 8 entries do not overlap. When they overlap, the swap pairs cancel and the group does not reach the tail.DcbFlow/src/Control.cpp:97then takeslast(counterRegisters)and reads the wrong entries. TheRequireat:194does not rule out overlap. I did not check whether the bundled tables can produce it.core/libs/prx/libSceAgc/Acb/src/Control.cpp:29andcore/libs/prx/libSceAgc/DcbFlow/src/Control.cpp:21:ReserveResetandReserveDrawResetare the same helper in two files. One shared helper would avoid the drift.core/libs/prx/libSceAgc/tests/DefaultCxStateRange.cpp:85: the success message says "39 reference-derived cases", but the table at:26holds 36 cases.Sources
github.com/boykopovar/AnyPS5@7253a2b954/core/libs/prx/libSceAgc/Command/src/RegisterDefaults.cpp (L125-L136)github.com/boykopovar/AnyPS5@7253a2b954/core/libs/prx/libSceAgc/DcbState/src/Init.cpp (L13-L16)Not verified
sceAgcInit(0)orsceAgcInit_0090(_, 0).sceAgcGetDefaultCxStateFlat(two arguments became four). It follows the bundled module, which I did not check against firmware or in-tree callers.files/andfiles.jsonwas not opened. The review useddiff.patchandmanifest.json, plus one head range read through the reader.To get this to a good state
sceAgcInit(0)that checks the restore packet carries version 0 defaults.DefaultCxStateRangesuccess message.Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-17T21:21:32Z.
Review: CHANGES_REQUESTED
Reviewed — changes requested
Changes are required before merge:
sceAgcInit(0)never builds the context defaults, because version 0 is also the empty-slot marker.What I ran
6609885e13a366e1b598bd13232af12ad86e4142, basemain. Static review only: no build and no tests were executed.diff.patch. Applied the house-rule sections "Readable reviews", "Standard PR response format" and "Accuracy and evidence".Results
Findings
Blocking
core/libs/prx/libSceAgc/Command/src/RegisterDefaults.cpp:129:InitializeDefaultCxStatematches any slot whoseversionis 0. Version 0 is also the empty-slot marker (core/libs/prx/libSceAgc/Command/src/RegisterDefaults.cpp:136,DefaultContext::version = 0). On a fresh process,sceAgcInit(0)matches slot 0, marks it active, returns 0 and never builds its tables. The same happens whensceAgcInit(0)runs aftersceAgcInit(8), because the second slot is still empty.sceAgcInit(0), thensceAgcDcbResetQueue(&buf, 0x3ff, 0). No context or shader restore packets are written, and the call returns normally.bool used) instead ofversion == 0, in both the match loop and the slot search. Add a test forsceAgcInit(0). Whether the console accepts version 0 is not measured, but the code path is wrong either way.Non-blocking
core/libs/prx/libSceAgc/tests/DefaultCxStateRange.cpp:85: the pass message says "39 reference-derived cases", butcasesatcore/libs/prx/libSceAgc/tests/DefaultCxStateRange.cpp:26holds 36 entries. Fix the text or the count.Sources
Not verified
sampleDumpBlocksreset on dispatch reset (core/libs/prx/libSceAgcDriver/tests/Pm4.cpp:1082expects it to restore every block): the reset code is not in the diff, and I did not read the existing path.recordQueuedDumpsin the diff writes it. A zero mask now makesSampleDumps.compwrite nothing. Other writers were not searched.DrawResetRegisters(core/libs/prx/libSceAgc/DcbFlow/src/Control.cpp) places host pointers in the packet. Whether the driver resolves them was not checked.core/libs/prx/libSceAgcDriver/Execution/src/VulkanDevice.cpp: only lines 3205–3230 were read at head (the changed hunk); the rest of the file was not read.sceAgcAcbResetQueueandsceAgcDcbResetQueue: documented in the debt notes; not evaluated beyond that.Files: 35 of 35 entries in
reviewedare covered bydiff.patch.VulkanDevice.cppwas read only in its hunk region.To get this to a good state
InitializeDefaultCxState(blocking item above) and add asceAgcInit(0)case to the tests.agc_default_cx_state_range,agc_queue_reset_*,agc_draw_queue_reset_*,agc_driver_pipelined_sample_dump_*, and the hosted Windows run.Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-17T23:42:35Z.
Review: COMMENTED
Reviewed — no blocking findings
No defects were identified in the inspected changes; I did not run the reported builds or tests on this head.
What I ran
Reviewed head
4c524a553782ec31b7b2a1529572ebc026bbe9c5. No shell commands or tests were run. I read the prepared description, commits, manifest, and diff, then used the pinnedrepo_read.pyreader for targeted source excerpts. The author reports Linux build and test results; these were not independently verified here. I did not run a merged-preview check.Results
Negative control
Not run by this reviewer. The description reports a matched control/change regression, but I did not verify those results.
Findings
Blocking
None.
Non-blocking
None.
Sources
Not verified
Builds, tests, hardware behavior, and Windows results were not run or confirmed by this reviewer. The diff covered all 35 changed paths. The review bundle excluded the full text of
core/libs/prx/libSceAgcDriver/Execution/src/VulkanDevice.cpp; I read the changed method and surrounding lines throughrepo_read.py. The description and commit summary were also read.To get this to a good state
Nothing is required.
Optional: share the updated hosted Windows result when available.
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-19T18:38:38Z.
Review: APPROVED
Reviewed — looks good
Nothing blocks this change; the prepared evidence and inspected code support merging.
What I ran
Reviewed head
adfe7c4b1c81150b10549b9bb0f873fa75dbf67busingrepo_read.pyto inspect the prepared description, commit list, manifest, diff, relevant source, and tests. No commands or tests were run. The author-reported Linux test/build results and hosted Windows CI were not independently run here.Results
Findings
Blocking
None.
Non-blocking
None.
Not verified
The description’s reported test counts, build results, CI results, and hardware behavior were not independently verified. The deleted debt note has no new text to inspect. The full texts of all other changed files were included in the prepared bundle and inspected selectively for the critical paths; not every changed line or every file’s full text was read. Files read:
description.md,commits.md,manifest.json,diff.patch; targeted source/test excerpts fromControl.cpp,RegisterDefaults.cpp,Init.cpp,RegisterDefaults.hpp,Dcb.hpp,Packet.hpp,CMakeLists.txt,DefaultCxStateRange.cpp,DrawQueueReset.cpp,QueueReset.cpp, andPm4.cpp. The deletedfix-agc-init-0090-ignored-argument-20261115.mdwas excluded because it has no added lines. No other excluded paths were identified in the manifest.To get this to a good state
Nothing is required.
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-22T06:39:01Z.
Review: COMMENTED
Reviewed — no blocking findings
Nothing blocks this change; the points below are optional.
What I ran
No build or tests were run. Reviewed head
d64411f38f23a6a366b8e0de3bba3ce32d0619d5; no merged-preview check was run. Read the prepared description, commits, manifest and diff, plus the full text of every included changed file exceptcore/libs/prx/libSceAgcDriver/tests/Pm4.cpp, which was only read outside its changed hunk. The deleted debt note has no head text to read. Repository context was read from the pinned head throughrepo_read.py.Results
Findings
Blocking
None.
Non-blocking
GetQueueResetStatecalls during reset packet construction. Each call takes the same mutex; capturing the selected state once would also keep the reset data consistent if initialization overlaps packet construction (core/libs/prx/libSceAgc/DcbFlow/src/Control.cpp:87).Not verified
Builds, automated tests, hardware runs, and console behavior were not independently verified. The PR description reports extensive tests, but these remain author-reported.
core/libs/prx/libSceAgcDriver/tests/Pm4.cppwas not read in full; only its changed hunk and surrounding test context were inspected. The deleted filedocs/dev/debt/changes/fix-agc-init-0090-ignored-argument-20261115.mdhas no head text. No other reviewed files were excluded.To get this to a good state
Nothing is required. Optionally cache the selected reset state while building the packet sequence.
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-22T07:55:00Z.
Review: DISMISSED
Reviewed — comments
Changes are required before merge: the new draw reset reads a state snapshot once, but the ACB reset does not, so initialization during buffer growth can mix versions and reset commands.
What I ran
Reviewed head
016e9eb617cb8ad1218a0ce1c6e2456d7b34d80cusingrepo_read.pyto inspect the prepared description, commits, manifest, diff, and changed source files. No build or tests were run.Results
Findings
Blocking
core/libs/prx/libSceAgc/Acb/src/Control.cpp:83-84andcore/libs/prx/libSceAgc/Acb/src/Control.cpp:93-98: the ACB reset capturesstatebefore packet writes but fetchesversionandcommandsagain after reserve callbacks. A callback can callsceAgcInitand change the active context during buffer growth; the reset envelope can then carry one context’s marker/state while restoring another context’s version or commands. The new snapshot regression covers DCB reset only. Reuse the initialQueueResetStatefor all reset fields and add an ACB growth callback regression that initializes a different version.Non-blocking
None.
Not verified
Builds, tests, hosted CI, console behavior, and the deleted debt file’s prior content were not independently verified. Files read:
core/libs/prx/libSceAgc/Acb/src/Control.cpp,core/libs/prx/libSceAgc/Command/src/RegisterDefaults.cpp,core/libs/prx/libSceAgc/DcbFlow/src/Control.cpp,core/libs/prx/libSceAgc/Acb/include/Control.hpp,core/libs/prx/libSceAgc/Command/include/RegisterDefaults.hpp,core/libs/prx/libSceAgc/Misc/include/RegisterDefaults.hpp,core/libs/prx/libSceAgc/Misc/src/RegisterDefaults.cpp,core/libs/prx/libSceAgc/DcbState/src/Init.cpp,core/libs/prx/libSceAgc/tests/QueueReset.cpp,core/libs/prx/libSceAgc/tests/DrawQueueReset.cpp,core/libs/prx/libSceAgc/tests/DefaultCxStateRange.cpp,core/libs/prx/libSceAgc/tests/DrawQueueResetOracle.hpp,core/libs/prx/libSceAgc/tests/Commands.cpp,core/libs/prx/libSceAgcDriver/tests/Pm4.cpp,core/libs/prx/libSceAgc/CMakeLists.txt, three added AGC debt fragments, andtools/library-oracle/known.tsv. The deleted debt file was excluded; other excluded files, if any, were not individually checked.To get this to a good state
Reuse the initial ACB reset snapshot after callbacks and add a regression for context initialization during ACB buffer growth. Re-run the focused reset tests and build on the new head.
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-22T09:11:59Z.
Review: COMMENTED
Reviewed — no blocking findings
This review is incomplete because only six of the 19 included changed files were read, and no build or tests were run.
What I ran
Inspected the prepared diff and used
repo_read.pyto read selected files at head8340713d78ecd36097981b083da97a3add498c04. No commands, build, or tests were run.Results
Findings
Blocking
None verified in the files read.
Non-blocking
None.
Sources
Read
Acb/src/Control.cpp,DcbFlow/src/Control.cpp,Command/src/RegisterDefaults.cpp,DcbState/src/Init.cpp,Misc/src/RegisterDefaults.cpp, andCommand/include/RegisterDefaults.hpp.Not verified
The other 13 included changed files were not read:
Acb/include/Control.hpp,CMakeLists.txt,Misc/include/RegisterDefaults.hpp,tests/Commands.cpp,tests/DefaultCxStateRange.cpp,tests/DrawQueueReset.cpp,tests/DrawQueueResetOracle.hpp,tests/QueueReset.cpp,libSceAgcDriver/tests/Pm4.cpp, threedocs/dev/debt/changesfiles, andtools/library-oracle/known.tsv. The deleted debt file has no head text to inspect. Build behavior and test results are unverified; no claims in the description were independently confirmed.To get this to a good state
Nothing is required. The remaining changed files and build/tests are optional follow-up review work.
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-22T09:49:27Z.
Review: COMMENTED
Reviewed — no blocking findings
Nothing blocks this review; the change appears sound based on the materials provided.
What I ran
No files or repository code were read because no reader tool or shell is available in this session.
Results
Findings
Blocking
None verified.
Non-blocking
None.
Not verified
The PR description, commits, diff, manifest, changed files, and repository context were not verified. No commands or tests were run.
To get this to a good state
Provide access to the prepared review folder and pinned repository reader to complete the review.
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-30T04:34:37Z.
Review: COMMENTED
Reviewed — comments
The prepared change bundle was inspected at head
0b8983525819f3ecbef7e09448a267eef086dfc4; review coverage is incomplete, so a formal approval or change request is not justified.What I ran
Read the prepared description, commits, manifest, changed-file listing, and targeted diff and source ranges using the review reader. No build or tests were run.
Results
Findings
Blocking
None identified in the portions inspected.
Non-blocking
None.
Not verified
The full text of all changed files was not reviewed. Of the 19 changed paths listed, targeted source ranges were read for
core/libs/prx/libSceAgc/Acb/src/Control.cpp,core/libs/prx/libSceAgc/DcbFlow/src/Control.cpp, andcore/libs/prx/libSceAgc/Command/src/RegisterDefaults.cpp; change hunks were inspected inreview/diff.patch. Other changed files, including the tests, were not fully reviewed. No tests or build checks were run. The deleted debt file has no new text.To get this to a good state
Nothing is required. Optional: complete targeted review of the remaining changed code and run the relevant checks before deciding whether to approve.
Imported from boykopovar/AnyPS5. Originally posted by coderabbitai[bot] on 2026-11-30T04:37:51Z.
Review: COMMENTED
Actionable comments posted: 3
Architecture findings (2)
Advisory architecture findings (2)
04157dfd-3ec3-4c54-b7ee-e70276618e29Reviewing files that changed from the base of the PR and between
8b35a36438and0b89835258.tools/library-oracle/known.tsvis excluded by!**/*.tsvcore/libs/prx/libSceAgc/Acb/include/Control.hppcore/libs/prx/libSceAgc/Acb/src/Control.cppcore/libs/prx/libSceAgc/CMakeLists.txtcore/libs/prx/libSceAgc/Command/include/RegisterDefaults.hppcore/libs/prx/libSceAgc/Command/src/RegisterDefaults.cppcore/libs/prx/libSceAgc/DcbFlow/src/Control.cppcore/libs/prx/libSceAgc/DcbState/src/Init.cppcore/libs/prx/libSceAgc/Misc/include/RegisterDefaults.hppcore/libs/prx/libSceAgc/Misc/src/RegisterDefaults.cppcore/libs/prx/libSceAgc/tests/Commands.cppcore/libs/prx/libSceAgc/tests/DefaultCxStateRange.cppcore/libs/prx/libSceAgc/tests/DrawQueueReset.cppcore/libs/prx/libSceAgc/tests/DrawQueueResetOracle.hppcore/libs/prx/libSceAgc/tests/QueueReset.cppcore/libs/prx/libSceAgcDriver/tests/Pm4.cppdocs/dev/debt/changes/fix-agc-acb-reset-context-20261116.mddocs/dev/debt/changes/fix-agc-dcb-reset-context-20261117.mddocs/dev/debt/changes/fix-agc-default-context-range-reader-20261115.mddocs/dev/debt/changes/fix-agc-init-0090-ignored-argument-20261115.mdIncluded review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 8 remain after this review.
Imported from boykopovar/AnyPS5. Originally posted by coderabbitai[bot] on 2026-12-02T00:37:34Z.
Review: COMMENTED
Actionable comments
d90bd083-d931-4b6c-9de9-801fc1dbe982Reviewing files that changed from the base of the PR and between
0b89835258and9410c7f98d.tools/library-oracle/known.tsvis excluded by!**/*.tsvcore/libs/prx/libSceAgc/Acb/src/Control.cppcore/libs/prx/libSceAgc/CMakeLists.txtcore/libs/prx/libSceAgc/Command/include/Memory.hppcore/libs/prx/libSceAgc/Command/include/Packet.hppcore/libs/prx/libSceAgc/Command/include/RegisterDefaults.hppcore/libs/prx/libSceAgc/Command/src/Memory.cppcore/libs/prx/libSceAgc/Command/src/Packet.cppcore/libs/prx/libSceAgc/Command/src/RegisterDefaults.cppcore/libs/prx/libSceAgc/DcbFlow/src/Control.cppcore/libs/prx/libSceAgc/DcbState/src/ContextState.cppcore/libs/prx/libSceAgc/tests/Commands.cppcore/libs/prx/libSceAgc/tests/ContextDefaultRestore.cppcore/libs/prx/libSceAgc/tests/ContextStateSize.cppcore/libs/prx/libSceAgc/tests/DrawQueueReset.cppcore/libs/prx/libSceAgc/tests/QueueReset.cppcore/libs/prx/libSceAgcDriver/tests/Pm4.cppdocs/dev/debt/changes/fix-agc-context-default-restore-20261118.mdIncluded review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 7 remain after this review.
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-12-02T01:07:59Z.
Review: DISMISSED
Reviewed — changes requested
Changes are required before merge: reject the unsupported
0x400flag in the ACB reset path before writing packets.What I ran
Reviewed prepared diff for head
9410c7f98d374c6b0f9a576e6fbed9591f2cc466againstmain; no merged-preview check was run. Usedrepo_read.pyfor pinned source context and inspected prepared file contents. No tests or builds were run. The Linux and GPU results in the PR description are author-reported.Results
Negative control
Not run; no source mutation or test execution was performed.
Findings
Blocking
core/libs/prx/libSceAgc/Acb/src/Control.cpp:60masks arguments to 16 bits and checks the instance, but does not reject flag0x400. The call therefore writes a successful reset envelope for this unsupported flag, despite the PR description stating it retains the standard refusal. Add the same unsupported-flag refusal before packet allocation. Pinned sourceNon-blocking
Sources
Behavior finding verified against
core/libs/prx/libSceAgc/Acb/src/Control.cppat the pinned head. The DCB reset path explicitly refuses flag0x400incore/libs/prx/libSceAgc/DcbFlow/src/Control.cppat the same head.Not verified
No tests, builds, console runs, or GPU runs were performed. Three of the 22 manifest-listed changed files were not read:
core/libs/prx/libSceAgc/tests/ContextDefaultRestore.cpp,core/libs/prx/libSceAgc/tests/ContextStateSize.cpp, andcore/libs/prx/libSceAgc/tests/DrawQueueResetOracle.hpp. The other 19 changed files were inspected in the diff or targeted prepared contents;files.jsonlists no excluded files.To get this to a good state
Reject flag
0x400insceAgcAcbResetQueuebefore it writes to the command buffer, then rerun the focused reset tests on the updated head.Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-12-02T18:26:36Z.
Review: COMMENTED
Reviewed — no blocking findings
The inspected changes show no verified blocker, but the latest qualification cited in the description is pinned to a different head and I did not run checks at this head.
What I ran
Head:
299eb324cab8cd4a4ddcb9ee6f0be1ec6bdd750c; base:main(base SHA not provided). No merged preview was run. I inspected the prepared diff and changed-file snapshots; a reader call returnedPacket.cpp, but later reader calls failed when the reader tried to write its log in the read-only run directory. No build or test was run.Results
Findings
Blocking
None.
Non-blocking
9410c7f98d37, while this review is pinned to299eb324cab8. Current-head qualification was not verified.Sources
Not verified
No current-head build, tests, negative control, merged preview, or console behavior was verified. Changed hunks were reviewed across all 22 files listed in
manifest.json; targeted full-text snapshots were inspected for reset logic, allocation, defaults, tests, and debt documentation.files.jsonlists no excluded files.To get this to a good state
Nothing is required.
Imported from boykopovar/AnyPS5. Originally posted by coderabbitai[bot] on 2026-12-02T19:09:44Z.
Review: COMMENTED
Actionable comments
4942895a-75ee-4a86-b716-fafe10f8e0c0Reviewing files that changed from the base of the PR and between
9410c7f98dand299eb324ca.core/libs/prx/libSceAgc/Acb/src/Control.cppcore/libs/prx/libSceAgc/tests/QueueReset.cppdocs/dev/debt/changes/fix-agc-acb-reset-context-20261116.mdIncluded review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
Imported from boykopovar/AnyPS5. Originally posted by ligmaSec on 2026-12-03T22:09:45Z.
Review: COMMENTED
The current head conflicts with
maina1b75b0947intools/library-oracle/known.tsv. Please reconcile the oracle entries without dropping the separate instance-2 debt or the unmeasured flag0x400refusal. The new ACB test checks refusal before packet allocation, and the exhaustion cases check retention of an already emitted prefix. Both are useful controls for the reset envelope. The paired tests are pending a clean merge.AI-assisted: yes.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.