Difference between revisions of "IPC (SDK)"
Jump to navigation
Jump to search
Hallowizer (talk | contribs) (Memory section came from Revolution OS) |
Hallowizer (talk | contribs) m (Typo) |
||
Line 1: | Line 1: | ||
− | '''IPC''' is the [[SDK]] library that | + | '''IPC''' is the [[SDK]] library that provides functions for communication with [[IOS]]. It seems to also mirror some [[IOS/Syscalls|IOS syscalls]], suggesting that IOS was originally planned to run on the [[Broadway]]. |
== Memory allocation == | == Memory allocation == |
Revision as of 20:40, 5 January 2022
IPC is the SDK library that provides functions for communication with IOS. It seems to also mirror some IOS syscalls, suggesting that IOS was originally planned to run on the Broadway.
Memory allocation
Memory used by IPC and NAND is mainly allocated with iosAllocAligned
, which allocates from one of 8 heaps, each with the following structure:
struct HeapBlockHeader { u16 magic; // always 0xbabe u16 status; // 0 means free, 1 means it is in the process of being allocated, 2 means it is being used u32 size; struct HeapBlockHeader *prev; // points to the same heap block if it is allocated, NULL for the beginning of the heap struct HeapBlockHeader *next; // NULL for the end of the heap or if this heap block is allocated } struct Heap { void *base; u32 processId; // See note below u32 size; struct HeapBlockHeader *firstBlock; }
processId
is probably only present to match the struct used by IOS; it is never set or checked, so it is probably filled with undefined values.