public class LiveVariableNode extends FlowGraphNode
| Modifier and Type | Field and Description |
|---|---|
private java.util.BitSet |
in |
private java.util.BitSet |
out |
private int |
setSize |
basicBlock, problem| Constructor and Description |
|---|
LiveVariableNode(DataFlowProblem prob,
BasicBlock n) |
| Modifier and Type | Method and Description |
|---|---|
private void |
addDFVar(Variable v) |
boolean |
applyTransferFunction()
Compute "OUT/IN" for the current node! The choice of "IN/OUT" is
determined by the direction of data flow.
|
void |
buildDataFlowVars(Instr i)
Builds the data-flow variables (or facts) for a particular instruction.
|
void |
compute_MEET(Edge e,
BasicBlock source,
FlowGraphNode pred)
"MEET" current solution of "IN/OUT" with "OUT/IN(pred)", where "pred"
is a predecessor of the current node! The choice of "IN/OUT" is
determined by the direction of data flow.
|
(package private) java.util.BitSet |
getLiveInBitSet() |
(package private) java.util.BitSet |
getLiveOutBitSet() |
void |
init()
Initialize this data flow node for solving the current problem
This is done after building dataflow variables for the problem.
|
void |
initSolnForNode()
Initialize this data flow node to compute the new solution
This is done before iteratively calling the MEET operator.
|
private void |
makeOutExceptionVariablesLiving(java.util.BitSet living)
Collect variables live out of the exception target node.
|
private void |
markAllVariablesLive(LiveVariablesProblem lvp,
java.util.BitSet living,
java.util.Collection<? extends Variable> variableList) |
(package private) void |
markDeadInstructions() |
private void |
markVariableLive(LiveVariablesProblem lvp,
java.util.BitSet living,
Variable x) |
java.lang.String |
toString() |
buildDataFlowVars, computeDataFlowInfo, finalizeSolnForNode, getBB, getExceptionTargetNode, getNonExitBBExceptionTargetNode, hasExceptionsRescuedprivate java.util.BitSet in
private java.util.BitSet out
private int setSize
public LiveVariableNode(DataFlowProblem prob, BasicBlock n)
public void init()
FlowGraphNodeinit in class FlowGraphNodeprivate void addDFVar(Variable v)
public void buildDataFlowVars(Instr i)
FlowGraphNodebuildDataFlowVars in class FlowGraphNodepublic void initSolnForNode()
FlowGraphNodeinitSolnForNode in class FlowGraphNodepublic void compute_MEET(Edge e, BasicBlock source, FlowGraphNode pred)
FlowGraphNodecompute_MEET in class FlowGraphNodeprivate void markAllVariablesLive(LiveVariablesProblem lvp, java.util.BitSet living, java.util.Collection<? extends Variable> variableList)
private void markVariableLive(LiveVariablesProblem lvp, java.util.BitSet living, Variable x)
public boolean applyTransferFunction()
FlowGraphNodeapplyTransferFunction in class FlowGraphNodeprivate void makeOutExceptionVariablesLiving(java.util.BitSet living)
public java.lang.String toString()
toString in class java.lang.Objectvoid markDeadInstructions()
java.util.BitSet getLiveInBitSet()
java.util.BitSet getLiveOutBitSet()