[PATCH] D50144: Add Windows support for the GNUstep Objective-C ABI V2.

2018-08-08 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: lib/CodeGen/CGBlocks.cpp:1276 +InitVar->setSection(".CRT$XCLa"); +CGM.addUsedGlobal(InitVar); + } DHowett-MSFT wrote: > rjmccall wrote: > > Is the priority system not good enough? > My reading of the LLVM langu

[PATCH] D50144: Add Windows support for the GNUstep Objective-C ABI V2.

2018-08-08 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added inline comments. Comment at: lib/CodeGen/CGBlocks.cpp:1276 +InitVar->setSection(".CRT$XCLa"); +CGM.addUsedGlobal(InitVar); + } rjmccall wrote: > DHowett-MSFT wrote: > > rjmccall wrote: > > > Is the priority system not good enough? > > My r

[libunwind] r339222 - Merging r339217:

2018-08-08 Thread Hans Wennborg via cfe-commits
Author: hans Date: Wed Aug 8 00:50:31 2018 New Revision: 339222 URL: http://llvm.org/viewvc/llvm-project?rev=339222&view=rev Log: Merging r339217: r339217 | cdavis | 2018-08-08 06:21:24 +0200 (Wed, 08 Aug 2018) | 11 lines [

[PATCH] D50412: [libunwind] Fix pointer-to-integer cast warnings on LLP64.

2018-08-08 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In https://reviews.llvm.org/D50412#1191843, @mstorsjo wrote: > @hans This looks 7.0-worthy to me. Okay, r339222. Repository: rL LLVM https://reviews.llvm.org/D50412 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

Re: [libunwind] r339217 - [libunwind] Fix pointer-to-integer cast warnings on LLP64.

2018-08-08 Thread Hans Wennborg via cfe-commits
Merged to 7.0 in r339222. On Wed, Aug 8, 2018 at 6:21 AM, Charles Davis via cfe-commits wrote: > Author: cdavis > Date: Tue Aug 7 21:21:24 2018 > New Revision: 339217 > > URL: http://llvm.org/viewvc/llvm-project?rev=339217&view=rev > Log: > [libunwind] Fix pointer-to-integer cast warnings on LLP

[PATCH] D50193: Added functionality to suggest FixIts for conversion of '->' to '.' and vice versa.

2018-08-08 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet updated this revision to Diff 159648. kadircet marked 3 inline comments as done. kadircet added a comment. - Resolve some more discussions. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D50193 Files: clangd/CodeComplete.cpp clangd/CodeComplete.h clangd/Diagnostic

[PATCH] D45444: [clang-tidy] implement new check for const-correctness

2018-08-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. > Could you give a concrete example of this? vi llvm/lib/Demangle/ItaniumDemangle.cpp +1762 /home/jonas/opt/llvm/lib/Demangle/ItaniumDemangle.cpp:1762:7: warning: variable 'num' of type 'char [FloatData::max_demangled_size]' can be declared 'const' [cppcoreguidelines-c

[PATCH] D50144: Add Windows support for the GNUstep Objective-C ABI V2.

2018-08-08 Thread David Chisnall via Phabricator via cfe-commits
theraven updated this revision to Diff 159651. theraven marked 2 inline comments as done. theraven added a comment. Herald added a subscriber: mgrang. - Address Dustin's review comments. - Fix an issue in protocol generation. - Fix failing test. - [gnu-objc] Make selector order deterministic. - Ad

[PATCH] D50144: Add Windows support for the GNUstep Objective-C ABI V2.

2018-08-08 Thread David Chisnall via Phabricator via cfe-commits
theraven updated this revision to Diff 159653. theraven added a comment. - Revert blocks part of the patch to put in a separate review. Repository: rC Clang https://reviews.llvm.org/D50144 Files: include/clang/Driver/Options.td lib/AST/MicrosoftMangle.cpp lib/CodeGen/CGException.cpp

[PATCH] D50193: Added functionality to suggest FixIts for conversion of '->' to '.' and vice versa.

2018-08-08 Thread Kadir Cetinkaya via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE339224: Added functionality to suggest FixIts for conversion of '->' to '.' and vice… (authored by kadircet, committed by ). Changed prior to commit: https://reviews.llvm.org/D50193?vs=159648&id=1596

[PATCH] D50385: [clangd] Collect symbol occurrences from AST.

2018-08-08 Thread Eric Liu via Phabricator via cfe-commits
ioeric added a comment. 2 high-level questions: 1. What's the reason for having a separate `SymbolOccurrenceSlab`? Could store occurrences as extra payload of `Symbol`? 2. Could we merge `SymbolOccurrenceCollector` into the existing `SymbolCollector`? They look a lot alike. Having another inde

[PATCH] D47849: [OpenMP][Clang][NVPTX] Enable math functions called in an OpenMP NVPTX target device region to be resolved as device-native function calls

2018-08-08 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld added a comment. In https://reviews.llvm.org/D47849#1190997, @gtbercea wrote: > Don't we want to use device specific math functions? > It's not just about avoiding some the host specific assembly, it's also > about getting an implementation tailored to the device. Ok, so you are alre

[PATCH] D50428: Add support for importing imaginary literals

2018-08-08 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added reviewers: a_sidorin, r.stahl, xazax.hun. Herald added subscribers: cfe-commits, dkrupp, rnkovacs. Repository: rC Clang https://reviews.llvm.org/D50428 Files: include/clang/ASTMatchers/ASTMatchers.h lib/AST/ASTImporter.cpp lib/ASTMatchers/ASTM

[PATCH] D50337: [clangd] DexIndex implementation prototype

2018-08-08 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 159658. kbobyrev added a comment. Minor code cleanup. This is now a fully functional symbol index. I have reflected my concerns and uncertainties in `FIXME`s, please indicate if you think there's something to improve in this patch. In general, I believe it

[PATCH] D49796: [ASTImporter] Load external Decls when getting field index.

2018-08-08 Thread Balázs Kéri via Phabricator via cfe-commits
balazske updated this revision to Diff 159659. balazske added a comment. - Added common getFieldIndex. - Corrected test ImportUnnamedFieldsInCorrectOrder. Repository: rC Clang https://reviews.llvm.org/D49796 Files: include/clang/AST/ASTImporter.h lib/AST/ASTImporter.cpp test/ASTMerge/u

[PATCH] D50428: Add support for importing imaginary literals

2018-08-08 Thread Gabor Marton via Phabricator via cfe-commits
martong updated this revision to Diff 159662. martong added a comment. Remove superflous newline Repository: rC Clang https://reviews.llvm.org/D50428 Files: include/clang/ASTMatchers/ASTMatchers.h lib/AST/ASTImporter.cpp lib/ASTMatchers/ASTMatchersInternal.cpp unittests/AST/ASTImport

r339226 - [ASTImporter] Load external Decls when getting field index.

2018-08-08 Thread Balazs Keri via cfe-commits
Author: balazske Date: Wed Aug 8 02:40:57 2018 New Revision: 339226 URL: http://llvm.org/viewvc/llvm-project?rev=339226&view=rev Log: [ASTImporter] Load external Decls when getting field index. Summary: At equality check of fields without name the index of fields is compared. At determining the

[PATCH] D49796: [ASTImporter] Load external Decls when getting field index.

2018-08-08 Thread Balázs Kéri via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL339226: [ASTImporter] Load external Decls when getting field index. (authored by balazske, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D49796

[PATCH] D50436: Correctly initialise global blocks on Windows.

2018-08-08 Thread David Chisnall via Phabricator via cfe-commits
theraven created this revision. theraven added a reviewer: rjmccall. Herald added a subscriber: cfe-commits. Windows does not allow globals to be initialised to point to globals in another DLL. Exported globals may be referenced only from code. Work around this by creating an initialiser that ru

[PATCH] D50144: Add Windows support for the GNUstep Objective-C ABI V2.

2018-08-08 Thread David Chisnall via Phabricator via cfe-commits
theraven added inline comments. Comment at: lib/CodeGen/CGBlocks.cpp:1262 + if (IsWindows) { +auto *Init = llvm::Function::Create(llvm::FunctionType::get(CGM.VoidTy, + {}), llvm::GlobalValue::InternalLinkage, ".block_isa_init", rjmccall wrote: > the

Re: r339128 - [objc-gnustep] Don't emit .guess ivar offset vars.

2018-08-08 Thread Hans Wennborg via cfe-commits
Merged to 7.0 in r339233. On Tue, Aug 7, 2018 at 2:02 PM, David Chisnall via cfe-commits wrote: > Author: theraven > Date: Tue Aug 7 05:02:46 2018 > New Revision: 339128 > > URL: http://llvm.org/viewvc/llvm-project?rev=339128&view=rev > Log: > [objc-gnustep] Don't emit .guess ivar offset vars. >

[PATCH] D50415: [clangd] extend the publishDiagnostics response to send back fixits to the client directly as well (if requested)

2018-08-08 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. +1 Sam's suggestion of configuring this during initial LSP handshake, rather than as a command-line flag. We could put it into `ClientCapabilities` or into `initializationOptions`. The latter has type 'any' in LSP, so it seems to be most in-line with the protocol

[PATCH] D50438: [clangd] Sort GoToDefinition results.

2018-08-08 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. hokein added a reviewer: ilya-biryukov. Herald added subscribers: arphaman, mgrang, jkorous, MaskRay, ioeric. GoToDefinition returns all declaration results (implicit/explicit) that are in the same location, and the results are returned in arbitrary order. Some LSP c

[PATCH] D50154: [clangd] capitalize diagnostic messages

2018-08-08 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. In https://reviews.llvm.org/D50154#1191002, @dblaikie wrote: > What's the motivation for clangd to differ from clang here? The presentation of diagnostics to the users is different between clang and clangd: - clang diagnostics are always prefixed with the file,

[PATCH] D48436: [analyzer][UninitializedObjectChecker] Fixed a false negative by no longer filtering out certain constructor calls

2018-08-08 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus added a comment. In https://reviews.llvm.org/D48436#1191458, @NoQ wrote: > Ok, let's commit this and see how to fix it later. Thanks! ^-^ > I still think it's more important to come up with clear rules of who is > responsible for initializing fields than making sure our warnings are

Re: r339210 - PR38286: Don't crash when attempting to define a constructor for an

2018-08-08 Thread Hans Wennborg via cfe-commits
Merged in r339236. Thanks! On Wed, Aug 8, 2018 at 2:46 AM, Richard Smith wrote: > Would be good to get this into the Clang 7 release. > > On Tue, 7 Aug 2018 at 17:43, Richard Smith via cfe-commits > wrote: >> >> Author: rsmith >> Date: Tue Aug 7 17:42:42 2018 >> New Revision: 339210 >> >> URL:

[PATCH] D48436: [analyzer][UninitializedObjectChecker] Fixed a false negative by no longer filtering out certain constructor calls

2018-08-08 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus updated this revision to Diff 159687. Szelethus added a comment. Added a TODO. https://reviews.llvm.org/D48436 Files: lib/StaticAnalyzer/Checkers/UninitializedObjectChecker.cpp test/Analysis/cxx-uninitialized-object.cpp Index: test/Analysis/cxx-uninitialized-object.cpp ==

r339237 - [analyzer][UninitializedObjectChecker] Fixed a false negative by no longer filtering out certain constructor calls

2018-08-08 Thread Kristof Umann via cfe-commits
Author: szelethus Date: Wed Aug 8 05:23:02 2018 New Revision: 339237 URL: http://llvm.org/viewvc/llvm-project?rev=339237&view=rev Log: [analyzer][UninitializedObjectChecker] Fixed a false negative by no longer filtering out certain constructor calls As of now, all constructor calls are ignored

[PATCH] D48436: [analyzer][UninitializedObjectChecker] Fixed a false negative by no longer filtering out certain constructor calls

2018-08-08 Thread Umann Kristóf via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC339237: [analyzer][UninitializedObjectChecker] Fixed a false negative by no longer… (authored by Szelethus, committed by ). Repository: rC Clang https://reviews.llvm.org/D48436 Files: lib/StaticAnal

[PATCH] D49199: [analyzer][UninitializedObjectChecker] Pointer/reference objects are dereferenced according to dynamic type

2018-08-08 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus added a comment. Thanks! I plan on revisiting how heap allocated regions are handled in the future. https://reviews.llvm.org/D49199 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe

[PATCH] D50439: [Tooling] Switch JSONCompilationDatabase to use JSON parser.

2018-08-08 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added reviewers: ioeric, klimek. Herald added a subscriber: cfe-commits. Rather than hold all the JSON source in memory, as well as the YAML structures needed to index into it, we parse eagerly into CompileCommand structures, which simplifies the implemen

[PATCH] D50439: [Tooling] Switch JSONCompilationDatabase to use JSON parser.

2018-08-08 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 159690. sammccall added a comment. (just updating description) Repository: rC Clang https://reviews.llvm.org/D50439 Files: include/clang/Tooling/JSONCompilationDatabase.h lib/Tooling/JSONCompilationDatabase.cpp test/Index/skip-parsed-bodies/compi

[PATCH] D50389: [clang-tidy] new check for Abseil

2018-08-08 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. Thanks for contributing to clang-tidy! Comment at: docs/clang-tidy/checks/abseil-duration-division.rst:3 + +abseil-duration-division + This is a nice document. Does abseil have similar thing in its official gui

[PATCH] D47849: [OpenMP][Clang][NVPTX] Enable math functions called in an OpenMP NVPTX target device region to be resolved as device-native function calls

2018-08-08 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added a comment. > Ok, so you are already talking about performance. I think we should fix > correctness first, in particular the compiler shouldn't complain whenever > `` is included. This patch is concerned with calling device functions when you're on the device. The correctness i

[PATCH] D50439: [Tooling] Switch JSONCompilationDatabase to use JSON parser.

2018-08-08 Thread Sam McCall via Phabricator via cfe-commits
sammccall planned changes to this revision. sammccall added a comment. Nevermind, this is like 5x slower to load the chromium CDB. probably because of all the little non-arena allocations. I'll profile and fix it when I get bored again. Repository: rC Clang https://reviews.llvm.org/D50439

[PATCH] D50376: AMDGPU: Fix enabling denormals by default on pre-VI targets

2018-08-08 Thread Konstantin Zhuravlyov via Phabricator via cfe-commits
kzhuravl accepted this revision. kzhuravl added a comment. This revision is now accepted and ready to land. LGTM https://reviews.llvm.org/D50376 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/c

[PATCH] D50443: [clang] Store code completion token range in preprocessor.This change is to support a new fature in clangd, tests will be send toclang-tools-extra with that change.

2018-08-08 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet created this revision. kadircet added a reviewer: ilya-biryukov. Herald added subscribers: cfe-commits, arphaman, jkorous, MaskRay, ioeric. Repository: rC Clang https://reviews.llvm.org/D50443 Files: include/clang/Lex/Preprocessor.h lib/Lex/Preprocessor.cpp Index: lib/Lex/Prepro

[PATCH] D50444: Fix structural inequivalency of forward EnumDecl

2018-08-08 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added reviewers: a_sidorin, r.stahl, xazax.hun. Herald added subscribers: cfe-commits, dkrupp, rnkovacs. Currently we consider one forward declared RecordDecl and another with a definition equal. We have to do the same in case of enums. Repository: rC Cla

[PATCH] D49199: [analyzer][UninitializedObjectChecker] Pointer/reference objects are dereferenced according to dynamic type

2018-08-08 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus updated this revision to Diff 159699. Szelethus added a comment. Rebased to latest trunk. https://reviews.llvm.org/D49199 Files: lib/StaticAnalyzer/Checkers/UninitializedObjectChecker.cpp test/Analysis/cxx-uninitialized-object-inheritance.cpp test/Analysis/cxx-uninitialized-obje

[PATCH] D50443: [clang] Store code completion token range in preprocessor.This change is to support a new fature in clangd, tests will be send toclang-tools-extra with that change.

2018-08-08 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. Maybe split the commit message into multiple lines? I suggest we wait for clangd changes to be reviewed and land them together, so that we have the tests and usages of this code. Other than that LG Comment at: include/clang/Lex/Preprocessor.h:11

[PATCH] D50446: [clangd] Record the currently active file in context for codeCompletion and findDefinitions.

2018-08-08 Thread Eric Liu via Phabricator via cfe-commits
ioeric created this revision. ioeric added a reviewer: ilya-biryukov. Herald added subscribers: cfe-commits, arphaman, jkorous, MaskRay. This allows implementations like different symbol indexes to know what the current active file is. For example, some customized index implementation might decide

r339240 - [analyzer][UninitializedObjectChecker] Pointer/reference objects are dereferenced according to dynamic type

2018-08-08 Thread Kristof Umann via cfe-commits
Author: szelethus Date: Wed Aug 8 06:18:53 2018 New Revision: 339240 URL: http://llvm.org/viewvc/llvm-project?rev=339240&view=rev Log: [analyzer][UninitializedObjectChecker] Pointer/reference objects are dereferenced according to dynamic type This patch fixed an issue where the dynamic type of

[PATCH] D49199: [analyzer][UninitializedObjectChecker] Pointer/reference objects are dereferenced according to dynamic type

2018-08-08 Thread Umann Kristóf via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC339240: [analyzer][UninitializedObjectChecker] Pointer/reference objects are… (authored by Szelethus, committed by ). Repository: rC Clang https://reviews.llvm.org/D49199 Files: lib/StaticAnalyzer/C

[PATCH] D50443: [clang] Store code completion token range in preprocessor.

2018-08-08 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet updated this revision to Diff 159703. kadircet marked an inline comment as done. kadircet added a comment. - Resolve discussions. Repository: rC Clang https://reviews.llvm.org/D50443 Files: include/clang/Lex/Preprocessor.h lib/Lex/Preprocessor.cpp Index: lib/Lex/Preprocessor.c

[PATCH] D50168: [Builtins] Implement __builtin_clrsb to be compatible with gcc

2018-08-08 Thread Sanjay Patel via Phabricator via cfe-commits
spatel added a comment. About the bit hacking: I don't think clang should be in the optimization business. We should be able to take the most obvious/simple representation for this builtin and reduce it as needed (either in instcombine or the backend). So it would be better to use the version w

r339244 - [analyzer] Fix a typo in `RegionStore.txt`.

2018-08-08 Thread Henry Wong via cfe-commits
Author: henrywong Date: Wed Aug 8 06:37:28 2018 New Revision: 339244 URL: http://llvm.org/viewvc/llvm-project?rev=339244&view=rev Log: [analyzer] Fix a typo in `RegionStore.txt`. Summary: The typo of the description for default bindings can be confusing. Reviewers: NoQ, george.karpenkov Review

[PATCH] D50382: [analyzer] Fix a typo in `RegionStore.txt`.

2018-08-08 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL339244: [analyzer] Fix a typo in `RegionStore.txt`. (authored by henrywong, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D50382 Files: cfe/tr

[PATCH] D47849: [OpenMP][Clang][NVPTX] Enable math functions called in an OpenMP NVPTX target device region to be resolved as device-native function calls

2018-08-08 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld added a comment. In https://reviews.llvm.org/D47849#1192134, @gtbercea wrote: > This patch is concerned with calling device functions when you're on the > device. The correctness issues you mention are orthogonal to this and should > be handled by another patch. I don't think this patc

[PATCH] D50447: [clang-tidy] Add a whitelistClasses option in performance-for-range-copy check.

2018-08-08 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. hokein added reviewers: ilya-biryukov, alexfh. Herald added a subscriber: xazax.hun. The upstream change r336737 causes a regression issue in our internal base codebase. Adding an option to the check allowing us whitelist these classes. Repository: rCTE Clang Too

[PATCH] D50175: [AArch64][NFC] better matching of AArch64 target in aarch64-cpus.c tests

2018-08-08 Thread Oliver Stannard via Phabricator via cfe-commits
olista01 added inline comments. Comment at: test/Driver/aarch64-cpus.c:10 +// GENERIC: "-cc1"{{.*}} "-triple" "aarch64"{{.*}} "-target-cpu" "generic" +// GENERIC-LE: "-cc1"{{.*}} "-triple" "aarch64--"{{.*}} "-target-cpu" "generic" Why do these need new check pr

[PATCH] D50447: [clang-tidy] Add a whitelistClasses option in performance-for-range-copy check.

2018-08-08 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added subscribers: shuaiwang, JonasToth, lebedev.ri. lebedev.ri added a comment. Regression is very broad term. Is it a false-positive? Perhaps it is better to address the issue in the ExprMutationAnalyzer itself? Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D50447

[PATCH] D50414: [libunwind][include] Add SEH declarations to .

2018-08-08 Thread Charles Davis via Phabricator via cfe-commits
cdavis5x added a comment. In https://reviews.llvm.org/D50414#1191834, @mstorsjo wrote: > Should we maybe add the same declaration of `_GCC_specific_handler` to > clang's unwind.h? That would allow removing the forward declaration in > libcxxabi from https://reviews.llvm.org/D49638. Probably.

[PATCH] D50448: [CGObjCGNU] Rename GetSelector helper method to fix -Woverloaded-virtual warning (PR38210)

2018-08-08 Thread Simon Pilgrim via Phabricator via cfe-commits
RKSimon created this revision. RKSimon added a reviewer: theraven. As suggested by @theraven on PR38210, this patch fixes the gcc -Woverloaded-virtual warnings by renaming the extra CGObjCGNU::GetSelector method to CGObjCGNU::GetTypedSelector Repository: rC Clang https://reviews.llvm.org/D5

[PATCH] D50447: [clang-tidy] Add a whitelistClasses option in performance-for-range-copy check.

2018-08-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. If whitelisting works, thats fine. But I agree with @lebedev.ri that a contribution/improvement to the ExprMutAnalyzer is the better option. This is especially the case, because multiple checks (and maybe even some other parts then clang-tidy) will utilize this analys

[PATCH] D50446: [clangd] Record the currently active file in context for codeCompletion and findDefinitions.

2018-08-08 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. Short summary of the offline discussion: I suggest adding this parameter into the corresponding requests of the index (FuzzyFindRequest, FindDefinitionsRequest) instead of stashing it in the context. Context has all the same problems as the global variables, so we

[PATCH] D50447: [clang-tidy] Add a whitelistClasses option in performance-for-range-copy check.

2018-08-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added inline comments. Comment at: test/clang-tidy/performance-for-range-copy.cpp:1 -// RUN: %check_clang_tidy %s performance-for-range-copy %t -- -- -std=c++11 -fno-delayed-template-parsing +// RUN: %check_clang_tidy %s performance-for-range-copy %t -config="{CheckOp

[PATCH] D50448: [CGObjCGNU] Rename GetSelector helper method to fix -Woverloaded-virtual warning (PR38210)

2018-08-08 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. Thanks, this warning is really annoying. Repository: rC Clang https://reviews.llvm.org/D50448 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D50449: [clangd] Support textEdit in addition to insertText.

2018-08-08 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet created this revision. kadircet added a reviewer: ilya-biryukov. Herald added subscribers: cfe-commits, arphaman, jkorous, MaskRay, ioeric. Completion replies contains textEdits as well. Note that this change relies on https://reviews.llvm.org/D50443. Repository: rCTE Clang Tools Extr

[PATCH] D50337: [clangd] DexIndex implementation prototype

2018-08-08 Thread Eric Liu via Phabricator via cfe-commits
ioeric added inline comments. Comment at: clang-tools-extra/clangd/index/MemIndex.h:45 // Index is a set of symbols that are deduplicated by symbol IDs. - // FIXME: build smarter index structure. llvm::DenseMap Index; I think this FIXME still applies here.

[PATCH] D50447: [clang-tidy] Add a whitelistClasses option in performance-for-range-copy check.

2018-08-08 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. In https://reviews.llvm.org/D50447#1192280, @JonasToth wrote: > If whitelisting works, thats fine. But I agree with @lebedev.ri that a > contribution/improvement to the ExprMutAnalyzer is the better option. This is > especially the case, because multiple checks (and mayb

[PATCH] D50447: [clang-tidy] Add a whitelistClasses option in performance-for-range-copy check.

2018-08-08 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a subscriber: EricWF. lebedev.ri added a comment. In https://reviews.llvm.org/D50447#1192316, @hokein wrote: > In https://reviews.llvm.org/D50447#1192280, @JonasToth wrote: > > > If whitelisting works, thats fine. But I agree with @lebedev.ri that a > > contribution/improvement

[PATCH] D50175: [AArch64][NFC] better matching of AArch64 target in aarch64-cpus.c tests

2018-08-08 Thread Sjoerd Meijer via Phabricator via cfe-commits
SjoerdMeijer added inline comments. Comment at: test/Driver/aarch64-cpus.c:10 +// GENERIC: "-cc1"{{.*}} "-triple" "aarch64"{{.*}} "-target-cpu" "generic" +// GENERIC-LE: "-cc1"{{.*}} "-triple" "aarch64--"{{.*}} "-target-cpu" "generic" olista01 wrote: > Why do t

[PATCH] D47849: [OpenMP][Clang][NVPTX] Enable math functions called in an OpenMP NVPTX target device region to be resolved as device-native function calls

2018-08-08 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added a comment. In https://reviews.llvm.org/D47849#1192245, @Hahnfeld wrote: > In https://reviews.llvm.org/D47849#1192134, @gtbercea wrote: > > > This patch is concerned with calling device functions when you're on the > > device. The correctness issues you mention are orthogonal to th

[PATCH] D47849: [OpenMP][Clang][NVPTX] Enable math functions called in an OpenMP NVPTX target device region to be resolved as device-native function calls

2018-08-08 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added a comment. > IIRC you started to work on this to fix the problem with inline assembly (see > https://reviews.llvm.org/D47849#1125019). AFAICS this patch fixes > declarations of math functions but you still cannot include `math.h` which > most "correct" codes do. I'm not sure w

[PATCH] D50447: [clang-tidy] Add a whitelistClasses option in performance-for-range-copy check.

2018-08-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. Is the type important, or specifics about the variable (e.g. the name?) The `_` variable names are sometimes used for RAII variables/lambdas that shall just do some cleanup, e.g. gsl::finally(). It might make sense to give `ExprMutAnalyzer` an ignore-mechanism. I wonde

[PATCH] D49851: [clang-tidy] run-clang-tidy add synchronisation to the output

2018-08-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. @alexfh or @aaron.ballman could you take a final look on this one? https://reviews.llvm.org/D49851 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D50175: [AArch64][NFC] better matching of AArch64 target in aarch64-cpus.c tests

2018-08-08 Thread Sjoerd Meijer via Phabricator via cfe-commits
SjoerdMeijer updated this revision to Diff 159715. SjoerdMeijer added a comment. Addressed comments. https://reviews.llvm.org/D50175 Files: test/Driver/aarch64-cpus.c Index: test/Driver/aarch64-cpus.c === --- test/Driver/aarch64

[PATCH] D50446: [clangd] Record the currently active file in context for codeCompletion and findDefinitions.

2018-08-08 Thread Eric Liu via Phabricator via cfe-commits
ioeric added a comment. In https://reviews.llvm.org/D50446#1192282, @ilya-biryukov wrote: > Short summary of the offline discussion: I suggest adding this parameter into > the corresponding requests of the index (FuzzyFindRequest, > FindDefinitionsRequest) instead of stashing it in the context.

[PATCH] D47849: [OpenMP][Clang][NVPTX] Enable math functions called in an OpenMP NVPTX target device region to be resolved as device-native function calls

2018-08-08 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld added a comment. In https://reviews.llvm.org/D47849#1192321, @gtbercea wrote: > > IIRC you started to work on this to fix the problem with inline assembly > > (see https://reviews.llvm.org/D47849#1125019). AFAICS this patch fixes > > declarations of math functions but you still cannot

[PATCH] D47849: [OpenMP][Clang][NVPTX] Enable math functions called in an OpenMP NVPTX target device region to be resolved as device-native function calls

2018-08-08 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added a comment. In https://reviews.llvm.org/D47849#1192368, @Hahnfeld wrote: > In https://reviews.llvm.org/D47849#1192321, @gtbercea wrote: > > > > IIRC you started to work on this to fix the problem with inline assembly > > > (see https://reviews.llvm.org/D47849#1125019). AFAICS this

[PATCH] D50414: [libunwind][include] Add SEH declarations to .

2018-08-08 Thread Charles Davis via Phabricator via cfe-commits
cdavis5x updated this revision to Diff 159722. cdavis5x added a comment. - Remove unneeded preprocessor condition. Repository: rUNW libunwind https://reviews.llvm.org/D50414 Files: include/unwind.h Index: include/unwind.h ==

[PATCH] D47849: [OpenMP][Clang][NVPTX] Enable math functions called in an OpenMP NVPTX target device region to be resolved as device-native function calls

2018-08-08 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld added a comment. In https://reviews.llvm.org/D47849#1192375, @gtbercea wrote: > I do not get that error. In the beginning you said that you were facing the same error. Did that go away in the meantime? Are you testing on x86 or Power? With optimizations enabled? Repository: rC Cla

[PATCH] D50451: Fix import of class templates partial specialization

2018-08-08 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added reviewers: a_sidorin, xazax.hun, r.stahl. Herald added subscribers: cfe-commits, dkrupp, rnkovacs. Currently there are several issues with the import of class template specializations. (1) Different TUs may have class template specializations with the

[PATCH] D50447: [clang-tidy] Add a whitelistClasses option in performance-for-range-copy check.

2018-08-08 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. > That looks remarkably like google benchmark main loop. (i don't know at hand > if making this const will break it, but probably not?) > I wonder if instead there should be an option to not complain about the > variables that aren't actually used? Yeah, it is google be

[PATCH] D50447: [clang-tidy] Add a whitelistClasses option in performance-for-range-copy check.

2018-08-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. Given it is about the performance in loops and the optimizer?! can better work with the copy-and-don't-use it might make sense to just check if the variable is dereferenced in the scope of the loop (any declRefExpr exists). That is more userfriendly, too. Am 08.08.2018

[PATCH] D49223: [AST] Check described template at structural equivalence check.

2018-08-08 Thread Balázs Kéri via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC339256: [AST] Check described template at structural equivalence check. (authored by balazske, committed by ). Changed prior to commit: https://reviews.llvm.org/D49223?vs=159458&id=159725#toc Repositor

r339256 - [AST] Check described template at structural equivalence check.

2018-08-08 Thread Balazs Keri via cfe-commits
Author: balazske Date: Wed Aug 8 08:04:27 2018 New Revision: 339256 URL: http://llvm.org/viewvc/llvm-project?rev=339256&view=rev Log: [AST] Check described template at structural equivalence check. Summary: When checking a class or function the described class or function template is checked too

[PATCH] D47849: [OpenMP][Clang][NVPTX] Enable math functions called in an OpenMP NVPTX target device region to be resolved as device-native function calls

2018-08-08 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added a comment. In https://reviews.llvm.org/D47849#1192368, @Hahnfeld wrote: > In https://reviews.llvm.org/D47849#1192321, @gtbercea wrote: > > > > IIRC you started to work on this to fix the problem with inline assembly > > > (see https://reviews.llvm.org/D47849#1125019). AFAICS this

[PATCH] D50447: [clang-tidy] Add a whitelistClasses option in performance-for-range-copy check.

2018-08-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. > But in our codebase, we have code intended to use like below, and it is in > base library, and is used widely. I think it makes sense to whitelist this > class in our internal configuration. > > for (auto _ : state) { > ... // no `_` being referenced in the f

[PATCH] D50414: [libunwind][include] Add SEH declarations to .

2018-08-08 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo accepted this revision. mstorsjo added a comment. This revision is now accepted and ready to land. In https://reviews.llvm.org/D50414#1192267, @cdavis5x wrote: > In https://reviews.llvm.org/D50414#1191834, @mstorsjo wrote: > > > Do you plan on implementing these SEH specific bits in libu

[libunwind] r339258 - [libunwind][include] Add SEH declarations to .

2018-08-08 Thread Charles Davis via cfe-commits
Author: cdavis Date: Wed Aug 8 08:18:20 2018 New Revision: 339258 URL: http://llvm.org/viewvc/llvm-project?rev=339258&view=rev Log: [libunwind][include] Add SEH declarations to . Summary: Make the `_Unwind_Exception` struct correct under SEH. Add a declaration of `_GCC_specific_handler()`, which

[PATCH] D50414: [libunwind][include] Add SEH declarations to .

2018-08-08 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL339258: [libunwind][include] Add SEH declarations to . (authored by cdavis, committed by ). Changed prior to commit: https://reviews.llvm.org/D50414?vs=159722&id=159728#toc Repository: rL L

[libunwind] r339259 - Remove unneeded preprocessor condition.

2018-08-08 Thread Charles Davis via cfe-commits
Author: cdavis Date: Wed Aug 8 08:18:22 2018 New Revision: 339259 URL: http://llvm.org/viewvc/llvm-project?rev=339259&view=rev Log: Remove unneeded preprocessor condition. Modified: libunwind/trunk/include/unwind.h Modified: libunwind/trunk/include/unwind.h URL: http://llvm.org/viewvc/llvm

[PATCH] D50452: [WIP] clangd XPC adapter

2018-08-08 Thread Jan Korous via Phabricator via cfe-commits
jkorous created this revision. jkorous added reviewers: arphaman, sammccall, ilya-biryukov, simark. Herald added subscribers: cfe-commits, dexonsmith, MaskRay, ioeric, mgorny. Based on our internal discussions we decided to change our direction with XPC support for clangd. We did some extra measu

[PATCH] D47849: [OpenMP][Clang][NVPTX] Enable math functions called in an OpenMP NVPTX target device region to be resolved as device-native function calls

2018-08-08 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added a comment. In https://reviews.llvm.org/D47849#1192383, @Hahnfeld wrote: > In https://reviews.llvm.org/D47849#1192375, @gtbercea wrote: > > > I do not get that error. > > > In the beginning you said that you were facing the same error. Did that go > away in the meantime? > Are you

[PATCH] D49548: [clangd] XPC WIP

2018-08-08 Thread Jan Korous via Phabricator via cfe-commits
jkorous abandoned this revision. jkorous added a comment. We decided to abandon this direction in favor of simpler solution. https://reviews.llvm.org/D50452 One of the reasons is that there's a design fault - handling of server-originated messages (notifications) in this patch. Repository: r

[PATCH] D48559: [clangd] refactoring for XPC transport layer [NFCI]

2018-08-08 Thread Jan Korous via Phabricator via cfe-commits
jkorous added a comment. Hi, we decided to go with a different solution: https://reviews.llvm.org/D50452 Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D48559 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.

[PATCH] D48562: [clangd] XPC transport layer

2018-08-08 Thread Jan Korous via Phabricator via cfe-commits
jkorous abandoned this revision. jkorous added a comment. We decided to go with a different solution: https://reviews.llvm.org/D50452 https://reviews.llvm.org/D48562 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-b

[PATCH] D50446: [clangd] Record the currently active file in context for codeCompletion and findDefinitions.

2018-08-08 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clangd/ClangdServer.cpp:162 +WithContextValue WithFileName(kActiveFile, File); // FIXME(ibiryukov): even if Preamble is non-null, we may want to check ioeric wrote: > ilya-biryukov wrote: > > If we want

r339261 - Fix -Wdocumentation warnings. NFCI.

2018-08-08 Thread Simon Pilgrim via cfe-commits
Author: rksimon Date: Wed Aug 8 08:34:00 2018 New Revision: 339261 URL: http://llvm.org/viewvc/llvm-project?rev=339261&view=rev Log: Fix -Wdocumentation warnings. NFCI. Modified: cfe/trunk/include/clang/Basic/IdentifierTable.h Modified: cfe/trunk/include/clang/Basic/IdentifierTable.h URL:

[PATCH] D50413: [libunwind][include] Add some missing definitions to .

2018-08-08 Thread Charles Davis via Phabricator via cfe-commits
cdavis5x added inline comments. Comment at: include/unwind.h:46 +typedef uintptr_t _Unwind_Ptr; +#endif + mstorsjo wrote: > What other reference is this list of typedefs for `_Unwind_Ptr` based on? I > don't see any of these cases in clang's unwind.h at least. W

[PATCH] D50448: [CGObjCGNU] Rename GetSelector helper method to fix -Woverloaded-virtual warning (PR38210)

2018-08-08 Thread David Chisnall via Phabricator via cfe-commits
theraven accepted this revision. theraven added a comment. This revision is now accepted and ready to land. Looks good to me. This method should probably take a StringRef rather than a `const std::string&`, but I can make that change separately. Repository: rC Clang https://reviews.llvm.org

[PATCH] D50413: [libunwind][include] Add some missing definitions to .

2018-08-08 Thread Charles Davis via Phabricator via cfe-commits
cdavis5x marked an inline comment as done. cdavis5x added a comment. In https://reviews.llvm.org/D50413#1191726, @krytarowski wrote: > NetBSD uses `typedef void *_Unwind_Ptr;` unconditionally in its > ``... if that has to be matched. Done. > Additionally: `typedef long _Unwind_Word;`. Done.

[PATCH] D50413: [libunwind][include] Add some missing definitions to .

2018-08-08 Thread Charles Davis via Phabricator via cfe-commits
cdavis5x updated this revision to Diff 159731. cdavis5x added a comment. - Add NetBSD-specific definitions. - Pull out common declaration of `__personality_routine`. Repository: rUNW libunwind https://reviews.llvm.org/D50413 Files: include/unwind.h Index: include/unwind.h ===

[PATCH] D50448: [CGObjCGNU] Rename GetSelector helper method to fix -Woverloaded-virtual warning (PR38210)

2018-08-08 Thread Simon Pilgrim via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL339264: [CGObjCGNU] Rename GetSelector helper method to fix -Woverloaded-virtual… (authored by RKSimon, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.

r339264 - [CGObjCGNU] Rename GetSelector helper method to fix -Woverloaded-virtual warning (PR38210)

2018-08-08 Thread Simon Pilgrim via cfe-commits
Author: rksimon Date: Wed Aug 8 08:53:14 2018 New Revision: 339264 URL: http://llvm.org/viewvc/llvm-project?rev=339264&view=rev Log: [CGObjCGNU] Rename GetSelector helper method to fix -Woverloaded-virtual warning (PR38210) As suggested by @theraven on PR38210, this patch fixes the gcc -Woverl

Re: [PATCH] D50154: [clangd] capitalize diagnostic messages

2018-08-08 Thread David Blaikie via cfe-commits
On Wed, Aug 8, 2018 at 5:00 AM Ilya Biryukov via Phabricator < revi...@reviews.llvm.org> wrote: > ilya-biryukov added a comment. > > In https://reviews.llvm.org/D50154#1191002, @dblaikie wrote: > > > What's the motivation for clangd to differ from clang here? > > > The presentation of diagnostics

[PATCH] D50099: [DebugInfo][OpenCL] Address post-commit review of D49930

2018-08-08 Thread Scott Linder via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL339265: [DebugInfo][OpenCL] Address post-commit review for r338299 (authored by scott.linder, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D

r339265 - [DebugInfo][OpenCL] Address post-commit review for r338299

2018-08-08 Thread Scott Linder via cfe-commits
Author: scott.linder Date: Wed Aug 8 08:56:12 2018 New Revision: 339265 URL: http://llvm.org/viewvc/llvm-project?rev=339265&view=rev Log: [DebugInfo][OpenCL] Address post-commit review for r338299 NFC refactor of code to generate debug info for OpenCL 2.X blocks. Differential Revision: https://

[PATCH] D47849: [OpenMP][Clang][NVPTX] Enable math functions called in an OpenMP NVPTX target device region to be resolved as device-native function calls

2018-08-08 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added a comment. @Hahnfeld do you get the same error if you compile with clang++ instead of clang? Repository: rC Clang https://reviews.llvm.org/D47849 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bi

  1   2   >