Package it.unive.lisa.interprocedural
Class FixpointResults<A extends it.unive.lisa.analysis.AbstractState<A,H,V,T>,H extends it.unive.lisa.analysis.heap.HeapDomain<H>,V extends it.unive.lisa.analysis.value.ValueDomain<V>,T extends it.unive.lisa.analysis.value.TypeDomain<T>>
- java.lang.Object
-
- it.unive.lisa.analysis.BaseLattice<F>
-
- it.unive.lisa.analysis.lattices.FunctionalLattice<FixpointResults<A,H,V,T>,it.unive.lisa.program.cfg.CFG,CFGResults<A,H,V,T>>
-
- it.unive.lisa.interprocedural.FixpointResults<A,H,V,T>
-
- Type Parameters:
A- the type ofAbstractStatecontained into the analysis stateH- the type ofHeapDomaincontained into the computed abstract stateV- the type ofValueDomaincontained into the computed abstract stateT- the type ofTypeDomaincontained into the computed abstract state
- All Implemented Interfaces:
it.unive.lisa.analysis.Lattice<FixpointResults<A,H,V,T>>,java.lang.Iterable<java.util.Map.Entry<it.unive.lisa.program.cfg.CFG,CFGResults<A,H,V,T>>>
public class FixpointResults<A extends it.unive.lisa.analysis.AbstractState<A,H,V,T>,H extends it.unive.lisa.analysis.heap.HeapDomain<H>,V extends it.unive.lisa.analysis.value.ValueDomain<V>,T extends it.unive.lisa.analysis.value.TypeDomain<T>> extends it.unive.lisa.analysis.lattices.FunctionalLattice<FixpointResults<A,H,V,T>,it.unive.lisa.program.cfg.CFG,CFGResults<A,H,V,T>>
AFunctionalLatticefromCFGs toCFGResultss. This class is meant to store all fixpoint results on all token generated during the interprocedural analysis for each cfg under analysis.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class it.unive.lisa.analysis.lattices.FunctionalLattice
it.unive.lisa.analysis.lattices.FunctionalLattice.FunctionalLift<V extends it.unive.lisa.analysis.Lattice<V>>, it.unive.lisa.analysis.lattices.FunctionalLattice.KeyFunctionalLift<K extends java.lang.Object>
-
-
Constructor Summary
Constructors Constructor Description FixpointResults(CFGResults<A,H,V,T> lattice)Builds a new result.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description FixpointResults<A,H,V,T>bottom()booleancontains(it.unive.lisa.program.cfg.CFG cfg)Yieldstrueif a result exists for the givencfg.voidforget(it.unive.lisa.program.cfg.CFG cfg)Forgets all results about the givenCFG.booleanisBottom()booleanisTop()protected FixpointResults<A,H,V,T>mk(CFGResults<A,H,V,T> lattice, java.util.Map<it.unive.lisa.program.cfg.CFG,CFGResults<A,H,V,T>> function)org.apache.commons.lang3.tuple.Pair<java.lang.Boolean,it.unive.lisa.analysis.CFGWithAnalysisResults<A,H,V,T>>putResult(it.unive.lisa.program.cfg.CFG cfg, ContextSensitivityToken token, it.unive.lisa.analysis.CFGWithAnalysisResults<A,H,V,T> result)Stores the result of a fixpoint computation on a cfg.FixpointResults<A,H,V,T>top()-
Methods inherited from class it.unive.lisa.analysis.lattices.FunctionalLattice
equals, functionalLift, getKeys, getMap, getState, getValues, glbKeys, hashCode, iterator, lessOrEqualAux, lubAux, lubKeys, mkNewFunction, putState, toString, wideningAux
-
-
-
-
Constructor Detail
-
FixpointResults
public FixpointResults(CFGResults<A,H,V,T> lattice)
Builds a new result.- Parameters:
lattice- a singleton instance used for retrieving top and bottom values
-
-
Method Detail
-
putResult
public org.apache.commons.lang3.tuple.Pair<java.lang.Boolean,it.unive.lisa.analysis.CFGWithAnalysisResults<A,H,V,T>> putResult(it.unive.lisa.program.cfg.CFG cfg, ContextSensitivityToken token, it.unive.lisa.analysis.CFGWithAnalysisResults<A,H,V,T> result) throws it.unive.lisa.analysis.SemanticException
Stores the result of a fixpoint computation on a cfg. This method returns the result of callingCFGResults.putResult(ContextSensitivityToken, CFGWithAnalysisResults)with the giventokenandresulton theCFGResultsinstance corresponding tocfg.- Parameters:
cfg- theCFGon which the result has been computedtoken- theContextSensitivityTokenthat identifying the resultresult- theCFGWithAnalysisResultsto store- Returns:
- the result of the update operation on the individual cfg result
- Throws:
it.unive.lisa.analysis.SemanticException- if something goes wrong during the update
-
contains
public boolean contains(it.unive.lisa.program.cfg.CFG cfg)
Yieldstrueif a result exists for the givencfg.- Parameters:
cfg- theCFGwhose result is to be checked- Returns:
trueif that condition holds
-
top
public FixpointResults<A,H,V,T> top()
-
isTop
public boolean isTop()
-
bottom
public FixpointResults<A,H,V,T> bottom()
-
isBottom
public boolean isBottom()
-
forget
public void forget(it.unive.lisa.program.cfg.CFG cfg)
Forgets all results about the givenCFG.- Parameters:
cfg- the cfg to forget
-
mk
protected FixpointResults<A,H,V,T> mk(CFGResults<A,H,V,T> lattice, java.util.Map<it.unive.lisa.program.cfg.CFG,CFGResults<A,H,V,T>> function)
- Specified by:
mkin classit.unive.lisa.analysis.lattices.FunctionalLattice<FixpointResults<A extends it.unive.lisa.analysis.AbstractState<A,H,V,T>,H extends it.unive.lisa.analysis.heap.HeapDomain<H>,V extends it.unive.lisa.analysis.value.ValueDomain<V>,T extends it.unive.lisa.analysis.value.TypeDomain<T>>,it.unive.lisa.program.cfg.CFG,CFGResults<A extends it.unive.lisa.analysis.AbstractState<A,H,V,T>,H extends it.unive.lisa.analysis.heap.HeapDomain<H>,V extends it.unive.lisa.analysis.value.ValueDomain<V>,T extends it.unive.lisa.analysis.value.TypeDomain<T>>>
-
-