public class DefaultForwardFlowFunction extends Object implements IForwardFlowFunction
| Constructor and Description |
|---|
DefaultForwardFlowFunction(BoomerangOptions opts) |
| Modifier and Type | Method and Description |
|---|---|
Set<Val> |
callFlow(Statement callSite,
Val fact,
Method callee)
Called by the forward analysis, when the forward solver reaches the callSite.
|
Collection<wpds.interfaces.State> |
callToReturnFlow(ForwardQuery query,
ControlFlowGraph.Edge edge,
Val fact)
Called by the forward analysis, when data-flow by-passes a call site with data-flow fact.
|
protected boolean |
killFlow(Statement curr,
Val value) |
Set<wpds.interfaces.State> |
normalFlow(ForwardQuery query,
ControlFlowGraph.Edge nextEdge,
Val fact)
Called by the forward analysis, for any non return statements or call site statements.
|
Set<Val> |
returnFlow(Method method,
Statement curr,
Val value)
Called by the forward analysis, when the forward solver reaches the returnStmt (any last
statement of callee method) of callee method with data-flow fact returnedVal.
|
void |
setSolver(ForwardBoomerangSolver solver,
com.google.common.collect.Multimap<Field,Statement> fieldLoadStatements,
com.google.common.collect.Multimap<Field,Statement> fieldStoreStatements) |
protected Collection<wpds.interfaces.State> |
systemArrayCopyFlow(ControlFlowGraph.Edge edge,
Val value) |
public DefaultForwardFlowFunction(BoomerangOptions opts)
public Set<Val> returnFlow(Method method, Statement curr, Val value)
IForwardFlowFunctionreturnFlow in interface IForwardFlowFunctionmethod - The method the data-flow analysis returns from. The caller method is not
available, as it will be internally added by the framework.curr - The statement from which the method returns from (will be any last/exit
statement of the callee method)value - The data-flow fact that is returned.public Set<Val> callFlow(Statement callSite, Val fact, Method callee)
IForwardFlowFunctioncallFlow in interface IForwardFlowFunctioncallSite - A call site reached by the backward analysis.fact - The data-flow fact reaching the callSitecallee - The callee that may be invoked at the callSitepublic Set<wpds.interfaces.State> normalFlow(ForwardQuery query, ControlFlowGraph.Edge nextEdge, Val fact)
IForwardFlowFunctionNote: The logic differs from general IFDS logic here. edge.getStart() can also contain a call site, but fact is not used in the call site (no parameter or base variable of the call expression) .
normalFlow in interface IForwardFlowFunctionnextEdge - The control-flow graph edge that will be propagated next.fact - The incoming data-flow fact that reaches the edge.public Collection<wpds.interfaces.State> callToReturnFlow(ForwardQuery query, ControlFlowGraph.Edge edge, Val fact)
IForwardFlowFunctioncallToReturnFlow in interface IForwardFlowFunctionedge - Edge that bypasses the call site. edge.getStart() is the call site,
edge.getTarget() is any succsessorfact - The fact that by-passes the call site.protected Collection<wpds.interfaces.State> systemArrayCopyFlow(ControlFlowGraph.Edge edge, Val value)
public void setSolver(ForwardBoomerangSolver solver, com.google.common.collect.Multimap<Field,Statement> fieldLoadStatements, com.google.common.collect.Multimap<Field,Statement> fieldStoreStatements)
setSolver in interface IForwardFlowFunctionCopyright © 2024. All rights reserved.