protected class FlowSensitiveConstantPropagator.BetterConstantPropagator extends ForwardFlowAnalysis<Unit,FlowSensitiveConstantPropagator.ConstantState>
FlowAnalysis.FlowfilterUnitToAfterFlow, unitToAfterFlowfilterUnitToBeforeFlow, graph, unitToBeforeFlow| Constructor and Description |
|---|
BetterConstantPropagator(DirectedGraph<Unit> graph) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
copy(FlowSensitiveConstantPropagator.ConstantState source,
FlowSensitiveConstantPropagator.ConstantState dest)
Creates a copy of the
source flow object in dest. |
protected void |
copyFreshToExisting(FlowSensitiveConstantPropagator.ConstantState in,
FlowSensitiveConstantPropagator.ConstantState dest)
Copies a *fresh* copy of in to dest.
|
protected void |
flowThrough(FlowSensitiveConstantPropagator.ConstantState in,
Unit d,
FlowSensitiveConstantPropagator.ConstantState out)
Given the merge of the
out sets, compute the in set for s (or in to out,
depending on direction). |
protected void |
merge(FlowSensitiveConstantPropagator.ConstantState in1,
FlowSensitiveConstantPropagator.ConstantState in2,
FlowSensitiveConstantPropagator.ConstantState out)
Compute the merge of the
in1 and in2 sets, putting the result into out. |
protected void |
mergeInto(Unit succNode,
FlowSensitiveConstantPropagator.ConstantState inout,
FlowSensitiveConstantPropagator.ConstantState in)
Merges in into inout, just before node succNode.
|
protected FlowSensitiveConstantPropagator.ConstantState |
newInitialFlow()
Returns the flow object corresponding to the initial values for each graph node.
|
protected boolean |
omissible(Unit n)
If a flow node can be omitted return
true, otherwise false. |
doAnalysis, isForwardgetFlow, getFlowAfter, getFlowBeforeentryInitialFlow, merge, treatTrapHandlersAsEntriespublic BetterConstantPropagator(DirectedGraph<Unit> graph)
protected boolean omissible(Unit n)
FlowAnalysistrue, otherwise false. There is no guarantee a node will
be omitted. A omissible node does not influence the result of an analysis.
If you are unsure, don't overwrite this methodomissible in class FlowAnalysis<Unit,FlowSensitiveConstantPropagator.ConstantState>n - the node to checkfalseprotected void flowThrough(FlowSensitiveConstantPropagator.ConstantState in, Unit d, FlowSensitiveConstantPropagator.ConstantState out)
FlowAnalysisout sets, compute the in set for s (or in to out,
depending on direction).
This function often causes confusion, because the same interface is used for both forward and backward flow analyses.
The first parameter is always the argument to the flow function (i.e. it is the "in" set in a forward analysis and the
"out" set in a backward analysis), and the third parameter is always the result of the flow function (i.e. it is the
"out" set in a forward analysis and the "in" set in a backward analysis).flowThrough in class FlowAnalysis<Unit,FlowSensitiveConstantPropagator.ConstantState>in - the input flowd - the current nodeout - the returned flowprotected FlowSensitiveConstantPropagator.ConstantState newInitialFlow()
AbstractFlowAnalysisnewInitialFlow in class AbstractFlowAnalysis<Unit,FlowSensitiveConstantPropagator.ConstantState>protected void mergeInto(Unit succNode, FlowSensitiveConstantPropagator.ConstantState inout, FlowSensitiveConstantPropagator.ConstantState in)
AbstractFlowAnalysismergeInto in class AbstractFlowAnalysis<Unit,FlowSensitiveConstantPropagator.ConstantState>protected void merge(FlowSensitiveConstantPropagator.ConstantState in1, FlowSensitiveConstantPropagator.ConstantState in2, FlowSensitiveConstantPropagator.ConstantState out)
AbstractFlowAnalysisin1 and in2 sets, putting the result into out. The
behavior of this function depends on the implementation ( it may be necessary to check whether in1 and
in2 are equal or aliased ). Used by the doAnalysis method.merge in class AbstractFlowAnalysis<Unit,FlowSensitiveConstantPropagator.ConstantState>protected void copy(FlowSensitiveConstantPropagator.ConstantState source, FlowSensitiveConstantPropagator.ConstantState dest)
AbstractFlowAnalysissource flow object in dest.copy in class AbstractFlowAnalysis<Unit,FlowSensitiveConstantPropagator.ConstantState>protected void copyFreshToExisting(FlowSensitiveConstantPropagator.ConstantState in, FlowSensitiveConstantPropagator.ConstantState dest)
FlowAnalysiscopyFreshToExisting in class FlowAnalysis<Unit,FlowSensitiveConstantPropagator.ConstantState>Copyright © 2024 Soot OSS. All rights reserved.