diff options
author | Mikhail R. Gadelha <mikhail.ramalho@gmail.com> | 2018-07-19 17:03:12 +0000 |
---|---|---|
committer | Mikhail R. Gadelha <mikhail.ramalho@gmail.com> | 2018-07-19 17:03:12 +0000 |
commit | ddd4229cc402cc74c656501614f694c977f45519 (patch) | |
tree | 2f07092386c784f8b8931e7ecb5adc66b7d36bbc /clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp | |
parent | 8c7a30baea219e8143b13e3e384ff713d8bb7c76 (diff) | |
download | bcm5719-llvm-ddd4229cc402cc74c656501614f694c977f45519.tar.gz bcm5719-llvm-ddd4229cc402cc74c656501614f694c977f45519.zip |
[analyzer] Memoize complexity of SymExpr
Summary:
This patch introduces a new member to SymExpr, which stores the symbol complexity, avoiding recalculating it every time computeComplexity() is called.
Also, increase the complexity of conjured Symbols by one, so it's clear that it has a greater complexity than its underlying symbols.
Reviewers: NoQ, george.karpenkov
Reviewed By: NoQ, george.karpenkov
Subscribers: xazax.hun, szepet, a.sidorin
Differential Revision: https://reviews.llvm.org/D49232
llvm-svn: 337472
Diffstat (limited to 'clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp')
-rw-r--r-- | clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp b/clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp index a4abb82e2af..eac07e659dc 100644 --- a/clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp +++ b/clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp @@ -390,7 +390,7 @@ unsigned AnalyzerOptions::getGraphTrimInterval() { unsigned AnalyzerOptions::getMaxSymbolComplexity() { if (!MaxSymbolComplexity.hasValue()) - MaxSymbolComplexity = getOptionAsInteger("max-symbol-complexity", 25); + MaxSymbolComplexity = getOptionAsInteger("max-symbol-complexity", 35); return MaxSymbolComplexity.getValue(); } |