Purpose | To guide a team though the implementation of a compiler. | |
Entry Criteria |
|
|
General |
|
|
Phases | Activities | Description |
|
Implementation Language |
Choose a suitable implementation language (see parsing strategy). |
Syntax Error Reporting and Handling |
Detect
|
|
|
Intermediate Representation |
Choose an intermediate representation
|
|
Semantic or Contextual Analysis |
Construct a contextual analyzer
|
Context Error Reporting and Handling |
Detect
|
|
|
Code Transformation (Optional) |
Construct a machine independent code transformer (optimizer) for
the AST
|
|
||
Code Generator |
Choose a target machine or language
Develop code functions for each phrase class. Develop code templates for each distinct form of phrase Complete the code generator as a visitor pattern for the AST |
|
Runtime Error Reporting and Handling |
Detect
|
|
|
Peephole Optimizer (optional) |
Fine tune the code with a machine dependent peephole optimizer. |
|
A working compiler |
Based on notes by Anthony Aaby.