Intermediate Representation
Tiger in Stratego -- Compilation by Program Transformation
IntermediateRepresentation is an abstract machine language that abstracts from the details of both source and target languages.
The definition of the
IntermediateRepresentation used in the
TigerCompiler, as well as components translating from
TigerAbstractSyntax and to assembly code, are provided in the
IR package.
Statements and Expressions
Module
IR defines the signature of intermediate representation expressions and statements.
Operators
Module
Operators provides the definition of operators.
Procedure Fragments
Module
Proc defines the structure of the
PROC fragment constructor. This constructor is not
only used in the intermediate format, but also in the abstract assembly language
ASM produced by
InstructionSelection. The
PROC fragments contain information about stack frame layout that
is used during register allocation. For this reason the module is provided in the
ASM package.
Concrete Syntax
CompilerComponent