Package com.ibm.wala.dataflow.ssa
Class SSAInference<T extends IVariable<?>>
- java.lang.Object
-
- com.ibm.wala.fixedpoint.impl.AbstractFixedPointSolver<T>
-
- com.ibm.wala.fixedpoint.impl.DefaultFixedPointSolver<T>
-
- com.ibm.wala.dataflow.ssa.SSAInference<T>
-
- All Implemented Interfaces:
FixedPointConstants
,IFixedPointSolver<T>
,VerboseAction
- Direct Known Subclasses:
TypeInference
public abstract class SSAInference<T extends IVariable<?>> extends DefaultFixedPointSolver<T>
This class performs intra-procedural propagation over an SSA form. A client will subclass anSSAInference
by providing factories that generateIVariable
s corresponding to SSA value numbers, andAbstractOperator
s corresponding to SSA instructions. This class will set up a dataflow system induced by the SSA def-use graph, and solve the system by iterating to a fixed point.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
SSAInference.OperatorFactory<T extends IVariable>
static interface
SSAInference.VariableFactory
-
Nested classes/interfaces inherited from class com.ibm.wala.fixedpoint.impl.AbstractFixedPointSolver
AbstractFixedPointSolver.Statement
-
-
Field Summary
-
Fields inherited from class com.ibm.wala.fixedpoint.impl.AbstractFixedPointSolver
DEFAULT_PERIODIC_MAINTENANCE_INTERVAL, DEFAULT_VERBOSE_INTERVAL, verbose, workList
-
Fields inherited from interface com.ibm.wala.fixpoint.FixedPointConstants
CHANGED, CHANGED_AND_FIXED, CHANGED_MASK, FIXED_MASK, NOT_CHANGED, NOT_CHANGED_AND_FIXED, SIDE_EFFECT_MASK
-
-
Constructor Summary
Constructors Constructor Description SSAInference()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected T
getVariable(int valueNumber)
protected void
init(IR ir, SSAInference.VariableFactory varFactory, SSAInference.OperatorFactory<T> opFactory)
initializer for SSA Inference equations.String
toString()
Return a string representation of the system-
Methods inherited from class com.ibm.wala.fixedpoint.impl.DefaultFixedPointSolver
getFixedPointSystem
-
Methods inherited from class com.ibm.wala.fixedpoint.impl.AbstractFixedPointSolver
addAllStatementsToWorkList, addToWorkList, changedVariable, emptyWorkList, getMaxEvalBetweenTopo, getMinSizeForTopSort, getNumberOfEvaluations, getPeriodicMaintainInterval, getStatements, getTopologicalGrowthFactor, getVerboseInterval, incNumberOfEvaluations, initForFirstSolve, initializeVariables, initializeWorkList, isChanged, isFixed, isSideEffect, lineBreak, makeStmtRHS, newStatement, newStatement, newStatement, newStatement, newStatement, orderStatements, performVerboseAction, periodicMaintenance, removeStatement, setMaxEvalBetweenTopo, setMinEquationsForTopSort, setTopologicalGrowthFactor, solve
-
-
-
-
Method Detail
-
init
protected void init(IR ir, SSAInference.VariableFactory varFactory, SSAInference.OperatorFactory<T> opFactory)
initializer for SSA Inference equations.
-
getVariable
protected T getVariable(int valueNumber)
- Returns:
- the dataflow variable representing the value number, or null if none found.
-
toString
public String toString()
Return a string representation of the system- Overrides:
toString
in classAbstractFixedPointSolver<T extends IVariable<?>>
- Returns:
- a string representation of the system
-
-