Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(497)

Issue 2667853004: Remove dependency on scan-build wrapper script for Clang analysis builds. (Closed)

Created:
3 years, 10 months ago by Kevin M
Modified:
3 years, 9 months ago
Reviewers:
Nico, Wez
CC:
chromium-reviews
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Remove dependency on scan-build wrapper script for analysis builds. This CL replaces the Clang 'c++-analyzer' Perl script with logic added to the Python wrapper script. This gives us the hooks we need to run analysis builds with "gomacc" (necessary for distributed builds) and gives us a convenient place to specify analyzer config flags which aren't exposed by scan-build. Adds a warning suppression rule which prevents the analyzer from raising false positives from stdlib code (code w/namespace "std"). Other changes: * Modify Goma portions of the GCC toolchain GNI to build paths to the Clang static analyzer. * Create an exception for ASM tool invocations, which don't play well with the analysis command line flags. * Removed 'scan-build' DEP. BUG=687245 R=thakis@chromium.org,wez@chromium.org Review-Url: https://codereview.chromium.org/2667853004 Cr-Commit-Position: refs/heads/master@{#456136} Committed: https://chromium.googlesource.com/chromium/src/+/6694c0e5e6727606e83542d3d471f3967fdb0128

Patch Set 1 #

Patch Set 2 : rebase #

Patch Set 3 : Redo buggy rebase #

Patch Set 4 : Cleanup #

Patch Set 5 : Removed goma TODO from docs #

Total comments: 22

Patch Set 6 : wez feedback #

Total comments: 8

Patch Set 7 : wez feedback #

Patch Set 8 : fixed bool type coercion bug in GNI #

Total comments: 4

Patch Set 9 : Added stdlib error suppression flag. #

Total comments: 7

Patch Set 10 : thakis feedback #

Patch Set 11 : r3b453 #

Patch Set 12 : WIP clang on windows #

Unified diffs Side-by-side diffs Delta from patch set Stats (+131 lines, -86 lines) Patch
M DEPS View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +0 lines, -7 lines 0 comments Download
M build/toolchain/clang_static_analyzer_wrapper.py View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +70 lines, -44 lines 0 comments Download
M build/toolchain/gcc_toolchain.gni View 1 2 3 4 5 6 7 8 9 10 11 4 chunks +42 lines, -29 lines 0 comments Download
M build/toolchain/nacl/BUILD.gn View 1 2 3 2 chunks +9 lines, -2 lines 0 comments Download
M build/toolchain/nacl_toolchain.gni View 1 chunk +1 line, -0 lines 0 comments Download
M build/toolchain/win/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +9 lines, -1 line 0 comments Download
M docs/clang_static_analyzer.md View 1 2 3 4 1 chunk +0 lines, -3 lines 0 comments Download

Messages

Total messages: 39 (18 generated)
Kevin M
3 years, 10 months ago (2017-02-01 02:32:51 UTC) #1
Kevin M
Friendly ping. I have another CL out for review shortly that implements file whitelisting, which ...
3 years, 10 months ago (2017-02-01 23:25:51 UTC) #2
Wez
Note that the "Goma requires multiple parameters to work" bit of the CL description was ...
3 years, 10 months ago (2017-02-03 08:05:01 UTC) #9
Kevin M
https://codereview.chromium.org/2667853004/diff/80001/build/toolchain/clang_static_analyzer_wrapper.py File build/toolchain/clang_static_analyzer_wrapper.py (right): https://codereview.chromium.org/2667853004/diff/80001/build/toolchain/clang_static_analyzer_wrapper.py#newcode6 build/toolchain/clang_static_analyzer_wrapper.py:6: """Adds a analysis build step to invocations of the ...
3 years, 10 months ago (2017-02-03 18:46:29 UTC) #10
Wez
https://codereview.chromium.org/2667853004/diff/80001/build/toolchain/clang_static_analyzer_wrapper.py File build/toolchain/clang_static_analyzer_wrapper.py (right): https://codereview.chromium.org/2667853004/diff/80001/build/toolchain/clang_static_analyzer_wrapper.py#newcode57 build/toolchain/clang_static_analyzer_wrapper.py:57: interleaved_analyzer_flags)) On 2017/02/03 18:46:29, Kevin M wrote: > On ...
3 years, 10 months ago (2017-02-03 19:27:55 UTC) #13
Kevin M
https://codereview.chromium.org/2667853004/diff/100001/build/toolchain/clang_static_analyzer_wrapper.py File build/toolchain/clang_static_analyzer_wrapper.py (right): https://codereview.chromium.org/2667853004/diff/100001/build/toolchain/clang_static_analyzer_wrapper.py#newcode54 build/toolchain/clang_static_analyzer_wrapper.py:54: # excluded files. On 2017/02/03 19:27:54, Wez wrote: > ...
3 years, 10 months ago (2017-02-06 17:39:57 UTC) #16
Kevin M
https://codereview.chromium.org/2667853004/diff/100001/build/toolchain/gcc_toolchain.gni File build/toolchain/gcc_toolchain.gni (right): https://codereview.chromium.org/2667853004/diff/100001/build/toolchain/gcc_toolchain.gni#newcode136 build/toolchain/gcc_toolchain.gni:136: assert(!(toolchain_cc_wrapper != "" && toolchain_uses_goma != ""), On 2017/02/06 ...
3 years, 10 months ago (2017-02-06 18:44:18 UTC) #17
Wez
lgtm https://codereview.chromium.org/2667853004/diff/100001/build/toolchain/gcc_toolchain.gni File build/toolchain/gcc_toolchain.gni (right): https://codereview.chromium.org/2667853004/diff/100001/build/toolchain/gcc_toolchain.gni#newcode136 build/toolchain/gcc_toolchain.gni:136: assert(!(toolchain_cc_wrapper != "" && toolchain_uses_goma != ""), On ...
3 years, 10 months ago (2017-02-06 21:05:50 UTC) #18
Nico
I think upstream also has a c++-analyzer python version. Maybe that works better (and if ...
3 years, 10 months ago (2017-02-06 22:19:13 UTC) #19
Kevin M
Hey Nico, I'm eager to land Goma support for the analyzer as it really lowers ...
3 years, 10 months ago (2017-02-08 19:41:34 UTC) #20
Nico
On 2017/02/08 19:41:34, Kevin M wrote: > Hey Nico, > > I'm eager to land ...
3 years, 10 months ago (2017-02-08 19:49:53 UTC) #21
Kevin M
I think that it is reasonable to push for an iterative approach in this case, ...
3 years, 10 months ago (2017-02-08 23:59:31 UTC) #22
Kevin M
Friendly ping!
3 years, 10 months ago (2017-02-11 01:00:40 UTC) #23
Kevin M
On the LLVM error front, I have removed the code that suppresses the error output. ...
3 years, 10 months ago (2017-02-11 01:04:39 UTC) #24
Kevin M
PTAL. I updated the CL title and description to reflect the current state of the ...
3 years, 9 months ago (2017-03-10 00:18:30 UTC) #26
Nico
Cool, this basically lgtm. I feel the upstream discussion was very fruitful, so thank you ...
3 years, 9 months ago (2017-03-10 01:55:02 UTC) #27
Kevin M
https://codereview.chromium.org/2667853004/diff/160001/build/toolchain/clang_static_analyzer_wrapper.py File build/toolchain/clang_static_analyzer_wrapper.py (right): https://codereview.chromium.org/2667853004/diff/160001/build/toolchain/clang_static_analyzer_wrapper.py#newcode44 build/toolchain/clang_static_analyzer_wrapper.py:44: assert(args) On 2017/03/10 01:55:02, Nico wrote: > nit: > ...
3 years, 9 months ago (2017-03-10 17:44:02 UTC) #28
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2667853004/180001
3 years, 9 months ago (2017-03-10 17:44:54 UTC) #31
commit-bot: I haz the power
Try jobs failed on following builders: ios-device on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/ios-device/builds/168375) ios-simulator on master.tryserver.chromium.mac (JOB_FAILED, ...
3 years, 9 months ago (2017-03-10 17:47:23 UTC) #33
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2667853004/200001
3 years, 9 months ago (2017-03-10 18:19:54 UTC) #36
commit-bot: I haz the power
3 years, 9 months ago (2017-03-10 19:48:37 UTC) #39
Message was sent while issue was closed.
Committed patchset #11 (id:200001) as
https://chromium.googlesource.com/chromium/src/+/6694c0e5e6727606e83542d3d471...

Powered by Google App Engine
This is Rietveld 408576698