feat(libSceAgc): implement sceAgcAcbSetFlip and execute flips on compute queues #6794
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/6794"
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 fma-rc on 2026-10-16T12:21:51Z.
What
Implements
sceAgcAcbSetFlip. It writes the same 6-dword flip packet assceAgcDcbSetFlip. In the PS5 6.00libSceAgcmodule both exports are the same 176-byte wrapper around onelibSceAgcDriverhelper; the only argument that differs selects the release event (CS_DONE for ACB), which our flip packet does not model.The second commit lets the driver execute that packet on a compute queue. Until now the PM4 validator (
Pm4.cpp) accepted a flip only on queue 0 and threwgraphics packet in compute queueotherwise. The flip path after validation already handles any queue: it reserves the output, hands it the frame and raises the end-of-pipe interrupt on the submitting queue, the way other compute-queue releases are delivered. Since two workers can now reach the flip, the frame serial became atomic, and a compute flip gets its own frame timing instead of taking queue 0's.Earlier attempts #1052 and #1585 were closed because no title was shown to reach it. Open PR 6447 writes the same packet for this function among changes to 100 files; this PR is only ACB flips. Death Stranding 2 (PPSA02015) stops on the export on its loading screen, about 1085 s in:
and, with the first commit alone, at 1333 s on the packet it writes:
Tested
Linux, on
main6a32550fd:agc_commandsfails onmainwithsceAgcAcbSetFlip not implemented;agc_driver_flip(new compute-queue case) fails without the second commit withAGC driver: FLIP at DWORD 0: graphics packet in compute queue. Both pass with this PR.agc_commandsagc_driver_flipagc_driver_flip_stores_small_resultsagc_driver_flip_computeWindows (WinLibs GCC 15.2 UCRT, no GPU): the whole suite builds and runs; the one failure is one
mainhas there too.Death Stranding 2 on Linux, RTX 5080: with both commits the run passes 1333 s with no refused submission, stays on the loading screen and stops at 1630 s on a heap corruption abort (
corrupted size vs. prev_size) that is not in this code. The title does not reach this call on plainmain: it also needs the open PRs #6437, #6297, #6277, #6196, #6530, #6300, #6727, #6492 and #6174 (none of them touches this code) and local changes for EQAA targets and image-table residency that are not ready to submit.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)Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-16T12:22:41Z.
Progress report (
6a32550→66cc672)📈 System libraries: 89.46% (+0.02%, +1 implemented functions)
✅ 1 implemented
sceAgcAcbSetFlipImported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-16T12:23:13Z.
The conventions failure is only the PR-template
Depends onfield: the validator requiresDepends on: #NorDepends on: nonedirectly on the checklist line. This PR lists integration-only prerequisites in prose, so please keep the checklist line in the accepted form (likelyDepends on: none, since you state there is no code dependency) and move the runtime/integration context to the description above. The failed run reported this as its sole finding; eligibility, intake and progress report pass.Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-16T12:35:01Z.
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.
core/libs/prx/libSceAgcDriver/Execution/src/Driver/Packets/PacketExecution.cppcore/libs/prx/libSceAgcDriver/Execution/src/Driver/Packets/PacketExecution.cppcore/libs/prx/libSceAgcDriver/Execution/src/Driver/Packets/PacketExecution.cppcore/libs/prx/libSceAgcDriver/Execution/src/Driver/Packets/PacketExecution.cppcore/libs/prx/libSceAgcDriver/Execution/src/Driver/Packets/PacketExecution.cppcore/libs/prx/libSceAgcDriver/Execution/src/Pm4.cppcore/libs/prx/libSceAgcDriver/Execution/src/Driver/Packets/PacketExecution.cppcore/libs/prx/libSceAgcDriver/Execution/src/Driver/Packets/PacketExecution.cppcore/libs/prx/libSceAgcDriver/Execution/src/Pm4.cppcore/libs/prx/libSceAgcDriver/Execution/src/Driver/Packets/PacketExecution.cppcore/libs/prx/libSceAgcDriver/Execution/src/Driver/Packets/PacketExecution.cppcore/libs/prx/libSceAgcDriver/Execution/src/Driver/Packets/PacketExecution.cppcore/libs/prx/libSceAgcDriver/Execution/src/Driver/Packets/PacketExecution.cppImported from boykopovar/AnyPS5. Originally posted by fma-rc on 2026-10-16T15:39:48Z.
Thanks, fixed: the checklist line is now
Depends on: noneand the prerequisites are listed in the description. The conventions check passes on the edit.Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-19T18:43:59Z.
Checked the ACB flip packet against
sceAgcDcbSetFlip, the compute-queue flip path (no flip hold on non-zero queues, own frame timing, EOP raised on the submitting queue) and the newagc_commands/agc_driver_flipcases, which fail on main with the errors quoted in the description; merged.