[PATCH] D84371: [DFSan] Add efficient fast16labels instrumentation mode.

2020-08-14 Thread Matt Morehouse via Phabricator via cfe-commits
morehouse added inline comments. Comment at: compiler-rt/lib/dfsan/dfsan.cpp:180 dfsan_label __dfsan_union(dfsan_label l1, dfsan_label l2) { - if (flags().fast16labels) + if (fast16labels) return l1 | l2; morehouse wrote: > vitalybuka wrote: > > morehouse

[PATCH] D85559: [MSAN] Reintroduce libatomic load/store instrumentation

2020-08-14 Thread Gui Andrade via Phabricator via cfe-commits
guiand closed this revision. guiand added a comment. Committed as 97de0188dd5d845ff90c8ac779a2ea09688b17df Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85559/new/ https://revie

[PATCH] D85457: [NewPM][optnone] Mark various passes as required

2020-08-14 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks updated this revision to Diff 285752. aeubanks added a comment. -target -> -triple rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85457/new/ https://reviews.llvm.org/D85457 Files: clang/test/CodeGen/O0-no-skipped-passes.c llvm/i

[clang] e492f95 - [docs] Add missing semicolon to example.

2020-08-14 Thread Matt Morehouse via cfe-commits
Author: Matt Morehouse Date: 2020-08-14T13:46:05-07:00 New Revision: e492f959e0e0930af3745c1e62b7ffc31f5bf29c URL: https://github.com/llvm/llvm-project/commit/e492f959e0e0930af3745c1e62b7ffc31f5bf29c DIFF: https://github.com/llvm/llvm-project/commit/e492f959e0e0930af3745c1e62b7ffc31f5bf29c.diff

[PATCH] D85998: Add clang-cl "vctoolsdir" option to specify the location of the msvc toolchain

2020-08-14 Thread Zachary Henkel via Phabricator via cfe-commits
zahen created this revision. zahen added reviewers: rnk, hans, thakis. Herald added subscribers: cfe-commits, dang. Herald added a project: clang. zahen requested review of this revision. Add an option to directly specify where the msvc toolchain lives for clang-cl and avoid unwanted file and reg

[PATCH] D85924: [clang][feature] Add cxx_abi_relative_vtable feature

2020-08-14 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan added a comment. CC @aaron.ballman who committed Features.def for signing off or knowing someone who can sign off. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85924/new/ https://reviews.llvm.org/D85924 __

[PATCH] D85796: [Analysis] Bug fix for exploded graph branching in evalCall for constructor

2020-08-14 Thread Nithin VR via Phabricator via cfe-commits
vrnithinkumar updated this revision to Diff 285763. vrnithinkumar marked 3 inline comments as done. vrnithinkumar added a comment. - Fix without passing the NodeBuilder Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85796/new/ https://reviews.llvm.o

[PATCH] D85796: [Analysis] Bug fix for exploded graph branching in evalCall for constructor

2020-08-14 Thread Nithin VR via Phabricator via cfe-commits
vrnithinkumar added inline comments. Comment at: clang/lib/StaticAnalyzer/Core/CheckerManager.cpp:682 anyEvaluated = true; +Dst.clear(); Dst.insert(checkDst); > runCheckersForEvalCall() already has its own builder, you don't need another

[PATCH] D85990: [Clang] Fix BZ47169, loader_uninitialized on incomplete types

2020-08-14 Thread Jon Chesterfield via Phabricator via cfe-commits
JonChesterfield added inline comments. Comment at: clang/test/Sema/attr-loader-uninitialized.cpp:14 +extern S incomplete_external_rejected __attribute__((loader_uninitialized)); +// expected-error@-1 {{variable has incomplete type 'S'}} +// expected-note@-3 {{forward declaration

[PATCH] D86000: Add an unsigned shift base sanitizer

2020-08-14 Thread JF Bastien via Phabricator via cfe-commits
jfb created this revision. jfb added a reviewer: vsk. Herald added subscribers: Sanitizers, cfe-commits, ributzka, dexonsmith, jkorous. Herald added projects: clang, Sanitizers. jfb requested review of this revision. It's not undefined behavior for an unsigned left shift to overflow (i.e. to shif

[PATCH] D85743: [CodeGen][AArch64] Support arm_sve_vector_bits attribute

2020-08-14 Thread Eli Friedman via Phabricator via cfe-commits
efriedma accepted this revision. efriedma added a comment. This revision is now accepted and ready to land. LGTM Like I mentioned on the review for the prototype, I still think we should try to implement a scheme that makes CK_BItCast between fixed and scalable types trivial. Doing coercion th

[PATCH] D85962: [SyntaxTree] Create annotations infrastructure and apply it in expression tests.

2020-08-14 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr2 accepted this revision. gribozavr2 added a comment. This revision is now accepted and ready to land. Very nice improvement to tests! Comment at: clang/unittests/Tooling/Syntax/BuildTreeTest.cpp:784 + +TEST_P(SyntaxTreeTest, QualifiedId_ComplexDeclaration) { + if (!G

[PATCH] D86000: Add an unsigned shift base sanitizer

2020-08-14 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added a comment. It'd be nice to fold the new check into an existing sanitizer group to bring this to a wider audience. Do you foresee adoption issues for existing -fsanitize=integer adopters? Fwiw some recently-added implicit conversion checks were folded in without much/any pushback. =

[PATCH] D85457: [NewPM][optnone] Mark various passes as required

2020-08-14 Thread Arthur Eubanks via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGe6ea8779c2e0: [NewPM][optnone] Mark various passes as required (authored by aeubanks). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85457/new/ https://revi

[clang] e6ea877 - [NewPM][optnone] Mark various passes as required

2020-08-14 Thread Arthur Eubanks via cfe-commits
Author: Arthur Eubanks Date: 2020-08-14T15:51:59-07:00 New Revision: e6ea8779c2e0c60007d1015cc98fe3d2642a1652 URL: https://github.com/llvm/llvm-project/commit/e6ea8779c2e0c60007d1015cc98fe3d2642a1652 DIFF: https://github.com/llvm/llvm-project/commit/e6ea8779c2e0c60007d1015cc98fe3d2642a1652.diff

[PATCH] D85948: [HeapProf] Clang and LLVM support for heap profiling instrumentation

2020-08-14 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson marked 12 inline comments as done. tejohnson added a comment. Addressed everyone's comments as well as the clang tidy warnings. I had hoped to get the runtime part ready and uploaded today, but it looks like I won't make it. I'll be out all next week, so will get that sent when I'm bac

[PATCH] D85948: [HeapProf] Clang and LLVM support for heap profiling instrumentation

2020-08-14 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson updated this revision to Diff 285777. tejohnson marked an inline comment as done. tejohnson added a comment. address comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85948/new/ https://reviews.llvm.org/D85948 Files: clang/include

[PATCH] D86000: Add an unsigned shift base sanitizer

2020-08-14 Thread JF Bastien via Phabricator via cfe-commits
jfb added a comment. In D86000#2219288 , @vsk wrote: > It'd be nice to fold the new check into an existing sanitizer group to bring > this to a wider audience. Do you foresee adoption issues for existing > -fsanitize=integer adopters? Fwiw some recently-

[PATCH] D84467: Add support for Branch Coverage in LLVM Source-Based Code Coverage

2020-08-14 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added inline comments. Comment at: clang/lib/CodeGen/CodeGenFunction.h:4359 + /// condition (i.e. no "&&" or "||"). + static bool isLeafCondition(const Expr *C); + alanphipps wrote: > vsk wrote: > > alanphipps wrote: > > > vsk wrote: > > > > vsk wrote: > >

[PATCH] D86000: Add an unsigned shift base sanitizer

2020-08-14 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added inline comments. Comment at: clang/test/Driver/fsanitize.c:911 +// CHECK-unsigned-shift-base-RECOVER-NOT: "-fsanitize-trap=unsigned-shift-base" +// CHECK-unsigned-shift-base-NORECOVER-NOT: "-fno-sanitize-recover=unsigned-shift-base" +// CHECK-unsigned-shift-base-NORECO

[PATCH] D86000: Add an unsigned shift base sanitizer

2020-08-14 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added a comment. In D86000#2219322 , @jfb wrote: > In D86000#2219288 , @vsk wrote: > >> It'd be nice to fold the new check into an existing sanitizer group to bring >> this to a wider audience. Do you foresee a

[PATCH] D86000: Add an unsigned shift base sanitizer

2020-08-14 Thread Evgenii Stepanov via Phabricator via cfe-commits
eugenis added a comment. In D86000#2219322 , @jfb wrote: > In D86000#2219288 , @vsk wrote: > >> It'd be nice to fold the new check into an existing sanitizer group to bring >> this to a wider audience. Do you fores

[PATCH] D84371: [DFSan] Add efficient fast16labels instrumentation mode.

2020-08-14 Thread Matt Morehouse via Phabricator via cfe-commits
morehouse added inline comments. Comment at: compiler-rt/lib/dfsan/dfsan.cpp:180 dfsan_label __dfsan_union(dfsan_label l1, dfsan_label l2) { - if (flags().fast16labels) + if (fast16labels) return l1 | l2; morehouse wrote: > morehouse wrote: > > vitalybuka

[PATCH] D86008: [NewPM][optnone] Fix clang tests in preparation for -enable-npm-optnone

2020-08-14 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks created this revision. Herald added subscribers: cfe-commits, dexonsmith, steven_wu, hiraditya. Herald added a project: clang. aeubanks requested review of this revision. These are the last clang tests failing before being able to turn on -enable-npm-optnone. Repository: rG LLVM Gith

[PATCH] D86008: [NewPM][optnone] Fix clang tests in preparation for -enable-npm-optnone

2020-08-14 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks updated this revision to Diff 285797. aeubanks added a comment. Split out other test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D86008/new/ https://reviews.llvm.org/D86008 Files: clang/test/CodeGen/aggregate-assign-call.c Index: cla

[PATCH] D85948: [HeapProf] Clang and LLVM support for heap profiling instrumentation

2020-08-14 Thread David Li via Phabricator via cfe-commits
davidxl accepted this revision. davidxl added a comment. This revision is now accepted and ready to land. lgtm. The user option should be documented after the runtime is ready. Comment at: llvm/lib/Transforms/Instrumentation/HeapProfiler.cpp:71 + +// This flag may need to be re

[PATCH] D86011: [test] Fix thinlto-debug-pm.c in preparation for -enable-npm-optnone

2020-08-14 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks created this revision. aeubanks added reviewers: asbirlea, ychen. Herald added subscribers: cfe-commits, dexonsmith, steven_wu, hiraditya, inglorion. Herald added a project: clang. aeubanks requested review of this revision. This fails due to the clang invocation running at -O0, producin

[PATCH] D86008: [test] Fix aggregate-assign-call.c in preparation for -enable-npm-optnone

2020-08-14 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen accepted this revision. ychen added a comment. This revision is now accepted and ready to land. LGTM. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D86008/new/ https://reviews.llvm.org/D86008 ___ cf

[PATCH] D85998: Add clang-cl "vctoolsdir" option to specify the location of the msvc toolchain

2020-08-14 Thread Zachary Henkel via Phabricator via cfe-commits
zahen updated this revision to Diff 285803. zahen added a comment. Fix formatting CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85998/new/ https://reviews.llvm.org/D85998 Files: clang/include/clang/Driver/Options.td clang/lib/Driver/ToolChains/MSVC.cpp clang/test/Driver/cl-option

[PATCH] D85948: [HeapProf] Clang and LLVM support for heap profiling instrumentation

2020-08-14 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: clang/include/clang/Basic/CodeGenOptions.def:148 CODEGENOPT(MergeFunctions, 1, 0) ///< Set when -fmerge-functions is enabled. +CODEGENOPT(HeapProf , 1, 0) ///< Set when -fmemprof is enabled. CODEGENOPT(MSVolatile

[PATCH] D85948: [HeapProf] Clang and LLVM support for heap profiling instrumentation

2020-08-14 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: llvm/test/Instrumentation/HeapProfiling/basic.ll:1 +; Test basic address sanitizer instrumentation. +; The implementation file is HeapProfiler.cpp Naming the test directory `Heapprofiler` can reduce the number of terms

[PATCH] D85948: [HeapProf] Clang and LLVM support for heap profiling instrumentation

2020-08-14 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. I am still trying to read the logic. Some comments to the tests. Some comments are applicable to other tests. Comment at: llvm/test/Instrumentation/HeapProfiling/basic.ll:22 +; CHECK: %[[LOAD_ADDR:[^ ]*]] = ptrtoint i32* %a to i64 +; CHECK: %[[MASK

[PATCH] D84988: WIP [Coverage] Add empty line regions to SkippedRegions

2020-08-14 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu updated this revision to Diff 285811. zequanwu added a comment. Herald added a project: Sanitizers. Herald added a subscriber: Sanitizers. - Rebase. - Merging adjcent skipped regions, if the regions are in the same file, could reduce binary size. - The new empty lines regions break exist

[PATCH] D86000: Add an unsigned shift base sanitizer

2020-08-14 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. What's next, a sanitizer that input to signed right-shift is always non-negative? :) FWIW "fixing" these "bugs" via `(x & ~(~1U << (32-shamt))) << shamt` is going to be fine, i've already taught instcombine to drop such pointless masking before left-shift in PR42563

<    1   2