NAME ^

src/stack_common.c - Common stack handling routines for Parrot

DESCRIPTION ^

Both the register stacks and stacks implemented in src/stacks.c have a common functionality, which is implemented in this file.

These stacks all differ only in the size of items.

Functions ^

void stack_system_init

Called from make_interpreter() to initialize the interpreter's register stacks.

Stack_Chunk_t *register_new_stack

Create a new stack and name it. stack->name is used for debugging/error reporting.

Stack_Chunk_t *cst_new_stack_chunk

Get a new chunk either from the freelist or allocate one.

Stack_Entry_t *stack_prepare_push

Return a pointer, where new entries go for push.

Stack_Entry_t *stack_prepare_pop

Return a pointer, where new entries are popped off.

SEE ALSO ^

include/parrot/stacks.h, src/stacks.c, src/registers.c


parrot