refactor(libSceAgc): name exports after the versioned SDK names their NIDs hash to #1215
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/1215"
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 polysius on 2026-10-07T18:00:27Z.
What
Eleven libSceAgc exports are published under a raw NID (
APS5_EXPORT) with a made-up or placeholder name. Each NID is the hash of a versioned SDK name. I found eight by hashing the names the tree already exports plus_0000–_9999suffixes withcompute_nidfromtools/nid_names.py. The last three come from OpenAGC'sinclude/agc_nids.h, and each of their names hashes to its NID too:23LRUSvYu1MsceAgcUnknownInitStatesceAgcInit_0090-KRzWekV120sceAgcUnknown__MKRzWekV120sceAgcDcbSetIndexSize_0600Ikfdt-rIqCEsceAgcUnknown_Ikfdt_MrIqCEsceAgcJumpPatchSetTarget_03007Wa3aeJgeVUsceAgcUnknown_7Wa3aeJgeVUsceAgcBranchPatchSetThenTarget_0300rP5xLdOf26ksceAgcUnknown_rP5xLdOf26ksceAgcBranchPatchSetElseTarget_0300fd5Bp5tGTgosceAgcUnknownFuseShaderHalvessceAgcFuseShaderHalves_0200qj7QZpgr9UwsceAgcDcbContextStateAnotherOpsceAgcDcbContextStateOp_0100k0E7vkgqAuEsceAgcCreateInterpolantMappingVsPssceAgcUpdateInterpolantMapping_0100gQkqkLttcpwsceAgcAcb_gQkqkLttcpwsceAgcAcbAtomicGds_0900dolOmWH+huQsceAgcUnknownGetFusedShaderSizesceAgcGetFusedShaderSize_0080V++UgBtQhn0sceAgcGetDataPacketPayloadAddressUnksceAgcGetDataPacketPayloadAddress_0090The names fit what the tree already does with them.
sceAgcDcbSetIndexSize_0600is SetIndexSize plus a per-instance-object-id bit.sceAgcJumpPatchSetTarget_0300is JumpPatchSetTarget plus a cache policy.sceAgcFuseShaderHalves_0200is whatsceAgcFuseShaderHalvesdelegates to. The Kyty-sized writer behindsceAgcDcbContextStateOpGetSizeissceAgcDcbContextStateOp_0100. The last one was declared as a "VsPs" create function, but the NID isUpdateInterpolantMapping.The functions now carry these names and are exported from them directly, without
APS5_EXPORT. The exported NIDs are unchanged, and the extra exports under the hashes of the old made-up names are gone. Behaviour is unchanged: the two BranchPatch_0300functions,sceAgcAcbAtomicGds_0900andsceAgcUpdateInterpolantMapping_0100still callNotImplemented_nid_no_patch.TechnicalDebt:
qj7QZpgr9Uw,fd5Bp5tGTgo,dolOmWH+huQandV++UgBtQhn0are removed.gQkqkLttcpwline now gives the name and keeps the unknown signature._0300signatures and thesceAgcUpdateInterpolantMapping_0100behaviour are unknown.OpenAGC still lists
qj7QZpgr9Uwandk0E7vkgqAuEas unknown, so those two names may be useful to it as well.Tested
--target libs, andctest.agc_command_tests,agc_context_state_size_tests,agc_shader_fusion,agc_branch_patchandagc_payload_rangepass.mainon this machine. The failures that remain are device-capability ones, since the Adreno X1-45 has no f64 and no 64-bit or float atomics, plus temp-file cleanup flakes in the Python relinker tests.objdump -p libs/libSceAgc.prx: each of the eleven NIDs is exported once, and no made-up name remains.compute_nid(name) == nidfor all eleven.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed in TechnicalDebt.mdfiles or images added to the repository (attach them to this PR)🤖 Generated with Claude Code
Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-08T04:37:14Z.
Progress report (
cea1ef1→f7424ea)➖ System libraries: 86.02% (+0.0%, +7 implemented, +4 declared, -11 removed functions)
✅ 7 implemented
sceAgcDcbContextStateOp_0100sceAgcDcbSetIndexSize_0600sceAgcFuseShaderHalves_0200sceAgcGetDataPacketPayloadAddress_0090sceAgcGetFusedShaderSize_0080sceAgcInit_0090sceAgcJumpPatchSetTarget_0300🆕 4 declared as stubs
sceAgcAcbAtomicGds_0900sceAgcBranchPatchSetElseTarget_0300sceAgcBranchPatchSetThenTarget_0300sceAgcUpdateInterpolantMapping_0100🗑️ 11 removed
sceAgcAcb_gQkqkLttcpwsceAgcCreateInterpolantMappingVsPssceAgcDcbContextStateAnotherOpsceAgcGetDataPacketPayloadAddressUnksceAgcUnknownFuseShaderHalvessceAgcUnknownGetFusedShaderSizesceAgcUnknownInitStatesceAgcUnknown_7Wa3aeJgeVUsceAgcUnknown_Ikfdt_MrIqCEsceAgcUnknown__MKRzWekV120sceAgcUnknown_rP5xLdOf26kImported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-08T09:05:39Z.
Checked that
compute_nidof all eleven names matches its NID, that each NID is exported exactly once from the builtlibSceAgc.prxwith no leftover old name in the tree, and build + full ctest (428/428, incl. the four AGC tests you touched) on top of current main; CI is green. TechnicalDebt lines look right. Merging.