public class CallSiteContextSensitiveAnalysis extends HeapAbstractionFactory
Modifier and Type | Field and Description |
---|---|
CContext |
EMPTY_CONTEXT
Empty context represents methods with no invoking objects (including
static methods).
|
Constructor and Description |
---|
CallSiteContextSensitiveAnalysis()
Create an analysis with the default sensitivity
|
CallSiteContextSensitiveAnalysis(int sensitivity)
Create an analysis with the given context-call-stack depth
|
Modifier and Type | Method and Description |
---|---|
void |
init()
Initialize the factory.
|
protected CContext |
initialContextImpl()
Return the initial CContext, i.e., to analyze the main method.
|
protected CContext |
mergeImpl(CallSiteNode callSite,
HContext receiver,
CContext callerContext)
Produce a code context (i.e., CContext) to analysis code
called from call site
callSite in code context
callerContext , where receiver is
the abstract object for the recevier of the method invocation. |
protected HContext |
recordImpl(CContext context,
AllocSiteNode alloc)
Produce an abstract object (i.e., HContext) to represent an
object created at allocation site
alloc in code
context context . |
java.lang.String |
toString() |
clearMemoization, fixContextForReferenceVariable, initialContext, memoize, memoize, merge, record
public CContext EMPTY_CONTEXT
public CallSiteContextSensitiveAnalysis()
public CallSiteContextSensitiveAnalysis(int sensitivity)
sensitivity
- depth of the call stack to keep track ofpublic java.lang.String toString()
toString
in class java.lang.Object
protected HContext recordImpl(CContext context, AllocSiteNode alloc)
HeapAbstractionFactory
alloc
in code
context context
.recordImpl
in class HeapAbstractionFactory
protected CContext mergeImpl(CallSiteNode callSite, HContext receiver, CContext callerContext)
HeapAbstractionFactory
callSite
in code context
callerContext
, where receiver
is
the abstract object for the recevier of the method invocation.
If the method being called does not have a receiver (i.e., it
is a static method), then receiver
will be null.mergeImpl
in class HeapAbstractionFactory
public void init()
HeapAbstractionFactory
init
in class HeapAbstractionFactory
protected CContext initialContextImpl()
HeapAbstractionFactory
initialContextImpl
in class HeapAbstractionFactory