|
ACSE 2.0.3
Advanced Compiler System for Education (basic documentation)
|
Program object definition and management. More...
Go to the source code of this file.
Data Structures | |
| struct | t_symbol |
| struct | t_program |
Macros | |
| #define | REG_INVALID ((t_regID)(-1)) |
| Constant used for invalid register identifiers. | |
| #define | REG_0 ((t_regID)(0)) |
| Constant identifying a register whose value is always zero. | |
Typedefs | |
| typedef int | t_regID |
| Type for register identifiers. | |
Enumerations | |
| enum | t_symbolType { TYPE_INT , TYPE_INT_ARRAY } |
Functions | |
Handling of labels | |
| t_label * | createLabel (t_program *program) |
| void | assignLabel (t_program *program, t_label *label) |
| void | setLabelName (t_program *program, t_label *label, const char *name) |
| char * | getLabelName (t_label *label) |
Generation of instructions | |
| t_regID | getNewRegister (t_program *program) |
| t_instruction * | genInstruction (t_program *program, int opcode, t_regID rd, t_regID rs1, t_regID rs2, t_label *label, int immediate) |
| void | removeInstructionAt (t_program *program, t_listNode *instrLi) |
Handling of symbols | |
| t_symbol * | createSymbol (t_program *program, char *ID, t_symbolType type, int arraySize) |
| t_symbol * | getSymbol (t_program *program, char *ID) |
| bool | isArray (t_symbol *symbol) |
Utility functions | |
| void | genEpilog (t_program *program) |
| void | programDump (t_program *program, FILE *fout) |
Program object definition and management.
Definition in file program.h.