diff options
author | Zhongxing Xu <xuzhongxing@gmail.com> | 2008-10-05 12:12:48 +0000 |
---|---|---|
committer | Zhongxing Xu <xuzhongxing@gmail.com> | 2008-10-05 12:12:48 +0000 |
commit | c1d1bbf691819dc69c122cbdd376c5c630bae378 (patch) | |
tree | c5c4d7392cb237ae4d163cc6e3e2cb525257cd9d /lib/Analysis/BasicStore.cpp | |
parent | eb1542540931887ccd587afd6f9de7d44040b8df (diff) |
Remove redundant parameter and rename StMgr to StateMgr.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@57107 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/BasicStore.cpp')
-rw-r--r-- | lib/Analysis/BasicStore.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/lib/Analysis/BasicStore.cpp b/lib/Analysis/BasicStore.cpp index 4616143d13..3be8a112d2 100644 --- a/lib/Analysis/BasicStore.cpp +++ b/lib/Analysis/BasicStore.cpp @@ -25,10 +25,10 @@ namespace { class VISIBILITY_HIDDEN BasicStoreManager : public StoreManager { VarBindingsTy::Factory VBFactory; - GRStateManager& StMgr; + GRStateManager& StateMgr; public: - BasicStoreManager(GRStateManager& mgr) : StMgr(mgr) {} + BasicStoreManager(GRStateManager& mgr) : StateMgr(mgr) {} virtual ~BasicStoreManager() {} @@ -36,7 +36,7 @@ public: virtual Store SetRVal(Store St, LVal LV, RVal V); virtual Store Remove(Store St, LVal LV); - virtual Store getInitialStore(GRStateManager& StateMgr); + virtual Store getInitialStore(); virtual Store RemoveDeadBindings(Store store, Stmt* Loc, const LiveVariables& Live, @@ -45,7 +45,7 @@ public: virtual void iterBindings(Store store, BindingsHandler& f); - virtual Store AddDecl(Store store, GRStateManager& StateMgr, + virtual Store AddDecl(Store store, const VarDecl* VD, Expr* Ex, RVal InitVal = UndefinedVal(), unsigned Count = 0); @@ -164,7 +164,7 @@ BasicStoreManager::RemoveDeadBindings(Store store, Stmt* Loc, // Iterate over the variable bindings. for (VarBindingsTy::iterator I=B.begin(), E=B.end(); I!=E ; ++I) if (Liveness.isLive(Loc, I.getKey())) { - RegionRoots.push_back(StMgr.getRegion(I.getKey())); + RegionRoots.push_back(StateMgr.getRegion(I.getKey())); RVal X = I.getData(); for (symbol_iterator SI=X.symbol_begin(), SE=X.symbol_end(); SI!=SE; ++SI) @@ -198,7 +198,7 @@ BasicStoreManager::RemoveDeadBindings(Store store, Stmt* Loc, // Remove dead variable bindings. for (VarBindingsTy::iterator I=B.begin(), E=B.end(); I!=E ; ++I) { - const VarRegion* R = cast<VarRegion>(StMgr.getRegion(I.getKey())); + const VarRegion* R = cast<VarRegion>(StateMgr.getRegion(I.getKey())); if (!Marked.count(R)) { store = Remove(store, lval::MemRegionVal(R)); @@ -212,7 +212,7 @@ BasicStoreManager::RemoveDeadBindings(Store store, Stmt* Loc, return store; } -Store BasicStoreManager::getInitialStore(GRStateManager& StateMgr) { +Store BasicStoreManager::getInitialStore() { // The LiveVariables information already has a compilation of all VarDecls // used in the function. Iterate through this set, and "symbolicate" // any VarDecl whose value originally comes from outside the function. @@ -240,14 +240,14 @@ Store BasicStoreManager::getInitialStore(GRStateManager& StateMgr) { ? RVal::GetSymbolValue(StateMgr.getSymbolManager(), VD) : UndefinedVal(); - St = SetRVal(St, StMgr.getLVal(VD), X); + St = SetRVal(St, StateMgr.getLVal(VD), X); } } } return St; } -Store BasicStoreManager::AddDecl(Store store, GRStateManager& StateMgr, +Store BasicStoreManager::AddDecl(Store store, const VarDecl* VD, Expr* Ex, RVal InitVal, unsigned Count) { @@ -280,16 +280,16 @@ Store BasicStoreManager::AddDecl(Store store, GRStateManager& StateMgr, if (!Ex) { QualType T = VD->getType(); if (LVal::IsLValType(T)) - store = SetRVal(store, StMgr.getLVal(VD), + store = SetRVal(store, StateMgr.getLVal(VD), lval::ConcreteInt(BasicVals.getValue(0, T))); else if (T->isIntegerType()) - store = SetRVal(store, StMgr.getLVal(VD), + store = SetRVal(store, StateMgr.getLVal(VD), nonlval::ConcreteInt(BasicVals.getValue(0, T))); else { // assert(0 && "ignore other types of variables"); } } else { - store = SetRVal(store, StMgr.getLVal(VD), InitVal); + store = SetRVal(store, StateMgr.getLVal(VD), InitVal); } } } else { @@ -307,7 +307,7 @@ Store BasicStoreManager::AddDecl(Store store, GRStateManager& StateMgr, : cast<RVal>(nonlval::SymbolVal(Sym)); } - store = SetRVal(store, StMgr.getLVal(VD), V); + store = SetRVal(store, StateMgr.getLVal(VD), V); } } @@ -337,7 +337,7 @@ void BasicStoreManager::iterBindings(Store store, BindingsHandler& f) { for (VarBindingsTy::iterator I=B.begin(), E=B.end(); I != E; ++I) { - f.HandleBinding(*this, store, StMgr.getRegion(I.getKey()),I.getData()); + f.HandleBinding(*this, store, StateMgr.getRegion(I.getKey()),I.getData()); } } |