NAME ^

compilers/imcc/imc.c

DESCRIPTION ^

Routines for handling imc_units, which represent subs.

Moved all register allocation and spill code to reg_alloc.c

Functions ^

void imc_compile_all_units

Compiles all imc_units, and free all memory of instructions and structures afterwards.

void imc_compile_unit

Compiles each unit in IMCC. This is the main loop of the compiler; it operates on a single compilation unit at a time.

void imc_cleanup

Cleans up the compiler state in preparation for another compiler invocation.

static IMC_Unit *imc_new_unit

Creates a new IMC_Unit of the given IMC_Unit_Type t.

IMC_Unit *imc_open_unit

Creates a new IMC_Unit and "open" it for construction. This sets the current state of the parser. You can close the unit later while retaining all the current state.

void imc_close_unit

Closes a unit from compilation. This does not destroy the unit, but leaves it on the list of units.

static void imc_free_unit

Frees an IMC_Unit and all of its associated memory.


parrot