[PATCH] D65445: [CrossTU] Handle case when no USR could be generated during Decl search.

2019-07-30 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. It looks like that the problem can happen when the anonymous union is in any `DeclContext` and for CTU import the import of a variable is requested and that variable is in a related `DeclContext` (it can be at upper or lower level). (See code of `findDefInDeclContext`:

[PATCH] D58091: Customize warnings for missing built-in type

2019-07-30 Thread Johannes Doerfert via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367387: [Fix] Customize warnings for missing built-in types (authored by jdoerfert, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: https:

r367387 - [Fix] Customize warnings for missing built-in types

2019-07-30 Thread Johannes Doerfert via cfe-commits
Author: jdoerfert Date: Tue Jul 30 22:16:38 2019 New Revision: 367387 URL: http://llvm.org/viewvc/llvm-project?rev=367387&view=rev Log: [Fix] Customize warnings for missing built-in types If we detect a built-in declaration for which we cannot derive a type matching the pattern in the Builtins.de

[PATCH] D58091: Customize warnings for missing built-in type

2019-07-30 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert updated this revision to Diff 212500. jdoerfert added a comment. Fix spelling in tests Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58091/new/ https://reviews.llvm.org/D58091 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td c

[PATCH] D65458: [NFC] Remove LLVM_ALIGNAS

2019-07-30 Thread JF Bastien via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367383: [NFC] Remove LLVM_ALIGNAS (authored by jfb, committed by ). Herald added a subscriber: kristina. Changed prior to commit: https://reviews.llvm.org/D65458?vs=212368&id=212496#toc Repository: r

r367383 - [NFC] Remove LLVM_ALIGNAS

2019-07-30 Thread JF Bastien via cfe-commits
Author: jfb Date: Tue Jul 30 20:22:08 2019 New Revision: 367383 URL: http://llvm.org/viewvc/llvm-project?rev=367383&view=rev Log: [NFC] Remove LLVM_ALIGNAS Summary: The minimum compilers support all have alignas, and we don't use LLVM_ALIGNAS anywhere anymore. This also removes an MSVC diagnosti

[clang-tools-extra] r367383 - [NFC] Remove LLVM_ALIGNAS

2019-07-30 Thread JF Bastien via cfe-commits
Author: jfb Date: Tue Jul 30 20:22:08 2019 New Revision: 367383 URL: http://llvm.org/viewvc/llvm-project?rev=367383&view=rev Log: [NFC] Remove LLVM_ALIGNAS Summary: The minimum compilers support all have alignas, and we don't use LLVM_ALIGNAS anywhere anymore. This also removes an MSVC diagnosti

[PATCH] D65300: [clang] [CodeGen] clang-misexpect prototype for compiler warnings

2019-07-30 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan accepted this revision. leonardchan added a comment. This revision is now accepted and ready to land. LGTM but I'd wait a day to see if anyone else has comments they'd like to add before landing. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm

[PATCH] D65300: [clang] [CodeGen] clang-misexpect prototype for compiler warnings

2019-07-30 Thread Petr Hosek via Phabricator via cfe-commits
phosek added inline comments. Comment at: clang/lib/CodeGen/MisExpect.cpp:29 + +void DebugPrintMisExpectSwitchInfo(SmallVector *SwitchWeights, + llvm::DenseMap *CaseMap); It seems like `DebugPrintMisExpectSwitchInfo` and `EmitMis

[PATCH] D65300: [clang] [CodeGen] clang-misexpect prototype for compiler warnings

2019-07-30 Thread Paul Kirth via Phabricator via cfe-commits
paulkirth updated this revision to Diff 212492. paulkirth added a comment. Update diff to have proper context on Phabricator Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65300/new/ https://reviews.llvm.org/D65300 Files: clang/include/clang/Basi

[PATCH] D65483: [clang-doc] Add link to source code in file definitions

2019-07-30 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added a comment. It'll be reasonable to mention new command-line arguments in documentation and Release Notes. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65483/new/ https://reviews.llvm.org/D65483 ___ cfe-commits mailing

[PATCH] D65493: Modernize atomic detection and usage

2019-07-30 Thread JF Bastien via Phabricator via cfe-commits
jfb updated this revision to Diff 212479. jfb added a comment. - Remove from cmake Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65493/new/ https://reviews.llvm.org/D65493 Files: clang-tools-extra/clangd/CMakeLists.txt lldb/source/Utility/CMak

[PATCH] D65493: Modernize atomic detection and usage

2019-07-30 Thread JF Bastien via Phabricator via cfe-commits
jfb created this revision. jfb added reviewers: rnk, Bigcheese, __simt__. Herald added subscribers: llvm-commits, lldb-commits, cfe-commits, kadircet, arphaman, dexonsmith, jkorous, hiraditya, mgorny. Herald added projects: clang, LLDB, LLVM. Some of the cmake checks are obsolete and make bootstr

r367371 - NFCI, optimize layout of FileEntry

2019-07-30 Thread Alex Lorenz via cfe-commits
Author: arphaman Date: Tue Jul 30 17:12:00 2019 New Revision: 367371 URL: http://llvm.org/viewvc/llvm-project?rev=367371&view=rev Log: NFCI, optimize layout of FileEntry The reordering of the UID field makes the size of a FileEntry 8 bytes smaller on 64bit platforms. Modified: cfe/trunk/incl

[PATCH] D65022: [Sema] Always instantiate the initializer of a variable template with undeduced type (8.0 regression)

2019-07-30 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington updated this revision to Diff 212470. erik.pilkington added a comment. Rebase on top of r367367. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65022/new/ https://reviews.llvm.org/D65022 Files: clang/lib/Sema/SemaExpr.cpp clang/lib/Sema/SemaExprMember.cpp clang/tes

[PATCH] D65359: [Sema] Map from a variable template specialization in a pattern to a variable template specialization in an instantiation properly

2019-07-30 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367367: [Sema] Actually map a variable template specialization from pattern to… (authored by epilk, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to

r367367 - [Sema] Actually map a variable template specialization from pattern to instantiation

2019-07-30 Thread Erik Pilkington via cfe-commits
Author: epilk Date: Tue Jul 30 16:38:18 2019 New Revision: 367367 URL: http://llvm.org/viewvc/llvm-project?rev=367367&view=rev Log: [Sema] Actually map a variable template specialization from pattern to instantiation We were previously just using a specialization in the class template instead of

[PATCH] D65486: [clangd] Ignore semicolons, whitespace, and comments in SelectionTree.

2019-07-30 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. It occurs to me that `claim` is `O(node_tokens + log total_tokens)` which is bad when the nodes are large. Indeed for an input like `namespace { namespace { namespace { ... } } }` time is quadratic. I think this is probably fine in practice. Against adversarial input

[PATCH] D65485: Revert "[NFC][clang] Refactor getCompilationPhases()+Types.def step 3."

2019-07-30 Thread Sam McCall via Phabricator via cfe-commits
sammccall abandoned this revision. sammccall added a comment. Please ignore this, I messed up with git/arc Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65485/new/ https://reviews.llvm.org/D65485 ___ c

[PATCH] D65487: [analyzer][NFC] Refactoring BugReporter.cpp P6.: Completely get rid of interestingness propagation

2019-07-30 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus created this revision. Szelethus added reviewers: NoQ, xazax.hun, rnkovacs, baloghadamsoftware, Charusso, dcoughlin. Szelethus added a project: clang. Herald added subscribers: cfe-commits, gamesh411, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, szepet, whisperity. Do you remember t

[PATCH] D65486: [clangd] Ignore semicolons, whitespace, and comments in SelectionTree.

2019-07-30 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added reviewers: SureYeaah, kadircet. Herald added subscribers: cfe-commits, arphaman, jkorous, MaskRay. Herald added a project: clang. Whitespace and comments are a clear bugfix: selecting some comments/space near a statement doesn't mean you're selectin

[PATCH] D65485: Revert "[NFC][clang] Refactor getCompilationPhases()+Types.def step 3."

2019-07-30 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. Herald added subscribers: cfe-commits, kadircet, arphaman, jkorous. Herald added a project: clang. This reverts commit d2254dbf21a3243233b75294ef901086199df1b9 . This (unintentionally?) changed b

[PATCH] D65484: [analyzer][NFC] Refactoring BugReporter.cpp P5.: Compact mile long function invocations into objects

2019-07-30 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus created this revision. Szelethus added reviewers: NoQ, xazax.hun, baloghadamsoftware, Charusso, dcoughlin, rnkovacs. Szelethus added a project: clang. Herald added subscribers: cfe-commits, gamesh411, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, szepet, whisperity. This patch is sca

[PATCH] D65483: [clang-format] Add link to source code in file definitions

2019-07-30 Thread Diego Astiazarán via Phabricator via cfe-commits
DiegoAstiazaran created this revision. DiegoAstiazaran added reviewers: juliehockett, jakehehrlich, lebedev.ri. DiegoAstiazaran added a project: clang-tools-extra. Herald added subscribers: kadircet, arphaman. Two command line options have been added to clang-doc. --repository= - URL of r

[PATCH] D65481: NFCI: Simplify SourceManager::translateFile by removing code path that should never be taken

2019-07-30 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman created this revision. arphaman added reviewers: rsmith, bruno, Bigcheese. Herald added subscribers: dexonsmith, jkorous. Herald added a project: clang. I noticed that `SourceManager::translateFile` has code that doesn't really make sense. In particular, if it fails to find a `FileID` by

[clang-tools-extra] r367361 - [clangd][NFC] Fix typo in comment

2019-07-30 Thread Jan Korous via cfe-commits
Author: jkorous Date: Tue Jul 30 15:18:04 2019 New Revision: 367361 URL: http://llvm.org/viewvc/llvm-project?rev=367361&view=rev Log: [clangd][NFC] Fix typo in comment Modified: clang-tools-extra/trunk/clangd/ClangdUnit.cpp Modified: clang-tools-extra/trunk/clangd/ClangdUnit.cpp URL: http:/

[PATCH] D64448: gsl::Owner/gsl::Pointer: Add implicit annotations for some std types

2019-07-30 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre updated this revision to Diff 212446. mgehre added a comment. - Fix crash Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64448/new/ https://reviews.llvm.org/D64448 Files: clang/include/clang/Basic/AttrDocs.td clang/include/clang/Sema/Sem

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-07-30 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 marked 2 inline comments as done. xbolva00 added inline comments. Comment at: include/clang/Basic/DiagnosticSemaKinds.td:5609 +def warn_mul_in_bool_context : Warning< + "'*' in bool context, maybe you mean '&&'?">, + InGroup; jfb wrote: > xbolva00 wrot

[PATCH] D65184: [Sema] Thread Safety Analysis: Fix negative capability's LockKind representation.

2019-07-30 Thread Aaron Puchert via Phabricator via cfe-commits
aaronpuchert added inline comments. Comment at: clang/test/SemaCXX/warn-thread-safety-negative.cpp:135-140 + if (condition) { +assertNotHeld(); // expected-warning {{mutex '!mu' is acquired exclusively and shared in the same scope}} + } else { +mu.Lock(); +mu.Unloc

[PATCH] D63907: [clang-scan-deps] Implementation of dependency scanner over minimized sources

2019-07-30 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman updated this revision to Diff 212442. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63907/new/ https://reviews.llvm.org/D63907 Files: clang/include/clang/Basic/FileManager.h clang/include/clang/Tooling/DependencyScanning/DependencyScanningFilesystem.h clang/include/clang/T

[PATCH] D65184: [Sema] Thread Safety Analysis: Fix negative capability's LockKind representation.

2019-07-30 Thread Aaron Puchert via Phabricator via cfe-commits
aaronpuchert added a comment. The primary purpose of Thread Safety Analysis is to make sure that accesses to shared resources are protected. That's why we only track whether a lock is available by default (i.e. without -Wthread-safety-negative), locks that we don't know anything about are assum

[PATCH] D65239: [analyzer] RangeConstraintManager: Apply constraint ranges of bitwise operations

2019-07-30 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso added inline comments. Comment at: clang/lib/StaticAnalyzer/Core/RangeConstraintManager.cpp:496 + // as a bitwise operation result could be null. + if (RS.getConcreteValue() && RS.getConcreteValue()->getExtValue() == 0) +return State; NoQ wrote: >

[PATCH] D64448: gsl::Owner/gsl::Pointer: Add implicit annotations for some std types

2019-07-30 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre updated this revision to Diff 212441. mgehre added a comment. - Add missing check Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64448/new/ https://reviews.llvm.org/D64448 Files: clang/include/clang/Basic/AttrDocs.td clang/include/clang/

[PATCH] D65239: [analyzer] RangeConstraintManager: Apply constraint ranges of bitwise operations

2019-07-30 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso updated this revision to Diff 212440. Charusso marked 6 inline comments as done. Charusso added a comment. - Fix. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65239/new/ https://reviews.llvm.org/D65239 Files: clang/include/clang/AST/Expr.h clang/include/clang/StaticAnaly

[PATCH] D64448: gsl::Owner/gsl::Pointer: Add implicit annotations for some std types

2019-07-30 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre added inline comments. Comment at: clang/include/clang/Sema/Sema.h:6097 + + /// Add [[gsl::Owner]] and [[gsl::Pointer]] attributes for std:: types. + void addDefaultGslPointerAttribute(TypedefNameDecl *TD); gribozavr wrote: > It seems like this function

[PATCH] D64448: gsl::Owner/gsl::Pointer: Add implicit annotations for some std types

2019-07-30 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre updated this revision to Diff 212439. mgehre marked 6 inline comments as done. mgehre added a comment. - Fix comments - Add Pointer via typedef on ClassTemplateDecl Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64448/new/ https://reviews.llv

[PATCH] D65184: [Sema] Thread Safety Analysis: Fix negative capability's LockKind representation.

2019-07-30 Thread Ziang Wan via Phabricator via cfe-commits
ziangwan marked 2 inline comments as done. ziangwan added inline comments. Comment at: clang/test/SemaCXX/thread-safety-annotations.h:47 +// Enable thread safety attributes only with clang. +// The attributes can be safely erased when compiling with other compilers. +#if defined(

[PATCH] D63139: [Diagnostics] Implement -Wswitch-unreachable

2019-07-30 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 accepted this revision. xbolva00 added a comment. This revision is now accepted and ready to land. Since motivation examples are already handled by -Wunreachable-code, I will close this revision. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63139/new/ https://reviews.llvm.org

[PATCH] D63907: [clang-scan-deps] Implementation of dependency scanner over minimized sources

2019-07-30 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added inline comments. Comment at: clang/include/clang/Tooling/DependencyScanning/DependencyScanningFilesystem.h:1 +//===- DependencyScanningFilesystem.h - clang-scan-deps fs ===---*- C++ -*-===// +// aganea wrote: > General comment for this file and t

[PATCH] D63907: [clang-scan-deps] Implementation of dependency scanner over minimized sources

2019-07-30 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman updated this revision to Diff 212435. arphaman marked 7 inline comments as done. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63907/new/ https://reviews.llvm.org/D63907 Files: clang/include/clang/Basic/FileManager.h clang/include/clang/Tooling/Depend

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-07-30 Thread JF Bastien via Phabricator via cfe-commits
jfb added inline comments. Comment at: include/clang/Basic/DiagnosticSemaKinds.td:5609 +def warn_mul_in_bool_context : Warning< + "'*' in bool context, maybe you mean '&&'?">, + InGroup; xbolva00 wrote: > jfb wrote: > > aaron.ballman wrote: > > > xbolva00 wrote

[PATCH] D65337: [clangd] Disallow extraction of expression-statements.

2019-07-30 Thread Sam McCall via Phabricator via cfe-commits
sammccall marked 6 inline comments as done. sammccall added a comment. In D65337#1604324 , @SureYeaah wrote: > What was the bug in getCallExpr() ? It could find calls where the DeclRef was an arbitrary subexpression of the callee, not exactly the callee

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-07-30 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 marked 2 inline comments as done and an inline comment as not done. xbolva00 added inline comments. Comment at: include/clang/Basic/DiagnosticSemaKinds.td:5609 +def warn_mul_in_bool_context : Warning< + "'*' in bool context, maybe you mean '&&'?">, + InGroup; -

[PATCH] D65337: [clangd] Disallow extraction of expression-statements.

2019-07-30 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 212433. sammccall added a comment. Add basic test for outerImplicit. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65337/new/ https://reviews.llvm.org/D65337 Files: clang-tools-extra/clangd/Selection.cpp

[PATCH] D65337: [clangd] Disallow extraction of expression-statements.

2019-07-30 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 212432. sammccall marked 2 inline comments as done. sammccall added a comment. Address review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65337/new/ https://reviews.llvm.org/D65337 Files: clang

[PATCH] D65050: [SemaTemplate] Mark a function type as dependent when its parameter list contains pack expansion

2019-07-30 Thread S. B. Tam via Phabricator via cfe-commits
cpplearner added a comment. In D65050#1606022 , @aaron.ballman wrote: > The noexcept specifier is part of the type these days, is that also handled > properly? I believe that it's properly handled in this section of `FunctionProtoType::FunctionProtoTy

[clang-tools-extra] r367354 - [clangd][NFC] Typo in comment

2019-07-30 Thread Jan Korous via cfe-commits
Author: jkorous Date: Tue Jul 30 13:39:39 2019 New Revision: 367354 URL: http://llvm.org/viewvc/llvm-project?rev=367354&view=rev Log: [clangd][NFC] Typo in comment Modified: clang-tools-extra/trunk/clangd/Headers.h Modified: clang-tools-extra/trunk/clangd/Headers.h URL: http://llvm.org/view

[PATCH] D65184: [Sema] Thread Safety Analysis: Fix negative capability's LockKind representation.

2019-07-30 Thread Aaron Puchert via Phabricator via cfe-commits
aaronpuchert added inline comments. Comment at: clang/test/SemaCXX/thread-safety-annotations.h:47 +// Enable thread safety attributes only with clang. +// The attributes can be safely erased when compiling with other compilers. +#if defined(__clang__) && (!defined(SWIG))

r367353 - Revert "[NFC][clang] Refactor getCompilationPhases()+Types.def step 3."

2019-07-30 Thread Sam McCall via cfe-commits
Author: sammccall Date: Tue Jul 30 13:38:11 2019 New Revision: 367353 URL: http://llvm.org/viewvc/llvm-project?rev=367353&view=rev Log: Revert "[NFC][clang] Refactor getCompilationPhases()+Types.def step 3." This reverts commit d2254dbf21a3243233b75294ef901086199df1b9. This (unintentionally?) cha

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-07-30 Thread JF Bastien via Phabricator via cfe-commits
jfb added inline comments. Comment at: test/Sema/warn-int-in-bool-context.c:26 + r = a << 7; // expected-warning {{'<<' in boolean context; did you mean '<'?}} + r = ONE << b; // expected-warning {{'<<' in boolean context; did you mean '<'?}} + xbolva00 wro

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-07-30 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 marked 4 inline comments as done and an inline comment as not done. xbolva00 added inline comments. Comment at: test/Sema/warn-int-in-bool-context.c:26 + r = a << 7; // expected-warning {{'<<' in boolean context; did you mean '<'?}} + r = ONE << b; // expected-warni

[PATCH] D64488: [Driver] Support -fsanitize=function on Solaris/x86

2019-07-30 Thread Rainer Orth via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367351: [Driver] Support -fsanitize=function on Solaris/x86 (authored by ro, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: https://revie

r367351 - [Driver] Support -fsanitize=function on Solaris/x86

2019-07-30 Thread Rainer Orth via cfe-commits
Author: ro Date: Tue Jul 30 13:04:53 2019 New Revision: 367351 URL: http://llvm.org/viewvc/llvm-project?rev=367351&view=rev Log: [Driver] Support -fsanitize=function on Solaris/x86 UBSan-Standalone-x86_64 :: TestCases/TypeCheck/Function/function.cpp currently FAILs on Solaris/x86_64: clang-9:

[PATCH] D55895: NFC: simplify Darwin environment handling

2019-07-30 Thread JF Bastien via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG42c9f3c9116c: [NFC] simplify Darwin environment handling (authored by jfb). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55895/new/ https://reviews.llvm.or

[PATCH] D55895: NFC: simplify Darwin environment handling

2019-07-30 Thread JF Bastien via Phabricator via cfe-commits
jfb updated this revision to Diff 212417. jfb added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55895/new/ https://reviews.llvm.org/D55895 Files: clang/lib/Driver/ToolChains/Darwin.cpp Index: clang/lib/Driver/ToolChains/Dar

r367350 - [NFC] simplify Darwin environment handling

2019-07-30 Thread JF Bastien via cfe-commits
Author: jfb Date: Tue Jul 30 13:01:46 2019 New Revision: 367350 URL: http://llvm.org/viewvc/llvm-project?rev=367350&view=rev Log: [NFC] simplify Darwin environment handling The previous code detected conflicts through copy-pasta, this versions uses a 'loop'. Modified: cfe/trunk/lib/Driver/To

[PATCH] D64488: [Driver] Support -fsanitize=function on Solaris/x86

2019-07-30 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D64488#1606758 , @ro wrote: > In D64488#1606716 , @krytarowski > wrote: > > > Something is broken between reviews. and my mailbox as I am not receiving > > any e-mails so pinging do

[PATCH] D61466: [Rewrite][NFC] Add FIXMEs and tests for RemoveLineIfEmpty bug

2019-07-30 Thread Jan Korous via Phabricator via cfe-commits
jkorous added a comment. In D61466#1602928 , @jdenny wrote: > In D61466#1602917 , @jkorous wrote: > > > > > > In an inline comment, you also mentioned the alternative of replacing > `EXPECT_EQ` with `EXPECT_NE`. N

[PATCH] D55895: NFC: simplify Darwin environment handling

2019-07-30 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman accepted this revision. arphaman added a comment. This revision is now accepted and ready to land. LGTM Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55895/new/ https://reviews.llvm.org/D55895 ___ cfe-commit

[PATCH] D62739: AMDGPU: Always emit amdgpu-flat-work-group-size

2019-07-30 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added a comment. ping CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62739/new/ https://reviews.llvm.org/D62739 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-07-30 Thread JF Bastien via Phabricator via cfe-commits
jfb added inline comments. Comment at: test/Sema/warn-int-in-bool-context.c:26 + r = a << 7; // expected-warning {{'<<' in boolean context; did you mean '<'?}} + r = ONE << b; // expected-warning {{'<<' in boolean context; did you mean '<'?}} + xbolva00 wro

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-07-30 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 marked an inline comment as done. xbolva00 added inline comments. Comment at: test/Sema/warn-int-in-bool-context.c:32 + r = a ? -2 : 0; + r = a ? 3 : -2; + r = a ? 0 : TWO; // expected-warning {{'?:' with integer constants in boolean context}} jfb wr

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-07-30 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 marked 3 inline comments as done. xbolva00 added inline comments. Comment at: test/Sema/warn-int-in-bool-context.c:26 + r = a << 7; // expected-warning {{'<<' in boolean context; did you mean '<'?}} + r = ONE << b; // expected-warning {{'<<' in boolean context; did

[PATCH] D65387: [clangd] Add a callback mechanism for handling responses from client.

2019-07-30 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clang-tools-extra/clangd/ClangdLSPServer.cpp:150 +// Log the reply. +log("<-- reply({0})", ID); +Server.onReply(std::move(ID), std::move(Result)); We want to keep logging errors (not just at verbose level).

[PATCH] D63954: Add lifetime categories attributes

2019-07-30 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre added a comment. I will include your latest comments into D64448 Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63954/new/ https://reviews.llvm.org/D63954 ___ cfe-commits maili

[PATCH] D62648: [Sema][Typo] Fix assertion failure for expressions with multiple typos

2019-07-30 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. I don't think you need to change the `TreeTranform` base class to support this; `TreeTransform::TransformExpr` is an extension point which you can override from `TransformTypos` to inject the custom logic you need. But I also don't think this `TreeTransform::TransformExp

[PATCH] D62960: Add SVE opaque built-in types

2019-07-30 Thread Richard Sandiford via Phabricator via cfe-commits
rsandifo-arm marked 10 inline comments as done. rsandifo-arm added a comment. Thanks. I think the current version of the patch addresses all review comments so far and the last set of comments seemed positive. Does the patch look OK to land? (I was waiting until Clang 9 branched, and then was

[PATCH] D64488: [Driver] Support -fsanitize=function on Solaris/x86

2019-07-30 Thread Rainer Orth via Phabricator via cfe-commits
ro updated this revision to Diff 212393. ro added a comment. Test i386--solaris instead of x86_64--solaris twice. Retested on x86_64-pc-solaris2.11. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64488/new/ https://reviews.llvm.org/D64488 Files: lib/Driver/Too

r367346 - [Parser] Lambda capture lists can start with '*'

2019-07-30 Thread Erik Pilkington via cfe-commits
Author: epilk Date: Tue Jul 30 12:21:20 2019 New Revision: 367346 URL: http://llvm.org/viewvc/llvm-project?rev=367346&view=rev Log: [Parser] Lambda capture lists can start with '*' Fixes llvm.org/PR42778 Modified: cfe/trunk/lib/Parse/ParseInit.cpp cfe/trunk/test/Parser/cxx0x-lambda-expre

[PATCH] D65308: [NFC][clang] Refactor getCompilationPhases()+Types.def step 3.

2019-07-30 Thread Puyan Lotfi via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367345: [NFC][clang] Refactor getCompilationPhases()+Types.def step 3. (authored by zer0, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D64666: [Sema] Enable -Wimplicit-float-conversion for integral to floating point precision loss

2019-07-30 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/lib/Sema/SemaChecking.cpp:11656 + IsListInit = + IsListInit || (isa(OrigE) && S.getLangOpts().CPlusPlus); + ziangwan wrote: > aaron.ballman wrote: > > ziangwan wrote: > > > aaron.ballman wrote: > > > >

r367345 - [NFC][clang] Refactor getCompilationPhases()+Types.def step 3.

2019-07-30 Thread Puyan Lotfi via cfe-commits
Author: zer0 Date: Tue Jul 30 12:03:17 2019 New Revision: 367345 URL: http://llvm.org/viewvc/llvm-project?rev=367345&view=rev Log: [NFC][clang] Refactor getCompilationPhases()+Types.def step 3. Dropping the 'u' entry and the entire Flags table from Types.def. Now it'll be a bit easier to tablegen

[PATCH] D59474: [OpenMP 5.0] Codegen support for user-defined mappers

2019-07-30 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added a comment. Thanks, looks good. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59474/new/ https://reviews.llvm.org/D59474 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cf

[PATCH] D59474: [OpenMP 5.0] Codegen support for user-defined mappers

2019-07-30 Thread Lingda Li via Phabricator via cfe-commits
lildmh updated this revision to Diff 212399. lildmh marked an inline comment as done. lildmh added a comment. Change mapper function argument checking CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59474/new/ https://reviews.llvm.org/D59474 Files: include/clang/AST/GlobalDecl.h lib/

[PATCH] D65184: [Sema] Thread Safety Analysis: Fix negative capability's LockKind representation.

2019-07-30 Thread Ziang Wan via Phabricator via cfe-commits
ziangwan marked an inline comment as done. ziangwan added inline comments. Comment at: clang/test/SemaCXX/warn-thread-safety-negative.cpp:135-140 + if (condition) { +assertNotHeld(); // expected-warning {{mutex '!mu' is acquired exclusively and shared in the same scope}} +

[PATCH] D65184: [Sema] Thread Safety Analysis: Fix negative capability's LockKind representation.

2019-07-30 Thread Ziang Wan via Phabricator via cfe-commits
ziangwan marked an inline comment as done. ziangwan added inline comments. Comment at: clang/test/SemaCXX/thread-safety-annotations.h:47 +// Enable thread safety attributes only with clang. +// The attributes can be safely erased when compiling with other compilers. +#if defined(

[PATCH] D65184: [Sema] Thread Safety Analysis: Fix negative capability's LockKind representation.

2019-07-30 Thread Ziang Wan via Phabricator via cfe-commits
ziangwan added a comment. The problem is: by the current state of the thread safety analysis, `ASSERT_SHARED_CAPABILTIY(!mu)` introduces a shared negative capability, whereas `RELEASE(mu)` **and `RELEASE_SHARED(mu)`** introduce an exclusive negative capability, and `UNLOCK_FUNCTION(mu)` introd

[PATCH] D65387: [clangd] Add a callback mechanism for handling responses from client.

2019-07-30 Thread Jan Korous via Phabricator via cfe-commits
jkorous added a comment. Hi @hokein, Do you have any thoughts on how to handle situation when client registers callback but doesn't send a request with registered ID later? Comment at: clang-tools-extra/clangd/ClangdLSPServer.cpp:317 +std::lock_guard Lock(ReplyCallbacksMut

[PATCH] D65462: gn build: Fix check-clang-tools after r362702.

2019-07-30 Thread Mirko Bonadei via Phabricator via cfe-commits
mbonadei added a comment. LGTM. Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65462/new/ https://reviews.llvm.org/D65462 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/l

[PATCH] D65462: gn build: Fix check-clang-tools after r362702.

2019-07-30 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367340: gn build: Fix check-clang-tools after r362702. (authored by nico, committed by ). Changed prior to commit: https://reviews.llvm.org/D65462?vs=212387&id=212391#toc Repository: rL LLVM CHANGES

[PATCH] D64564: Loop pragma parsing. NFC.

2019-07-30 Thread Sjoerd Meijer via Phabricator via cfe-commits
SjoerdMeijer marked an inline comment as done. SjoerdMeijer added inline comments. Comment at: lib/Parse/ParsePragma.cpp:1011 + Str = llvm::StringSwitch(Str) + .Case("loop", "clang loop " + Str.str()) + .Case("unroll_and_jam", Str) Me

[PATCH] D64666: [Sema] Enable -Wimplicit-float-conversion for integral to floating point precision loss

2019-07-30 Thread Ziang Wan via Phabricator via cfe-commits
ziangwan marked an inline comment as done. ziangwan added inline comments. Comment at: clang/lib/Sema/SemaChecking.cpp:11656 + IsListInit = + IsListInit || (isa(OrigE) && S.getLangOpts().CPlusPlus); + aaron.ballman wrote: > ziangwan wrote: > > aaron.ballman

[PATCH] D64488: [Driver] Support -fsanitize=function on Solaris/x86

2019-07-30 Thread Rainer Orth via Phabricator via cfe-commits
ro added a comment. In D64488#1606716 , @krytarowski wrote: > Something is broken between reviews. and my mailbox as I am not receiving any > e-mails so pinging does not make any effect... no LLVM admin replied to my > questions on this to validate wheth

[PATCH] D65462: gn build: Fix check-clang-tools after r362702.

2019-07-30 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. Seems good to me CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65462/new/ https://reviews.llvm.org/D65462 ___ cfe-commits mailing list cfe-c

[PATCH] D65462: gn build: Fix check-clang-tools after r362702.

2019-07-30 Thread Nico Weber via Phabricator via cfe-commits
thakis created this revision. thakis added reviewers: hans, pcc, mbonadei. Herald added subscribers: llvm-commits, jfb. Herald added a reviewer: jdoerfert. Herald added a project: LLVM. r362702 added a test that requires clang-tidy to be linked into libclang, so add that to the gn build. https:/

[PATCH] D64488: [Driver] Support -fsanitize=function on Solaris/x86

2019-07-30 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Something is broken between reviews. and my mailbox as I am not receiving any e-mails so pinging does not make any effect... no LLVM admin replied to my questions on this to validate whether my mail was blacklisted or similar. I have decided to change server of my

[PATCH] D65428: Remove cache for macro arg stringization

2019-07-30 Thread Reid Kleckner via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367337: Remove cache for macro arg stringization (authored by rnk, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.or

[PATCH] D65127: Even more warnings utilizing gsl::Owner/gsl::Pointer annotations

2019-07-30 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre added inline comments. Comment at: clang/lib/Sema/SemaInit.cpp:6581 +if (!Callee->getIdentifier()) { + auto OO = Callee->getOverloadedOperator(); + return OO == OverloadedOperatorKind::OO_Subscript || xazax.hun wrote: > If we want to relax th

[PATCH] D65428: Remove cache for macro arg stringization

2019-07-30 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. Thanks for looking into it as well, I would not have seen the issue without reviewing the test case again. :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65428/new/ https://reviews.llvm.org/D65428

r367337 - Remove cache for macro arg stringization

2019-07-30 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Tue Jul 30 10:58:22 2019 New Revision: 367337 URL: http://llvm.org/viewvc/llvm-project?rev=367337&view=rev Log: Remove cache for macro arg stringization Summary: The cache recorded the wrong expansion location for all but the first stringization. It seems uncommon to stringize t

[PATCH] D65458: [NFC] Remove LLVM_ALIGNAS

2019-07-30 Thread Reid Kleckner via Phabricator via cfe-commits
rnk accepted this revision. rnk 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/D65458/new/ https://reviews.llvm.org/D65458 ___ cfe-c

[PATCH] D65426: [Coverage] Hide coverage for regions with incorrect end locations (PR39942)

2019-07-30 Thread Vedant Kumar via Phabricator via cfe-commits
vsk abandoned this revision. vsk added a comment. Thanks Reid! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65426/new/ https://reviews.llvm.org/D65426 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/m

[PATCH] D65428: Remove cache for macro arg stringization

2019-07-30 Thread Vedant Kumar via Phabricator via cfe-commits
vsk accepted this revision. vsk added a comment. This revision is now accepted and ready to land. Thanks, lgtm. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65428/new/ https://reviews.llvm.org/D65428

[PATCH] D65461: [OPENMP]Add support for analysis of linear variables and step.

2019-07-30 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added a reviewer: NoQ. Herald added a subscriber: guansong. Herald added a project: clang. Added support for basic analysis of the linear variables and linear step expression. Linear loop iteration variables must be excluded from this analysis, only non-loop

[PATCH] D63932: [GlobalDCE] Dead Virtual Function Elimination

2019-07-30 Thread Peter Collingbourne via Phabricator via cfe-commits
pcc added a comment. In D63932#1606248 , @ostannard wrote: > In that example, with everything having default ELF visibility, all of the > vtables will get vcall_visibility public, which can't be optimised by VFE, > and won't ever be relaxed to one of the

[PATCH] D62574: Initial draft of target-configurable address spaces.

2019-07-30 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia added inline comments. Comment at: include/clang/AST/ASTContext.h:2598 + /// Returns true if address space A overlaps with B. + bool isAddressSpaceOverlapping(LangAS A, LangAS B) const { +// A overlaps with B if either is a superset of the other.

[PATCH] D65343: [clang-tidy] Fix the documentation for linuxkernel-must-use-errs.

2019-07-30 Thread Tom Roeder via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367333: [clang-tidy] Fix the documentation for linuxkernel-must-use-errs. (authored by tmroeder, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to com

[clang-tools-extra] r367333 - [clang-tidy] Fix the documentation for linuxkernel-must-use-errs.

2019-07-30 Thread Tom Roeder via cfe-commits
Author: tmroeder Date: Tue Jul 30 09:49:28 2019 New Revision: 367333 URL: http://llvm.org/viewvc/llvm-project?rev=367333&view=rev Log: [clang-tidy] Fix the documentation for linuxkernel-must-use-errs. Summary: This changes ReleaseNotes.txt to have the first sentence of the full documentation from

[PATCH] D63932: [GlobalDCE] Dead Virtual Function Elimination

2019-07-30 Thread Oliver Stannard (Linaro) via Phabricator via cfe-commits
ostannard updated this revision to Diff 212370. ostannard marked 2 inline comments as done. ostannard added a comment. - Rebase - Don't emit llvm.assume when not necessary (we already weren't checking for it's presence in GlobalDCE) - s/"public"/"default"/ in IR docs Repository: rG LLVM Githu

[PATCH] D65456: [OpenCL] Add generic type handling for builtin functions

2019-07-30 Thread Sven van Haastregt via Phabricator via cfe-commits
svenvh added a comment. Main changes since D63434 : - Rename List* to Vec*. - Rename TLnn -> TLAll, TLInt, TLFloat. - Apply clang-format. - Improve/update documentation. - Factor out renaming of base types into separate commit. - Change return type of OCL2Qual. -

  1   2   >