public class LiveVariablesProblem extends DataFlowProblem
DataFlowProblem.DF_Direction
_cfg, _direction, _fgNodes
Constructor and Description |
---|
LiveVariablesProblem() |
Modifier and Type | Method and Description |
---|---|
void |
addDFVar(Variable v) |
java.util.Set<Variable> |
allDefinedOrUsedVariables() |
FlowGraphNode |
buildFlowGraphNode(BasicBlock bb) |
java.util.Set<Variable> |
getAllVars() |
java.lang.String |
getDataFlowVarsForOutput() |
DataFlowVar |
getDFVar(Variable v) |
java.lang.String |
getName() |
Variable |
getVariable(int id) |
java.util.List<Variable> |
getVarsLiveOnEntry()
Get variables that are live on entry to the cfg.
|
java.util.Collection<Variable> |
getVarsLiveOnExit() |
void |
initVarsLiveOnExit(java.util.Collection<Variable> vars)
Initialize the exit cfg with variables that are live on exit
This is the case for closures where vars defined in the closure (or accessed from the surrounding scope)
can be used outside the closure.
|
boolean |
isDefinedOrUsed(Variable v) |
void |
markDeadInstructions() |
void |
setup(CFG c) |
compute_MOP_Solution, getCFG, getDFVarsCount, getFlowDirection, getFlowGraphNode, incomingEdgesOf, isEmpty, outgoingEdgesOf, toString
public java.lang.String getName()
getName
in class DataFlowProblem
public DataFlowVar getDFVar(Variable v)
public Variable getVariable(int id)
public FlowGraphNode buildFlowGraphNode(BasicBlock bb)
buildFlowGraphNode
in class DataFlowProblem
public void addDFVar(Variable v)
public void initVarsLiveOnExit(java.util.Collection<Variable> vars)
public java.util.List<Variable> getVarsLiveOnEntry()
public void setup(CFG c)
setup
in class DataFlowProblem
public java.lang.String getDataFlowVarsForOutput()
getDataFlowVarsForOutput
in class DataFlowProblem
public void markDeadInstructions()
public java.util.Collection<Variable> getVarsLiveOnExit()
public boolean isDefinedOrUsed(Variable v)
public java.util.Set<Variable> allDefinedOrUsedVariables()
public java.util.Set<Variable> getAllVars()
Copyright © 2002-2009 JRuby Team. All Rights Reserved.