harpoon.Backend.CSAHack.RegAlloc
Class Liveness
java.lang.Object
harpoon.Backend.CSAHack.Graph.Graph
harpoon.Backend.CSAHack.RegAlloc.InterferenceGraph
harpoon.Backend.CSAHack.RegAlloc.Liveness
public class Liveness
- extends InterferenceGraph
An interference graph by examination of liveness of nodes
in a flow graph.
- Version:
- 1.00, 25 Nov 1996
- Author:
- C. Scott Ananian
Constructor Summary |
Liveness(FlowGraph flow)
Construct interference graph from flow graph. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Liveness
public Liveness(FlowGraph flow)
- Construct interference graph from flow graph.
tnode
public Node tnode(Temp temp)
- Specified by:
tnode
in class InterferenceGraph
- Parameters:
temp
- a temporary used in the flow graph
- Returns:
- the interference graph node corresponding to the temporary.
gtemp
public Temp gtemp(Node node)
- Specified by:
gtemp
in class InterferenceGraph
- Parameters:
node
- a node in the interference graph.
- Returns:
- the temporary corresponding to the node.
spillCost
public int spillCost(Node node)
- Overrides:
spillCost
in class InterferenceGraph
- Parameters:
node
- a node in the interference graph.
- Returns:
- an estimate of the cost of spilling this node.
moves
public MoveList moves()
- Specified by:
moves
in class InterferenceGraph
- Returns:
- a list of moves found in the flow graph.
newNode
public Node newNode(Temp t)