aboutsummaryrefslogtreecommitdiff
path: root/lib/Analysis/RegionStore.cpp
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2009-04-09 22:22:44 +0000
committerTed Kremenek <kremenek@apple.com>2009-04-09 22:22:44 +0000
commit8d7f5481a0eeb4c0508202a4bd2b754cfa93c4fe (patch)
treefbd4f2479b757e9694ffa66acf47cb6a12e72496 /lib/Analysis/RegionStore.cpp
parentc612f7bc9a6379cd7e7c2dd306d05938e890051b (diff)
- 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
Diffstat (limited to 'lib/Analysis/RegionStore.cpp')
-rw-r--r--lib/Analysis/RegionStore.cpp12
1 files changed, 5 insertions, 7 deletions
diff --git a/lib/Analysis/RegionStore.cpp b/lib/Analysis/RegionStore.cpp
index 5e60363573..4088158627 100644
--- a/lib/Analysis/RegionStore.cpp
+++ b/lib/Analysis/RegionStore.cpp
@@ -148,7 +148,7 @@ class VISIBILITY_HIDDEN RegionStoreManager : public StoreManager {
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 @@ public:
virtual ~RegionStoreManager() {}
- MemRegionManager& getRegionManager() { return MRMgr; }
-
SubRegionMap* getSubRegionMap(const GRState *state);
const GRState* BindCompoundLiteral(const GRState* St,
@@ -756,7 +754,7 @@ SVal RegionStoreManager::Retrieve(const GRState* St, Loc L, QualType T) {
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 @@ SVal RegionStoreManager::Retrieve(const GRState* St, Loc L, QualType T) {
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 @@ SVal RegionStoreManager::Retrieve(const GRState* St, Loc L, QualType T) {
// 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 @@ SVal RegionStoreManager::RetrieveStruct(const GRState* St,const TypedRegion* R){
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);