public class CallDependencies<ContextType extends IContext<ContextType>>
extends java.lang.Object
A call edge is charged when new flow appears on the edge. It is discharged when the callee has no blocks in the worklist, nor any outgoing charged call edges. Return flow can safely ignore call edges that are not charged.
Modifier and Type | Field and Description |
---|---|
static boolean |
DELAY_RETURN_FLOW_UNTIL_DISCHARGED |
static boolean |
DELAY_RETURN_FLOW_UNTIL_INACTIVE |
Constructor and Description |
---|
CallDependencies(GenericSolver.SolverInterface c) |
Modifier and Type | Method and Description |
---|---|
void |
assertEmpty()
Checks whether all functions are inactive.
|
void |
chargeCallEdge(AbstractNode caller,
ContextType caller_context,
ContextType edge_context,
BasicBlock callee,
ContextType callee_context,
boolean implicit)
Records a call edge that awaits return flow.
|
void |
decrementFunctionActivityLevel(BlockAndContext<ContextType> bc)
Decrements the function activity level for the given function and context.
|
void |
dischargeIfInactive(BlockAndContext<ContextType> entry)
Processes return flow and then discharges the incoming call edges if the function is inactive.
|
void |
incrementFunctionActivityLevel(BlockAndContext<ContextType> bc)
Increments the function activity level for the given function and context.
|
boolean |
isCallEdgeCharged(AbstractNode caller,
ContextType caller_context,
ContextType edge_context,
BasicBlock callee,
ContextType callee_context)
Checks whether the given edge is charged.
|
boolean |
isFunctionActive(BlockAndContext<ContextType> bc)
Checks whether the given function and context pair is active,
i.e.
|
void |
registerDelayedReturn(BasicBlock b,
ContextType c)
Registers that processing of return flow has been delayed.
|
public static boolean DELAY_RETURN_FLOW_UNTIL_DISCHARGED
public static boolean DELAY_RETURN_FLOW_UNTIL_INACTIVE
public CallDependencies(GenericSolver.SolverInterface c)
public void assertEmpty()
AnalysisException
- if not all functions are not inactivepublic void chargeCallEdge(AbstractNode caller, ContextType caller_context, ContextType edge_context, BasicBlock callee, ContextType callee_context, boolean implicit)
public void decrementFunctionActivityLevel(BlockAndContext<ContextType> bc)
public void dischargeIfInactive(BlockAndContext<ContextType> entry)
public void incrementFunctionActivityLevel(BlockAndContext<ContextType> bc)
public boolean isCallEdgeCharged(AbstractNode caller, ContextType caller_context, ContextType edge_context, BasicBlock callee, ContextType callee_context)
public boolean isFunctionActive(BlockAndContext<ContextType> bc)
public void registerDelayedReturn(BasicBlock b, ContextType c)
Copyright © 2009-2019 Aarhus University