11.6.3 Register Allocation by Graph Coloring

Using data flow of uses and definitions of variables, set up use-def chains:

Two program quantities cannot share the same register if their use-def chains overlap.

Called Overlapping lifetimes

Called an Interference Graph

If n registers, and graph can be colored with n colors, registers can be assigned.

An NP-Complete Problem