[PATCH] D44609: [Clang-Format] New option BeforeLambdaBody to manage lambda line break inside function parameter call (in Allman style)

2018-10-04 Thread Christophe Calmejane via Phabricator via cfe-commits
christophe-calmejane added a comment. Hi, consider the following code myFunc([](int x) { if (x) call(); }); When activating your BeforeLambdaBody option, it changes the code to this (breaking the start of the lambda to a new line) myFunc( [](int x)

[PATCH] D50179: [AArch64][ARM] Context sensitive meaning of option "crypto"

2018-10-04 Thread Sjoerd Meijer via Phabricator via cfe-commits
SjoerdMeijer added a comment. Thanks! https://reviews.llvm.org/D50179 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r343758 - [AArch64][ARM] Context sensitive meaning of crypto

2018-10-04 Thread Sjoerd Meijer via cfe-commits
Author: sjoerdmeijer Date: Thu Oct 4 00:38:53 2018 New Revision: 343758 URL: http://llvm.org/viewvc/llvm-project?rev=343758&view=rev Log: [AArch64][ARM] Context sensitive meaning of crypto For AArch64, crypto means: - sm4 + sha3 + sha2 + aes for Armv8.4-A and up, and - sha2 + aes for Armv8.3-A a

[PATCH] D50179: [AArch64][ARM] Context sensitive meaning of option "crypto"

2018-10-04 Thread Sjoerd Meijer via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL343758: [AArch64][ARM] Context sensitive meaning of crypto (authored by SjoerdMeijer, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D50179?vs

Re: r343285 - [cxx2a] P0641R2: (Some) type mismatches on defaulted functions only

2018-10-04 Thread Stephan Bergmann via cfe-commits
On 04/10/2018 01:14, Richard Smith wrote: On Tue, 2 Oct 2018 at 01:18, Stephan Bergmann via cfe-commits mailto:cfe-commits@lists.llvm.org>> wrote: On 28/09/2018 03:16, Richard Smith via cfe-commits wrote: > Author: rsmith > Date: Thu Sep 27 18:16:43 2018 > New Revision: 34328

[PATCH] D52726: [clangd] Support refs() in dex. Largely cloned from MemIndex.

2018-10-04 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clangd/index/dex/Dex.h:61 } // Symbols are owned by BackingData, Index takes ownership. + template nit: this comment is stale too. Comment at: unittests/clangd/DexTests.cpp:618 +Files.push_b

[clang-tools-extra] r343759 - [clangd] clangd-indexer: Drop support for MR-via-YAML

2018-10-04 Thread Sam McCall via cfe-commits
Author: sammccall Date: Thu Oct 4 01:30:03 2018 New Revision: 343759 URL: http://llvm.org/viewvc/llvm-project?rev=343759&view=rev Log: [clangd] clangd-indexer: Drop support for MR-via-YAML Summary: It's slow, and the open-source reduce implementation doesn't scale properly. While here, tidy up s

[PATCH] D52517: [clangd] clangd-indexer: Drop support for MR-via-YAML

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL343759: [clangd] clangd-indexer: Drop support for MR-via-YAML (authored by sammccall, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D52517 Files

[PATCH] D52782: [clang-tidy] Sequence statements with multiple parents correctly (PR39149)

2018-10-04 Thread Martin Böhme via Phabricator via cfe-commits
mboehme updated this revision to Diff 168239. mboehme added a comment. - Responses to reviewer comments. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52782 Files: clang-tidy/bugprone/UseAfterMoveCheck.cpp clang-tidy/utils/ExprSequence.cpp clang-tidy/utils/ExprSequence.h

[PATCH] D52782: [clang-tidy] Sequence statements with multiple parents correctly (PR39149)

2018-10-04 Thread Martin Böhme via Phabricator via cfe-commits
mboehme marked 3 inline comments as done. mboehme added inline comments. Comment at: clang-tidy/utils/ExprSequence.cpp:103 for (const Stmt *Parent : getParentStmts(S, Context)) { +// For statements that have multiple parents, make sure we're using the +// parent that l

[PATCH] D44609: [Clang-Format] New option BeforeLambdaBody to manage lambda line break inside function parameter call (in Allman style)

2018-10-04 Thread Christophe Calmejane via Phabricator via cfe-commits
christophe-calmejane added a comment. Actually, without your change to HasMultipleNestedBlocks, I'm almost getting the expected result: Lambda body is correctly indented (and not by function name's length). The only thing not working (and it's not either way, with or without your change to HasM

[PATCH] D52726: [clangd] Support refs() in dex. Largely cloned from MemIndex.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall marked 2 inline comments as done. sammccall added inline comments. Comment at: unittests/clangd/DexTests.cpp:618 +Files.push_back(R.Location.FileURI); + }); +} hokein wrote: > The test seems doesn't verify any thing? Oops, thanks! Repository: r

[PATCH] D52695: [clang][Parse] Diagnose useless null statements (PR39111)

2018-10-04 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri updated this revision to Diff 168240. lebedev.ri marked an inline comment as done. lebedev.ri added a comment. Thank you for taking a look! - Reworded the diag as suggested a little - Do consume consequtive semis as one - Do still record each one of them in AST. I'm not sure if we wa

[PATCH] D52870: [NestedNameSpecifier] Add missing stream-specific dump methods

2018-10-04 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. Herald added a subscriber: cfe-commits. Repository: rC Clang https://reviews.llvm.org/D52870 Files: include/clang/AST/NestedNameSpecifier.h lib/AST/NestedNameSpecifier.cpp Index: lib/AST/NestedNameSpecifier.cpp ===

[PATCH] D52726: [clangd] Support refs() in dex. Largely cloned from MemIndex.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 168242. sammccall marked an inline comment as done. sammccall added a comment. Fix test and comment, and sync Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52726 Files: clangd/index/Serialization.cpp clangd/index/dex/Dex.cpp clangd

[PATCH] D52531: [clangd] clangd-indexer gathers refs and stores them in index files.

2018-10-04 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. Looks great! I played around this patch a bit on LLVM. The output size is 50MB (binary)/1.2G (YAML). The ref output is not complete (missing all refs in headers, since we only collect refs from main file), I think we will add an option to `SymbolCollector` to allow coll

[PATCH] D52726: [clangd] Support refs() in dex. Largely cloned from MemIndex.

2018-10-04 Thread Haojian Wu via Phabricator via cfe-commits
hokein accepted this revision. hokein added a comment. This revision is now accepted and ready to land. LGTM Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52726 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.l

[clang-tools-extra] r343760 - [clangd] Support refs() in dex. Largely cloned from MemIndex.

2018-10-04 Thread Sam McCall via cfe-commits
Author: sammccall Date: Thu Oct 4 02:16:12 2018 New Revision: 343760 URL: http://llvm.org/viewvc/llvm-project?rev=343760&view=rev Log: [clangd] Support refs() in dex. Largely cloned from MemIndex. Reviewers: hokein Subscribers: ilya-biryukov, ioeric, MaskRay, jkorous, arphaman, kadircet, cfe-c

[PATCH] D52726: [clangd] Support refs() in dex. Largely cloned from MemIndex.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE343760: [clangd] Support refs() in dex. Largely cloned from MemIndex. (authored by sammccall, committed by ). Changed prior to commit: https://reviews.llvm.org/D52726?vs=168242&id=168243#toc Reposito

[PATCH] D51855: [constexpr] Fix ICE when memcpy() is given a pointer to an incomplete array

2018-10-04 Thread Petr Pavlu via Phabricator via cfe-commits
petpav01 added a comment. No worries, thanks. https://reviews.llvm.org/D51855 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D51855: [constexpr] Fix ICE when memcpy() is given a pointer to an incomplete array

2018-10-04 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL343761: [constexpr] Fix ICE when memcpy() is given a pointer to an incomplete array (authored by petr.pavlu, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://rev

r343761 - [constexpr] Fix ICE when memcpy() is given a pointer to an incomplete array

2018-10-04 Thread Petr Pavlu via cfe-commits
Author: petr.pavlu Date: Thu Oct 4 02:25:44 2018 New Revision: 343761 URL: http://llvm.org/viewvc/llvm-project?rev=343761&view=rev Log: [constexpr] Fix ICE when memcpy() is given a pointer to an incomplete array Fix code for constant evaluation of __builtin_memcpy() and __builtin_memmove() that

[PATCH] D52531: [clangd] clangd-indexer gathers refs and stores them in index files.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall marked 2 inline comments as done. sammccall added a comment. In https://reviews.llvm.org/D52531#1254828, @hokein wrote: > The ref output is not complete (missing all refs in headers, since we only > collect refs from main file), I think we will add an option to > `SymbolCollector` to

[PATCH] D52531: [clangd] clangd-indexer gathers refs and stores them in index files.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 168245. sammccall added a comment. Address review comments. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52531 Files: clangd/index/IndexAction.cpp clangd/index/IndexAction.h clangd/index/Serialization.cpp clangd/index/Serializat

[PATCH] D37813: clang-format: better handle namespace macros

2018-10-04 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. In https://reviews.llvm.org/D37813#1253813, @Typz wrote: > In https://reviews.llvm.org/D37813#1184051, @klimek wrote: > > > The problem here is that we have different opinions on how the formatting > > on namespace macros should behave in the first place- I think they sho

[PATCH] D52871: [clangd] Use canonical declarations in ReferenceFinder.

2018-10-04 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. hokein added a reviewer: sammccall. Herald added subscribers: kadircet, arphaman, jkorous, MaskRay, ioeric, ilya-biryukov. handleDeclOccurrencce reports a canonical declartion, so stick to use canonical declarations to determine whether a declaration is in the target

[PATCH] D44609: [Clang-Format] New option BeforeLambdaBody to manage lambda line break inside function parameter call (in Allman style)

2018-10-04 Thread Christophe Calmejane via Phabricator via cfe-commits
christophe-calmejane added a comment. Ok I found the issue with noexcept, it's not related to your patch. There is a missing case tok::kw_noexcept: in UnwrappedLineParser::tryToParseLambda Repository: rC Clang https://reviews.llvm.org/D44609 _

[PATCH] D52617: [clangd] Make stable_partition on include candidates less slow. NFC

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added a comment. This revision is now accepted and ready to land. The implementation looks fine, but I believe we concluded that seeing huge lists here was basically a bug. So you may not want to land it, if you prefer to keep things simple. Up to you.

[PATCH] D52531: [clangd] clangd-indexer gathers refs and stores them in index files.

2018-10-04 Thread Haojian Wu via Phabricator via cfe-commits
hokein accepted this revision. hokein added a comment. This revision is now accepted and ready to land. looks good. Comment at: clangd/index/Serialization.cpp:301 +// A refs section has data grouped by Symbol. Each symbol has: +// - SymbolID: 20 bytes +// - NumRefs: varint --

[PATCH] D52871: [clangd] Use canonical declarations in ReferenceFinder.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added a comment. This revision is now accepted and ready to land. Nice catch! Comment at: unittests/clangd/XRefsTests.cpp:1185 std::vector> ExpectedLocations; for (const auto &R : T.ranges("foo")) ExpectedLocations.pu

[clang-tools-extra] r343763 - [clangd] Use canonical declarations in ReferenceFinder.

2018-10-04 Thread Haojian Wu via cfe-commits
Author: hokein Date: Thu Oct 4 02:56:08 2018 New Revision: 343763 URL: http://llvm.org/viewvc/llvm-project?rev=343763&view=rev Log: [clangd] Use canonical declarations in ReferenceFinder. Summary: handleDeclOccurrencce reports a canonical declartion, so stick to use canonical declarations to det

[PATCH] D37813: clang-format: better handle namespace macros

2018-10-04 Thread Francois Ferrand via Phabricator via cfe-commits
Typz added a comment. In https://reviews.llvm.org/D37813#1254865, @klimek wrote: > In https://reviews.llvm.org/D37813#1253813, @Typz wrote: > > > In https://reviews.llvm.org/D37813#1184051, @klimek wrote: > > > > > The problem here is that we have different opinions on how the formatting > > > o

[PATCH] D52871: [clangd] Use canonical declarations in ReferenceFinder.

2018-10-04 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 168248. hokein marked an inline comment as done. hokein added a comment. Remove unnecessary labels. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52871 Files: clangd/XRefs.cpp unittests/clangd/XRefsTests.cpp Index: unittests/clangd/XRe

[PATCH] D50766: Fix false positive unsequenced access and modification warning in array subscript expression.

2018-10-04 Thread Mateusz Janek via Phabricator via cfe-commits
stryku added a comment. @Rakete Any more comments? https://reviews.llvm.org/D50766 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D52871: [clangd] Use canonical declarations in ReferenceFinder.

2018-10-04 Thread Haojian Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE343763: [clangd] Use canonical declarations in ReferenceFinder. (authored by hokein, committed by ). Changed prior to commit: https://reviews.llvm.org/D52871?vs=168248&id=168250#toc Repository: rL

[PATCH] D52871: [clangd] Use canonical declarations in ReferenceFinder.

2018-10-04 Thread Haojian Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL343763: [clangd] Use canonical declarations in ReferenceFinder. (authored by hokein, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D52871 Files:

[PATCH] D51340: Add /Zc:DllexportInlines option to clang-cl

2018-10-04 Thread Takuto Ikuta via Phabricator via cfe-commits
takuto.ikuta added a comment. Ping? https://reviews.llvm.org/D51340 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D52808: [cland] Dex: fix/simplify trigram generation

2018-10-04 Thread Eric Liu via Phabricator via cfe-commits
ioeric added a comment. > Generate more short-query trigrams, e.g. "AbcDefGhi" now yields "d" and "ag". I am concerned about the impact on the size of posting lists (we can measure) and retrieval quality by adding more incomplete trigrams. > This is effectively required by LSP, having "ag" not

[PATCH] D52789: [clangd] Dex: FALSE iterator, peephole optimizations, fix AND bug

2018-10-04 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 and a few NITs. Comment at: clangd/index/dex/Iterator.cpp:376 +} +default: + RealChildren.push_back(std::move(Child)); Maybe

[PATCH] D52814: [PassManager/Sanitizer] Enable usage of ported AddressSanitizer passes with -fsanitize=address

2018-10-04 Thread Philip Pfaffe via Phabricator via cfe-commits
philip.pfaffe added a comment. Is this the right place in the pipeline to put the passes? The legacy PM inserts the asan passes at EP_OptimizerLast, why not do the same thing? Repository: rC Clang https://reviews.llvm.org/D52814 ___ cfe-commits

[PATCH] D52753: [tooling] Create executor by name

2018-10-04 Thread Eric Liu via Phabricator via cfe-commits
ioeric added a comment. > This is useful in the case where the calling tool always wants to use a > particular non-default implementation (e.g. the tool should always be run > with the all-TUs executor) Any reason not to use the constructor of `AllTUsToolExecutor` directly? There is one that t

[PATCH] D52117: Generate llvm.loop.parallel_accesses instead of llvm.mem.parallel_loop_access metadata.

2018-10-04 Thread Michael Kruse via Phabricator via cfe-commits
Meinersbur updated this revision to Diff 168251. Meinersbur marked 2 inline comments as done. Meinersbur added a comment. - Address @pekka.jaaskelainen's review. Repository: rC Clang https://reviews.llvm.org/D52117 Files: lib/CodeGen/CGLoopInfo.cpp lib/CodeGen/CGLoopInfo.h test/CodeGen

[clang-tools-extra] r343764 - [clangd] Revert accidental flag change

2018-10-04 Thread Sam McCall via cfe-commits
Author: sammccall Date: Thu Oct 4 03:10:35 2018 New Revision: 343764 URL: http://llvm.org/viewvc/llvm-project?rev=343764&view=rev Log: [clangd] Revert accidental flag change Modified: clang-tools-extra/trunk/clangd/indexer/IndexerMain.cpp Modified: clang-tools-extra/trunk/clangd/indexer/Ind

[PATCH] D52814: [PassManager/Sanitizer] Enable usage of ported AddressSanitizer passes with -fsanitize=address

2018-10-04 Thread Fedor Sergeev via Phabricator via cfe-commits
fedor.sergeev added inline comments. Comment at: lib/CodeGen/BackendUtil.cpp:1031-1038 + MPM.addPass(AddressSanitizerModulePass()); + + // Add Function Pass + CGSCCPassManager MainCGPipeline(CodeGenOpts.DebugPassManager); + MainCGPipeline.addPass(createCGSCCTo

[PATCH] D52872: [clangd] Make binary index format the default, remove dead flag.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added a reviewer: hokein. Herald added subscribers: cfe-commits, kadircet, arphaman, jkorous, MaskRay, ioeric, ilya-biryukov. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52872 Files: clangd/indexer/IndexerMain.cpp Index: clangd/i

[PATCH] D52782: [clang-tidy] Sequence statements with multiple parents correctly (PR39149)

2018-10-04 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. Thanks for clarification :) Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52782 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D52873: Remove unwanted signedness conversion from tests

2018-10-04 Thread Marco Antognini via Phabricator via cfe-commits
mantognini created this revision. mantognini added a reviewer: Anastasia. Herald added a subscriber: cfe-commits. This is just a minor update of the tests. Repository: rC Clang https://reviews.llvm.org/D52873 Files: test/SemaOpenCL/cl20-device-side-enqueue.cl Index: test/SemaOpenCL/cl20-

[PATCH] D52782: [clang-tidy] Sequence statements with multiple parents correctly (PR39149)

2018-10-04 Thread Martin Böhme via Phabricator via cfe-commits
mboehme marked 2 inline comments as done. mboehme added a comment. In https://reviews.llvm.org/D52782#1254933, @JonasToth wrote: > Thanks for clarification :) Thanks! Do you agree this is ready to land now? Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52782 _

[PATCH] D52872: [clangd] Make binary index format the default, remove dead flag.

2018-10-04 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clangd/indexer/IndexerMain.cpp:84 - $ clangd-indexer --executor=all-TUs compile_commands.json > index.yaml + $ clangd-indexer --executor=all-TUs compile_commands.json > clangd-index Maybe we should suggest a

[PATCH] D52875: Fix definitions of __builtin_(add|sub|mul)_overflow

2018-10-04 Thread Marco Antognini via Phabricator via cfe-commits
mantognini created this revision. mantognini added reviewers: Anastasia, erichkeane. Herald added subscribers: cfe-commits, kristina. Ensure __builtin_(add|sub|mul)_overflow return bool instead of void as per specification (LanguageExtensions). Repository: rC Clang https://reviews.llvm.org/D

[PATCH] D52877: [Index] Respect "IndexFunctionLocals" option during index.

2018-10-04 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. hokein added a reviewer: sammccall. Herald added subscribers: kadircet, arphaman, ioeric, ilya-biryukov. Previously, clangd index ignored symbols defined in the function body even IndexFunctionLocals is true. Repository: rC Clang https://reviews.llvm.org/D52877

[PATCH] D52877: [Index] Respect "IndexFunctionLocals" option during index.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added a comment. This revision is now accepted and ready to land. (can you update the title/summary to reflect that only local *types* are affected?) Repository: rC Clang https://reviews.llvm.org/D52877 __

[PATCH] D52872: [clangd] Make binary index format the default, remove dead flag.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clangd/indexer/IndexerMain.cpp:84 - $ clangd-indexer --executor=all-TUs compile_commands.json > index.yaml + $ clangd-indexer --executor=all-TUs compile_commands.json > clangd-index hokein wrote: > ilya-biryukov

[PATCH] D52880: [clang-tidy] fix PR39167, bugprone-exception-escape hangs-up

2018-10-04 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth created this revision. JonasToth added reviewers: alexfh, aaron.ballman, baloghadamsoftware. Herald added subscribers: cfe-commits, rnkovacs, xazax.hun. The check bugprone-exception-escape should not register if -fno-exceptions is set for the compile options. Bailing out on non-cplusplu

[PATCH] D52872: [clangd] Make binary index format the default, remove dead flag.

2018-10-04 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clangd/indexer/IndexerMain.cpp:58 SymbolCollector::Options Opts; -Opts.FallbackDir = AssumedHeaderDir; return createStaticIndexingAction( If we remove the `assume-header-dir`, we probably remove `FallbackDir

[PATCH] D52879: Derive builtin return type from its definition

2018-10-04 Thread Marco Antognini via Phabricator via cfe-commits
mantognini created this revision. mantognini added reviewers: Anastasia, spatel. Herald added subscribers: cfe-commits, kristina. mantognini added dependencies: D52873: Remove unwanted signedness conversion from tests, D52875: Fix definitions of __builtin_(add|sub|mul)_overflow. Prior to this pat

[PATCH] D52782: [clang-tidy] Sequence statements with multiple parents correctly (PR39149)

2018-10-04 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. In https://reviews.llvm.org/D52782#1254945, @mboehme wrote: > In https://reviews.llvm.org/D52782#1254933, @JonasToth wrote: > > > Thanks for clarification :) > > > Thanks! Do you agree this is ready to land now? Sure! Repository: rCTE Clang Tools Extra https://re

[PATCH] D52880: [clang-tidy] fix PR39167, bugprone-exception-escape hangs-up

2018-10-04 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. This should definitly be backported, as exception-escape is in 7.0 and it hangs up on no-except builds Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52880 ___ cfe-commits mailing list cfe-commits@lists.l

[PATCH] D52880: [clang-tidy] fix PR39167, bugprone-exception-escape hangs-up

2018-10-04 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Needs a test. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52880 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r343767 - [Index] Respect "IndexFunctionLocals" option for type loc.

2018-10-04 Thread Haojian Wu via cfe-commits
Author: hokein Date: Thu Oct 4 04:03:55 2018 New Revision: 343767 URL: http://llvm.org/viewvc/llvm-project?rev=343767&view=rev Log: [Index] Respect "IndexFunctionLocals" option for type loc. Summary: Previously, clang index ignored local symbols defined in the function body even IndexFunctionLoc

[PATCH] D52877: [Index] Respect "IndexFunctionLocals" option for type loc.

2018-10-04 Thread Haojian Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC343767: [Index] Respect "IndexFunctionLocals" option for type loc. (authored by hokein, committed by ). Changed prior to commit: https://reviews.llvm.org/D52877?vs=168261&id=168263#toc Repository: rC

[PATCH] D52880: [clang-tidy] fix PR39167, bugprone-exception-escape hangs-up

2018-10-04 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. In https://reviews.llvm.org/D52880#1255031, @lebedev.ri wrote: > Needs a test. How shall i test it? It feels that this condition should have been there from the beginning on, as the check only makes sense in c++ and with exceptions. Repository: rCTE Clang Tools E

[PATCH] D52880: [clang-tidy] fix PR39167, bugprone-exception-escape hangs-up

2018-10-04 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. In https://reviews.llvm.org/D52880#1255035, @JonasToth wrote: > In https://reviews.llvm.org/D52880#1255031, @lebedev.ri wrote: > > > Needs a test. > > > How shall i test it? It feels that this condition should have been there from > the beginning on, as the check only

[PATCH] D52808: [cland] Dex: fix/simplify trigram generation

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall marked an inline comment as done. sammccall added a comment. **TL;DR**: i'm no longer convinced of my conclusions for short-query, look at the proposal below. In https://reviews.llvm.org/D52808#1254899, @ioeric wrote: > > Generate more short-query trigrams, e.g. "AbcDefGhi" now yields

[clang-tools-extra] r343768 - [clang-tidy] Sequence statements with multiple parents correctly (PR39149)

2018-10-04 Thread Martin Bohme via cfe-commits
Author: mboehme Date: Thu Oct 4 04:36:39 2018 New Revision: 343768 URL: http://llvm.org/viewvc/llvm-project?rev=343768&view=rev Log: [clang-tidy] Sequence statements with multiple parents correctly (PR39149) Summary: Before this fix, the bugprone-use-after-move check could incorrectly conclude t

[PATCH] D52782: [clang-tidy] Sequence statements with multiple parents correctly (PR39149)

2018-10-04 Thread Martin Böhme via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL343768: [clang-tidy] Sequence statements with multiple parents correctly (PR39149) (authored by mboehme, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llv

[PATCH] D52773: clang-cl: Add /showFilenames option (PR31957)

2018-10-04 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In https://reviews.llvm.org/D52773#1252584, @zturner wrote: > Canyou add a test that demonstrates that multiple input files on the command > line will print all of them? Will do. > Also does this really need to be a cc1 arg? Why not just print it in the > driver? Yeah

[PATCH] D52882: [clang-tidy] Added pointer types to clang-tidy readability-identifier-naming check.

2018-10-04 Thread Francesc Figueras via Phabricator via cfe-commits
ffigueras created this revision. ffigueras added reviewers: alexfh, kbobyrev. Herald added subscribers: cfe-commits, xazax.hun. Option to check for different naming conventions on the following types: - GlobalConstantPointer - GlobalPointer - LocalConstantPointer - LocalPointer - PointerParameter

[PATCH] D52727: [clang-tidy] White List Option for performance-unnecessary-value-param, performance-unnecessary-copy-initialization and performance-for-range-copy

2018-10-04 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 168274. baloghadamsoftware added a comment. Herald added a subscriber: mgorny. Updated according to the comments. https://reviews.llvm.org/D52727 Files: clang-tidy/performance/ForRangeCopyCheck.cpp clang-tidy/performance/ForRangeCopyCheck.h

Re: [PATCH] D52773: clang-cl: Add /showFilenames option (PR31957)

2018-10-04 Thread Zachary Turner via cfe-commits
I agree magic environment variables are bad, but without it we don’t address the only current actual use we have for this, which is making the vs integration print filenames. Detecting compiler version from inside the integration is hard, but with an environment variable it’s very easy to solve. I

[PATCH] D52773: clang-cl: Add /showFilenames option (PR31957)

2018-10-04 Thread Zachary Turner via Phabricator via cfe-commits
zturner added a subscriber: rnk. zturner added a comment. I agree magic environment variables are bad, but without it we don’t address the only current actual use we have for this, which is making the vs integration print filenames. Detecting compiler version from inside the integration is hard, b

[PATCH] D52727: [clang-tidy] White List Option for performance-unnecessary-value-param, performance-unnecessary-copy-initialization and performance-for-range-copy

2018-10-04 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Thanks looks even better, getting there. There are some spurious whiteline changes. Comment at: clang-tidy/performance/ForRangeCopyCheck.cpp:53 const auto *Var = Result.Nodes.getNodeAs("loopVar"); + // Ignore code in macros since we can't place

[PATCH] D52727: [clang-tidy] White List Option for performance-unnecessary-value-param, performance-unnecessary-copy-initialization and performance-for-range-copy

2018-10-04 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware added inline comments. Comment at: clang-tidy/utils/Matchers.cpp:20 +matchesAnyListedName(const std::vector &NameList) { + SmallString<256> NameRegEx; + llvm::raw_svector_ostream NameOut(NameRegEx); lebedev.ri wrote: > ``` > if(NameList.empty

[PATCH] D52727: [clang-tidy] White List Option for performance-unnecessary-value-param, performance-unnecessary-copy-initialization and performance-for-range-copy

2018-10-04 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang-tidy/utils/Matchers.cpp:20 +matchesAnyListedName(const std::vector &NameList) { + SmallString<256> NameRegEx; + llvm::raw_svector_ostream NameOut(NameRegEx); baloghadamsoftware wrote: > lebedev.ri wrote: > > `

[PATCH] D52727: [clang-tidy] White List Option for performance-unnecessary-value-param, performance-unnecessary-copy-initialization and performance-for-range-copy

2018-10-04 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang-tidy/utils/Matchers.cpp:18-19 + +Matcher +matchesAnyListedName(const std::vector &NameList) { + SmallString<256> NameRegEx; Actually wait, what is this? It should be something like ``` AST_MATCHER_P(NamedDecl,

[PATCH] D52808: [cland] Dex: fix/simplify trigram generation

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 168280. sammccall added a comment. Use similar but better-defined rules for short trigram matches. Modify Dex to account for the matches not being exhaustive. Unfortunately the test needs https://reviews.llvm.org/D52796, which depends on this patch. Repo

[PATCH] D52727: [clang-tidy] White List Option for performance-unnecessary-value-param, performance-unnecessary-copy-initialization and performance-for-range-copy

2018-10-04 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang-tidy/utils/Matchers.cpp:1 +//===--- Matchers.cpp - clang-tidy-===// +// Also, why is this not in a header? I suspect that heavily pessimizes inlining. https://reviews.l

[PATCH] D52789: [clangd] Dex: FALSE iterator, peephole optimizations, fix AND bug

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall marked 5 inline comments as done. sammccall added inline comments. Comment at: clangd/index/dex/Iterator.cpp:376 +} +default: + RealChildren.push_back(std::move(Child)); ilya-biryukov wrote: > Maybe replace with `case Kind::Other` to make s

[PATCH] D52727: [clang-tidy] White List Option for performance-unnecessary-value-param, performance-unnecessary-copy-initialization and performance-for-range-copy

2018-10-04 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware added inline comments. Comment at: clang-tidy/utils/Matchers.cpp:18-19 + +Matcher +matchesAnyListedName(const std::vector &NameList) { + SmallString<256> NameRegEx; lebedev.ri wrote: > Actually wait, what is this? > It should be something like

[clang-tools-extra] r343774 - [clangd] Dex: FALSE iterator, peephole optimizations, fix AND bug

2018-10-04 Thread Sam McCall via cfe-commits
Author: sammccall Date: Thu Oct 4 06:12:23 2018 New Revision: 343774 URL: http://llvm.org/viewvc/llvm-project?rev=343774&view=rev Log: [clangd] Dex: FALSE iterator, peephole optimizations, fix AND bug Summary: The FALSE iterator will be used in a followup patch to fix a logic bug in Dex (current

[PATCH] D52789: [clangd] Dex: FALSE iterator, peephole optimizations, fix AND bug

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. sammccall marked an inline comment as done. Closed by commit rCTE343774: [clangd] Dex: FALSE iterator, peephole optimizations, fix AND bug (authored by sammccall, committed by ). Changed prior to commit: https://reviews.l

[PATCH] D52875: Fix definitions of __builtin_(add|sub|mul)_overflow

2018-10-04 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. Can you write tests for this please? Particularly validate the results in a constexpr context. Additionally, these all have the 't' flag, which means that these signatures are meaningless, right? What are you seeing where this works incorrectly? Repository: rC

[PATCH] D52727: [clang-tidy] White List Option for performance-unnecessary-value-param, performance-unnecessary-copy-initialization and performance-for-range-copy

2018-10-04 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang-tidy/utils/Matchers.cpp:18-19 + +Matcher +matchesAnyListedName(const std::vector &NameList) { + SmallString<256> NameRegEx; baloghadamsoftware wrote: > lebedev.ri wrote: > > Actually wait, what is this? > > It

[PATCH] D52398: Thread safety analysis: Unwrap __builtin_expect in getTrylockCallExpr

2018-10-04 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. Hi, @aaronpuchert, the patch has caused many new warnings in our internal codebase, below is a reduced one. Do you mind reverting the patch? // if the condition is not true, CHECK will terminate the program. #define CHECK(condition) (__builtin_expect((condition), true

[PATCH] D52727: [clang-tidy] White List Option for performance-unnecessary-value-param, performance-unnecessary-copy-initialization and performance-for-range-copy

2018-10-04 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added inline comments. Comment at: clang-tidy/utils/Matchers.cpp:18-19 + +Matcher +matchesAnyListedName(const std::vector &NameList) { + SmallString<256> NameRegEx; lebedev.ri wrote: > baloghadamsoftware wrote: > > lebedev.ri wrote: > > > Actually wait

[PATCH] D52885: [clangd] Remove one-segment-skipping from Dex trigrams.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added reviewers: ilya-biryukov, ioeric. Herald added subscribers: cfe-commits, kadircet, arphaman, jkorous, MaskRay. Currently queries like "ab" can match identifiers like a_yellow_bee. The value of allowing this for exactly one segment but no more seems

[PATCH] D52875: Fix definitions of __builtin_(add|sub|mul)_overflow

2018-10-04 Thread Marco Antognini via Phabricator via cfe-commits
mantognini added a comment. In https://reviews.llvm.org/D52875#1255146, @erichkeane wrote: > Can you write tests for this please? Particularly validate the results in a > constexpr context. There are already some tests for those builtins (not sure about constexpr context). They already tests

[PATCH] D52873: Remove unwanted signedness conversion from tests

2018-10-04 Thread Marco Antognini via Phabricator via cfe-commits
mantognini added a comment. Note: the `get_kernel_*` functions used here all return unsigned integers, hence the warning/present patch. Repository: rC Clang https://reviews.llvm.org/D52873 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D52808: [cland] Dex: fix/simplify trigram generation

2018-10-04 Thread Eric Liu via Phabricator via cfe-commits
ioeric accepted this revision. ioeric added a comment. This revision is now accepted and ready to land. > The problem is LSP clients are free to assume that the result list is > complete (unless marked as incomplete) and therefore will never retrieve the > better symbols. Good point. Thanks for

[PATCH] D52885: [clangd] Remove one-segment-skipping from Dex trigrams.

2018-10-04 Thread Eric Liu via Phabricator via cfe-commits
ioeric accepted this revision. ioeric added a comment. This revision is now accepted and ready to land. lgtm Comment at: clangd/index/dex/Trigram.cpp:44 // * Next Head - front character of the next segment // * Skip-1-Next Head - front character of the skip-1-next segment

[clang-tools-extra] r343775 - [cland] Dex: fix/simplify short-trigram generation

2018-10-04 Thread Sam McCall via cfe-commits
Author: sammccall Date: Thu Oct 4 07:01:55 2018 New Revision: 343775 URL: http://llvm.org/viewvc/llvm-project?rev=343775&view=rev Log: [cland] Dex: fix/simplify short-trigram generation Summary: 1) Instead of x$$ for a short-query trigram, just use x 2) Make rules more coherent: prefixes of leng

[PATCH] D52808: [cland] Dex: fix/simplify trigram generation

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. sammccall marked 2 inline comments as done. Closed by commit rCTE343775: [cland] Dex: fix/simplify short-trigram generation (authored by sammccall, committed by ). Changed prior to commit: https://reviews.llvm.org/D52808?

[PATCH] D51633: [ASTImporter] Added error handling for AST import.

2018-10-04 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added inline comments. Comment at: lib/AST/ASTImporter.cpp:194 + // FIXME: This should be the final code. + //auto ToOrErr = Importer.Import(From); + //if (ToOrErr) { a_sidorin wrote: > Do I understand correctly that we have to use the upp

[clang-tools-extra] r343777 - [clangd] Remove one-segment-skipping from Dex trigrams.

2018-10-04 Thread Sam McCall via cfe-commits
Author: sammccall Date: Thu Oct 4 07:08:11 2018 New Revision: 343777 URL: http://llvm.org/viewvc/llvm-project?rev=343777&view=rev Log: [clangd] Remove one-segment-skipping from Dex trigrams. Summary: Currently queries like "ab" can match identifiers like a_yellow_bee. The value of allowing this

[PATCH] D52885: [clangd] Remove one-segment-skipping from Dex trigrams.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. sammccall marked an inline comment as done. Closed by commit rCTE343777: [clangd] Remove one-segment-skipping from Dex trigrams. (authored by sammccall, committed by ). Changed prior to commit: https://reviews.llvm.org/D5

Re: [libcxx] r342073 - Implement the infrastructure for feature-test macros. Very few actual feature test macros, though. Reviewed as: https://reviews.llvm.org/D51955

2018-10-04 Thread Marshall Clow via cfe-commits
On Wed, Oct 3, 2018 at 3:38 AM Christof Douma wrote: > Hi. > > > > Yes, including would try to include the “version” file inside > the users project. The problem is not the existence of the header file, but > the #include directive that is not guarded. To give examples on when this > goes wrong:

[clang-tools-extra] r343778 - [clangd] clangd-indexer gathers refs and stores them in index files.

2018-10-04 Thread Sam McCall via cfe-commits
Author: sammccall Date: Thu Oct 4 07:09:55 2018 New Revision: 343778 URL: http://llvm.org/viewvc/llvm-project?rev=343778&view=rev Log: [clangd] clangd-indexer gathers refs and stores them in index files. Reviewers: ioeric Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, kadircet, cfe-com

[PATCH] D52531: [clangd] clangd-indexer gathers refs and stores them in index files.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL343778: [clangd] clangd-indexer gathers refs and stores them in index files. (authored by sammccall, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.or

[PATCH] D52872: [clangd] Make binary index format the default, remove dead flag.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 168287. sammccall added a comment. example filename "clangd.dex" Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52872 Files: clangd/indexer/IndexerMain.cpp Index: clangd/indexer/IndexerMain.cpp

[PATCH] D52872: [clangd] Make binary index format the default, remove dead flag.

2018-10-04 Thread Sam McCall via Phabricator via cfe-commits
sammccall marked an inline comment as done. sammccall added inline comments. Comment at: clangd/indexer/IndexerMain.cpp:58 SymbolCollector::Options Opts; -Opts.FallbackDir = AssumedHeaderDir; return createStaticIndexingAction( hokein wrote: > If we

  1   2   3   >