-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME
57 lines (44 loc) · 1.86 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
Alan Compiler
Project for Course: http://courses.softlab.ntua.gr/compilers/
Author: Lampropoulos Leonidas - 03107044
Compilation:
make depend
make
Basics:
Lexer: Lexer.mll AlanString.ml
Parser: Parser.mly
Semantic: Semantic.ml
Intermediate: QuadTypes.ml Quads.ml
Final Code: FinalTypes.ml Final.ml AlanString.ml
Optimizations:
Easy ones:
-Constant Folding (Deactivated) : Optimizations.ml
-Reverse Copy Propagation : Optimizations.ml
-Linear Unreachable Code Elimination : CodeElimination.ml
-Jump Simplification : Optimizations.ml
Control Flow:
-Block Conversion : Blocks.ml
-Flowgraph creation : ControlFlow.ml
-Dominators (used for SSA) : ControlFlow.ml
-Tail Recursion Elimination : TailRecursion.ml
-Unreachable Code Elimination (flow) : CodeElimination.ml
Data Flow:
-SSA (calculation of phi-points) : SSA.ml (unused - UDChains used for CP instead)
-Copy Propagation : CopyPropagation.ml
-Reaching Definitions : UDChains.ml
-Dead Code Elimination : DeadCodeElimination.ml
-Constant Propagation : ConstantPropagation.ml
Low Level:
-Consecutive Load/Store Deletions : FinalOptimizations.ml
Other:
-Remove unused temporaries : CodeElimination.ml
-Fixed point computation : Main.ml (trivial)
Significant Changes:
-Added type to scope, library flag in functions
-Added hashtable field in functions to contain global use information
-Added special "TailCall" Quad
-Added live parameter list in par quad
-Changed the logic of intermediate code jump creation (see pdf readme...)
-Added pointer type to handle arrays more clearly
-Debug.ml contains flag declaration to enable debugging messages
For more information, AlanCompiler.pdf. (Turned out little longer than expected...)