Compiling C to MIPS
What does the compiler need to do to convert C to MIPS?
- pre-process
#include and #define
- parse code to check syntactically valid
- manage a list of symbols used in program
- decide how to represent data structures
- allocate local variables to registers or stack
- map control structures to MIPS instructions
|