diff options
author | Tom Care <tcare@apple.com> | 2010-08-06 22:23:07 +0000 |
---|---|---|
committer | Tom Care <tcare@apple.com> | 2010-08-06 22:23:07 +0000 |
commit | 1fafd1d96419f587763d1b81332d8f476aeace2e (patch) | |
tree | dfbe224ceff38f092eda913f96230d8bf15005b4 /lib/Checker/AnalysisConsumer.cpp | |
parent | db1423008b6185fc570558cff77d92f94e55b386 (diff) |
Removed IdempotentOperationChecker from default analysis and returned back to a flag (-analyzer-check-idempotent-operations)
- Added IdempotentOperationChecker to experimental analyses for testing purposes
- Updated test cases to explictly call the checker
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@110482 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Checker/AnalysisConsumer.cpp')
-rw-r--r-- | lib/Checker/AnalysisConsumer.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/Checker/AnalysisConsumer.cpp b/lib/Checker/AnalysisConsumer.cpp index 2607664406..ad5ccb503b 100644 --- a/lib/Checker/AnalysisConsumer.cpp +++ b/lib/Checker/AnalysisConsumer.cpp @@ -29,6 +29,7 @@ #include "clang/Checker/PathSensitive/GRTransferFuncs.h" #include "clang/Checker/PathDiagnosticClients.h" #include "GRExprEngineExperimentalChecks.h" +#include "GRExprEngineInternalChecks.h" #include "clang/Basic/FileManager.h" #include "clang/Basic/SourceManager.h" #include "clang/Frontend/AnalyzerOptions.h" @@ -343,6 +344,12 @@ static void ActionGRExprEngine(AnalysisConsumer &C, AnalysisManager& mgr, if (C.Opts.EnableExperimentalChecks) RegisterExperimentalChecks(Eng); + // Enable idempotent operation checking if it was explicitly turned on, or if + // we are running experimental checks (i.e. everything) + if (C.Opts.IdempotentOps || C.Opts.EnableExperimentalChecks + || C.Opts.EnableExperimentalInternalChecks) + RegisterIdempotentOperationChecker(Eng); + // Set the graph auditor. llvm::OwningPtr<ExplodedNode::Auditor> Auditor; if (mgr.shouldVisualizeUbigraph()) { |