feat(libkernel): implement sceKernelGetProcessAbiType #11939
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/11939"
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 ionut27001 on 2026-10-27T13:13:35Z.
What
Implements
sceKernelGetProcessAbiType(int pid)incore/libs/prx/libkernel/System/src/Process.cppand removes the throwing declaration fromUnimplemented.cpp. The own pid and -1 return 1, pid 0 returns 0, and any other pid throws as unmodelled; the second argument is ignored here, and whether the export uses one is unknown. The debt entry says what is still open: other existing pids, which process pid 0 names, the meaning of the values, and a title process.Measured in two payload process runs on a PS5 (firmware 12.70), p85 and p86 (
E:/CLI/ps5-oracle/results/20261027T103808Z_p85_libkernel/result.log,E:/CLI/ps5-oracle/results/20261027T104816Z_p86_libkernel/result.log), result inrax:getpid()(108): 1 with a 16-byte0xa5buffer and with null as the second argument (p86 linescase abi_out pid=108 rax=0x1 buf=a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5,case abi_null pid=108 rax=0x1)case abi_out pid=-1 rax=0x1 buf=a5a5...,case abi_null pid=-1 rax=0x1)case abi_out pid=0 rax=0 buf=a5a5...,case abi_null pid=0 rax=0)0x80020003(p85 v2case abi_buf rax=0x80020003 buf=0000...,case abi_noarg rax=0x80020003)abi_outcases the 16-byte0xa5buffer passed as the second argument was not written.Other existing pids were not tried, so they throw here instead of returning
SCE_KERNEL_ERROR_ESRCH, which was seen only for a stack pointer and an unspecified first argument (p85). PS5_MihawkOS (PPSA99170) imports this export.Tested
Windows 11, WinLibs GCC 15.2.0 (Release, Ninja), commit 4fddc50616 on main
75f3702aed(the revert check below ran on ea35db574d, the same code on main431a5156b9):ctest -R ^guest_process_abi_type$passed twice.sceKernelGetProcessAbiType not implemented).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)docs/dev/debt/libkernel.mdconflicts; this lands after both and rebases)Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-27T13:18:50Z.
Review: DISMISSED
The implementation is supported by the measured own-pid,
-1, and0cases; my local syntax, conventions, and NID checks pass. I found one contribution-rule blocker before approval: #9326 is open and changes the samedocs/dev/debt/libkernel.mdregion. I fetched both exact heads and rangit merge-treeagainst their common base; the merge conflicts in that debt file (the shared CMake/API files merge cleanly). Please coordinate the agreed landing order with #9326 and record it inDepends on/the overlap note, or rebase and update the report after one lands. The hosted Windows test and policy checks are still running; this request is specifically for the confirmed documentation conflict.