[clang] 6846aec - [analyzer] SATestBuild.py: Optionally override compiler
Valeriy Savchenko via cfe-commits
cfe-commits at lists.llvm.org
Tue May 19 07:13:05 PDT 2020
Author: Valeriy Savchenko
Date: 2020-05-19T17:12:46+03:00
New Revision: 6846aec7313f81d6d8fd5190d6b49eba9f038a8e
URL: https://github.com/llvm/llvm-project/commit/6846aec7313f81d6d8fd5190d6b49eba9f038a8e
DIFF: https://github.com/llvm/llvm-project/commit/6846aec7313f81d6d8fd5190d6b49eba9f038a8e.diff
LOG: [analyzer] SATestBuild.py: Optionally override compiler
Differential Revision: https://reviews.llvm.org/D80211
Added:
Modified:
clang/utils/analyzer/SATestBuild.py
Removed:
################################################################################
diff --git a/clang/utils/analyzer/SATestBuild.py b/clang/utils/analyzer/SATestBuild.py
index 02eb887500d7..91a9f09e2727 100755
--- a/clang/utils/analyzer/SATestBuild.py
+++ b/clang/utils/analyzer/SATestBuild.py
@@ -291,9 +291,9 @@ def runScanBuild(Args, Dir, SBOutputDir, PBuildLogFile):
SBOptions += "--keep-empty "
SBOptions += "-analyzer-config '%s' " % generateAnalyzerConfig(Args)
- # Always use ccc-analyze to ensure that we can locate the failures
- # directory.
- SBOptions += "--override-compiler "
+ if Args.override_compiler:
+ SBOptions += "--override-compiler "
+
ExtraEnv = {}
try:
SBCommandFile = open(BuildScriptPath, "r")
@@ -800,11 +800,14 @@ def testAll(Args):
reference. Default is 0.')
Parser.add_argument('-r', dest='regenerate', action='store_true',
default=False, help='Regenerate reference output.')
+ Parser.add_argument('--override-compiler', action='store_true',
+ default=False, help='Call scan-build with \
+ --override-compiler option.')
Parser.add_argument('-j', '--jobs', dest='jobs', type=int,
default=0,
help='Number of projects to test concurrently')
- Parser.add_argument('--extra-analyzer-config', dest='extra_analyzer_config',
- type=str,
+ Parser.add_argument('--extra-analyzer-config',
+ dest='extra_analyzer_config', type=str,
default="",
help="Arguments passed to to -analyzer-config")
Args = Parser.parse_args()
More information about the cfe-commits
mailing list