- Move ownership of MemRegionManager into ValueManager.
- Pull SVal::GetConjuredSymbol() and friends into ValueManager. This greatly
simplifies the calling interface to clients.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@68731 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Analysis/RegionStore.cpp b/lib/Analysis/RegionStore.cpp
index 5e60363..4088158 100644
--- a/lib/Analysis/RegionStore.cpp
+++ b/lib/Analysis/RegionStore.cpp
@@ -148,7 +148,7 @@
public:
RegionStoreManager(GRStateManager& mgr)
- : StoreManager(mgr.getAllocator()),
+ : StoreManager(mgr.getValueManager()),
RBFactory(mgr.getAllocator()),
RVFactory(mgr.getAllocator()),
StateMgr(mgr), SelfRegion(0), SelfDecl(0) {
@@ -159,8 +159,6 @@
virtual ~RegionStoreManager() {}
- MemRegionManager& getRegionManager() { return MRMgr; }
-
SubRegionMap* getSubRegionMap(const GRState *state);
const GRState* BindCompoundLiteral(const GRState* St,
@@ -756,7 +754,7 @@
if (SR == SelfRegion) {
// FIXME: Do we need to handle the case where the super region
// has a view? We want to canonicalize the bindings.
- return SVal::GetRValueSymbolVal(getSymbolManager(), MRMgr, R);
+ return ValMgr.getRValueSymbolVal(R);
}
// Otherwise, we need a new symbol. For now return Unknown.
@@ -778,7 +776,7 @@
VD->hasGlobalStorage()) {
QualType VTy = VD->getType();
if (Loc::IsLocType(VTy) || VTy->isIntegerType())
- return SVal::GetRValueSymbolVal(getSymbolManager(), MRMgr, VR);
+ return ValMgr.getRValueSymbolVal(VR);
else
return UnknownVal();
}
@@ -794,7 +792,7 @@
// All other integer values are symbolic.
if (Loc::IsLocType(RTy) || RTy->isIntegerType())
- return SVal::GetRValueSymbolVal(getSymbolManager(), MRMgr, R);
+ return ValMgr.getRValueSymbolVal(R);
else
return UnknownVal();
}
@@ -833,7 +831,7 @@
if (MRMgr.onStack(FR) || MRMgr.onHeap(FR))
FieldValue = UndefinedVal();
else
- FieldValue = SVal::GetRValueSymbolVal(getSymbolManager(), MRMgr, FR);
+ FieldValue = ValMgr.getRValueSymbolVal(FR);
}
StructVal = getBasicVals().consVals(FieldValue, StructVal);