R0 = Reason code
other registers as appropriate for reason code
The following heap operations are available:-
This SWI provides access to a heap management system. Access to blocks
is provided via 'anchors'. When calling WimpExt_Heap routines, you can
either refer to a block by a pointer to it, or by a pointer to its
anchor. I will refer to this as a 'block pointer'. The anchor contains
the address of the block. This address may change on calls to
WimpExt_Heap as the blocks are shuffled around, but the anchor will
always stay fixed. The size of the block is stored 4 bytes before the
start of the block.
eg. to find the size of a block from its anchor:
size%=!((!anchor%)-4)
All these calls can return the errors 'Heap corrupt' or 'Bad heap
operation'. All the calls act on the currently selected heap. The heap
can be selected using R0=14.
|
|
|