[cfe-commits] r113862 - in /cfe/trunk: examples/wpa/clang-wpa.cpp include/clang/Checker/PathSensitive/AnalysisManager.h lib/Checker/GRCoreEngine.cpp lib/Checker/GRExprEngine.cpp

Tom Care tcare at apple.com
Tue Sep 14 14:35:27 PDT 2010


Author: tcare
Date: Tue Sep 14 16:35:27 2010
New Revision: 113862

URL: http://llvm.org/viewvc/llvm-project?rev=113862&view=rev
Log:
Rename 'MaxLoop' to 'MaxVisit' in AnalysisManager to more correctly reflect that we aborted analysis may not necessarily be due to a loop.

Modified:
    cfe/trunk/examples/wpa/clang-wpa.cpp
    cfe/trunk/include/clang/Checker/PathSensitive/AnalysisManager.h
    cfe/trunk/lib/Checker/GRCoreEngine.cpp
    cfe/trunk/lib/Checker/GRExprEngine.cpp

Modified: cfe/trunk/examples/wpa/clang-wpa.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/examples/wpa/clang-wpa.cpp?rev=113862&r1=113861&r2=113862&view=diff
==============================================================================
--- cfe/trunk/examples/wpa/clang-wpa.cpp (original)
+++ cfe/trunk/examples/wpa/clang-wpa.cpp Tue Sep 14 16:35:27 2010
@@ -134,7 +134,7 @@
                        PP.getLangOptions(), /* PathDiagnostic */ 0,
                        CreateRegionStoreManager,
                        CreateRangeConstraintManager, &Idxer,
-                       /* MaxNodes */ 300000, /* MaxLoop */ 3,
+                       /* MaxNodes */ 300000, /* MaxVisit */ 3,
                        /* VisualizeEG */ false, /* VisualizeEGUbi */ false,
                        /* PurgeDead */ true, /* EagerlyAssume */ false,
                        /* TrimGraph */ false, /* InlineCall */ true, 

Modified: cfe/trunk/include/clang/Checker/PathSensitive/AnalysisManager.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Checker/PathSensitive/AnalysisManager.h?rev=113862&r1=113861&r2=113862&view=diff
==============================================================================
--- cfe/trunk/include/clang/Checker/PathSensitive/AnalysisManager.h (original)
+++ cfe/trunk/include/clang/Checker/PathSensitive/AnalysisManager.h Tue Sep 14 16:35:27 2010
@@ -50,8 +50,8 @@
   // The maximum number of exploded nodes the analyzer will generate.
   unsigned MaxNodes;
 
-  // The maximum number of times the analyzer will go through a loop.
-  unsigned MaxLoop;
+  // The maximum number of times the analyzer visit a block.
+  unsigned MaxVisit;
 
   bool VisualizeEGDot;
   bool VisualizeEGUbi;
@@ -74,14 +74,14 @@
                   StoreManagerCreator storemgr,
                   ConstraintManagerCreator constraintmgr, 
                   idx::Indexer *idxer,
-                  unsigned maxnodes, unsigned maxloop,
+                  unsigned maxnodes, unsigned maxvisit,
                   bool vizdot, bool vizubi, bool purge, bool eager, bool trim,
                   bool inlinecall, bool useUnoptimizedCFG)
 
     : AnaCtxMgr(useUnoptimizedCFG), Ctx(ctx), Diags(diags), LangInfo(lang),
       PD(pd),
       CreateStoreMgr(storemgr), CreateConstraintMgr(constraintmgr),Idxer(idxer),
-      AScope(ScopeDecl), MaxNodes(maxnodes), MaxLoop(maxloop),
+      AScope(ScopeDecl), MaxNodes(maxnodes), MaxVisit(maxvisit),
       VisualizeEGDot(vizdot), VisualizeEGUbi(vizubi), PurgeDead(purge),
       EagerlyAssume(eager), TrimGraph(trim), InlineCall(inlinecall) {}
   
@@ -133,7 +133,7 @@
 
   unsigned getMaxNodes() const { return MaxNodes; }
 
-  unsigned getMaxLoop() const { return MaxLoop; }
+  unsigned getMaxVisit() const { return MaxVisit; }
 
   bool shouldVisualizeGraphviz() const { return VisualizeEGDot; }
 

Modified: cfe/trunk/lib/Checker/GRCoreEngine.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Checker/GRCoreEngine.cpp?rev=113862&r1=113861&r2=113862&view=diff
==============================================================================
--- cfe/trunk/lib/Checker/GRCoreEngine.cpp (original)
+++ cfe/trunk/lib/Checker/GRCoreEngine.cpp Tue Sep 14 16:35:27 2010
@@ -703,7 +703,7 @@
                          OldMgr.getStoreManagerCreator(),
                          OldMgr.getConstraintManagerCreator(),
                          OldMgr.getIndexer(),
-                         OldMgr.getMaxNodes(), OldMgr.getMaxLoop(),
+                         OldMgr.getMaxNodes(), OldMgr.getMaxVisit(),
                          OldMgr.shouldVisualizeGraphviz(),
                          OldMgr.shouldVisualizeUbigraph(),
                          OldMgr.shouldPurgeDead(),

Modified: cfe/trunk/lib/Checker/GRExprEngine.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Checker/GRExprEngine.cpp?rev=113862&r1=113861&r2=113862&view=diff
==============================================================================
--- cfe/trunk/lib/Checker/GRExprEngine.cpp (original)
+++ cfe/trunk/lib/Checker/GRExprEngine.cpp Tue Sep 14 16:35:27 2010
@@ -1213,7 +1213,7 @@
                                         const ExplodedNode *Pred,
                                         GRBlockCounter BC) {
   return BC.getNumVisited(Pred->getLocationContext()->getCurrentStackFrame(), 
-                          B->getBlockID()) < AMgr.getMaxLoop();
+                          B->getBlockID()) < AMgr.getMaxVisit();
 }
 
 //===----------------------------------------------------------------------===//





More information about the cfe-commits mailing list