Skip to content

Stack Control

Simon Amtoft Pedersen edited this page May 5, 2020 · 3 revisions

Table showcasing an example of each Stack Control instruction.

Example Explanation
sens 8 Checks if there is 8 bytes reserved space available in the stack cache. If needed, it refills from the global memory using ss
sfree 4 Frees space on stack by updating ss & st and the stack-cache register head
sres 4 Reserves 4 bytes of the stack, spills to global memory with ss if not enough space
sspill 1 Spills the tail to global memory.

Note: Since Chora doesn't implement a stack, these instructions only updates the pointer registers.

Clone this wiki locally