summaryrefslogtreecommitdiffstats
path: root/content/zettel/1c5c.md
diff options
context:
space:
mode:
Diffstat (limited to 'content/zettel/1c5c.md')
-rw-r--r--content/zettel/1c5c.md25
1 files changed, 25 insertions, 0 deletions
diff --git a/content/zettel/1c5c.md b/content/zettel/1c5c.md
new file mode 100644
index 0000000..de4f6ee
--- /dev/null
+++ b/content/zettel/1c5c.md
@@ -0,0 +1,25 @@
++++
+title = "Graph-Colouring Allocation"
+author = "Yann Herklotz"
+tags = []
+categories = []
+backlinks = ["1c5b"]
+forwardlinks = ["1c5d"]
+zettelid = "1c5c"
++++
+
+The following are the main phases of graph-colouring:
+
+1. **Renumber**: discover the live range information in the source
+ program.
+2. **Build**: build the inference graph.
+3. **Coalesce**: merge the live ranges of non-interfering variables
+ related by copy instructions.
+4. **Spill cost**: compute the spill cost of each variable. This
+ assesses the impact of mapping a variable to memory on the speed of
+ the final program.
+5. **Simplify**: construct an ordering of the nodes in the inferences
+ graph.
+6. **Spill code**: insert spill instructions, i.e. loads and stores to
+ commute values between registers and memory.
+7. **Select**: assign a register to each variable.