public class JvmReferenceAbstractState extends JvmAbstractState<SetAbstractState<Reference>>
JvmAbstractState
for the reference CPA. Since the analysis may skip library methods
which include some constructors, it treats missing information about variables (i.e.,
initialization) as if they were references to distinct heap locations. Thus, we can approximate
missing analysis of library constructors and call site of the entry method. Thus, some aliasing
can be missed and the analysis result becomes unsound.DEFAULT_FIELD, frame, heap, programLocation, staticFields, topLocation
Constructor and Description |
---|
JvmReferenceAbstractState(JvmCfaNode programLocation,
JvmFrameAbstractState<SetAbstractState<Reference>> frame,
JvmHeapAbstractState<SetAbstractState<Reference>> heap,
MapAbstractState<java.lang.String,SetAbstractState<Reference>> staticFields)
Create a JVM reference abstract state.
|
Modifier and Type | Method and Description |
---|---|
JvmReferenceAbstractState |
copy()
Creates a copy of itself.
|
<T> SetAbstractState<Reference> |
getFieldOrDefault(T object,
java.lang.String descriptor,
SetAbstractState<Reference> defaultValue)
Returns an abstract state representing the field
descriptor of the object or
defaultState if there is no entry. |
SetAbstractState<Reference> |
getStaticOrDefault(java.lang.String fqn,
SetAbstractState<Reference> defaultState)
Returns an abstract state representing the static field
fqn or defaultState if
there is no entry. |
SetAbstractState<Reference> |
getVariableOrDefault(int index,
SetAbstractState<Reference> defaultState)
Returns an abstract state at the
index th position of the variable array or defaultState if there is no entry. |
JvmReferenceAbstractState |
join(JvmAbstractState<SetAbstractState<Reference>> abstractState)
Computes a join over itself and the
abstractState . |
clearOperandStack, equals, getArrayElementOrDefault, getFieldOrDefault, getFrame, getHeap, getProgramLocation, getStaticFields, hashCode, isLessOrEqual, newArray, newObject, newObject, peek, peek, peekOrDefault, peekOrDefault, pop, popOrDefault, push, pushAll, setArrayElement, setField, setField, setProgramLocation, setStatic, setVariable
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
isLess
getPrecision, getStateByName
public JvmReferenceAbstractState(JvmCfaNode programLocation, JvmFrameAbstractState<SetAbstractState<Reference>> frame, JvmHeapAbstractState<SetAbstractState<Reference>> heap, MapAbstractState<java.lang.String,SetAbstractState<Reference>> staticFields)
programLocation
- a CFA nodeframe
- a frame abstract stateheap
- a heap abstract statestaticFields
- a static field tablepublic SetAbstractState<Reference> getVariableOrDefault(int index, SetAbstractState<Reference> defaultState)
JvmAbstractState
index
th position of the variable array or defaultState
if there is no entry.getVariableOrDefault
in class JvmAbstractState<SetAbstractState<Reference>>
public SetAbstractState<Reference> getStaticOrDefault(java.lang.String fqn, SetAbstractState<Reference> defaultState)
JvmAbstractState
fqn
or defaultState
if
there is no entry.getStaticOrDefault
in class JvmAbstractState<SetAbstractState<Reference>>
public <T> SetAbstractState<Reference> getFieldOrDefault(T object, java.lang.String descriptor, SetAbstractState<Reference> defaultValue)
JvmAbstractState
descriptor
of the object
or
defaultState
if there is no entry.getFieldOrDefault
in class JvmAbstractState<SetAbstractState<Reference>>
public JvmReferenceAbstractState join(JvmAbstractState<SetAbstractState<Reference>> abstractState)
LatticeAbstractState
abstractState
.join
in interface LatticeAbstractState<JvmAbstractState<SetAbstractState<Reference>>>
join
in class JvmAbstractState<SetAbstractState<Reference>>
public JvmReferenceAbstractState copy()
AbstractState
copy
in interface AbstractState
copy
in class JvmAbstractState<SetAbstractState<Reference>>