summaryrefslogtreecommitdiffstats
path: root/clang/lib/StaticAnalyzer/Core/AnalysisManager.cpp
diff options
context:
space:
mode:
authorPeter Szecsi <szepet95@gmail.com>2017-08-19 11:19:16 +0000
committerPeter Szecsi <szepet95@gmail.com>2017-08-19 11:19:16 +0000
commit999a25ff7283bd83f105ffb826b85181a30ffa41 (patch)
tree1109e6b4c4b99cfa0d7ee19acc2c9242aeea91a5 /clang/lib/StaticAnalyzer/Core/AnalysisManager.cpp
parent8de103f2f0aab1952d9cb9387a03d84a5b05c63e (diff)
downloadbcm5719-llvm-999a25ff7283bd83f105ffb826b85181a30ffa41.tar.gz
bcm5719-llvm-999a25ff7283bd83f105ffb826b85181a30ffa41.zip
[CFG] Add LoopExit information to CFG
This patch introduces a new CFG element CFGLoopExit that indicate when a loop ends. It does not deal with returnStmts yet (left it as a TODO). It hidden behind a new analyzer-config flag called cfg-loopexit (false by default). Test cases added. The main purpose of this patch right know is to make loop unrolling and loop widening easier and more efficient. However, this information can be useful for future improvements in the StaticAnalyzer core too. Differential Revision: https://reviews.llvm.org/D35668 llvm-svn: 311235
Diffstat (limited to 'clang/lib/StaticAnalyzer/Core/AnalysisManager.cpp')
-rw-r--r--clang/lib/StaticAnalyzer/Core/AnalysisManager.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/StaticAnalyzer/Core/AnalysisManager.cpp b/clang/lib/StaticAnalyzer/Core/AnalysisManager.cpp
index 83e67662e61..10cf079b346 100644
--- a/clang/lib/StaticAnalyzer/Core/AnalysisManager.cpp
+++ b/clang/lib/StaticAnalyzer/Core/AnalysisManager.cpp
@@ -26,7 +26,8 @@ AnalysisManager::AnalysisManager(ASTContext &ctx, DiagnosticsEngine &diags,
Options.includeImplicitDtorsInCFG(),
/*AddInitializers=*/true,
Options.includeTemporaryDtorsInCFG(),
- Options.includeLifetimeInCFG(),
+ Options.includeLifetimeInCFG(),
+ Options.includeLoopExitInCFG(),
Options.shouldSynthesizeBodies(),
Options.shouldConditionalizeStaticInitializers(),
/*addCXXNewAllocator=*/true,
OpenPOWER on IntegriCloud