Runtime system-call notes
What each runtime system call is for, what it must do, what the game was seen to do with it, and how Paleblood's runtime answers.
At a glance
- Covers
- Calls from runtime issue #34, the files from #35, the start-up services from #36 and #40, sound and movies from #37, the controller, the clock, save data, trophies and the offline PSN calls, the network from #41, and the graphics calls from #39. Every one of these issues is closed: all but #34 on 10 November (below), and #34, with all 184 of its calls answered, on 11 November. A generated list of every registered call is near the end; the runtime call reference has the full notes and sources for each call.
- Status
- implemented: the runtime answers the call. unresolved: no established answer, so the runtime has no implementation or stops by name. observed: seen in a real boot, not yet implemented.
- How to read
- Each group starts with a status table, then explains the calls. PRs, citations, call-site addresses and "what would settle it" notes are in the collapsibles.
- Caution
- A platform manual describes that platform; it does not prove every detail of the PS4 implementation. These notes separate documented behavior from what remains unknown for the target.
Two rules the runtime follows
Most calls below share the same shape, so it helps to know it first.
- Stopping by name. When the PS4's answer to a call is not established, the runtime does not guess. It stops the process (a "fail-loud diagnostic") and names the call the guest made. A registry entry that stops like this is not an implementation.
- Two error conventions. Many calls exist under an SCE name (
scePthread…) and a POSIX name (pthread_…). As with the mutex functions (runtime/syslib/kernel_mutex.c), the SCE name returns0x80020000plus the error number, and the POSIX name returns the number itself.
Time and process
| Call | Status | What the runtime does |
|---|---|---|
getpagesize |
implemented (maintainer's ruling) | Answers 16384 (16 KiB), the value every PS4 runtime and port uses and the alignment of every segment in the game's files (#528). |
getpid |
implemented (maintainer's ruling) | Answers a fixed id, 1000, so runs stay reproducible; the host's process id is not the guest's (#528). |
clock_gettime, sceKernelClockGettime |
implemented | FreeBSD's clocks 0 (wall clock), 4 (monotonic) and 13 (wall-clock seconds) from the host's clocks; other clocks stop or answer EINVAL. |
sceKernelGetProcessTime |
implemented | Microseconds since the runtime started. |
gettimeofday, sceKernelGettimeofday |
implemented | The host's wall clock; a timezone argument stops by name. |
time (libSceLibcInternal) |
implemented | Seconds since the Epoch, from the same clock as clock_gettime(13), also stored through a non-null pointer, as FreeBSD's time.c does (#296, by @EzequielRindello). The game's file module is its only caller. |
gmtime, gmtime_s, printf, vprintf, vsnprintf (libSceLibcInternal) |
implemented | For the bundled file library: UTC calendar time in ISO C's nine-field struct tm (the PS4's is 36 bytes, measured from the library's own copy), and formatted output through the host's formatter after each format is checked; wide-character conversions stop by name (#468). |
What the calls are for
getpagesize- Takes no arguments and returns the system's memory page size in bytes. The number is platform-specific. It is not in current POSIX; portable code uses
sysconf(_SC_PAGESIZE). getpid- Takes no arguments and returns a
pid_tfor the calling process. POSIX defines no error return. What a process ID means, and how long it lives, is platform-specific. clock_gettime- Reads the clock chosen by
clock_idinto astruct timespec: seconds (tv_sec) and nanoseconds (tv_nsec, from 0 through 999,999,999). POSIX returns 0 on success, and -1 witherrnoon failure; an unsupported clock ID isEINVAL. gettimeofday- Reads wall time into a
struct timeval: seconds since the Epoch and microseconds (tv_usecfrom 0 through 999,999). Wall time can jump, so it is not a monotonic clock for measuring elapsed time. POSIX.1-2024 removed the interface.
What the game does with them
The executable imports getpagesize and gettimeofday from libScePosix. The game's bundled
libc.elf imports clock_gettime, getpagesize, getpid, and gettimeofday from libkernel.
These imports tell us which names are needed, not every argument or how the PS4 behaves.
- The frame limiter reads the time with
gettimeofdayand passes null for the timezone argument. - A separate verified game helper calls
sceKernelClockGettimewith clock ID4, identified asCLOCK_MONOTONIC. - The bundled C library's
time()callsclock_gettimewith clock ID13and keeps only the seconds. That is FreeBSD'sCLOCK_SECOND, whose answer is the wall clock in whole seconds.
Clock ID numbers are implementation-defined. The PS4's kernel descends from FreeBSD, and both
observed IDs fit FreeBSD's numbering, so the runtime answers FreeBSD's realtime (0), monotonic (4)
and second (13) clocks from your computer's clocks
(#164,
#165). Any other ID stops by name, or
answers EINVAL under the SCE name.
Working out the page size
The page size is a good example of how far file evidence goes, and where it stops.
getpagesize is the only page-size query the game has: nothing imports sysconf.
- Observed in the game files. Every loadable segment of the eight images is aligned to
0x4000, and each segment's file offset and address differ by exactly0x4000. Three call sites use the result the same way: they accept it only if it is a power of two and cache it next to three fixed sizes (0x10000,0x40000,0x200000). Nothing else reads that cached value, and nothing compares it with a constant. - Inferred, with its assumptions. If the PS4 loader follows the usual ELF rules for these segments, the page size cannot be larger than
0x4000; any power of two that divides0x4000would fit. Narrowing that to 4 KiB, 8 KiB or 16 KiB also assumes a page is at least 4 KiB, which is our assumption, not an observation. The game's own check accepts every power of two, so it does not pick one either. - Unknown. The actual value. Stock FreeBSD on AMD64 uses 4096, but that describes the PS4 kernel's ancestor, not the console.
For a month both getpagesize entries stopped by name. On 10 November the maintainer ruled
on it (#528): the runtime answers 16 KiB. No console measurement exists, but every public PS4
runtime and port answers that value, and it is the largest the files allow, the alignment every
segment already has. It is a ruling, not a measurement, and the page says so. Paleblood's loader
does not depend on the page size either way: it copies each segment to its exact address.
Time and process: full contract table
| Call | Arguments and representation | Publicly documented result and errors | Still unknown for the PS4 target |
|---|---|---|---|
getpagesize(void) |
No arguments; returns the system page size in bytes. The number is platform-specific. | Linux and FreeBSD document the byte count. getpagesize is not in current POSIX; portable code uses sysconf(_SC_PAGESIZE). The manuals do not define a general error return. |
The target's page-size value and behavior under unusual configurations. Never substitute the build host's page size without evidence. |
getpid(void) |
No arguments; returns a pid_t for the calling process. |
POSIX specifies success and no error return. Linux PID namespaces scope process IDs; process-ID scope and lifetime are platform-specific. | The guest-visible ID and its scope. The host PID is not automatically the correct guest result. |
clock_gettime(clock_id, tp) |
clock_id selects a clock. tp points to a struct timespec; POSIX represents it as seconds (tv_sec) and nanoseconds (tv_nsec), normalized so tv_nsec is from 0 through 999,999,999. |
POSIX returns 0 on success and -1 with errno on failure; an unsupported clock ID is EINVAL. Linux and BSD manuals document pointer errors, but exact error mapping is platform-specific. |
Implemented for IDs 0, 4 and 13 (FreeBSD's numbering; the game uses 4 and 13). Other IDs and pointer errors stop by name under the POSIX name, because errno is not modelled. |
gettimeofday(tv, tz) |
tv points to a struct timeval: seconds since the Epoch and microseconds (tv_usec from 0 through 999,999). The game passes null for tz. |
This is wall time and may jump; it is not a monotonic elapsed-time clock. Older POSIX specified 0 on success but left errors undefined. Linux reports -1/EFAULT for inaccessible pointers and ignores tz. POSIX.1-2024 removed the interface. |
Implemented from the host's wall clock with FreeBSD's amd64 struct timeval (#145). A non-null timezone stops by name. |
The numeric clock IDs in POSIX are implementation-defined. The game's two observed IDs, 4
(sceKernelClockGettime) and 13 (clock_gettime, from the C library's time()), match
FreeBSD's CLOCK_MONOTONIC and CLOCK_SECOND; Linux's numbers are not used.
getpagesize: PR, call-site addresses and what would settle it
Both getpagesize entries were registered as fail-loud unresolved diagnostics
(PR #66) until the maintainer's ruling
in #528.
The three call sites are 0x00e04168, 0x00e04939 and 0x00e05cf9; they cache the result at
0x05859ec8.
What would still settle it: one getpagesize() result observed on a console.
Threads and yielding
| Call | Status | What the runtime does |
|---|---|---|
scePthreadEqual |
implemented | Compares guest thread handles; zero means different. |
sched_yield |
implemented | Yields the host thread and returns zero. |
scePthreadYield |
implemented | Yields the host thread and returns zero (#308). |
pthread_self |
implemented | Answers what scePthreadSelf answers. |
scePthreadKeyCreate, scePthreadKeyDelete, scePthreadGetspecific, scePthreadSetspecific |
implemented | Per-thread values, following FreeBSD libthr's thr_spec.c. At thread exit each destructor runs, for up to four rounds; past the POSIX minimums (128 keys, 4 rounds) it stops by name (#298, by @EzequielRindello). |
A guest thread runs on a host thread. A thread handle is an opaque pointer to the runtime's object for that thread, so these calls work by comparing or returning those pointers.
scePthreadEqualasks whether two handles name the same thread. The runtime compares the opaque object pointers used as guest thread handles: zero means different, nonzero means equal. The exact nonzero value the PS4 returns, and its behavior for a null handle, are not established.sched_yieldlets other threads run. The runtime yields the calling host thread and returns zero, following the POSIX/FreeBSD contract. A host failure stops by name. The unit test checks the result; it cannot prove that the host scheduler ran another thread.- On macOS the registry is gathered the same way, from a section of the Mach-O binary instead of the ELF one (#216); Linux is unchanged.
- Darwin (macOS) versions by @evill33t, each tested on their own Macs, with Linux unchanged: timed locks and condition waits on native try-locks and relative waits that recheck the original deadline (#576), direct memory backed on Darwin (#580), and guest worker threads with their thread-local storage on x86-64 (#583). The game does not run on macOS yet.
scePthreadYielddoes the same (#308; Paleblood's own call notes were brought in line by contributor @EzequielRindello in #1184). Its PS4 signature is not published (FreeBSD's analogue returns nothing, Linux's returns an int), but answering zero is right either way: a caller of a function that returns nothing never reads the result, and zero is the int version's success. Every one of the game's 26 direct calls ignores the result.pthread_self(libScePosix) returns the calling thread's own handle. It answers exactly whatscePthreadSelfanswers. With no guest thread registered on the host thread, it stops by the name the guest used. POSIX defines no error return.
These are runtime services, not new decompiled game functions. The boots recorded on merged
main since then pass through them.
Threads and yielding: PRs, credits and test limits
Merged PR #62 and
PR #72, by
@EzequielRindello, add these narrowly scoped behaviors.
pthread_self was added by PR #95.
| Call | Runtime behavior | Evidence limit |
|---|---|---|
scePthreadEqual |
Compares the opaque object pointers used as guest thread handles; zero means different and nonzero means equal. | Synthetic tests cover identical and distinct handles and null values. They do not establish valid PS4 null-handle behavior, the exact PS4 nonzero result, or real multi-guest-thread execution. |
sched_yield(void) |
Yields the calling host thread and returns zero, following the POSIX/FreeBSD contract. A host failure stops by name. | The unit test checks the result; it cannot prove that the host scheduler ran another thread. |
scePthreadYield |
Yields the calling host thread and returns zero (#308). | The PS4-visible signature is unpublished; zero is right whether it returns nothing or an int, and all 26 direct call sites in the executable ignore the result. The test checks the result only. |
pthread_self(void) (libScePosix) |
Answers exactly what scePthreadSelf answers: the calling thread's own handle. With no guest thread registered on the host thread it stops by the name the guest used. |
POSIX defines no error return. The test compares it with scePthreadSelf and checks the stop on a fresh host thread; it does not show real multi-thread guest execution. |
The implementation is in
runtime/syslib/kernel_thread.c.
Thread attributes
| Call | Status | What the runtime does |
|---|---|---|
scePthreadAttrSetdetachstate, pthread_attr_setdetachstate |
implemented | Records the state; bad values give EINVAL. |
| Default detach state (fresh or copied attribute) | unresolved | Thread creation stops by name instead of assuming joinable. |
pthread_attr_init, pthread_attr_destroy |
implemented | Allocate and free attributes under the POSIX names. |
A thread attribute is a small object a program fills in before creating a thread: it describes how the new thread should start. The game creates and frees these objects, and sets one field of them, the detach state.
Creating and freeing attributes
eboot imports pthread_attr_init and pthread_attr_destroy from libScePosix, next to the SCE
names the runtime already had.
- Init allocates the attribute and stores it in the variable;
ENOMEMwhen it cannot (POSIX; FreeBSD libthr's_pthread_attr_init). - Destroy frees it and empties the variable;
EINVALfor a missing or empty variable (libthr's_pthread_attr_destroy). - A missing variable passed to init is undefined in POSIX and unchecked in libthr. The runtime answers
EINVALunder both names, as the SCE name already did and as the mutex attribute calls do. No PS4 source or call site says otherwise.
An attribute made under one name can be freed under the other.
Setting the detach state
eboot and libSceFios2.elf import scePthreadAttrSetdetachstate from libkernel, and eboot
imports pthread_attr_setdetachstate from libScePosix (symbols/imports.csv).
- What the call does. A thread created with the attribute starts detached for
PTHREAD_CREATE_DETACHED(nobody waits for it to finish) and joinable forPTHREAD_CREATE_JOINABLE(another thread can join it). This is POSIXpthread_attr_setdetachstate. - Invalid detach state. POSIX and FreeBSD's
pthread_attr(3)both make any other valueEINVAL. - Invalid attribute variable. POSIX leaves a null or uninitialised attribute undefined and only recommends
EINVAL, and the FreeBSD manual lists no error for it. The behaviour comes from FreeBSD libthr's_pthread_attr_setdetachstate(lib/libthr/thread/thr_attr.c), which returnsEINVALwhen the variable is null or holds no attribute object. - The numbers. FreeBSD's
<pthread.h>defines the two states as0and1. The OpenOrbis homebrew SDK header (include/orbis/_types/pthread.h) definesORBIS_PTHREAD_CREATE_JOINABLEandORBIS_PTHREAD_CREATE_DETACHEDwith the same values. That header follows FreeBSD's text, so it corroborates the numbers rather than measuring them independently.
The default nobody has measured
Two detach states come from the system rather than the game: the state a fresh attribute starts
with, and the one scePthreadAttrGet copies from a running thread. POSIX makes joinable the
default, but nothing we can cite confirms what the PS4 reports. In FreeBSD libthr,
_pthread_create (thr_create.c) uses that same default (_pthread_attr_default) when it is
given no attribute variable or an empty one. The runtime treats both cases as the unknown default,
so the outcome, a fatal, does not depend on the PS4 matching libthr there.
How the runtime keeps that open:
- Record only what was set. The attribute records a state only when one is set (
has_detach_state).scePthreadAttrGetreplaces the whole attribute, as libthr'spthread_attr_get_npdoes, so a state set before the copy is dropped. - Read through one function. By convention, thread creation reads the state through
rt_thread_attr_detach_state(runtime/include/runtime/process.h) and never from the field. A fresh attribute's field holds zero, which is the joinable value, so reading the field directly would assume joinable silently. - Stop when there is no answer. For no variable, an empty variable, or a state nobody set, the reader stops the process (
rt_fatal), names the call that asked, and says which of those cases it hit.
Thread attributes: PRs, credits and tests
Merged PR #95,
by @EzequielRindello, registers pthread_attr_init and
pthread_attr_destroy, following the same split as the mutex and detach-state calls: the POSIX
names return the FreeBSD error number itself, the SCE names 0x80020000 plus it, and an
attribute made under one name can be freed under the other.
The registry tests cover both error conventions and freeing across names. They do not establish a new boot result.
Default detach state: what would settle it
An observed scePthreadAttrGetdetachstate result on a console, for a fresh
attribute and for one filled by scePthreadAttrGet from the main thread. Guest call sites would
also settle it: a thread created without a detach state being set, then joined or detached
(scePthreadJoin, pthread_join and scePthreadDetach are imported).
Sleeping
| Call | Status | What the runtime does |
|---|---|---|
sceKernelUsleep, usleep |
implemented | Sleeps the host thread at least the requested time, then returns 0. |
usleep of a second or more |
unresolved | Stops by name. |
SCE error values for sceKernelUsleep |
unresolved | Stops by name. |
sleep (libScePosix) |
implemented | Sleeps the host thread at least the requested seconds, then returns 0 (#315, by @EzequielRindello). |
sleep of more than INT_MAX seconds |
unresolved | Stops by name. |
nanosleep (libkernel) |
implemented | Sleeps the host thread at least the requested seconds and nanoseconds, then returns 0; like usleep, an interrupted sleep resumes, so the time left is never written back (#351, by @EzequielRindello). |
nanosleep with no request, nanoseconds out of range, or negative seconds |
unresolved | Stops by name. |
Both calls pause the calling thread. They take one unsigned 32-bit count of microseconds and return
int. For sceKernelUsleep the game itself fixes that shape: the verified frame limiter and
swap-chain present functions call it that way and expect 0 back.
How the runtime answers. A guest thread runs on a host thread, so the host thread sleeps at
least the requested time and the call returns 0. A host signal is not a guest event, so an
interrupted sleep resumes with the time left.
What stays open, and each stops by name rather than guessing:
usleepwith 1,000,000 or more. Old SUSv2 allowedEINVALthere; FreeBSD sleeps. No PS4 source says which the guest gets.- Any SCE error value for
sceKernelUsleep. The game's call sites never check the result, and no public source names one. sleepof more thanINT_MAXseconds. FreeBSD's libc sleepsINT_MAXseconds and returns the rest; POSIX has no early return without a signal; no PS4 source says which the guest gets.nanosleepwith negative seconds. POSIX doesn't define it, FreeBSD returns0at once, and no PS4 source says which the guest gets. Its error cases stop too, since the runtime doesn't modelerrno.
Sleeping: PR, credits and tests
Merged PR #94, by @EzequielRindello, implements both.
The tests measure that each call lasts at least what was asked on the host's monotonic clock.
Stack protector
| Call | Status | What the runtime does |
|---|---|---|
__stack_chk_fail |
implemented | Ends the process by name; the stop is the whole contract. |
_exit |
implemented | Ends the process at once with the guest's status, as POSIX defines it (no atexit handlers, nothing flushed); under the boot harness the run is recorded as "exited with code N" first (by @EzequielRindello, #454). |
__stack_chk_guard |
implemented (maintainer's ruling) | A fixed, non-zero canary word, as other PS4 runtimes use; unbound, it read a zeroed page (#528). |
Code built with the compiler's stack protector places a canary value in each protected function's
stack frame. The function calls __stack_chk_fail when its saved canary no longer matches, meaning
that function's stack frame was overwritten. eboot, libSceFios2.elf and libc.elf import it
from libkernel.
Here the stop is the implementation: the LSB contract is void(void), the call never returns and
the program ends (FreeBSD's libc reports it and aborts). So the runtime stops the process by name,
and the entry counts as implemented, unlike the fail-loud diagnostics elsewhere on this page.
Not covered: the PS4's own message or crash report, which the guest cannot observe after it ends,
The canary itself, __stack_chk_guard, is a separate data import. Its PS4 value is not
established; since #528 the runtime gives it a fixed non-zero word (before, an unbound data
import got a zeroed page).
Stack protector: PR and credits
Merged PR #97, by @EzequielRindello, stops the process by name.
Memory operations
| Call | Status | What the runtime does |
|---|---|---|
memcpy, memset |
implemented | ISO C copy and fill; both return the destination. |
These are the two ISO C operations imported by libSceFios2.elf from libSceLibcInternal.
memcpy copies the requested bytes, and memset writes a value, converted to an unsigned byte,
across a region. Both return the destination. Undefined cases such as overlapping memcpy regions
and null pointers are not modeled.
Memory operations: PR and tests
Merged PR #82 supplies both. The registry tests cover the returned pointer, zero length, byte truncation, untouched bytes past the requested region, and coverage classification. These tests do not establish additional PS4 behavior or a new boot milestone.
Network: byte order, IPv4 text and network control
| Call | Status | What the runtime does |
|---|---|---|
sceNetHtonl, sceNetHtons, sceNetNtohl, sceNetNtohs |
implemented | Byte reversal between host and network order. |
sceNetInetPton, sceNetInetNtop |
implemented | IPv4 text to binary and back (#465), for AF_INET only; other cases, and a buffer too small for the text, stop. |
sceNetCtlGetState |
implemented | Reports disconnected and returns success. |
sceNetCtlCheckCallback |
implemented | Returns 0; no callback is due while disconnected. |
sceNetCtlRegisterCallback |
implemented | Stores the callback opaquely and returns an ID. |
sceNetCtlUnregisterCallback |
implemented | Removes a registration by its ID. |
sceNetCtlGetNatInfo |
implemented | Answers "not connected" and writes nothing, so the game falls back to its own NAT type (#380). |
sceNetCtlGetInfo |
implemented (IP address only) | Asked for the IP address (code 14), it answers "not connected" and writes nothing (#461); any other code stops by name. |
sceNetInit, sceNetTerm, sceNetPoolCreate |
implemented | Start the network library offline; a repeat start answers "already initialized". |
sceSslInit, sceHttpInit, sceHttpCreateTemplate, sceHttpSetNonblock, sceHttpCreateEpoll, sceHttpAddRequestHeader |
implemented | Set up the game's HTTP client offline: each step is only an ID; nothing is ever sent. |
sceHttpWaitRequest |
implemented | The game's network worker polls for finished requests; offline none was ever sent, so it answers "no events" (#303). |
sceHttpTerm, sceHttpDeleteTemplate, sceHttpDestroyEpoll, sceHttpAbortWaitRequest, sceSslTerm, sceNetPoolDestroy |
implemented | Shut the offline network, SSL and HTTP set-up down again: each frees its ID; an ID that is not live answers "invalid id" (#451). |
sceHttpsEnableOption, sceHttpsDisableOption |
implemented | Set and clear a template's HTTPS options and keep them for a request that is never sent (#381). |
sceNetErrnoLoc, sceNetEpollCreate, …Wait, …Abort, …Destroy |
implemented | The network library's own error variable, and waiting sets on which no socket ever becomes ready: a wait ends only by its timeout, an abort or a destroy (#386). |
These are deliberately limited offline paths, not network connectivity or PSN support.
Byte order
Network protocols send integers big-endian ("network order"); the CPU may store them the other
way round ("host order"). Paleblood imports four integer conversion calls from libSceNet in
eboot: sceNetHtonl, sceNetHtons, sceNetNtohl, and sceNetNtohs. Their public SCE
declarations use unsigned 32-bit and 16-bit integer arguments and results. The documented contract
converts between host order and big-endian network order; the reverse direction uses the same
operation. For the project's AMD64 guest ABI, this is byte reversal. The four calls are pure value
conversions and do not require socket or online state.
This evidence supports only these four conversions. It does not establish behavior for libSceNet
sockets, name resolution, epoll, or offline-state queries. Those imports remain unimplemented until
their own evidence is available.
IPv4 text to binary (sceNetInetPton)
inet_pton turns an address written as text, such as dotted decimal, into its binary form. The
game was seen calling it in four places, each passing address-family value 2 (AF_INET) and using
the result as an IPv4 address.
For that observed path, the implementation parses dotted-decimal text into four network-order
bytes, returns 1 for a valid address and 0 for malformed text, and performs no network I/O. The
original call sites support the family and output use; the parser's accepted text forms come from
the public BSD inet_pton(3) contract. Other address families and PS4 null-pointer error behavior
are not established, so the runtime fails loudly for those cases rather than choosing host-specific
results.
Offline network control (libSceNetCtl)
The executable imports six calls from libSceNetCtl. They report connection state and let the game
register a callback for state changes. Four currently provide a constrained offline behavior:
sceNetCtlGetStatewrites the disconnected value (0) and returns success. The game checks0and3; the disconnected interpretation is cross-checked against the public API family. The meanings of intermediate states and PS4 error behavior for a null pointer remain unknown.sceNetCtlCheckCallbackreturns0; while the runtime remains disconnected, no state-change callback is due. Behavior for a connected state is not implemented or established.sceNetCtlRegisterCallbackstores an opaque callback and argument under a nonzero ID written to the caller's output slot. Callback invocation and PS4 error values for invalid pointers or allocation failure remain unresolved.sceNetCtlUnregisterCallbackremoves a registration by its returned ID. PS4 behavior for unknown or repeated IDs remains unresolved and fails loudly.
The registration call sites show the callback, argument, and output-ID slot; the guest later passes the returned ID to unregister. The callback pointer is kept opaque and never called. Static call-site evidence establishes these shapes, not every PS4 error case.
sceNetCtlGetNatInfo asks what kind of network address translation the connection is
behind. The game writes the structure's size (16) first and reads only the NAT type at offset 8,
and only on success; on any other answer it assumes NAT type 1 itself. Offline the runtime answers
"not connected" (0x80412108) and writes nothing, so the game's own fallback applies (#380).
The structure's layout and the error value come from public sources of other PS4 runtimes, as
facts; a size other than 16 stops by name.
sceNetCtlGetInfo is answered for the one code the game asks for, 14, which public PS4
headers name the IP address: a disconnected console has none, so the runtime answers "not
connected" (0x80412108, the value sceNetCtlGetNatInfo uses) and writes nothing (#461). Any
other code still stops by name: a disconnected console may still describe its device or link,
and that answer is not established.
Network: sources, PRs and tests
Byte order. The declaration reference (see References) is PSP2SDK's public net.h API
surface; it supplies the SCE function names and integer widths, not a PS4 runtime trace. The
FreeBSD manual documents the standard host/network conversion contract.
sceNetInetPton (issue #41). Merged Paleblood PR #63
adds this import using the documented BSD inet_pton(3) AF_INET contract. Unit tests cover
valid, malformed, truncated, unsupported-family, and null-pointer inputs; these are synthetic
runtime tests, not additional original-game execution or function-verification evidence.
libSceNetCtl. The four offline behaviors are based on Paleblood PR #59 and its
source-level tests. The unit tests exercise Paleblood's synthetic implementation; they are not
original-game execution or console validation. Merged Paleblood PR #61 registers
sceNetCtlGetInfo and sceNetCtlGetNatInfo as unresolved entries, leaves them callable for
named diagnostics, and excludes them from implementation coverage.
sceNetInetPton: call-site addresses and executable hash
Inspection of the exact local Bloodborne 1.09 executable found four unconditional call
instructions, at 0x0085785e, 0x011c7a7b, 0x02f984f6, and 0x02df348d; each passes
address-family value 2 and consumes the result as an IPv4 address. The local executable used for
that inspection has SHA-256 ca8813862d7b1345a6791b7d88cc1d383ede2a6bbc944f39dd3c0e0e3ad9e285
(the file and disassembly remain outside the public repository).
libSceNetCtl: full table
| Call | Implemented offline behavior | Evidence limit |
|---|---|---|
sceNetCtlGetState |
Writes the disconnected value (0) and returns success. The game checks 0 and 3; the disconnected interpretation is cross-checked against the public API family. |
The meanings of intermediate states and PS4 error behavior for a null pointer remain unknown. |
sceNetCtlCheckCallback |
Returns 0; while the runtime remains disconnected, no state-change callback is due. |
Behavior for a connected state is not implemented or established. |
sceNetCtlRegisterCallback |
Stores an opaque callback and argument under a nonzero ID written to the caller's output slot. | Callback invocation and PS4 error values for invalid pointers or allocation failure remain unresolved. |
sceNetCtlUnregisterCallback |
Removes a registration by its returned ID. | PS4 behavior for unknown or repeated IDs remains unresolved and fails loudly. |
The game's HTTP client. Early in start-up the game builds an HTTP client for its online features: it starts the network library, makes a memory pool, an SSL context, an HTTP context, a request template with its user agent, and a waiting handle, then adds a request header. The runtime is offline, so each of those is only an ID the game passes back; any call that would actually send something stops by name. PRs #157, #158, #159 and #160.
HTTPS options. The game's HTTP wrapper turns server verification on or off on its template. The runtime keeps each template's option bits (a new template starts with server verification, the name and known-CA checks and SNI on) for when a request is sent, which offline never happens (#381).
Network waits. The game's network thread creates a waiting set (an "epoll" set) and waits on
it. Offline no socket ever becomes ready, so a wait returns no events when its timeout passes, or
is cut short when the game aborts or destroys the set. A failing network call sets the network
library's own error variable, separate from the C library's errno, which sceNetErrnoLoc points
at (#386).
System modules (libSceSysmodule)
| Call | Status | What the runtime does |
|---|---|---|
sceSysmoduleLoadModule, sceSysmoduleIsLoaded, sceSysmoduleUnloadModule |
implemented | Answer for stub modules and for system modules the runtime provides itself; every other case stops by name. |
A system module is a PS4 library the game can ask for at run time. The executable asks for system
modules by id through sceSysmoduleLoadModule, sceSysmoduleIsLoaded and
sceSysmoduleUnloadModule; it imports no other loader entry.
Five of the seven modules the title ships are recorded in Paleblood's module list as stubs: the executable imports nothing from them, so they are not mapped. Their public ids come from the OpenOrbis toolchain's list. System modules the game does not ship but loads by id (app content, PlayGo, trophies and the PSN libraries, for example) are listed as provided by the runtime once it implements the calls the game imports from them; loading one is answered the same way, and its imports go to the runtime's own entries.
How the runtime answers, for those modules:
- A load marks the module loaded and succeeds without mapping anything.
- A query of a loaded one answers
0. - An unload clears the mark.
Everything else stops by name: a module that is not a stub (the runtime cannot load system modules yet), a second load of a loaded stub, and a query or unload of a stub that is not loaded. The error values for those cases are not public.
The boot recorded on 6 November 2026 (#443) shows which modules the game loaded: none of the five stubs it ships, and nine system modules the runtime provides (app content, PlayGo, trophies, and the PSN utility, matchmaking, score ranking, authentication, profile dialog and signalling libraries).
System modules: PR and credits
Merged PR #83, by @adurham, answers those three calls for the stub modules only.
Creating threads and waiting
| Call | Status | What the runtime does |
|---|---|---|
scePthreadCreate |
implemented | Runs the guest's entry on a new host thread with its own stack and thread-local storage. |
scePthreadSetaffinity |
implemented | Records the CPU mask; the host schedules the thread. scePthreadGetaffinity answers it back, or 0x3f for a thread nobody set a mask on (#585). No thread answers "no such thread", which the game's job system ignores for its empty worker slots (#310). |
pthread_create_name_np |
implemented | The POSIX name for the same thread creation (#310). |
scePthreadAttrSetstacksize, pthread_attr_setstacksize |
implemented | Records the size; below 16 KiB it answers "invalid", as the game expects. |
scePthreadAttrSetschedpolicy |
implemented | Records FIFO, other or round-robin. |
sceKernelCreateSema … sceKernelPollSema |
implemented | Counting semaphores: create, wait, signal, poll, delete. A semaphore created for priority order wakes its best-priority waiter first (#426). |
scePthreadExit |
implemented | Ends the calling thread exactly as a return from its entry function would (#389, #399). |
pthread_cond_* |
implemented | Condition variables; a recursive mutex is released completely for the wait. pthread_cond_timedwait waits until a wall-clock time and is never early; a time already passed answers ETIMEDOUT with the mutex taken back (#353, by @EzequielRindello). Open: a change of the wall clock during the wait isn't followed. |
Module thread-local storage (__tls_get_addr) |
implemented | Each loaded module's thread-local data is set up before the game's code starts: the executable reuses its static block, and the others get a copy of their initial bytes, zero-filled and aligned (#227, by @evill33t). Threads the game creates get the executable's static block but no module blocks yet, so a module lookup there stops by name. |
pthread_mutex_lock, pthread_mutex_unlock (libkernel) |
implemented | Since #224 (by evill33t): the same POSIX (error-number) answers as the libScePosix names, which the system library also exports from libkernel. |
sceKernelGetCompiledSdkVersion |
implemented | Since #215 (by evill33t): the SDK version the executable was built with, read from its own process parameters (PT_SCE_PROCPARAM); an inconsistent record stops by name. |
| Mutex ownership | implemented | Since #241 (by EzequielRindello): unlocking, or waiting on a condition with, a mutex the caller does not own answers EPERM for every type; an adaptive mutex locked again by its owner answers EDEADLK; a normal one stops by name (FreeBSD libthr would wait forever). |
scePthreadGetprio, scePthreadSetprio |
implemented | Records each thread's priority; the main thread starts at 700. |
scePthreadAttrSetschedparam, scePthreadAttrSetaffinity |
implemented | Record a priority and CPU mask on the attribute. |
scePthreadAttrGetaffinity |
implemented | Writes eight bytes: the mask set on the attribute, or copied from a thread by scePthreadAttrGet, otherwise 0x3f, the six CPUs 0 to 5 (#585, maintainer ruling of 11 November, which replaced the all-ones default of 10 November). No attribute is EINVAL; no mask variable stops by name (#561). |
_sigprocmask |
implemented | Keeps each thread's blocked-signal set; no signal reaches the game yet. |
sigprocmask, sigfillset, scePthreadRename |
implemented | The same per-thread signal mask under the libkernel name, a full signal set, and a thread name of up to 31 bytes (#469). |
scePthreadJoin, scePthreadDetach, scePthreadOnce, scePthreadAttrSetinheritsched |
implemented | Wait for a thread to end and collect it, or let it be collected when it ends; run a set-up routine exactly once; start a thread at its creator's priority or the attribute's. FreeBSD's error order; joining the main thread stops by name (#460). |
pthread_create, pthread_join, pthread_exit, pthread_attr_setschedparam |
implemented | The POSIX names of the same calls (#460). |
scePthreadMutexTimedlock, scePthreadRwlockTimedrdlock, scePthreadRwlockTimedwrlock |
implemented | Wait for a lock for at most a given number of microseconds on the monotonic clock, then answer ETIMEDOUT (#464). |
sceKernelCreateEqueue, sceKernelWaitEqueue, sceKernelDeleteEqueue |
implemented | Event queues: a thread waits until the runtime raises an event, such as a finished frame flip. |
A game keeps many threads busy at once: loading, audio, rendering, the game's own logic. These calls let the game start those threads and make them wait for one another.
Starting a thread. The game describes a thread with an attribute object (stack size, scheduling policy, whether anyone will wait for it to finish), then creates it. The runtime gives each guest thread its own stack and its own copy of the game's thread-local data, then runs the game's entry function on a new host thread. The game asks for a 16 KiB stack again whenever a smaller size is refused, which is how the runtime knows the smallest size it should accept.
Waiting. A semaphore holds a count. A thread that needs a unit waits until another thread signals one. Condition variables do the same job for the POSIX side of the game's libraries. Waiters are served in the order they arrived, or, for a semaphore the game creates with priority order, by thread priority: the most urgent (smallest number) first, equal priorities in arrival order (#426). Before that change a second waiter on such a semaphore stopped the boot by name, which happened in some boots and not others, depending on thread timing.
Ending a thread. A thread can end itself early with scePthreadExit. The runtime cannot
unwind the game's stack frames with the host's tools, so it marks the point where it starts the
game's entry function and jumps back there: the thread then ends exactly as if its entry had
returned, keeping the value for a join and running its per-thread destructors (#389).
It uses the compiler's own setjmp/longjmp: the C library's checked longjmp, which some
compilers switch on by default, can refuse a jump from the game's stack to the host's (#399).
Thread handles fit in 40 bits. The game's own lock code stores the owner thread's handle in only 40 bits, then compares it with the full handle. A handle above 2^40 would never match, and the thread would wait forever on a lock it already held. A local boot hung exactly there. The host's memory lies above that limit, so the runtime now places its thread objects in a range below it.
Priorities. Every thread has a priority from 256 (most urgent) to 767. The game never declares its main thread's priority, so it starts at the console's default, 700; new threads inherit their creator's, and the game then sets each one explicitly. The runtime records them; your computer's own scheduler decides which thread runs.
Signal masks. The C library saves and restores each thread's set of blocked signals whenever
the game uses setjmp and longjmp. No signal is delivered to the game yet, so the runtime keeps
the set for each thread and gives it back unchanged.
Threads and waiting: PRs, call sites and what stops by name
- PRs #144 (semaphores), #147 (condition variables), #148 (attribute setters), #149 (thread creation) and #155 (handles below 2^40), #161 (signal masks), #162 (recursive condition waits), #163 and #168 (priorities and attributes) and #179 (event queues).
- The 16 KiB retry is at
0x02a3b383; the 40-bit lock is at0x024368c0. - Stops by name: creating a thread without an attribute, a stack size or a detach state; a stack the guest supplies; an empty CPU mask; a semaphore wait with a timeout; a wait for more than one unit behind another waiter; a thread exit from a destructor or from the main thread.
Memory: direct and flexible
| Call | Status | What the runtime does |
|---|---|---|
sceKernelGetDirectMemorySize |
implemented | Answers the size of the runtime's own pool (5 GiB). |
sceKernelAllocateDirectMemory |
implemented | Hands out a range of the pool. |
sceKernelMapDirectMemory |
implemented | Maps an allocated range; GPU access is accepted, and so is the no-overwrite flag (#423). |
sceKernelReleaseDirectMemory |
implemented | Gives a whole, unmapped range back. |
sceKernelMapFlexibleMemory |
implemented | Maps fresh zeroed memory that is not part of the pool. |
sceKernelQueryMemoryProtection |
implemented | Answers the protection the game asked for when it mapped the memory, GPU bits included, and the mapping's start and end (#422). |
sceKernelVirtualQuery |
implemented | Describes the mapping that holds an address: where it starts, and where it sits in direct memory. |
sceKernelMunmap, sceKernelMprotect |
implemented | Remove, or change the protection of, one whole mapping the runtime made; after an unmap, the direct range can be released. Part of a mapping, or several, stops by name (#467). |
sceKernelGetDirectMemoryType |
implemented | The type, start and end of the allocated range holding an offset; an offset outside every range stops by name (#467). |
The PS4 has two kinds of memory a game asks for. Direct memory is physical memory: the game first reserves a range of it, then maps that range into its address space, and two maps of the same range see the same bytes. Flexible memory is memory the system simply hands over.
The runtime backs direct memory with one shared host memory file, so the "same bytes" rule holds.
The pool's size is the runtime's choice, not a measured PS4 value. The game maps some memory for
both the CPU and the GPU. The runtime accepts the GPU flags and maps the memory for the CPU; with
the display on, the renderer hands the same memory to your GPU (see "Where maps go" below). Since
#616 the CPU's writes to that memory are noticed through page protection, so the renderer reloads
a texture only when its memory changed, and since #642 pages under a render target the GPU has
drawn into are closed to the CPU until the drawing is copied back: a read or write there pauses the
thread while the renderer writes the target back, then goes on. The kernel does not pause a system
call that way, so the runtime first makes such memory current before handing it to a file read or
write, the small memory save or the C library's output, and before sceKernelMprotect changes it. The PS4 limits how much flexible memory a game may use; that budget is
not established, so the runtime does not enforce one.
Asking about memory. The game sometimes asks whether a piece of memory it mapped can be read by the CPU or by the GPU. The runtime remembers every mapping with the access the game asked for, including GPU access, and answers from that. Asked for a start and an end too, it gives the mapping's first address and the address just past its last byte (#422), as other PS4 runtimes answer; the game's movie code asks this way. A direct map can also be asked for at a particular address, and goes exactly there when that range is free.
Mapping memory twice. The movie code maps part of its own direct memory a second time, with the "no-overwrite" flag and no address. That flag only forbids replacing memory that is already mapped, which the runtime never does anyway, so it is accepted and the second map shows the same bytes as the first (#423).
Where maps go. When the game lets the system pick the address, a map the GPU will read goes at a fixed base plus its place in the pool, so the renderer can give the GPU the whole pool as one buffer and reach every such address at one fixed distance. Other maps go anywhere free above that region, and an address the game asks for is kept (#348). A boot maps each range once, so a second GPU-visible map of a range, which would need the same place, stops by name.
Bounds. A reservation must fit wholly inside the range the game searches, and a map must fit inside one reservation. The runtime checks lengths by subtraction, so a huge length cannot wrap around the end of the address space and slip past the checks (#226, by @evill33t). These are the runtime's own limits; the PS4's error codes for such calls are not established.
Memory: PRs, call sites and what stops by name
- PRs #143 (direct memory), #154 (GPU access) and #156 (flexible memory), #175 (protection queries) and #176 (maps at a requested address) and #177 (virtual memory queries), #422 (start and end) and #423 (no-overwrite).
- The game's maps use protection 3 (CPU read and write) and
0x33(CPU and GPU read and write); its only flexible map is at0x02481dbe. - The movie code's second map is at
0x02d032b9and its start-and-end query at0x02d031df. - Stops by name: map flags other than no-overwrite (
0x80), other protection bits, lengths that are not whole 16 KiB pages, a range that does not fit, and releasing part of a range or a mapped one.
Console services at start-up
| Call | Status | What the runtime does |
|---|---|---|
sceUserServiceInitialize, …GetInitialUser, …GetLoginUserIdList |
implemented | One user, logged in from the start. |
sceUserServiceGetUserName, sceUserServiceGetEvent |
implemented | The user is called Hunter; no one logs in or out during a run, so every event poll answers "no event" (#372). |
sceCommonDialogInitialize |
implemented | Succeeds once; a repeat answers "already initialized". |
sceSystemServiceParamGetInt |
implemented | Answers the console language you choose (English, United States, by default). |
sceAppContentInitialize, sceAppContentAppParamGetInt |
implemented | Answers the title's own parameters from your copy's param.sfo. |
sceAppContentGetAddcontInfoList |
implemented | Lists the add-ons you say you own (tools/boot.py --addcont LABEL); none by default (#392). |
sceSystemServiceHideSplashScreen, sceSystemServiceGetStatus |
implemented | Takes down the boot splash; reports no system events, nothing overlaid, in the foreground (#396). |
scePlayGoInitialize, …Open, …GetChunkId, …GetLocus, …SetInstallSpeed |
implemented | Every part of the package is installed; the install speed is recorded (#370, #405). |
sceNpSetContentRestriction |
implemented | Records nothing: the runtime is offline and has no online content. |
sceSystemServiceReceiveEvent |
implemented | The runtime raises no system events, so it answers "no event" and writes nothing (#466). |
Before the title screen the game asks the console a few questions: who is playing, which language to use, and what its own package says about itself.
- The user. The runtime models one user, the person running it, logged in from the start.
- The language. The language is a console setting, so you choose it:
tools/boot.py --system-param 1=18picks English (United Kingdom), for example. - The title's parameters. These come from your own copy's
param.sfo. Paleblood ships none. - Repeats. The game initializes some services twice. In each case its second call accepts one exact "already initialized" error, and the runtime answers that error.
- The user's name and events. The name is the runtime's choice,
Hunter. A thread of the game polls for login and logout events every 33 ms; no user logs in or out during a run, so each poll answers "no event" (#372). - Add-ons. The game asks which add-ons (DLC) are installed. The runtime lists only the ones
the person running it owns and names, each as installed; by default none. The Old Hunters is
SPEXPANSIONDLC03; its data already ships with patch 1.09, so the entitlement is all it needs (#392). - The splash screen and system status. When its own screens are ready, the game tells the system it may take down the boot splash; the runtime notes that, a useful sign of how far a boot got. The game also polls the system's status; the runtime has no system menu or events, so it always answers: nothing pending, nothing overlaid, in the foreground (#396).
- The install service (PlayGo). A PS4 game can start before its whole package is installed and
asks PlayGo which parts ("chunks") are present. On the runtime the whole game is always there, so
every chunk is reported ready; the number of chunks (3 for this title) comes from your copy's
sce_sys/playgo-manifest.xml(#370). The install speed the game asks for is recorded and changes nothing (#405).
Console services: PRs, call sites and what stops by name
- PRs #146 (app content), #150 (user service), #151 (common dialog), #152 (system language) and #153 (content restriction), #370 and #405 (PlayGo), #372 (user name and events), #392 (add-ons) and #396 (splash screen and status).
- The event poll is at
0x025628e4, the add-on count query at0x023b67cf, the splash call at0x01d5d995, and the PlayGo calls at0x023dd67a-0x023deb30. - The "already initialized" answers are
0x80960003(user service, accepted at0x010ba1ac) and0x80b80002(common dialog, accepted at0x02023fbb). All nine language reads ask for setting 1. - Stops by name: a service call before initialize, a setting nobody gave, a title parameter your copy does not declare, and missing arguments.
The controller
| Call | Status | What the runtime does |
|---|---|---|
scePadInit, scePadOpen, scePadClose |
implemented | One standard controller, the one user's, always connected (#373). |
scePadReadState |
implemented | At rest by default; with --input host, your gamepad and keyboard (#431). |
scePadGetControllerInformation |
implemented | A DualShock 4's touch pad size (1920 × 942) and stick deadzones of 13, the runtime's choice. |
scePadSetVibration |
implemented | Keeps the motor speeds, and with --input host rumbles your gamepad. |
scePadResetOrientation, scePadSetAngularVelocityDeadbandState, scePadSetTiltCorrectionState |
implemented | Motion is not modelled (the controller never turns), so each answers success and changes nothing (#462). |
sceMouseInit, sceMouseOpen, sceMouseRead, sceMouseClose |
implemented | No mouse is plugged in: a read gives one record that says "not connected" (#462). |
The game reads its controller's latest state with scePadReadState (not the buffered history),
and asks for the controller's details (the touch pad's size and the sticks' deadzones). The
runtime models one standard controller that is always connected.
- By default (
--input none) the controller is at rest: no button pressed, both sticks centred, the triggers released. CI and recorded boots see exactly the same state every time. - With
--input host(and a window,--display window) your first gamepad and the window's keyboard drive it through SDL3: buttons by position (south is cross, east circle), sticks, triggers, up to two touches on a DualShock 4 or DualSense touch pad, and vibration to your gamepad's motors (#431). The keyboard works with or without a gamepad: W A S D move the left stick, the arrow keys the right one, I J K L the D-pad, Return or Space is cross, Backspace circle, R square, F triangle, Q and E L1 and R1, Z and C L2 and R2, Escape options. - With
--input-script SPECa timed script presses the buttons, for unattended boots without a person at the controller (#447). Each event is a time, in seconds or in presented frames, then the buttons or stick directions it holds, for example560f:down,620f:cross. A malformed script is refused before the boot, naming the event. Recorded boots never use it. - Walks steer instead of pressing on a clock (#975). A route timed by the clock drifts from
run to run (a slower frame, a door that opens later) and can end against a wall. A script step
such as
20:walk -10 4.5 within 1.5 every 6*90pushes the left stick fully towards a ground position until the character is within the given distance, aiming again every few presented frames, and gives up after its time limit so the script goes on. The walk is not told the camera: it compares the stick's direction with the way the character actually moved since the last aim and corrects for the difference. A character that barely moved is treated as stuck and sidesteps at growing angles, alternating sides. Walks run in script order, and a+SECONDStime counts from the end of the walk before it, so a press that belongs to a place (opening a door) follows the walk that leads there. - Where the character is comes from the game library, not the runtime: the boot looks up an
optional
bbgame_player_positionin it and refuses a script with a walk when the library has none. This game's version reports the player position that the game's own Havok navigation debug display already reads; while there is no character, during a loading screen for example, the walk waits with the stick at rest. In one local boot in Iosefka's Clinic, twelve walks took the player from the operating table, through the door and down the stairs to the first enemy, each arriving within a unit of its target; the clock-timed route it replaced did not play back the same way twice. - Not modelled: the motion sensors. The units and axes the system reports them in are not established, so acceleration and rotation stay zero.
Controller: PRs, call sites and sources
- PRs #373 (one controller at rest), #431 (host input), #447 (scripted input) and #975 (walks).
- The game clears exactly the 120-byte state block before each
scePadReadState(0x02a90168,0x02a91948) and then tests the "connected" byte at offset0x4c. It treats a stick within0x80± the deadzone as centred. Vibration is set at0x02a9c7c1and stopped at0x02a9c822. - Layouts and button bits from the OpenOrbis homebrew SDK's
Pad.h; the touch pad size from the Linux kernel's DualShock 4 driver. - Stops by name: a second initialize, another user or port type, an unknown handle, and the orientation and motion-sensor setters, which stay unbound until a boot reaches them.
The clock and the calendar
| Call | Status | What the runtime does |
|---|---|---|
sceRtcGetCurrentClockLocalTime |
implemented | Your computer's local time, as the console gives the time its owner set (#378). |
sceRtcGetTick, sceRtcSetTick, sceRtcGetTickResolution |
implemented | Ticks are microseconds since 1 January of year 1, a million a second (#378). |
sceRtcGetDayOfWeek |
implemented | 0 for Sunday to 6 for Saturday (#379). |
sceRtcSetTime_t, sceRtcConvertUtcToLocalTime, sceRtcConvertLocalTimeToUtc, sceRtcFormatRFC2822LocalTime, sceRtcGetCurrentNetworkTick |
implemented | Unix time to ticks, your computer's time zone and daylight saving rule, dates written as Mon, 02 Nov 2026 15:05:09 +0100, and the network tick from the wall clock. A local time that a daylight-saving change skips or repeats stops by name (#466). |
The game asks for the local date and time in about 60 places and turns it straight into "ticks", a single number it can compare and subtract. The executable holds no constant that ties ticks to another starting point, so the runtime's convention (microseconds since year 1) is safe as long as it is the same in every call, which it is: setting a tick gives back exactly the date it came from. The day-of-week numbering (Sunday first) comes from another PS4 runtime's public notes, used as a fact; an older PSP library numbered Monday first, which is why this call waited for evidence before it was implemented.
Clock: PRs and what stops by name
Save data and trophies
| Call | Status | What the runtime does |
|---|---|---|
sceSaveDataInitialize, …Mount, …Umount, …SetParam, …SaveIcon, …DirNameSearch, …Terminate |
implemented | Saves in a folder on your computer, seen by the game as /savedataN (#402). |
sceSaveDataSetupSaveDataMemory, sceSaveDataGet/SetSaveDataMemory |
implemented | The small memory-backed save, kept in one file (#402). |
sceSaveDataDelete |
implemented | Removes a save's folder; a mounted save answers "busy". Another title's saves, or a save that is not there, stop by name (#459). |
sceDiscMapIsRequestOnHDD |
implemented | The file library asks whether a read is on the hard disk; the game is served from files with no disc, so the runtime answers "no bitmap" (0x81100004) and the library treats the request as not mapped (#459). |
sceNpTrophyCreateContext, …CreateHandle, …RegisterContext, …UnlockTrophy, …GetGameInfo, …GetTrophyInfo |
implemented | Trophies unlock offline and are kept with your save data (#405). |
Save data. The game's saves live in a folder you choose (tools/boot.py --savedata DIR);
without one, each boot gets a new, empty folder, so boots start alike. A mounted save appears to the
game as /savedata0, /savedata1 and so on, read through the same file calls as the game's own
files. Since #641, --savedata-from DIR (for unrecorded boots) starts a run's new folder as a copy
of a folder an earlier run kept, which itself never changes: the game autosaves once the contract is
finalised, so a boot can choose Continue at the title and go straight on from there. A few answers
depend on the SDK version the game was built with (2.00 for this executable),
which the runtime reads from the executable itself. The files are the runtime's own layout, not a
console's.
Trophies. The game creates a trophy context for its user, registers it and unlocks trophies by number. The runtime records each unlock with its time in the save folder, so unlocks survive across runs when you keep that folder. The trophy names and grades are in the game's encrypted trophy file, which the runtime cannot read, so it knows none of them and never awards a platinum.
Save data and trophies: PRs, sources and what stops by name
- PRs #402 (save data) and #405 (trophies). Layouts, limits and error values come from public sources of other PS4 runtimes and Bloodborne ports, checked against the OpenOrbis headers; the code is the runtime's own. The full list is in the runtime call reference.
- Stops by name: another title's saves, the free-space check, backup copies, and a memory-backed read or write past the size set up. Deleting a save and the save data dialog stay unbound until a boot reaches them.
PSN, offline
| Call | Status | What the runtime does |
|---|---|---|
sceNpSetNpTitleId |
implemented | Keeps the title's PSN id; the secret is not kept (#382). |
sceNpGetState, sceNpCheckCallback, sceNpRegisterStateCallback, sceNpUnregisterStateCallback, sceNpRegisterGamePresenceCallback |
implemented | The user is signed out for the whole run; callbacks are kept and never called, because nothing changes (#385, #400). |
sceNpMatching2Initialize, sceNpMatching2Terminate |
implemented | Start and stop the matchmaking library; nothing is ever sent (#385). |
sceNpGetNpId, sceNpGetOnlineId, sceNpCheckNpAvailability, sceNpCheckPlus, sceNpPollAsync and the other identity and Plus calls |
implemented | A console that is not signed in: identity calls answer "signed out", each check completes at once with that result, and the Plus callback is kept but never called (#450). |
sceNpAuthCreateAsyncRequest, …GetAuthorizationCode, …PollAsync, …DeleteRequest |
implemented | Requests are created and deleted; the authorization code cannot be had signed out, so the game takes its failure path (#461). |
The runtime never contacts a network. To the game, its user is simply signed out of PSN, and stays signed out: the state never changes, so no state callback is ever due. The game still registers its title id and starts its matchmaking library at start-up, and both succeed offline.
PSN: PRs and call sites
- PRs #382 (title id), #385 (sign-in state, callbacks, matchmaking) and #400 (the runtime can read back the callbacks it keeps, for a future online path; this also fixed a Clang 23 build).
- The title id is set at
0x010ba192, the presence callback registered at0x010b8386, and matchmaking started at0x010ba2d0.
Sound
| Call | Status | What the runtime does |
|---|---|---|
sceAjmInitialize, sceAjmModuleRegister |
implemented | Start the audio decoder with the one codec the game registers, ATRAC9. |
sceAjmInstanceCreate, the batch calls (sceAjmBatchJob…, …StartBuffer, …Wait, …Cancel) |
implemented | Decode the game's ATRAC9 sound with LibAtrac9 (#398). |
sceAudioOutInit, sceAudioOutOpen |
implemented | Open the game's two output ports (256 float samples at 48 kHz, eight channels) and the movie player's (1024 samples, #420). |
sceAudioOutSetVolume |
implemented | Records each channel's volume. |
sceAudioOutOutput |
implemented | Takes one block every 5.33 ms, as a real port would; with --audio host it plays the block on your computer (#406). With no block (the movie player's sound thread has nothing to give) it waits for room and hands nothing over (#481). |
sceAudioOutGetPortState |
implemented | Reports a port as heard only while it plays on your computer. |
Bloodborne mixes its sound in eight channels (7.1) and hands the console one block of 256 samples at a time, 48,000 samples a second. Its audio thread has no timer of its own: handing over a block blocks until the console has room for the next, so the output call is what keeps the game's audio in time. The runtime takes one block every 5.33 ms, exactly as fast as real playback.
Decoding. The game's sounds are stored compressed as ATRAC9, and its sound engine (FMOD) hands them to the console's audio job manager in batches of jobs: set up a decoder, then decode so many frames into a buffer. The runtime runs each batch when the game starts it and decodes with LibAtrac9 (MIT, by Alex Barney, included unmodified in Paleblood) (#398). The tests use a stand-in decoder, because no ATRAC9 data may be kept in the repository.
Playing it. Boots are silent by default. With --audio host each port plays through SDL3 on
your default sound device, each channel at the volume the game set, and the output call waits
while more than four blocks are queued, so the game's audio runs at your device's pace
(#406). In the maintainer's local runs the game's own music and sounds start after about
17 seconds; that is an observation, not a saved record.
The movie player's sound gets a port of its own: 1024 samples at 48 kHz, in a format chosen from the movie's channel count (#420).
Sound: PRs and call sites
- PRs #166 (audio decoder start-up), #167 (output ports and volume) and #169 (real-time pacing) and #174 (port state), #398 (ATRAC9 decoding), #406 (sound on the host) and #420 (the movie's port).
- The game creates its ATRAC9 decoders at
0x01118d9a, with one to eight channels, 16-bit samples and gapless looping. The movie's port is opened at0x02c225aeand0x02c22842. - Stops by name: codecs other than ATRAC9, sample formats other than 16-bit, resampling, and any port the game was not seen to open.
- The output format is the game's own evidence: its callback at
0x0111b600asks for format4 | (channels == 8), so 5 is float with eight channels.
Movies
| Call | Status | What the runtime does |
|---|---|---|
sceAvPlayerInit, …PostInit, …AddSource, …Start, …Stop, …Close and the other movie player calls |
implemented | Opens the movie from your copy and decodes it with FFmpeg on your computer (#419). |
sceAvPlayerGetVideoDataEx, sceAvPlayerGetAudioData |
implemented | Hand the game each picture and block of sound when the movie's clock reaches it. |
The game plays its movies (H.264 video with AAC sound in several languages) through the console's movie player, all from one wrapper in the executable. It opens a movie, waits until it is ready, picks one video stream and the sound in your language, starts it, then asks for a picture each frame and for sound on its audio thread.
The runtime decodes a few frames ahead on a thread of its own, so the decoder never runs on one of the game's small thread stacks, and the game's calls only copy finished pictures and sound into the game's buffers, on the movie's clock. A movie that loops starts again; one that does not ends with a "stopped" event. FFmpeg is optional when building Paleblood: without it, opening a movie stops by name.
While a movie is paused, its clock (what sceAvPlayerCurrentTime reports) stands exactly still
and no new picture is handed out (#983). The clock used to drift by a millisecond during a
pause, because it read the computer's clock twice and rounded each reading separately; it now
reads it once, in nanoseconds. A test reads the paused clock ten times at different points within
a millisecond and requires the same answer every time.
Movies: PRs, call sites and sources
- PRs #419 (the movie player), #420 (its sound port) and #983 (the paused clock).
- The wrapper's calls are at
0x02cfdf33-0x02d004a9. Pictures are NV12, in a buffer from the game's own texture allocator. - Layouts, event numbers and error values come from public sources of another PS4 runtime,
checked against the OpenOrbis
AvPlayer.h; the code is the runtime's own.
Reading the game's files
| Call | Status | What the runtime does |
|---|---|---|
sceKernelStat |
implemented | Describes a file of your copy (without write permission) or of the scratch folder. |
stat (libScePosix), __error |
implemented | The same answer the POSIX way, with the error in the calling thread's own errno (#376). |
sceKernelOpen, sceKernelRead, sceKernelPread, sceKernelLseek, sceKernelFstat, sceKernelClose |
implemented | Read your copy's files, where any attempt to write is refused as on a read-only disc; open, create and truncate files in the scratch folder /data (#308). |
sceKernelWrite, sceKernelPwrite |
implemented | Write to a file the runtime opened for writing (the scratch and save folders), returning the bytes written, with FreeBSD's checks: a descriptor not open for writing EBADF, a negative offset EINVAL. The save code's first call after "Creating save data" (by @EzequielRindello, #444). |
sceKernelFtruncate, sceKernelRename, sceKernelTruncate |
implemented | Cut a file to a length, or rename it, in the scratch or save folders; the save code needs them after "Creating save data". Across two folders answers EXDEV, inside your read-only copy EROFS (#449, #458). |
mkdir, rmdir, rename (libScePosix) |
implemented | The same, the POSIX way, with the error number in errno (#458). |
On the console, a game sees its own package as a read-only folder called /app0. The runtime
serves /app0 from your own copy of the game (tools/boot.py --app0), and never writes to it.
The first file Bloodborne looks for and reads is sprj_mixer.fev, its sound mixer description.
The game also keeps scratch files under /data: its engine maps the temp: and title: drives
there and creates a fresh cache.bin at start-up. The runtime serves /data from a writable
folder of its own choosing (pbboot --data); tools/boot.py gives each run a new, empty one,
so every boot starts alike and nothing the game writes outlives the run.
The executable also asks for file details through POSIX stat, which reports an error through
errno instead of its result. The runtime answers from the same lookup, and keeps a separate
errno for each of the game's threads, as the C library expects (#376).
Files: PRs and what stops by name
Showing frames: video out
| Call | Status | What the runtime does |
|---|---|---|
sceVideoOutOpen, sceVideoOutClose |
implemented | Opens the game's video output. |
sceVideoOutSetFlipRate, sceVideoOutAddFlipEvent |
implemented | Records the rate, and which event queue hears about each flip. |
sceVideoOutSetBufferAttribute, sceVideoOutRegisterBuffers |
implemented | Describes and keeps the game's frame buffers (1920 × 1080). The attribute keeps all six values the game gives, uninterpreted, and clears its reserved bytes (#229, by @evill33t). |
sceVideoOutSubmitFlip, sceVideoOutGetFlipStatus |
implemented | Flips to the next buffer (an hsync flip at once, a vsync flip at the next 60 Hz tick) and tells the waiting game it is done; before the first flip the status is all zero. |
Each frame the game asks video out to show one of its frame buffers, then waits on an event
queue until the console reports that the flip happened, or reads the flip status until it
catches up. The runtime keeps the buffers and answers every flip straight away, so the game's
frame loop can run. Each buffer also has a frame on your side, which the flip shows: in a window
with --display window (SDL3 and Vulkan), or written to image files with --display-capture DIR
(#313). Since #369 the runtime's own
renderer draws into those frames when the game submits its GPU work,
and since 6 November 2026 the maintainer's local runs show the studio logos and the title screen
there (#441, #442). With the display off they are not drawn.
Flips no longer hold up the next frame (#572, 11 November). About half of the maintainer's local boots stopped on a corrupted command buffer. Instrumented boots showed the engine's render thread presenting a frame while its main thread drew the movie layer into the same graphics context: the main thread only sleeps a fixed 20 ms first. Each present waits for a free display buffer, that is for an earlier flip, and those flips were held on the renderer's thread for up to a vertical blank, so presents slid into the main thread's drawing. As on the PS4, whose GPU hands a flip to the display and goes on, flips after a frame's work are now queued to a video out thread. In four of four local boots with the character creation script the corruption did not return. A renderer frame slower than the frame budget can still delay the present, and the flip status's times and pending counts are still not modelled.
Video out: PRs and call sites
Graphics: the first calls
| Call | Status | What the runtime does |
|---|---|---|
sceGnmGetTheTessellationFactorRingBufferBaseAddress |
implemented | Answers an address the runtime reserves; the game maps its tessellation memory there. |
sceGnmValidateCommandBuffers |
implemented | Answers "validation is not available" (#297): Paleblood has no GPU validation layer, and that is the one answer the game's start-up probe checks for. |
sceGnmDispatchInitDefaultHardwareState, sceGnmDrawInitDefaultHardwareState200 |
implemented | Write nothing and answer 0 words (#299): there is no GPU state to set up. |
sceGnmSetCsShader |
implemented | Fills the space the game reserved with a single no-op packet and reports success (#299). |
sceGnmIsUserPaEnabled |
implemented | Answers "off" (#299): Paleblood has no GPU performance-analysis mode. |
sceGnmSet{Es,Gs,Hs,Ls,Ps,Vs}Shader, sceGnmUpdate{Gs,Hs,Ps,Vs}Shader, the marker calls, sceGnmInsertWaitFlipDone |
implemented | Fill the space the game reserved with one no-op packet (#310). The vertex, pixel and compute shader calls also hand the shader to the renderer (#412, #418), and since #659 (12 November) so do the local, hull, export and geometry shader calls, with the hull shader's tessellation settings; draws that use those stages still stop by name. |
sceGnmSubmitCommandBuffers, sceGnmSubmitAndFlipCommandBuffers, sceGnmSubmitDone |
implemented (temporary stand-in) | Complete a frame's GPU work: "work done" values are written, waits are checked, the other packets are skipped; then the frame is flipped (#310). With the display on, the renderer also runs the drawing calls recorded for each submitted buffer (#369); since #488 the call returns at once and the renderer's own thread runs the work in submission order, with each "work done" value, wait and flip placed after the work before it. Any number of buffers per call (#504: character creation submits 70). Since #572 the flip after a frame's work no longer waits on that thread: the picture is taken there and the flip is queued to a video out thread, which waits for the vertical blank, updates the flip status, presents and raises the flip events in order; sceVideoOutSubmitFlip waits for queued flips first. Since #595 the renderer's thread no longer waits for the GPU at each step: the "work done" writes are performed once the GPU has finished the work before them. Since #630 a flip does not hold up the work after it either: the flipped picture is copied in order with the work and the flip happens once that copy has run. Constant-engine buffers (#622), end-of-shader and memory writes (#624, #627), indirect dispatches (#649) and memory copies through the global data share (#653) run too (below). |
sceGnmMapComputeQueue |
implemented | Records a GPU compute queue and gives it an ID. |
sceGnmDingDong |
implemented | Until #606 (11 November) it completed submitted compute work at once (#302): no shaders ran, but each job's "work done" value was written and the queue freed. Now each buffer the ring points to goes to the renderer like a graphics buffer: with the display on its dispatches run on the GPU in submission order, with the graphics work, and its "work done" values are written after them; with the display off they are written at once, as before. Since #470 the renderer takes each buffer's recorded calls and drops them, so their shader bindings cannot leak into a later graphics buffer in the same memory. Since #820 (13 November) the renderer is told which queue each buffer came from, and each queue keeps its own compute shader and user data, as each GPU queue keeps its own registers: the game's compute buffers that start a new ring chunk dispatch without binding a shader and rely on the one their own queue bound last. |
Paleblood does not emulate the PS4's graphics chip. It will rebuild the graphics at the level of the game engine's own drawing interface, so the graphics-driver calls only need to answer what the engine expects back. The first one asks where the GPU keeps its tessellation factors (the data it uses to split surfaces into finer triangles); the engine then maps memory at that address. The PS4 answers a fixed address of its own; the runtime answers one it reserves, because nothing but the engine's own graphics code ever uses it.
The next call validates a command buffer, and the engine treats one particular error code as "this console cannot validate". Paleblood has no validation layer, so it gives that answer (#297).
The temporary GPU stand-in. The game hands work to the GPU through compute queues: it writes a
pointer to each finished command buffer into a ring, then rings a "doorbell" (sceGnmDingDong).
Each command buffer the game sent during start-up holds the same few steps: set shader registers,
run a compute shader, then write a "work done" value to memory, which the CPU waits for. Until the
engine's own renderer replaces this layer, the doorbell completes the work at once (#302): it
follows each buffer, skips the shader steps (nothing is drawn or computed), writes the "work done"
value and moves the queue's read position on. Any other kind of step stops by name. This keeps
start-up moving; it does not make anything appear on screen. Since #606 (11 November), with the
display on, the compute queues' dispatches run on the GPU instead: character creation's lit preview
needs what they make (a colour volume, composed images and its light data).
What the stand-in skips safely. As the boot went further, the frame's command buffers held more kinds of packets. The stand-in skips only those that change nothing it would have to model: an empty constant-buffer entry (#375), a memory read that only warms the GPU's cache and the size of an index (#377), and an indexed draw's packets (#395). Any other form still stops by name.
What it runs since 11 November. The loading screen after character creation and the load into
Iosefka's Clinic brought packets that change memory, so the stand-in now performs them in order
with the drawing work around them, each a step on the renderer's thread:
- The constant engine (#622). The PS4's GPU has a second command processor beside the one
that draws. It keeps 48 KB of constant memory, which its own command buffer fills and copies out
into memory, and the two keep in step with counters: the drawing side waits until the constant
side is far enough. The runtime runs the constant buffer lazily, in the drawing side's order, so
each copy lands just before the draws that read it.
- Writes after the work (#624, #627): EVENT_WRITE_EOS stores a value once the shaders
before it are done, and WRITE_DATA writes the packet's words to memory between the work before
and after it.
- Indirect dispatches (#649): SET_BASE and DISPATCH_INDIRECT; the GPU reads the
workgroup counts from memory when the dispatch runs, so earlier GPU work may have written them.
- DMA_DATA copies and fills (#653) between memory, the packet's own value and the GPU's
64 KB global data share, which the engine uses for per-slot counters. Since
#684 (12 November) the shaders reach the
same memory too: ds_append and ds_consume move its counters on the GPU.
- Occlusion counts, a stand-in (#689,
found entering Iosefka's Clinic). The game's occlusion queries ask each of the GPU's 8 depth blocks
to store its running count of samples that passed the depth test (EVENT_WRITE with
PIXEL_PIPE_STAT_DUMP), before and after the draws they measure. The runtime counts no samples
yet: each dump stores an invented count that grows every time, so every query reads visible.
That is not the GPU's behaviour; anything the game decides from visibility (flares, hiding objects
behind walls) acts as if everything were visible until real counts are made with Vulkan occlusion
queries (a follow-up).
Each still stops by name on a form it does not handle, such as register writes, a GDS store at the end of the shaders or another event that writes memory.
The renderer alongside it. The drawing itself does not happen here. When the game binds a
shader through sceGnmSetVsShader, sceGnmSetPsShader or sceGnmSetCsShader, the runtime also
hands the shader's registers to Paleblood's renderer (#412, #418), and the
game's own GPU library functions report its draws (see The renderer).
At each submit the renderer runs what was recorded for that buffer on your GPU, and the stand-in
still writes the "work done" values the game waits for.
Where the engine meets the GPU. Every one of the game's 50 graphics-driver imports is
reached through one thin engine wrapper, with one or two callers each, and none of them draws
anything. Bloodborne builds its GPU command buffers itself, with the graphics library compiled into
the game, and only hands finished buffers to the system to run and to put on screen. So the
runtime cannot take over drawing at the system-call boundary: the graphics have to be rebuilt above
it, in the engine's own renderer (its GX graphics framework). The full map is on
issue #39.
Graphics: PRs and call sites
- PRs #176 and #178 (compute queues); claimed on #39.
- The tessellation ring is mapped at
0x02ad3fdawith protection0x33(CPU and GPU read and write). The runtime's address is0xfe00000000. - The validation check is at
0x02abb950: the engine compares the result with0x80d13fff. - The compute submit is at
0x0148c830and its ring-packet writer at0x0148b330; the stand-in handles the packet kinds a boot found there: NOP, SET_SH_REG, DISPATCH_DIRECT and RELEASE_MEM (AMD's public PM4 format). - Since then: #375 (empty constant entries, from the second submit caller at
0x0149bf3a), #377 (DMA_DATAintoCP_DMA_READ_TAGS,INDEX_TYPE), #395 (INDEX_BASE,INDEX_BUFFER_SIZE,DRAW_INDEX_2,DRAW_INDEX_OFFSET_2), #412 (vertex and pixel shaders handed to the renderer; a vertex shader's modifier is applied to its register block) and #418 (compute shaders).
10 November: the rest of the checklist
On 10 November the runtime answered every system import the boot can reach. Each call follows the executable's own call sites; where the PS4's answer is not public, the maintainer ruled on it, using what other PS4 runtimes and ports agree on as facts (never their code). The generated list below and the runtime call reference have every call.
| Group | What the runtime does | Pull request |
|---|---|---|
| Directories and flushing | Opens a directory, lists it as FreeBSD 9 records the engine's directory walker reads, and flushes files. | #498 |
| Message, save data, profile and commerce dialogs | Each opens and finishes at once, as a dialog the user closed; the game never reads a choice from them. Nothing is shown. | #500 |
| On-screen keyboard, web browser | The keyboard opens and is found cancelled at the first status query; the browser is not opened. Since #619, --keyboard-text TEXT (unrecorded boots) makes the keyboard answer as if TEXT was typed and confirmed: character creation's contract cannot be finalised without a name. The keyboard's settings are copied when it opens, because the game reuses their memory before the first status query. |
#502, #619 |
| Microphone and voice chat | A console with no microphone or headset: the record port opens and gives silence, voice chat answers success with no audio. | #506 |
| GNM queries and debug calls | The answers of a retail console with no capture tool attached. | #506 |
| PSN matchmaking, web API, leaderboards, signaling, lookup | Signed out: every service is gated on the user's online id, which a signed-out console has not got. | #507 |
| Sockets, resolver, HTTP requests | A console with no connection: sockets can be created and bound as with only loopback, anything that would leave the machine fails at once. Nothing is ever sent. | #509 |
| What the game's C library imports | The calls and data the bundled C library and file library take from the kernel (C++ exception support, standard output, the heap, local time). | #513, #521 |
| The maintainer's kernel and file rulings | Page size, process id, the stack canary, standard input at end of file, the process-map query, resuming at an exception landing pad, module information, reserving address space and batches of maps. | #528 |
| The last graphics calls | Graphics events raised when the GPU's completion step performs a write that asks for one; flip requests; the remaining queries. | #532 |
| Sound ports | A movie's sound port closes when the movie ends, and its handle is used again. | #490 |
| File paths | Kept off the game's small thread stacks; one boot in five overflowed the save thread's stack while creating the save. | #512 |
The last three of the executable's imports, sceKernelMkdir, sceKernelRmdir and
sceKernelUnlink, were implemented by @EzequielRindello in
#455, merged on 11 November as #555. The bundled C library's scePthreadAttrGetaffinity (below) answers since #561,
the same day, building on @evill33t's groundwork in #239. With it, #34 closed at 184 of 184 calls.
Every call the runtime answers
This list is generated from the runtime's registry in Paleblood main each time the wiki syncs,
so it is complete even when the explanations above have not caught up. "Stops by name" means the
call is registered only to name itself and stop, because its answer is not established.
libkernel
| Call | Status | Source |
|---|---|---|
__elf_phdr_match_addr |
implemented | runtime/syslib/kernel_unwind.c |
__error |
implemented | runtime/syslib/kernel.c |
__progname |
implemented | runtime/syslib/kernel_libc_support.c |
__pthread_cxa_finalize |
implemented | runtime/syslib/kernel_libc_support.c |
__stack_chk_fail |
implemented | runtime/syslib/kernel.c |
__stack_chk_guard |
implemented | runtime/syslib/kernel_libc_support.c |
__tls_get_addr |
implemented | runtime/syslib/kernel_tls.c |
__Ux86_64_setcontext |
implemented | runtime/syslib/kernel_unwind.c |
_exit |
implemented | runtime/syslib/kernel.c |
_is_signal_return |
implemented | runtime/syslib/kernel_libc_support.c |
_read |
implemented | runtime/syslib/kernel_libc_support.c |
_sceKernelRtldSetApplicationHeapAPI |
implemented | runtime/syslib/kernel.c |
_sigprocmask |
implemented | runtime/syslib/kernel_thread.c |
_write |
implemented | runtime/syslib/kernel_libc_support.c |
clock_gettime |
implemented | runtime/syslib/kernel_time_of_day.c |
fstat |
implemented | runtime/syslib/files.c |
getpagesize |
implemented | runtime/syslib/kernel.c |
getpid |
implemented | runtime/syslib/kernel_libc_support.c |
getrusage |
implemented | runtime/syslib/kernel_libc_support.c |
gettimeofday |
implemented | runtime/syslib/kernel_time_of_day.c |
mmap |
implemented | runtime/syslib/kernel_memory.c |
msync |
implemented | runtime/syslib/kernel_memory.c |
munmap |
implemented | runtime/syslib/kernel_memory.c |
nanosleep |
implemented | runtime/syslib/kernel.c |
pthread_mutex_lock |
implemented | runtime/syslib/kernel_mutex.c |
pthread_mutex_unlock |
implemented | runtime/syslib/kernel_mutex.c |
sceKernelAllocateDirectMemory |
implemented | runtime/syslib/kernel_memory.c |
sceKernelBatchMap |
implemented | runtime/syslib/kernel_memory.c |
sceKernelClockGettime |
implemented | runtime/syslib/kernel_time_of_day.c |
sceKernelClose |
implemented | runtime/syslib/files.c |
sceKernelCreateEqueue |
implemented | runtime/syslib/kernel_equeue.c |
sceKernelCreateSema |
implemented | runtime/syslib/kernel_sema.c |
sceKernelDebugRaiseException |
implemented | runtime/syslib/kernel_libc_support.c |
sceKernelDebugRaiseExceptionOnReleaseMode |
implemented | runtime/syslib/kernel_libc_support.c |
sceKernelDeleteEqueue |
implemented | runtime/syslib/kernel_equeue.c |
sceKernelDeleteSema |
implemented | runtime/syslib/kernel_sema.c |
sceKernelFstat |
implemented | runtime/syslib/files.c |
sceKernelFsync |
implemented | runtime/syslib/files.c |
sceKernelFtruncate |
implemented | runtime/syslib/files.c |
sceKernelGetCompiledSdkVersion |
implemented | runtime/syslib/kernel_sdk.c |
sceKernelGetDirectMemorySize |
implemented | runtime/syslib/kernel_memory.c |
sceKernelGetDirectMemoryType |
implemented | runtime/syslib/kernel_memory.c |
sceKernelGetdirentries |
implemented | runtime/syslib/files.c |
sceKernelGetModuleInfoFromAddr |
implemented | runtime/syslib/kernel_unwind.c |
sceKernelGetProcessTime |
implemented | runtime/syslib/kernel_time_of_day.c |
sceKernelGetProcParam |
implemented | runtime/syslib/kernel.c |
sceKernelGettimeofday |
implemented | runtime/syslib/kernel_time_of_day.c |
sceKernelGettimezone |
implemented | runtime/syslib/kernel_libc_support.c |
sceKernelLseek |
implemented | runtime/syslib/files.c |
sceKernelMapDirectMemory |
implemented | runtime/syslib/kernel_memory.c |
sceKernelMapFlexibleMemory |
implemented | runtime/syslib/kernel_memory.c |
sceKernelMapNamedFlexibleMemory |
implemented | runtime/syslib/kernel_memory.c |
sceKernelMkdir |
implemented | runtime/syslib/files.c |
sceKernelMlock |
implemented | runtime/syslib/kernel_memory.c |
sceKernelMprotect |
implemented | runtime/syslib/kernel_memory.c |
sceKernelMunmap |
implemented | runtime/syslib/kernel_memory.c |
sceKernelOpen |
implemented | runtime/syslib/files.c |
sceKernelPollSema |
implemented | runtime/syslib/kernel_sema.c |
sceKernelPread |
implemented | runtime/syslib/files.c |
sceKernelPrintBacktraceWithModuleInfo |
implemented | runtime/syslib/kernel_unwind.c |
sceKernelPwrite |
implemented | runtime/syslib/files.c |
sceKernelQueryMemoryProtection |
implemented | runtime/syslib/kernel_memory.c |
sceKernelRead |
implemented | runtime/syslib/files.c |
sceKernelReadTsc |
implemented | runtime/syslib/kernel_time_of_day.c |
sceKernelReleaseDirectMemory |
implemented | runtime/syslib/kernel_memory.c |
sceKernelReleaseFlexibleMemory |
implemented | runtime/syslib/kernel_memory.c |
sceKernelRename |
implemented | runtime/syslib/files.c |
sceKernelReserveVirtualRange |
implemented | runtime/syslib/kernel_memory.c |
sceKernelRmdir |
implemented | runtime/syslib/files.c |
sceKernelSignalSema |
implemented | runtime/syslib/kernel_sema.c |
sceKernelStat |
implemented | runtime/syslib/files.c |
sceKernelTruncate |
implemented | runtime/syslib/file_names.c |
sceKernelUnlink |
implemented | runtime/syslib/files.c |
sceKernelUsleep |
implemented | runtime/syslib/kernel.c |
sceKernelVirtualQuery |
implemented | runtime/syslib/kernel_memory.c |
sceKernelWaitEqueue |
implemented | runtime/syslib/kernel_equeue.c |
sceKernelWaitSema |
implemented | runtime/syslib/kernel_sema.c |
sceKernelWrite |
implemented | runtime/syslib/files.c |
scePthreadAttrDestroy |
implemented | runtime/syslib/kernel_thread.c |
scePthreadAttrGet |
implemented | runtime/syslib/kernel_thread.c |
scePthreadAttrGetaffinity |
implemented | runtime/syslib/kernel_thread.c |
scePthreadAttrInit |
implemented | runtime/syslib/kernel_thread.c |
scePthreadAttrSetaffinity |
implemented | runtime/syslib/kernel_thread.c |
scePthreadAttrSetdetachstate |
implemented | runtime/syslib/kernel_thread.c |
scePthreadAttrSetinheritsched |
implemented | runtime/syslib/kernel_thread.c |
scePthreadAttrSetschedparam |
implemented | runtime/syslib/kernel_thread.c |
scePthreadAttrSetschedpolicy |
implemented | runtime/syslib/kernel_thread.c |
scePthreadAttrSetstacksize |
implemented | runtime/syslib/kernel_thread.c |
scePthreadCondBroadcast |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadCondDestroy |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadCondInit |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadCondSignal |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadCondTimedwait |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadCondWait |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadCreate |
implemented | runtime/syslib/kernel_thread.c |
scePthreadDetach |
implemented | runtime/syslib/kernel_thread.c |
scePthreadEqual |
implemented | runtime/syslib/kernel_thread.c |
scePthreadExit |
implemented | runtime/syslib/kernel_thread.c |
scePthreadGetaffinity |
implemented | runtime/syslib/kernel_thread.c |
scePthreadGetprio |
implemented | runtime/syslib/kernel_thread.c |
scePthreadGetspecific |
implemented | runtime/syslib/kernel_key.c |
scePthreadJoin |
implemented | runtime/syslib/kernel_thread.c |
scePthreadKeyCreate |
implemented | runtime/syslib/kernel_key.c |
scePthreadKeyDelete |
implemented | runtime/syslib/kernel_key.c |
scePthreadMutexattrDestroy |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadMutexattrInit |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadMutexattrSetprotocol |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadMutexattrSettype |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadMutexDestroy |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadMutexInit |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadMutexLock |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadMutexTimedlock |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadMutexTrylock |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadMutexUnlock |
implemented | runtime/syslib/kernel_mutex.c |
scePthreadOnce |
implemented | runtime/syslib/kernel_thread.c |
scePthreadRename |
implemented | runtime/syslib/kernel_thread.c |
scePthreadRwlockDestroy |
implemented | runtime/syslib/kernel_rwlock.c |
scePthreadRwlockInit |
implemented | runtime/syslib/kernel_rwlock.c |
scePthreadRwlockRdlock |
implemented | runtime/syslib/kernel_rwlock.c |
scePthreadRwlockTimedrdlock |
implemented | runtime/syslib/kernel_rwlock.c |
scePthreadRwlockTimedwrlock |
implemented | runtime/syslib/kernel_rwlock.c |
scePthreadRwlockTryrdlock |
implemented | runtime/syslib/kernel_rwlock.c |
scePthreadRwlockTrywrlock |
implemented | runtime/syslib/kernel_rwlock.c |
scePthreadRwlockUnlock |
implemented | runtime/syslib/kernel_rwlock.c |
scePthreadRwlockWrlock |
implemented | runtime/syslib/kernel_rwlock.c |
scePthreadSelf |
implemented | runtime/syslib/kernel_thread.c |
scePthreadSetaffinity |
implemented | runtime/syslib/kernel_thread.c |
scePthreadSetprio |
implemented | runtime/syslib/kernel_thread.c |
scePthreadSetspecific |
implemented | runtime/syslib/kernel_key.c |
scePthreadYield |
implemented | runtime/syslib/kernel_thread.c |
sched_yield |
implemented | runtime/syslib/kernel_thread.c |
sigfillset |
implemented | runtime/syslib/kernel_thread.c |
signal |
implemented | runtime/syslib/kernel_libc_support.c |
sigprocmask |
implemented | runtime/syslib/kernel_thread.c |
sigreturn |
implemented | runtime/syslib/kernel_unwind.c |
sysctl |
implemented | runtime/syslib/kernel_unwind.c |
libSceAjm
| Call | Status | Source |
|---|---|---|
sceAjmBatchCancel |
implemented | runtime/syslib/audio_ajm.c |
sceAjmBatchErrorDump |
implemented | runtime/syslib/audio_ajm.c |
sceAjmBatchJobControlBufferRa |
implemented | runtime/syslib/audio_ajm.c |
sceAjmBatchJobRunBufferRa |
implemented | runtime/syslib/audio_ajm.c |
sceAjmBatchStartBuffer |
implemented | runtime/syslib/audio_ajm.c |
sceAjmBatchWait |
implemented | runtime/syslib/audio_ajm.c |
sceAjmFinalize |
implemented | runtime/syslib/audio_ajm.c |
sceAjmInitialize |
implemented | runtime/syslib/audio_ajm.c |
sceAjmInstanceCreate |
implemented | runtime/syslib/audio_ajm.c |
sceAjmInstanceDestroy |
implemented | runtime/syslib/audio_ajm.c |
sceAjmModuleRegister |
implemented | runtime/syslib/audio_ajm.c |
sceAjmModuleUnregister |
implemented | runtime/syslib/audio_ajm.c |
libSceAppContent
| Call | Status | Source |
|---|---|---|
sceAppContentAppParamGetInt |
implemented | runtime/syslib/app_content.c |
sceAppContentGetAddcontInfoList |
implemented | runtime/syslib/app_content.c |
sceAppContentInitialize |
implemented | runtime/syslib/app_content.c |
libSceAudioIn
| Call | Status | Source |
|---|---|---|
sceAudioInClose |
implemented | runtime/syslib/audio_in.c |
sceAudioInInput |
implemented | runtime/syslib/audio_in.c |
sceAudioInOpen |
implemented | runtime/syslib/audio_in.c |
libSceAudioOut
| Call | Status | Source |
|---|---|---|
sceAudioOutClose |
implemented | runtime/syslib/audio_out.c |
sceAudioOutGetPortState |
implemented | runtime/syslib/audio_out.c |
sceAudioOutInit |
implemented | runtime/syslib/audio_out.c |
sceAudioOutOpen |
implemented | runtime/syslib/audio_out.c |
sceAudioOutOutput |
implemented | runtime/syslib/audio_out.c |
sceAudioOutSetVolume |
implemented | runtime/syslib/audio_out.c |
libSceAvPlayer
| Call | Status | Source |
|---|---|---|
sceAvPlayerAddSource |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerClose |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerCurrentTime |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerEnableStream |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerGetAudioData |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerGetStreamInfo |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerGetVideoDataEx |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerInit |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerIsActive |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerPause |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerPostInit |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerResume |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerSetLooping |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerStart |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerStop |
implemented | runtime/syslib/avplayer.c |
sceAvPlayerStreamCount |
implemented | runtime/syslib/avplayer.c |
libSceCommonDialog
| Call | Status | Source |
|---|---|---|
sceCommonDialogInitialize |
implemented | runtime/syslib/common_dialog.c |
libSceDiscMap
| Call | Status | Source |
|---|---|---|
sceDiscMapIsRequestOnHDD |
implemented | runtime/syslib/disc_map.c |
libSceGnmDriver
| Call | Status | Source |
|---|---|---|
sceGnmAddEqEvent |
implemented | runtime/syslib/gnm.c |
sceGnmAreSubmitsAllowed |
implemented | runtime/syslib/gnm.c |
sceGnmDebugHardwareStatus |
implemented | runtime/syslib/gnm.c |
sceGnmDeleteEqEvent |
implemented | runtime/syslib/gnm.c |
sceGnmDingDong |
implemented | runtime/syslib/gnm.c |
sceGnmDisableMipStatsReport |
implemented | runtime/syslib/gnm.c |
sceGnmDispatchInitDefaultHardwareState |
implemented | runtime/syslib/gnm.c |
sceGnmDrawInitDefaultHardwareState200 |
implemented | runtime/syslib/gnm.c |
sceGnmDriverCaptureInProgress |
implemented | runtime/syslib/gnm.c |
sceGnmDriverTriggerCapture |
implemented | runtime/syslib/gnm.c |
sceGnmFlushGarlic |
implemented | runtime/syslib/gnm.c |
sceGnmGetEqEventType |
implemented | runtime/syslib/gnm.c |
sceGnmGetEqTimeStamp |
implemented | runtime/syslib/gnm.c |
sceGnmGetTheTessellationFactorRingBufferBaseAddress |
implemented | runtime/syslib/gnm.c |
sceGnmInsertPopMarker |
implemented | runtime/syslib/gnm.c |
sceGnmInsertPushColorMarker |
implemented | runtime/syslib/gnm.c |
sceGnmInsertPushMarker |
implemented | runtime/syslib/gnm.c |
sceGnmInsertSetColorMarker |
implemented | runtime/syslib/gnm.c |
sceGnmInsertSetMarker |
implemented | runtime/syslib/gnm.c |
sceGnmInsertWaitFlipDone |
implemented | runtime/syslib/gnm.c |
sceGnmIsUserPaEnabled |
implemented | runtime/syslib/gnm.c |
sceGnmLogicalCuIndexToPhysicalCuIndex |
implemented | runtime/syslib/gnm.c |
sceGnmLogicalCuMaskToPhysicalCuMask |
implemented | runtime/syslib/gnm.c |
sceGnmMapComputeQueue |
implemented | runtime/syslib/gnm.c |
sceGnmMapComputeQueueWithPriority |
implemented | runtime/syslib/gnm.c |
sceGnmRequestFlipAndSubmitDone |
implemented | runtime/syslib/gnm.c |
sceGnmRequestMipStatsReportAndReset |
implemented | runtime/syslib/gnm.c |
sceGnmSetCsShader |
implemented | runtime/syslib/gnm.c |
sceGnmSetEsShader |
implemented | runtime/syslib/gnm.c |
sceGnmSetGsRingSizes |
implemented | runtime/syslib/gnm.c |
sceGnmSetGsShader |
implemented | runtime/syslib/gnm.c |
sceGnmSetHsShader |
implemented | runtime/syslib/gnm.c |
sceGnmSetLsShader |
implemented | runtime/syslib/gnm.c |
sceGnmSetPsShader |
implemented | runtime/syslib/gnm.c |
sceGnmSetupMipStatsReport |
implemented | runtime/syslib/gnm.c |
sceGnmSetVsShader |
implemented | runtime/syslib/gnm.c |
sceGnmSubmitAndFlipCommandBuffers |
implemented | runtime/syslib/gnm.c |
sceGnmSubmitCommandBuffers |
implemented | runtime/syslib/gnm.c |
sceGnmSubmitDone |
implemented | runtime/syslib/gnm.c |
sceGnmUnmapComputeQueue |
implemented | runtime/syslib/gnm.c |
sceGnmUpdateGsShader |
implemented | runtime/syslib/gnm.c |
sceGnmUpdateHsShader |
implemented | runtime/syslib/gnm.c |
sceGnmUpdatePsShader |
implemented | runtime/syslib/gnm.c |
sceGnmUpdateVsShader |
implemented | runtime/syslib/gnm.c |
sceGnmValidateCommandBuffers |
implemented | runtime/syslib/gnm.c |
sceRazorCaptureCommandBuffersOnlyImmediate |
implemented | runtime/syslib/gnm.c |
sceRazorCaptureCommandBuffersOnlySinceLastFlip |
implemented | runtime/syslib/gnm.c |
sceRazorCaptureImmediate |
implemented | runtime/syslib/gnm.c |
sceRazorCaptureSinceLastFlip |
implemented | runtime/syslib/gnm.c |
sceRazorIsLoaded |
implemented | runtime/syslib/gnm.c |
libSceHttp
| Call | Status | Source |
|---|---|---|
sceHttpAbortWaitRequest |
implemented | runtime/syslib/network.c |
sceHttpAddRequestHeader |
implemented | runtime/syslib/network.c |
sceHttpCreateConnectionWithURL |
implemented | runtime/syslib/http_requests.c |
sceHttpCreateEpoll |
implemented | runtime/syslib/network.c |
sceHttpCreateRequestWithURL |
implemented | runtime/syslib/http_requests.c |
sceHttpCreateTemplate |
implemented | runtime/syslib/network.c |
sceHttpDeleteConnection |
implemented | runtime/syslib/http_requests.c |
sceHttpDeleteRequest |
implemented | runtime/syslib/http_requests.c |
sceHttpDeleteTemplate |
implemented | runtime/syslib/network.c |
sceHttpDestroyEpoll |
implemented | runtime/syslib/network.c |
sceHttpGetResponseContentLength |
implemented | runtime/syslib/http_requests.c |
sceHttpGetStatusCode |
implemented | runtime/syslib/http_requests.c |
sceHttpInit |
implemented | runtime/syslib/network.c |
sceHttpReadData |
implemented | runtime/syslib/http_requests.c |
sceHttpsDisableOption |
implemented | runtime/syslib/network.c |
sceHttpsEnableOption |
implemented | runtime/syslib/network.c |
sceHttpSendRequest |
implemented | runtime/syslib/http_requests.c |
sceHttpSetConnectTimeOut |
implemented | runtime/syslib/http_requests.c |
sceHttpSetEpoll |
implemented | runtime/syslib/http_requests.c |
sceHttpSetNonblock |
implemented | runtime/syslib/network.c |
sceHttpSetRequestContentLength |
implemented | runtime/syslib/http_requests.c |
sceHttpTerm |
implemented | runtime/syslib/network.c |
sceHttpUnsetEpoll |
implemented | runtime/syslib/http_requests.c |
sceHttpWaitRequest |
implemented | runtime/syslib/network.c |
libSceImeDialog
| Call | Status | Source |
|---|---|---|
sceImeDialogAbort |
implemented | runtime/syslib/ime_dialog.c |
sceImeDialogGetResult |
implemented | runtime/syslib/ime_dialog.c |
sceImeDialogGetStatus |
implemented | runtime/syslib/ime_dialog.c |
sceImeDialogInit |
implemented | runtime/syslib/ime_dialog.c |
sceImeDialogTerm |
implemented | runtime/syslib/ime_dialog.c |
libSceLibcInternal
| Call | Status | Source |
|---|---|---|
__cxa_finalize |
implemented | runtime/syslib/libc_internal.c |
_Stdout |
implemented | runtime/syslib/libc_internal.c |
fflush |
implemented | runtime/syslib/libc_internal.c |
free |
implemented | runtime/syslib/libc_internal.c |
gmtime |
implemented | runtime/syslib/libc_internal.c |
gmtime_s |
implemented | runtime/syslib/libc_internal.c |
localtime |
implemented | runtime/syslib/libc_internal.c |
malloc |
implemented | runtime/syslib/libc_internal.c |
memcpy |
implemented | runtime/syslib/kernel.c |
memset |
implemented | runtime/syslib/kernel.c |
mktime |
implemented | runtime/syslib/libc_internal.c |
Need_sceLibcInternal |
implemented | runtime/syslib/libc_internal.c |
printf |
implemented | runtime/syslib/libc_internal.c |
time |
implemented | runtime/syslib/kernel_time_of_day.c |
vprintf |
implemented | runtime/syslib/libc_internal.c |
vsnprintf |
implemented | runtime/syslib/libc_internal.c |
libSceMouse
| Call | Status | Source |
|---|---|---|
sceMouseClose |
implemented | runtime/syslib/mouse.c |
sceMouseInit |
implemented | runtime/syslib/mouse.c |
sceMouseOpen |
implemented | runtime/syslib/mouse.c |
sceMouseRead |
implemented | runtime/syslib/mouse.c |
libSceMsgDialog
| Call | Status | Source |
|---|---|---|
sceMsgDialogInitialize |
implemented | runtime/syslib/dialogs.c |
sceMsgDialogOpen |
implemented | runtime/syslib/dialogs.c |
sceMsgDialogTerminate |
implemented | runtime/syslib/dialogs.c |
sceMsgDialogUpdateStatus |
implemented | runtime/syslib/dialogs.c |
libSceNet
| Call | Status | Source |
|---|---|---|
sceNetAccept |
implemented | runtime/syslib/net_sockets.c |
sceNetBind |
implemented | runtime/syslib/net_sockets.c |
sceNetConnect |
implemented | runtime/syslib/net_sockets.c |
sceNetEpollAbort |
implemented | runtime/syslib/network.c |
sceNetEpollControl |
implemented | runtime/syslib/network.c |
sceNetEpollCreate |
implemented | runtime/syslib/network.c |
sceNetEpollDestroy |
implemented | runtime/syslib/network.c |
sceNetEpollWait |
implemented | runtime/syslib/network.c |
sceNetErrnoLoc |
implemented | runtime/syslib/network.c |
sceNetGetsockname |
implemented | runtime/syslib/net_sockets.c |
sceNetGetsockopt |
implemented | runtime/syslib/net_sockets.c |
sceNetHtonl |
implemented | runtime/syslib/network.c |
sceNetHtons |
implemented | runtime/syslib/network.c |
sceNetInetNtop |
implemented | runtime/syslib/network.c |
sceNetInetPton |
implemented | runtime/syslib/network.c |
sceNetInit |
implemented | runtime/syslib/network.c |
sceNetListen |
implemented | runtime/syslib/net_sockets.c |
sceNetNtohl |
implemented | runtime/syslib/network.c |
sceNetNtohs |
implemented | runtime/syslib/network.c |
sceNetPoolCreate |
implemented | runtime/syslib/network.c |
sceNetPoolDestroy |
implemented | runtime/syslib/network.c |
sceNetRecv |
implemented | runtime/syslib/net_sockets.c |
sceNetRecvfrom |
implemented | runtime/syslib/net_sockets.c |
sceNetResolverCreate |
implemented | runtime/syslib/net_sockets.c |
sceNetResolverDestroy |
implemented | runtime/syslib/net_sockets.c |
sceNetResolverStartAton |
implemented | runtime/syslib/net_sockets.c |
sceNetResolverStartNtoa |
implemented | runtime/syslib/net_sockets.c |
sceNetSend |
implemented | runtime/syslib/net_sockets.c |
sceNetSendto |
implemented | runtime/syslib/net_sockets.c |
sceNetSetsockopt |
implemented | runtime/syslib/net_sockets.c |
sceNetShutdown |
implemented | runtime/syslib/net_sockets.c |
sceNetSocket |
implemented | runtime/syslib/net_sockets.c |
sceNetSocketAbort |
implemented | runtime/syslib/net_sockets.c |
sceNetSocketClose |
implemented | runtime/syslib/net_sockets.c |
sceNetTerm |
implemented | runtime/syslib/network.c |
libSceNetCtl
| Call | Status | Source |
|---|---|---|
sceNetCtlCheckCallback |
implemented | runtime/syslib/netctl.c |
sceNetCtlGetInfo |
implemented | runtime/syslib/netctl.c |
sceNetCtlGetNatInfo |
implemented | runtime/syslib/netctl.c |
sceNetCtlGetState |
implemented | runtime/syslib/netctl.c |
sceNetCtlRegisterCallback |
implemented | runtime/syslib/netctl.c |
sceNetCtlUnregisterCallback |
implemented | runtime/syslib/netctl.c |
libSceNpAuth
| Call | Status | Source |
|---|---|---|
sceNpAuthCreateAsyncRequest |
implemented | runtime/syslib/np_auth.c |
sceNpAuthDeleteRequest |
implemented | runtime/syslib/np_auth.c |
sceNpAuthGetAuthorizationCode |
implemented | runtime/syslib/np_auth.c |
sceNpAuthPollAsync |
implemented | runtime/syslib/np_auth.c |
libSceNpCommerce
| Call | Status | Source |
|---|---|---|
sceNpCommerceDialogInitialize |
implemented | runtime/syslib/dialogs.c |
sceNpCommerceDialogOpen |
implemented | runtime/syslib/dialogs.c |
sceNpCommerceDialogTerminate |
implemented | runtime/syslib/dialogs.c |
sceNpCommerceDialogUpdateStatus |
implemented | runtime/syslib/dialogs.c |
libSceNpCommon
| Call | Status | Source |
|---|---|---|
sceNpCmpNpId |
implemented | runtime/syslib/np_common.c |
sceNpCmpOnlineId |
implemented | runtime/syslib/np_common.c |
libSceNpManager
| Call | Status | Source |
|---|---|---|
sceNpAbortRequest |
implemented | runtime/syslib/np_manager.c |
sceNpCheckCallback |
implemented | runtime/syslib/np_manager.c |
sceNpCheckNpAvailability |
implemented | runtime/syslib/np_manager.c |
sceNpCheckPlus |
implemented | runtime/syslib/np_manager.c |
sceNpCreateAsyncRequest |
implemented | runtime/syslib/np_manager.c |
sceNpDeleteRequest |
implemented | runtime/syslib/np_manager.c |
sceNpGetGamePresenceStatus |
implemented | runtime/syslib/np_manager.c |
sceNpGetNpId |
implemented | runtime/syslib/np_manager.c |
sceNpGetOnlineId |
implemented | runtime/syslib/np_manager.c |
sceNpGetParentalControlInfo |
implemented | runtime/syslib/np_manager.c |
sceNpGetState |
implemented | runtime/syslib/np_manager.c |
sceNpNotifyPlusFeature |
implemented | runtime/syslib/np_manager.c |
sceNpPollAsync |
implemented | runtime/syslib/np_manager.c |
sceNpRegisterGamePresenceCallback |
implemented | runtime/syslib/np_manager.c |
sceNpRegisterPlusEventCallback |
implemented | runtime/syslib/np_manager.c |
sceNpRegisterStateCallback |
implemented | runtime/syslib/np_manager.c |
sceNpSetContentRestriction |
implemented | runtime/syslib/np_manager.c |
sceNpSetNpTitleId |
implemented | runtime/syslib/np_manager.c |
sceNpUnregisterPlusEventCallback |
implemented | runtime/syslib/np_manager.c |
sceNpUnregisterStateCallback |
implemented | runtime/syslib/np_manager.c |
libSceNpMatching2
| Call | Status | Source |
|---|---|---|
sceNpMatching2ContextStart |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2ContextStop |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2CreateContext |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2CreateJoinRoom |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2DestroyContext |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2GetLobbyInfoList |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2GetServerId |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2GetWorldInfoList |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2GrantRoomOwner |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2Initialize |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2JoinLobby |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2JoinRoom |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2KickoutRoomMember |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2LeaveLobby |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2LeaveRoom |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2RegisterContextCallback |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2RegisterLobbyEventCallback |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2RegisterRoomEventCallback |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2RegisterSignalingCallback |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2SearchRoom |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2SetDefaultRequestOptParam |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2SetRoomDataExternal |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2SetRoomDataInternal |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2SetRoomMemberDataInternal |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2SignalingGetConnectionStatus |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2SignalingGetPingInfo |
implemented | runtime/syslib/np_matching2.c |
sceNpMatching2Terminate |
implemented | runtime/syslib/np_matching2.c |
libSceNpProfileDialog
| Call | Status | Source |
|---|---|---|
sceNpProfileDialogGetResult |
implemented | runtime/syslib/dialogs.c |
sceNpProfileDialogInitialize |
implemented | runtime/syslib/dialogs.c |
sceNpProfileDialogOpen |
implemented | runtime/syslib/dialogs.c |
sceNpProfileDialogTerminate |
implemented | runtime/syslib/dialogs.c |
sceNpProfileDialogUpdateStatus |
implemented | runtime/syslib/dialogs.c |
libSceNpScore
| Call | Status | Source |
|---|---|---|
sceNpScoreAbortRequest |
implemented | runtime/syslib/np_score.c |
sceNpScoreCensorComment |
implemented | runtime/syslib/np_score.c |
sceNpScoreCreateNpTitleCtx |
implemented | runtime/syslib/np_score.c |
sceNpScoreCreateRequest |
implemented | runtime/syslib/np_score.c |
sceNpScoreDeleteNpTitleCtx |
implemented | runtime/syslib/np_score.c |
sceNpScoreDeleteRequest |
implemented | runtime/syslib/np_score.c |
sceNpScoreGetBoardInfo |
implemented | runtime/syslib/np_score.c |
sceNpScoreGetGameData |
implemented | runtime/syslib/np_score.c |
sceNpScoreGetRankingByNpIdPcId |
implemented | runtime/syslib/np_score.c |
sceNpScoreGetRankingByRange |
implemented | runtime/syslib/np_score.c |
sceNpScoreRecordGameData |
implemented | runtime/syslib/np_score.c |
sceNpScoreRecordScore |
implemented | runtime/syslib/np_score.c |
sceNpScoreSanitizeComment |
implemented | runtime/syslib/np_score.c |
sceNpScoreSetPlayerCharacterId |
implemented | runtime/syslib/np_score.c |
libSceNpSignaling
| Call | Status | Source |
|---|---|---|
sceNpSignalingActivateConnection |
implemented | runtime/syslib/np_signaling.c |
sceNpSignalingCreateContext |
implemented | runtime/syslib/np_signaling.c |
sceNpSignalingDeactivateConnection |
implemented | runtime/syslib/np_signaling.c |
sceNpSignalingDeleteContext |
implemented | runtime/syslib/np_signaling.c |
sceNpSignalingGetConnectionStatus |
implemented | runtime/syslib/np_signaling.c |
sceNpSignalingInitialize |
implemented | runtime/syslib/np_signaling.c |
sceNpSignalingTerminate |
implemented | runtime/syslib/np_signaling.c |
libSceNpTrophy
| Call | Status | Source |
|---|---|---|
sceNpTrophyCreateContext |
implemented | runtime/syslib/np_trophy.c |
sceNpTrophyCreateHandle |
implemented | runtime/syslib/np_trophy.c |
sceNpTrophyGetGameInfo |
implemented | runtime/syslib/np_trophy.c |
sceNpTrophyGetTrophyInfo |
implemented | runtime/syslib/np_trophy.c |
sceNpTrophyRegisterContext |
implemented | runtime/syslib/np_trophy.c |
sceNpTrophyUnlockTrophy |
implemented | runtime/syslib/np_trophy.c |
libSceNpUtility
| Call | Status | Source |
|---|---|---|
sceNpLookupAbortRequest |
implemented | runtime/syslib/np_utility.c |
sceNpLookupCreateAsyncRequest |
implemented | runtime/syslib/np_utility.c |
sceNpLookupCreateTitleCtx |
implemented | runtime/syslib/np_utility.c |
sceNpLookupDeleteRequest |
implemented | runtime/syslib/np_utility.c |
sceNpLookupDeleteTitleCtx |
implemented | runtime/syslib/np_utility.c |
sceNpLookupNpId |
implemented | runtime/syslib/np_utility.c |
sceNpLookupPollAsync |
implemented | runtime/syslib/np_utility.c |
libSceNpWebApi
| Call | Status | Source |
|---|---|---|
sceNpWebApiAbortRequest |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiCreateContext |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiCreatePushEventFilter |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiCreateRequest |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiDeleteContext |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiDeletePushEventFilter |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiDeleteRequest |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiGetHttpResponseHeaderValue |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiGetHttpResponseHeaderValueLength |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiGetHttpStatusCode |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiInitialize |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiReadData |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiRegisterPushEventCallback |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiSendRequest |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiTerminate |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiUnregisterPushEventCallback |
implemented | runtime/syslib/np_web_api.c |
sceNpWebApiUtilityParseNpId |
implemented | runtime/syslib/np_web_api.c |
libScePad
| Call | Status | Source |
|---|---|---|
scePadClose |
implemented | runtime/syslib/pad.c |
scePadGetControllerInformation |
implemented | runtime/syslib/pad.c |
scePadInit |
implemented | runtime/syslib/pad.c |
scePadOpen |
implemented | runtime/syslib/pad.c |
scePadReadState |
implemented | runtime/syslib/pad.c |
scePadResetOrientation |
implemented | runtime/syslib/pad.c |
scePadSetAngularVelocityDeadbandState |
implemented | runtime/syslib/pad.c |
scePadSetTiltCorrectionState |
implemented | runtime/syslib/pad.c |
scePadSetVibration |
implemented | runtime/syslib/pad.c |
libScePlayGo
| Call | Status | Source |
|---|---|---|
scePlayGoGetChunkId |
implemented | runtime/syslib/playgo.c |
scePlayGoGetLocus |
implemented | runtime/syslib/playgo.c |
scePlayGoInitialize |
implemented | runtime/syslib/playgo.c |
scePlayGoOpen |
implemented | runtime/syslib/playgo.c |
scePlayGoSetInstallSpeed |
implemented | runtime/syslib/playgo.c |
libScePosix
| Call | Status | Source |
|---|---|---|
getpagesize |
implemented | runtime/syslib/kernel.c |
gettimeofday |
implemented | runtime/syslib/kernel_time_of_day.c |
mkdir |
implemented | runtime/syslib/file_names.c |
pthread_attr_destroy |
implemented | runtime/syslib/kernel_thread.c |
pthread_attr_init |
implemented | runtime/syslib/kernel_thread.c |
pthread_attr_setdetachstate |
implemented | runtime/syslib/kernel_thread.c |
pthread_attr_setschedparam |
implemented | runtime/syslib/kernel_thread.c |
pthread_attr_setstacksize |
implemented | runtime/syslib/kernel_thread.c |
pthread_cond_broadcast |
implemented | runtime/syslib/kernel_mutex.c |
pthread_cond_destroy |
implemented | runtime/syslib/kernel_mutex.c |
pthread_cond_init |
implemented | runtime/syslib/kernel_mutex.c |
pthread_cond_signal |
implemented | runtime/syslib/kernel_mutex.c |
pthread_cond_timedwait |
implemented | runtime/syslib/kernel_mutex.c |
pthread_cond_wait |
implemented | runtime/syslib/kernel_mutex.c |
pthread_create |
implemented | runtime/syslib/kernel_thread.c |
pthread_create_name_np |
implemented | runtime/syslib/kernel_thread.c |
pthread_exit |
implemented | runtime/syslib/kernel_thread.c |
pthread_join |
implemented | runtime/syslib/kernel_thread.c |
pthread_mutex_destroy |
implemented | runtime/syslib/kernel_mutex.c |
pthread_mutex_init |
implemented | runtime/syslib/kernel_mutex.c |
pthread_mutex_lock |
implemented | runtime/syslib/kernel_mutex.c |
pthread_mutex_trylock |
implemented | runtime/syslib/kernel_mutex.c |
pthread_mutex_unlock |
implemented | runtime/syslib/kernel_mutex.c |
pthread_mutexattr_destroy |
implemented | runtime/syslib/kernel_mutex.c |
pthread_mutexattr_init |
implemented | runtime/syslib/kernel_mutex.c |
pthread_mutexattr_settype |
implemented | runtime/syslib/kernel_mutex.c |
pthread_self |
implemented | runtime/syslib/kernel_thread.c |
rename |
implemented | runtime/syslib/file_names.c |
rmdir |
implemented | runtime/syslib/file_names.c |
sleep |
implemented | runtime/syslib/kernel.c |
stat |
implemented | runtime/syslib/files.c |
usleep |
implemented | runtime/syslib/kernel.c |
libSceRtc
| Call | Status | Source |
|---|---|---|
sceRtcConvertLocalTimeToUtc |
implemented | runtime/syslib/rtc.c |
sceRtcConvertUtcToLocalTime |
implemented | runtime/syslib/rtc.c |
sceRtcFormatRFC2822LocalTime |
implemented | runtime/syslib/rtc.c |
sceRtcGetCurrentClockLocalTime |
implemented | runtime/syslib/rtc.c |
sceRtcGetCurrentNetworkTick |
implemented | runtime/syslib/rtc.c |
sceRtcGetDayOfWeek |
implemented | runtime/syslib/rtc.c |
sceRtcGetTick |
implemented | runtime/syslib/rtc.c |
sceRtcGetTickResolution |
implemented | runtime/syslib/rtc.c |
sceRtcSetTick |
implemented | runtime/syslib/rtc.c |
sceRtcSetTime_t |
implemented | runtime/syslib/rtc.c |
libSceSaveData
| Call | Status | Source |
|---|---|---|
sceSaveDataDelete |
implemented | runtime/syslib/save_data.c |
sceSaveDataDirNameSearch |
implemented | runtime/syslib/save_data.c |
sceSaveDataGetSaveDataMemory |
implemented | runtime/syslib/save_data.c |
sceSaveDataInitialize |
implemented | runtime/syslib/save_data.c |
sceSaveDataMount |
implemented | runtime/syslib/save_data.c |
sceSaveDataSaveIcon |
implemented | runtime/syslib/save_data.c |
sceSaveDataSetParam |
implemented | runtime/syslib/save_data.c |
sceSaveDataSetSaveDataMemory |
implemented | runtime/syslib/save_data.c |
sceSaveDataSetupSaveDataMemory |
implemented | runtime/syslib/save_data.c |
sceSaveDataTerminate |
implemented | runtime/syslib/save_data.c |
sceSaveDataUmount |
implemented | runtime/syslib/save_data.c |
libSceSaveDataDialog
| Call | Status | Source |
|---|---|---|
sceSaveDataDialogInitialize |
implemented | runtime/syslib/dialogs.c |
sceSaveDataDialogOpen |
implemented | runtime/syslib/dialogs.c |
sceSaveDataDialogTerminate |
implemented | runtime/syslib/dialogs.c |
sceSaveDataDialogUpdateStatus |
implemented | runtime/syslib/dialogs.c |
libSceSsl
| Call | Status | Source |
|---|---|---|
sceSslInit |
implemented | runtime/syslib/network.c |
sceSslTerm |
implemented | runtime/syslib/network.c |
libSceSysmodule
| Call | Status | Source |
|---|---|---|
sceSysmoduleIsLoaded |
implemented | runtime/syslib/kernel_sysmodule.c |
sceSysmoduleLoadModule |
implemented | runtime/syslib/kernel_sysmodule.c |
sceSysmoduleUnloadModule |
implemented | runtime/syslib/kernel_sysmodule.c |
libSceSystemService
| Call | Status | Source |
|---|---|---|
sceSystemServiceGetStatus |
implemented | runtime/syslib/system_service.c |
sceSystemServiceHideSplashScreen |
implemented | runtime/syslib/system_service.c |
sceSystemServiceLaunchWebBrowser |
implemented | runtime/syslib/system_service.c |
sceSystemServiceParamGetInt |
implemented | runtime/syslib/system_service.c |
sceSystemServiceReceiveEvent |
implemented | runtime/syslib/system_service.c |
libSceUserService
| Call | Status | Source |
|---|---|---|
sceUserServiceGetEvent |
implemented | runtime/syslib/user_service.c |
sceUserServiceGetInitialUser |
implemented | runtime/syslib/user_service.c |
sceUserServiceGetLoginUserIdList |
implemented | runtime/syslib/user_service.c |
sceUserServiceGetUserName |
implemented | runtime/syslib/user_service.c |
sceUserServiceInitialize |
implemented | runtime/syslib/user_service.c |
sceUserServiceTerminate |
implemented | runtime/syslib/user_service.c |
libSceVideoOut
| Call | Status | Source |
|---|---|---|
sceVideoOutAddFlipEvent |
implemented | runtime/syslib/video_out.c |
sceVideoOutClose |
implemented | runtime/syslib/video_out.c |
sceVideoOutGetFlipStatus |
implemented | runtime/syslib/video_out.c |
sceVideoOutOpen |
implemented | runtime/syslib/video_out.c |
sceVideoOutRegisterBuffers |
implemented | runtime/syslib/video_out.c |
sceVideoOutSetBufferAttribute |
implemented | runtime/syslib/video_out.c |
sceVideoOutSetFlipRate |
implemented | runtime/syslib/video_out.c |
sceVideoOutSubmitFlip |
implemented | runtime/syslib/video_out.c |
libSceVoice
| Call | Status | Source |
|---|---|---|
sceVoiceConnectIPortToOPort |
implemented | runtime/syslib/voice.c |
sceVoiceCreatePort |
implemented | runtime/syslib/voice.c |
sceVoiceDeletePort |
implemented | runtime/syslib/voice.c |
sceVoiceDisconnectIPortFromOPort |
implemented | runtime/syslib/voice.c |
sceVoiceEnd |
implemented | runtime/syslib/voice.c |
sceVoiceGetPortInfo |
implemented | runtime/syslib/voice.c |
sceVoiceInit |
implemented | runtime/syslib/voice.c |
sceVoiceReadFromOPort |
implemented | runtime/syslib/voice.c |
sceVoiceStart |
implemented | runtime/syslib/voice.c |
sceVoiceStop |
implemented | runtime/syslib/voice.c |
sceVoiceWriteToIPort |
implemented | runtime/syslib/voice.c |
The former startup stop: CPU affinity
| Call | Status | What the runtime does |
|---|---|---|
scePthreadAttrGetaffinity |
implemented | Answers the ruled mask since #561 (11 November), 0x3f by default since #585. From #207 the C library's probe no longer called it; since #571 it does again. The boot of 19 October stopped here; the boot of 4 November passes it. |
A thread's CPU affinity mask says which CPU cores it may run on, one bit per core. The boot of
19 October stopped when the bundled libc.elf asked for the main thread's mask.
What the caller does. It is understood from the hash-pinned module:
- Copy the attributes. It copies the current thread's attributes.
- Ask for the mask. It passes the attribute variable and an eight-byte zeroed slot: two pointers, not FreeBSD's three-argument form with a size.
- Count the cores. It ignores the result, counts the set bits in the slot, and stores that count.
Synthetic runs of that original caller with scripted imports confirm this. They are not observations of PS4 affinity.
Why the runtime did not answer at first. Returning success with a guessed mask would change the CPU
count the C library stores without implementing the query. So the import stayed unbound while the
main thread's real mask, the exact output width and the error contract were unknown.
Issue #34 tracked it. BluePinetree
claimed the work:
a way for the runtime to replace a function inside a bundled module such as libc.elf, so this
probe could be answered there.
How it was answered (#207, by BluePinetree, merged 3 November 2026). The runtime can
now replace a function inside a bundled module before any of its code runs: it writes a jump
at the function's start to a small stub just past the module's image. Two replacements are listed
in game/module_hooks.csv for the pinned libc.elf:
- the thread-count probe described above returns at once, so
scePthreadAttrGetaffinityis never called and the stored core count stays as it was (no mask is invented; this hook was dropped in #571, below); std::thread::hardware_concurrency, which would read that count, stops the run by name if the game ever calls it, the same way an unimplemented import stops it.
Since #456 (also by
BluePinetree) each entry also lists the function's first bytes, and pbboot compares them with
the loaded module before patching: a different libc.elf build is refused by name before any
game code runs, instead of patching the middle of another function.
The boot recorded on 4 November 2026 (#295) confirms it: merged main now passes this
point; later the same day (#300) it reaches the video out milestone. The hooks only cover these two functions, and their offsets fit only the pinned
libc.elf.
What it answers now (#561, merged 11 November 2026). The console's own mask is still not
measured. On 10 November the maintainer ruled that a thread whose mask the game never set answers
all ones, as scePthreadGetaffinity already did (on 11 November a second ruling made the default 0x3f, below). So scePthreadAttrGetaffinity(attr, mask) writes
eight bytes: the mask set on the attribute with scePthreadAttrSetaffinity, or the thread's mask that
scePthreadAttrGet copied (from its creation attribute or scePthreadSetaffinity), otherwise
UINT64_MAX. A variable holding no attribute is EINVAL; no variable for the mask stops by name. The
host's CPUs are not consulted. @evill33t's #239 did the groundwork,
taking the value from the host, which the ruling replaced. The tests (test/syslib/attr_affinity.c)
check a fresh attribute with canaries around the eight bytes, set masks up to bit 63, copies from
threads with and without a mask, and the two error paths; four planted mistakes are caught.
The probe hook above stays, so the game's CPU count does not change; whether to drop it and let the
probe count the ruled mask is a separate decision.
The probe runs again (#571, merged 11 November 2026; default 0x3f since #585). The
maintainer decided to drop the probe's hook, so the original probe runs in libc.elf's start-up code,
before any of the executable's code. It asks scePthreadAttrGetaffinity about a copy of the main
thread's attributes, which have no mask set by the game yet, counts the set bits and stores the count
at libc.elf+0xd1c54. On 11 November the maintainer ruled that the default mask is 0x3f, the six
CPUs 0 to 5: the mask the executable's own thread setup gives each thread. Both
scePthreadGetaffinity and scePthreadAttrGetaffinity answer it for a thread or attribute with no
mask. A local boot without a display read 6 from the running process (64 under the first ruling,
0 while the hook was in place). That count follows from the ruling; the console's own mask is still
not measured. The second hook stays: std::thread::hardware_concurrency, the count's only reader
found, still stops the run by name, so nothing reads the ruled count as if it were the console's.
The boot recorded with #571 shows 248 imports called, up from 243.
scePthreadAttrGetaffinity: declaration source
OpenOrbis libkernel.h
has the affinity declaration. It is corroboration, not a measured PS4 contract.
Implementation and tests
- Implement only behavior supported by public documentation, independent reverse engineering, or observed behavior.
- Keep unresolved target behavior visible; do not fabricate a return value to make
tools/boot.pyadvance. - Add cases for each established behavior and error path in a test file of the group's own,
test/syslib/<group>.c, asSYSLIB_TEST(name) { ... }blocks (#407;test/syslib/np_trophy.cis an example), so parallel pull requests do not edit the same lines. Cases already intest/test_syslib.cmay be updated there. - Runtime-only contributions do not need a game dump, captures, or function-level
verify.pyresults; CI builds and runs the runtime and syslib tests.
References
References
- POSIX
clock_gettime, POSIX clock definitions, and POSIXgetpid - Older POSIX
gettimeofdayspecification - FreeBSD
getpagesize(3),clock_gettime(2), andgettimeofday(2) - Linux
getpagesize(2),getpid(2),clock_gettime(2), andgettimeofday(2) - PSP2SDK network API declarations for the four SCE byte-order functions
- FreeBSD
htonl(3)/htons(3)/ntohl(3)/ntohs(3) - POSIX
pthread_self, POSIXpthread_attr_init/pthread_attr_destroyand FreeBSD libthrthr_attr.c - FreeBSD
usleep(3)and SUSv2usleep - POSIX
sleep, FreeBSDsleep(3)and FreeBSD libcsleep.c - LSB Core
__stack_chk_failand FreeBSD libclibc_stack_protector.c - OpenOrbis toolchain
Sysmodule.hand_types/sysmodule.h; OpenOrbislibkernel.hfor the affinity declaration (corroboration, not a measured PS4 contract)