Interference graph
Instructions
Live vars
b = a + 2
c = b * b
a,c
b = c + 1
b,a
return b * a
Monday, October 17, 2011
Interference graph
Instructions
Live vars
b = a + 2
b,a
c = b * b
a,c
b = c + 1
b,a
return b * a
Monday, October 17, 2011
Interference graph
Instructions
Live vars
a
b = a + 2
b,a
c = b * b
a,c
b = c + 1
b,a
return b * a
Monday, October 17, 2011
Interference graph
Instructions
Live vars
a
b = a + 2
a,b
c = b * b
a,c
b = c + 1
a,b
return b * a
a
c
b
eax
ebx
color
register
Monday, October 17, 2011
Interference graph
Instructions
Live vars
a
b = a + 2
a,b
c = b * b
a,c
b = c + 1
a,b
return b * a
a
c
b
eax
ebx
color
register
Monday, October 17, 2011
Graph coloring
• Questions:
– Can we efficiently find a coloring of the graph
whenever possible?
– Can we efficiently find the optimum coloring of