Re: [PATCH] D64029: [PGO] Add PGO support at -O0 in the experimental new pass manager

2019-08-02 Thread Rong Xu via cfe-commits
yes. I already know this issue as this also breaks windows bolt. The fix should be simple. -Rong On Thu, Aug 1, 2019 at 11:52 PM Petr Hosek via Phabricator < revi...@reviews.llvm.org> wrote: > phosek added a comment. > > Looks like this change broke `Profile/gcc-flag-compatibility.c` test on > m

r367658 - Revert r367649: Improve raw_ostream so that you can "write" colors using operator<

2019-08-02 Thread Rui Ueyama via cfe-commits
Author: ruiu Date: Fri Aug 2 00:22:34 2019 New Revision: 367658 URL: http://llvm.org/viewvc/llvm-project?rev=367658&view=rev Log: Revert r367649: Improve raw_ostream so that you can "write" colors using operator<< This reverts commit r367649 in an attempt to unbreak Windows bots. Modified:

r367657 - [PGO] Fix bolt failures from r367628

2019-08-02 Thread Rong Xu via cfe-commits
Author: xur Date: Fri Aug 2 00:21:50 2019 New Revision: 367657 URL: http://llvm.org/viewvc/llvm-project?rev=367657&view=rev Log: [PGO] Fix bolt failures from r367628 Relaxed the check in a test because the windows bolt generates different profile variables. Modified: cfe/trunk/test/Profile/

Re: [PATCH] D64029: [PGO] Add PGO support at -O0 in the experimental new pass manager

2019-08-02 Thread Rong Xu via cfe-commits
r367657 should fix this. On Fri, Aug 2, 2019 at 12:20 AM Rong Xu wrote: > yes. I already know this issue as this also breaks windows bolt. > The fix should be simple. > > -Rong > > On Thu, Aug 1, 2019 at 11:52 PM Petr Hosek via Phabricator < > revi...@reviews.llvm.org> wrote: > >> phosek added a

[PATCH] D65577: [ASTImporter] Import default expression of param before creating the param.

2019-08-02 Thread Balázs Kéri via Phabricator via cfe-commits
balazske marked 2 inline comments as done. balazske added inline comments. Comment at: clang/lib/AST/ASTImporter.cpp:3859 ToTypeSourceInfo, D->getStorageClass(), /*DefaultArg*/ nullptr)) return ToParm; ---

[PATCH] D64695: [clang-format] Added new style rule: SortNetBSDIncludes

2019-08-02 Thread Manikishan Ghantasala via Phabricator via cfe-commits
Manikishan updated this revision to Diff 212978. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64695/new/ https://reviews.llvm.org/D64695 Files: include/clang/Format/Format.h include/clang/Tooling/Inclusions/HeaderIncludes.h include/clang/Tooling/Inclusions/

r367661 - Don't try emitting dllexported explicitly defaulted non-trivial ctors twice during explicit template instantiation definition (PR42857)

2019-08-02 Thread Hans Wennborg via cfe-commits
Author: hans Date: Fri Aug 2 00:51:41 2019 New Revision: 367661 URL: http://llvm.org/viewvc/llvm-project?rev=367661&view=rev Log: Don't try emitting dllexported explicitly defaulted non-trivial ctors twice during explicit template instantiation definition (PR42857) Trying to emit the definition

[PATCH] D65579: Don't try emitting dllexported explicitly defaulted non-trivial ctors twice during explicit template instantiation definition (PR42857)

2019-08-02 Thread Hans Wennborg via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367661: Don't try emitting dllexported explicitly defaulted non-trivial ctors twice… (authored by hans, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior

[PATCH] D48866: [clang-tidy] Add incorrect-pointer-cast checker

2019-08-02 Thread Balázs Benics via Phabricator via cfe-commits
steakhal added a comment. Herald added a subscriber: whisperity. Do you have some time @Szelethus to check this change? Your experience and comments would help a lot to finish this. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D48866/new/ https://reviews.llvm.org/D48866 _

[PATCH] D65525: [clangd] Add new helpers to make tweak tests scale better. Convert most tests. NFC

2019-08-02 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 212985. sammccall marked 9 inline comments as done. sammccall added a comment. address comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65525/new/ https://reviews.llvm.org/D65525 Files: clang-tools-e

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

2019-08-02 Thread Balázs Kéri via Phabricator via cfe-commits
balazske updated this revision to Diff 212986. balazske added a comment. Rebase and add a new testing case. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65445/new/ https://reviews.llvm.org/D65445 Files: clang/include/clang/CrossTU/CrossTranslat

[PATCH] D65574: Added hack to prevent toHalfOpenFileRange assertion fail

2019-08-02 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clang-tools-extra/clangd/Selection.cpp:373 +if(!Range) + return SelectionTree::Unselected; dlog("{1}claimRange: {0}", Range->printToString(SM), indent()); This isn't a sufficient fix, there are 5 callsite

[PATCH] D65525: [clangd] Add new helpers to make tweak tests scale better. Convert most tests. NFC

2019-08-02 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/unittests/TweakTesting.h:44 +// Snippet is an expression. +Expression, + }; ilya-biryukov wrote: > I wonder whether we could use `Function` and get rid of 'expression' mode > comp

[PATCH] D65637: [clangd] [WIP] Semantic highlighting prototype for the vscode extension.

2019-08-02 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom created this revision. jvikstrom added reviewers: hokein, sammccall, ilya-biryukov. Herald added subscribers: cfe-commits, kadircet, arphaman, jkorous, MaskRay. Herald added a project: clang. Contains all the functionality for the highlighting, is going to get cleaned up a lot though. M

[PATCH] D65625: [clangd] Allow the client to specify multiple compilation databases in the 'initialize' request

2019-08-02 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a subscriber: sammccall. ilya-biryukov added a comment. Could this be handled outside clangd? If not, what are the complications? We currently have a capability to specify a path to a single `compile_commands.json`. I would expect clients using this extension (Theia?) also ha

[PATCH] D65562: Move LangStandard*, InputKind::Language to Basic

2019-08-02 Thread Rainer Orth via Phabricator via cfe-commits
ro updated this revision to Diff 212992. ro marked an inline comment as done. ro added a comment. Change Language to enum class. Tested as before. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65562/new/ https://reviews.llvm.org/D65562 Files: include/clang/Ba

[PATCH] D65562: Move LangStandard*, InputKind::Language to Basic

2019-08-02 Thread Rainer Orth via Phabricator via cfe-commits
ro marked 2 inline comments as done. ro added inline comments. Comment at: include/clang/Basic/LangStandard.h:19 +/// standard and possible actions. +enum Language { + Unknown, rnk wrote: > Is it feasible to make this an `enum class`? I'm worried about namespace

[PATCH] D64793: [Driver] Properly use values-X[ca].o, values-xpg[46].o on Solaris

2019-08-02 Thread Rainer Orth via Phabricator via cfe-commits
ro updated this revision to Diff 212993. ro added a comment. Account for enum class Language change in D65562 . Tested as before. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64793/new/ https://reviews.llvm.org/D64793 Files:

[PATCH] D65525: [clangd] Add new helpers to make tweak tests scale better. Convert most tests. NFC

2019-08-02 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clang-tools-extra/clangd/unittests/TweakTesting.cpp:74 +return true; + llvm::consumeError(PrepareResult.takeError()); + return false; ilya-biryukov wrote: > Maybe print the input in case of failure? This is a mat

[PATCH] D65525: [clangd] Add new helpers to make tweak tests scale better. Convert most tests. NFC

2019-08-02 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov accepted this revision. ilya-biryukov 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/D65525/new/ https://reviews.llvm.org/D65525 _

[clang-tools-extra] r367667 - [clangd] Add new helpers to make tweak tests scale better. Convert most tests. NFC

2019-08-02 Thread Sam McCall via cfe-commits
Author: sammccall Date: Fri Aug 2 02:12:39 2019 New Revision: 367667 URL: http://llvm.org/viewvc/llvm-project?rev=367667&view=rev Log: [clangd] Add new helpers to make tweak tests scale better. Convert most tests. NFC Summary: TweakTests.cpp has some pretty good helpers added for the first few

[PATCH] D65525: [clangd] Add new helpers to make tweak tests scale better. Convert most tests. NFC

2019-08-02 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367667: [clangd] Add new helpers to make tweak tests scale better. Convert most tests. (authored by sammccall, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Change

[PATCH] D48357: [RISCV] Remove duplicated logic when determining the target ABI

2019-08-02 Thread Sam Elliott via Phabricator via cfe-commits
lenary accepted this revision. lenary added a comment. This revision is now accepted and ready to land. Ok, sure! I think I'm happy for this to land then. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D48357/new/ https://reviews.llvm.org/D48357

[clang-tools-extra] r367672 - [clangd] Remove bad assert: nothing relies on it, and the reasons it was true no longer hold.

2019-08-02 Thread Sam McCall via cfe-commits
Author: sammccall Date: Fri Aug 2 03:39:46 2019 New Revision: 367672 URL: http://llvm.org/viewvc/llvm-project?rev=367672&view=rev Log: [clangd] Remove bad assert: nothing relies on it, and the reasons it was true no longer hold. Modified: clang-tools-extra/trunk/clangd/XRefs.cpp Modified:

[PATCH] D65637: [clangd] [WIP] Semantic highlighting prototype for the vscode extension.

2019-08-02 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom updated this revision to Diff 213011. jvikstrom added a comment. Readded guard against rules without scopes that somehow disappeared. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65637/new/ https://reviews.llvm.org/D65637 Files: clang

[PATCH] D65574: Added hack to prevent toHalfOpenFileRange assertion fail

2019-08-02 Thread Shaurya Gupta via Phabricator via cfe-commits
SureYeaah marked an inline comment as done. SureYeaah added inline comments. Comment at: clang-tools-extra/clangd/SourceCode.cpp:314 while (!FileRange.getBegin().isFileID()) { -assert(!FileRange.getEnd().isFileID() && - "Both Begin and End should be MacroIDs.");

r367675 - [OpenCL] Allow OpenCL C style vector initialization in C++

2019-08-02 Thread Anastasia Stulova via cfe-commits
Author: stulova Date: Fri Aug 2 04:19:35 2019 New Revision: 367675 URL: http://llvm.org/viewvc/llvm-project?rev=367675&view=rev Log: [OpenCL] Allow OpenCL C style vector initialization in C++ Allow creating vector literals from other vectors. float4 a = (float4)(1.0f, 2.0f, 3.0f, 4.0f); float

[PATCH] D65286: [OpenCL] Allow OpenCL C style vector initialization in C++

2019-08-02 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367675: [OpenCL] Allow OpenCL C style vector initialization in C++ (authored by stulova, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: h

[PATCH] D65637: [clangd] [WIP] Semantic highlighting prototype for the vscode extension.

2019-08-02 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom updated this revision to Diff 213013. jvikstrom added a comment. Fixed bug that made it impossible to find colors that were a perfect match to the scope we are looking for (ex: fixes function being color as functions and not as entity.name) Explanation for the bug: When adding the fun

[PATCH] D65637: [clangd] [WIP] Semantic highlighting prototype for the vscode extension.

2019-08-02 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom marked an inline comment as done. jvikstrom added inline comments. Comment at: clang-tools-extra/clangd/clients/clangd-vscode/src/TextMate.ts:20 +const split = scope.split('.'); +while(split.length > 0) { +split.splice(-1) ---

[PATCH] D65637: [clangd] [WIP] Semantic highlighting prototype for the vscode extension.

2019-08-02 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom updated this revision to Diff 213015. jvikstrom added a comment. Fix matching logic on TM scopes. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65637/new/ https://reviews.llvm.org/D65637 Files: clang-tools-extra/clangd/clients/clangd-v

[PATCH] D65634: [RISCV] Default to lp64d in 64-bit RISC-V Linux

2019-08-02 Thread Sam Elliott via Phabricator via cfe-commits
lenary added inline comments. Comment at: clang/lib/Driver/ToolChains/Arch/RISCV.cpp:385 + ? "ilp32" + : Triple.getOS() == llvm::Triple::Linux ? "lp64d" : "lp64"; } Please may you turn this into a set of if-statements? Nesting ternary ope

[PATCH] D65634: [RISCV] Default to lp64d in 64-bit RISC-V Linux

2019-08-02 Thread Roger Ferrer Ibanez via Phabricator via cfe-commits
rogfer01 created this revision. rogfer01 added reviewers: asb, lenary. Herald added subscribers: cfe-commits, s.egerton, Jim, benna, psnobl, jocewei, PkmX, rkruppe, the_o, brucehoult, MartinMosbeck, edward-jones, zzheng, MaskRay, jrtc27, shiva0217, kito-cheng, niosHD, sabuasal, apazos, simoncook,

Re: [PATCH] D58418: [clang][DirectoryWatcher] Upstream DirectoryWatcher

2019-08-02 Thread Puyan Lotfi via cfe-commits
Hi Jan, Thanks for the follow up! Me and Compnerd narrowed down the issue to the inotify file count limit being exceeded as the cause. DirectoryWatcherLinux::create() in DirectoryWatcher-linux.cpp also doesn't properly perror, I'll post a patch for this shortly to print perror info if the file cou

[PATCH] D65634: [RISCV] Default to lp64d in 64-bit RISC-V Linux

2019-08-02 Thread Alex Bradbury via Phabricator via cfe-commits
asb added a comment. Thank Roger. While we're doing this, I think it would make sense to default to ilp32d on 32-bit Linux? I know the glibc support etc is less mature than for RV64, but it seems the sensible thing to do. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https

[PATCH] D65573: Add User docs for ASTImporter

2019-08-02 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. Lovely documentation with practical use-cases! I left a few inline remarks. Also wouldn't it be nice to have a section which introduces the `-ast-merge` command-line option. It would be helpful to see an example where a PCH is dumped and merged into another TU. You cou

[PATCH] D65637: [clangd] [WIP] Semantic highlighting prototype for the vscode extension.

2019-08-02 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tools-extra/clangd/clients/clangd-vscode/src/TextMate.ts:20 +const split = scope.split('.'); +while(split.length > 0) { +split.splice(-1) jvikstrom wrote: > I'm pretty sure th

[PATCH] D60943: Delay diagnosing asm constraints that require immediates until after inlining

2019-08-02 Thread Joerg Sonnenberger via Phabricator via cfe-commits
joerg added a comment. The combination of D60942 , D06943 and D65280 solves the problems for me on all targets I have. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60943/new/ https://reviews.ll

[PATCH] D64932: [Parser] Emit descriptive diagnostic for misplaced pragma

2019-08-02 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff updated this revision to Diff 213023. sepavloff added a comment. Updated patch Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64932/new/ https://reviews.llvm.org/D64932 Files: clang/include/clang/Basic/DiagnosticParseKinds.td clang/li

[PATCH] D64932: [Parser] Emit descriptive diagnostic for misplaced pragma

2019-08-02 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff marked 2 inline comments as done. sepavloff added inline comments. Comment at: clang/lib/Basic/TokenKinds.cpp:15 #include "llvm/Support/ErrorHandling.h" +#include using namespace clang; rjmccall wrote: > This is no longer necessary, right? Sure, remo

[PATCH] D48866: [clang-tidy] Add incorrect-pointer-cast checker

2019-08-02 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tools-extra/clang-tidy/bugprone/IncorrectPointerCastCheck.cpp:69-70 + "cast from %0 to %1 may lead to access memory based on invalid " + "memory layout; pointed to type is strictly aligned than the " +

[clang-tools-extra] r367678 - Fix "not all control paths return a value" warning. NFCI.

2019-08-02 Thread Simon Pilgrim via cfe-commits
Author: rksimon Date: Fri Aug 2 05:55:04 2019 New Revision: 367678 URL: http://llvm.org/viewvc/llvm-project?rev=367678&view=rev Log: Fix "not all control paths return a value" warning. NFCI. Modified: clang-tools-extra/trunk/clangd/unittests/TweakTesting.cpp Modified: clang-tools-extra/trun

[PATCH] D65192: [Sema] Make -Wbitwise-op-parentheses and -Wlogical-op-parentheses disabled-by-default

2019-08-02 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. Thank you for this! LGTM aside from a testing request (doesn't require further review). Comment at: include/clang/Basic/DiagnosticSemaKinds.td:5645 def warn_b

[PATCH] D65526: [Clangd] Initial prototype version of ExtractFunction

2019-08-02 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. I guess you're looking for design review at this point. But the most important part of that is the documentation of the high-level structure, which is entirely missing. I can't really infer it from the code because most of the design is (presumably) not implemented at

[PATCH] D65648: [clang-format] Add support to SpacesBeforeTrailingComments to add spaces before Block comments.

2019-08-02 Thread Manikishan Ghantasala via Phabricator via cfe-commits
Manikishan created this revision. Manikishan added reviewers: cfe-commits, mgorny, christos, MyDeveloperDay, rdwampler, lebedev.ri. Manikishan added a project: clang. Herald added a subscriber: krytarowski. Patch: SpacesBeforeTrailingBlockComments This patch is to support ```spacesBeforeTrailing

Re: r367675 - [OpenCL] Allow OpenCL C style vector initialization in C++

2019-08-02 Thread Yvan Roux via cfe-commits
Hi Anastasia, This commit broke ARMv8 bots, logs are available here: http://lab.llvm.org:8011/builders/clang-cmake-armv8-quick/builds/14655/steps/ninja%20check%201/logs/FAIL%3A%20Clang%3A%3Avector_literals_valid.cl Thanks, Yvan On Fri, 2 Aug 2019 at 13:18, Anastasia Stulova via cfe-commits wro

[PATCH] D65650: [Analyzer] Iterator Checkers - Fix for Crash on Iterator Differences

2019-08-02 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware created this revision. baloghadamsoftware added reviewers: NoQ, Szelethus. baloghadamsoftware added a project: clang. Herald added subscribers: Charusso, gamesh411, donat.nagy, mikhail.ramalho, a.sidorin, rnkovacs, szepet, xazax.hun, whisperity. Iterators differences were mista

[PATCH] D65637: [clangd] [WIP] Semantic highlighting prototype for the vscode extension.

2019-08-02 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom marked an inline comment as done. jvikstrom added inline comments. Comment at: clang-tools-extra/clangd/clients/clangd-vscode/src/TextMate.ts:20 +const split = scope.split('.'); +while(split.length > 0) { +split.splice(-1) ---

[PATCH] D65650: [Analyzer] Iterator Checkers - Fix for Crash on Iterator Differences

2019-08-02 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware added a comment. This is an emergency patch. Please someone review this patch as soon as possible. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65650/new/ https://reviews.llvm.org/D65650 ___ cfe-

[PATCH] D62829: [clang-tidy] Check for dynamically initialized statics in headers.

2019-08-02 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tools-extra/test/clang-tidy/bugprone-dynamic-static-initializers.hpp:33-35 + // This may work fine when optimization is enabled because bar() can + // be turned into a constant 7. But without optimization, it can + // ca

[PATCH] D65655: [clangd] Fix a crash when presenting values for Hover

2019-08-02 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. ilya-biryukov added a reviewer: sammccall. Herald added subscribers: kadircet, arphaman, jkorous, MaskRay. Herald added a project: clang. We should pass the expression type, not a variable type when printing the resulting value. Variable type may be different f

[PATCH] D65510: [clangd] Fix implicit template instatiations appearing as topLevelDecls.

2019-08-02 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom marked 2 inline comments as done. jvikstrom added inline comments. Comment at: clang-tools-extra/clangd/ClangdUnit.cpp:68 + if (const auto *TD = dyn_cast(D)) +return TD->getTemplateSpecializationKind() == TSK_ImplicitInstantiation; + return false;

[PATCH] D65510: [clangd] Fix implicit template instatiations appearing as topLevelDecls.

2019-08-02 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom updated this revision to Diff 213041. jvikstrom added a comment. Moved test to ClangdUnitTests. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65510/new/ https://reviews.llvm.org/D65510 Files: clang-tools-extra/clangd/AST.h clang-tool

Re: r367530 - [Preprocessor] Always discard body of #define if we failed to parse it

2019-08-02 Thread Hans Wennborg via cfe-commits
Merged to release_90 in r367681. On Thu, Aug 1, 2019 at 11:09 AM Ilya Biryukov via cfe-commits wrote: > > Author: ibiryukov > Date: Thu Aug 1 02:10:37 2019 > New Revision: 367530 > > URL: http://llvm.org/viewvc/llvm-project?rev=367530&view=rev > Log: > [Preprocessor] Always discard body of #defi

[PATCH] D65517: [Preprocessor] Always discard body of #define if we failed to parse it

2019-08-02 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In D65517#1609990 , @ilya-biryukov wrote: > SG, just wanted to make sure it's on your list ;-) Merged in r367681. Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65517/new/ https://reviews.llvm.org/D

[PATCH] D65526: [Clangd] Initial prototype version of ExtractFunction

2019-08-02 Thread Shaurya Gupta via Phabricator via cfe-commits
SureYeaah marked 2 inline comments as done. SureYeaah added a comment. In D65526#1612117 , @sammccall wrote: > I guess you're looking for design review at this point. > > But the most important part of that is the documentation of the high-level > structu

[PATCH] D65657: [clangd][vscode] clang-format the the extension code.

2019-08-02 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. hokein added reviewers: ilya-biryukov, sammccall, jvikstrom. Herald added subscribers: kadircet, arphaman, jkorous, MaskRay. Herald added a project: clang. As we are going to grow the extension in the near future, it is time to formalize the TS code format/style of ou

[PATCH] D65526: [Clangd] Initial prototype version of ExtractFunction

2019-08-02 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clang-tools-extra/clangd/refactor/tweaks/ExtractFunction.cpp:211 + // Note that DRELocType is never OUTSIDECONTEXT. + if (DeclLocType + 1 != DRELocType) +return; SureYeaah wrote: > sammccall wrote: > > this line

[PATCH] D65510: [clangd] Fix implicit template instatiations appearing as topLevelDecls.

2019-08-02 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. the change looks good to me, leave the final approval to Ilya as he knows more context. Comment at: clang-tools-extra/clangd/unittests/ClangdUnitTests.cpp:116 + auto AST = TU.build(); + EXPECT_THAT(AST.getLocalTopLevelDecls(), ElementsAre(DeclNamed("f

[clang-tools-extra] r367684 - [clangd][vscode] clang-format the the extension code.

2019-08-02 Thread Haojian Wu via cfe-commits
Author: hokein Date: Fri Aug 2 07:24:02 2019 New Revision: 367684 URL: http://llvm.org/viewvc/llvm-project?rev=367684&view=rev Log: [clangd][vscode] clang-format the the extension code. Summary: As we are going to grow the extension in the near future, it is time to formalize the TS code format/

[PATCH] D65657: [clangd][vscode] clang-format the the extension code.

2019-08-02 Thread Haojian Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367684: [clangd][vscode] clang-format the the extension code. (authored by hokein, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: https:/

[PATCH] D65573: Add User docs for ASTImporter

2019-08-02 Thread Gabor Marton via Phabricator via cfe-commits
martong marked 23 inline comments as done. martong added a comment. Thanks for the review! Comment at: clang/docs/LibASTImporter.rst:19 +``ASTContext`` holds long-lived AST nodes (such as types and decls) that can be referred to throughout the semantic analysis of a file. +The

[PATCH] D65573: Add User docs for ASTImporter

2019-08-02 Thread Gabor Marton via Phabricator via cfe-commits
martong updated this revision to Diff 213046. martong marked 5 inline comments as done. martong added a comment. - Address comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65573/new/ https://reviews.llvm.org/D65573 Files: clang/docs/LibAST

[PATCH] D64932: [Parser] Emit descriptive diagnostic for misplaced pragma

2019-08-02 Thread John McCall via Phabricator via cfe-commits
rjmccall accepted this revision. rjmccall 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/D64932/new/ https://reviews.llvm.org/D64932 ___

[clang-tools-extra] r367687 - [clangd] Fix a crash when presenting values for Hover

2019-08-02 Thread Ilya Biryukov via cfe-commits
Author: ibiryukov Date: Fri Aug 2 08:23:04 2019 New Revision: 367687 URL: http://llvm.org/viewvc/llvm-project?rev=367687&view=rev Log: [clangd] Fix a crash when presenting values for Hover Summary: We should pass the expression type, not a variable type when printing the resulting value. Variabl

[PATCH] D65655: [clangd] Fix a crash when presenting values for Hover

2019-08-02 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367687: [clangd] Fix a crash when presenting values for Hover (authored by ibiryukov, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: http

[PATCH] D65655: [clangd] Fix a crash when presenting values for Hover

2019-08-02 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a subscriber: hans. ilya-biryukov added a comment. @hans, could we merge this commit into the release branch? Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65655/new/ https://reviews.llvm.org/D65655 __

[PATCH] D64464: [CodeGen] Emit destructor calls for non-trivial C structs

2019-08-02 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Herald added a subscriber: rnkovacs. Comment at: include/clang/AST/ExprCXX.h:3220 + /// It's useful to remember the set of blocks and compound literals; we could + /// also remember the set of temporaries, but there's currently no need. + using

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

2019-08-02 Thread Paul Kirth via Phabricator via cfe-commits
paulkirth updated this revision to Diff 213059. paulkirth marked 2 inline comments as done. paulkirth added a comment. Fix typo in comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65300/new/ https://reviews.llvm.org/D65300 Files: clang/inc

[PATCH] D65192: [Sema] Make -Wbitwise-op-parentheses and -Wlogical-op-parentheses disabled-by-default

2019-08-02 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 213064. MaskRay added a comment. Add bitwise-op-parentheses.c logical-op-parentheses.c Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65192/new/ https://reviews.llvm.org/D65192 Files: include/clang/Basic/DiagnosticSemaKinds

r367690 - [Sema] Disable -Wbitwise-op-parentheses and -Wlogical-op-parentheses by default

2019-08-02 Thread Fangrui Song via cfe-commits
Author: maskray Date: Fri Aug 2 09:31:38 2019 New Revision: 367690 URL: http://llvm.org/viewvc/llvm-project?rev=367690&view=rev Log: [Sema] Disable -Wbitwise-op-parentheses and -Wlogical-op-parentheses by default Summary: The -Wparentheses warnings are enabled by default in clang but they are un

[PATCH] D65192: [Sema] Make -Wbitwise-op-parentheses and -Wlogical-op-parentheses disabled-by-default

2019-08-02 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 213065. MaskRay added a comment. . Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65192/new/ https://reviews.llvm.org/D65192 Files: include/clang/Basic/DiagnosticSemaKinds.td test/Sema/bitwise-op-parentheses.c test/Sema

[PATCH] D65192: [Sema] Make -Wbitwise-op-parentheses and -Wlogical-op-parentheses disabled-by-default

2019-08-02 Thread Fangrui Song via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367690: [Sema] Disable -Wbitwise-op-parentheses and -Wlogical-op-parentheses by default (authored by MaskRay, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Reposit

[PATCH] D65517: [Preprocessor] Always discard body of #define if we failed to parse it

2019-08-02 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. Thanks! Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65517/new/ https://reviews.llvm.org/D65517 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/ma

[PATCH] D62829: [clang-tidy] Check for dynamically initialized statics in headers.

2019-08-02 Thread Charles Zhang via Phabricator via cfe-commits
czhang marked 2 inline comments as done. czhang added inline comments. Comment at: clang-tools-extra/test/clang-tidy/bugprone-dynamic-static-initializers.hpp:33-35 + // This may work fine when optimization is enabled because bar() can + // be turned into a constant 7. But wit

[PATCH] D65663: [analyzer] ConditionBRVisitor: Fix HTML PathDiagnosticPopUpPieces

2019-08-02 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso added a comment. It also reverts https://reviews.llvm.org/rL362632 which is not a fix, but a problem instead. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65663/new/ https://reviews.llvm.org/D65663 ___ cfe

[PATCH] D65663: [analyzer] ConditionBRVisitor: Fix HTML PathDiagnosticPopUpPieces

2019-08-02 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso created this revision. Charusso added a reviewer: NoQ. Charusso added a project: clang. Herald added subscribers: cfe-commits, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Charusso added a comment. It also reverts https://reviews.llvm.

[PATCH] D62829: [clang-tidy] Check for dynamically initialized statics in headers.

2019-08-02 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tools-extra/test/clang-tidy/bugprone-dynamic-static-initializers.hpp:33-35 + // This may work fine when optimization is enabled because bar() can + // be turned into a constant 7. But without optimization, it can + // ca

[clang-tools-extra] r367694 - [clang-tidy] Adding static analyzer check to list of clang-tidy checks

2019-08-02 Thread Nathan Huckleberry via cfe-commits
Author: nathan-huckleberry Date: Fri Aug 2 10:18:31 2019 New Revision: 367694 URL: http://llvm.org/viewvc/llvm-project?rev=367694&view=rev Log: [clang-tidy] Adding static analyzer check to list of clang-tidy checks Summary: Since clang-tidy supports use of the static analyzer there should be doc

[PATCH] D64454: [clang-tidy] Adding static analyzer check to list of clang-tidy checks

2019-08-02 Thread Nathan Huckleberry via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367694: [clang-tidy] Adding static analyzer check to list of clang-tidy checks (authored by Nathan-Huckleberry, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Chang

[PATCH] D65664: [BPF] annotate DIType metadata for builtin preseve_array_access_index()

2019-08-02 Thread Yonghong Song via Phabricator via cfe-commits
yonghong-song created this revision. yonghong-song added a reviewer: ast. Herald added subscribers: llvm-commits, cfe-commits, arphaman, aprantl. Herald added projects: clang, LLVM. Previously, debuginfo types are annotated to IR builtin preserve_struct_access_index() and preserve_union_access_ind

[PATCH] D65615: [BPF] annotate DIType metadata for builtin preseve_array_access_index()

2019-08-02 Thread Yonghong Song via Phabricator via cfe-commits
yonghong-song abandoned this revision. yonghong-song added a comment. abandon this one. use git monorepo https://reviews.llvm.org/D65664 since we have llvm/clang inter-dependence here. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65615/new/ https://reviews.llvm

[PATCH] D65635: Sidestep false positive due to a matching git repository name

2019-08-02 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 It would be cleaner to convert this test to FileCheck, but it's probably not worth spending the time at this point. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D65665: Support for attributes on @class declarations

2019-08-02 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington created this revision. erik.pilkington added reviewers: aaron.ballman, arphaman, rjmccall. Herald added subscribers: dexonsmith, jkorous. Herald added a project: clang. This is useful to make availability checking work with forward declarations, but there also seem to be other att

[PATCH] D62829: [clang-tidy] Check for dynamically initialized statics in headers.

2019-08-02 Thread Charles Zhang via Phabricator via cfe-commits
czhang marked 2 inline comments as done. czhang added inline comments. Comment at: clang-tools-extra/test/clang-tidy/bugprone-dynamic-static-initializers.hpp:33-35 + // This may work fine when optimization is enabled because bar() can + // be turned into a constant 7. But wit

[PATCH] D62829: [clang-tidy] Check for dynamically initialized statics in headers.

2019-08-02 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang-tools-extra/test/clang-tidy/bugprone-dynamic-static-initializers.hpp:33-35 + // This may work fine when optimization is enabled because bar() can + // be turned into a constant 7. But without optimization, it can + // cause

[PATCH] D65668: [Driver][test] Avoid undefined grep in darwin-ld.c

2019-08-02 Thread Hubert Tong via Phabricator via cfe-commits
hubert.reinterpretcast created this revision. hubert.reinterpretcast added reviewers: rnk, daltenty, xingxue, jasonliu. Herald added a project: clang. question-mark is not a BRE special character. POSIX.1-2017 XBD Section 9.3.2 indicates that the interpretation of `\?` as used by rC366282

[PATCH] D65668: [Driver][test] Avoid undefined grep in darwin-ld.c

2019-08-02 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. Probably like most programmers, I am not familiar with section 9.3.2 of posix. I assume this is affecting a real platform that you care about, but I'm curious what it is. lgtm Repository: rC Cl

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

2019-08-02 Thread Paul Kirth via Phabricator via cfe-commits
paulkirth marked 2 inline comments as done. paulkirth added inline comments. Comment at: clang/lib/CodeGen/MisExpect.cpp:82 + if (ExpectedTrueBranch) { +const llvm::BranchProbability HotFunctionThreshold(1, 100); +Scaled = HotFunctionThreshold.scale(CurrProfCount); -

[PATCH] D56326: [OpenMP 5.0] Parsing/sema support for "omp declare mapper" directive

2019-08-02 Thread David Major via Phabricator via cfe-commits
dmajor added a comment. Herald added a reviewer: jdoerfert. Herald added a subscriber: erik.pilkington. While debugging something else, I noticed that with this patch, `Decl` now has 33 bits worth of bitfields, so it has gained an extra word. Is that ok? Just want to make sure it wasn't unintent

[PATCH] D65670: Use switch instead of series of comparisons

2019-08-02 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff created this revision. sepavloff added reviewers: rjmccall, alexfh. Herald added a project: clang. This is style correction, no functional changes. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D65670 Files: clang/include/clang/Basic/TokenKinds.h clang/lib/Basic/

[PATCH] D65670: Use switch instead of series of comparisons

2019-08-02 Thread John McCall via Phabricator via cfe-commits
rjmccall accepted this revision. rjmccall 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/D65670/new/ https://reviews.llvm.org/D65670 ___

[PATCH] D65405: [Parser] Use special definition for pragma annotations

2019-08-02 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff added a comment. > LGTM, although I don't think it would be ridiculous to make this an inline > function definition like isAnnotation. Thank you! The fix for `isAnnotation` is D65670 . Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews

[PATCH] D62829: [clang-tidy] Check for dynamically initialized statics in headers.

2019-08-02 Thread Charles Zhang via Phabricator via cfe-commits
czhang updated this revision to Diff 213102. czhang marked an inline comment as done. czhang added a comment. Be more explicit about -fno-threadsafe-statics CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62829/new/ https://reviews.llvm.org/D62829 Files: clang-tools-extra/clang-tidy/bu

[PATCH] D62829: [clang-tidy] Check for dynamically initialized statics in headers.

2019-08-02 Thread Charles Zhang via Phabricator via cfe-commits
czhang added inline comments. Comment at: clang-tools-extra/test/clang-tidy/bugprone-dynamic-static-initializers.hpp:33-35 + // This may work fine when optimization is enabled because bar() can + // be turned into a constant 7. But without optimization, it can + // cause pro

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

2019-08-02 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added inline comments. Comment at: clang/lib/CodeGen/MisExpect.cpp:140-146 +void EmitMisExpectWarning(const CallExpr *Call, CodeGenModule &CGM) { + SourceLocation ExprLoc = Call->getBeginLoc(); + unsigned DiagID = CGM.getDiags().getCustomDiagID( + DiagnosticsEngin

[PATCH] D62829: [clang-tidy] Check for dynamically initialized statics in headers.

2019-08-02 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. I think this last update clarified the concerns i raised in last comment. But, did you mean to update the tests? They should have broke now that you require `!getLangOpts().ThreadsafeStatics`. Comment at: clang-tools-extra/docs/clang-tidy/checks/bu

[PATCH] D65622: [clang-doc] Update documentation

2019-08-02 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tools-extra/docs/clang-doc.rst:93 +--public - Document only public declarations. +--stylesheets= - CSS stylesheets to extend the default styles. It'll be reasonable to mention t

[PATCH] D65668: [Driver][test] Avoid undefined grep in darwin-ld.c

2019-08-02 Thread Hubert Tong via Phabricator via cfe-commits
hubert.reinterpretcast added a comment. In D65668#1612711 , @rnk wrote: > I assume this is affecting a real platform that you care about, but I'm > curious what it is. Yes, this is affecting our tests on AIX. `\?` there matches a literal `?` character.

[PATCH] D65627: [clang-doc] Continue after mapping error

2019-08-02 Thread Jake Ehrlich via Phabricator via cfe-commits
jakehehrlich added a comment. What's the use case for this and how do we handle return codes when an error occurs but we continue on? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65627/new/ https://reviews.llvm.org/D65627 ___ cfe-commits

  1   2   >