[PATCH] D67140: [analyzer][NFC] Fix inconsistent references to checkers as "checks"

2019-09-09 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D67140#1659982 , @gribozavr wrote: > We should take a page from desktop software here. If the messages were in a > separate file, there would be a lot of people capable of mass-editing them. > When messages are hardcoded in the to

[PATCH] D67321: Respect CLANG_LINK_CLANG_DYLIB=ON in libclang and c-index-test

2019-09-09 Thread Aaron Puchert via Phabricator via cfe-commits
aaronpuchert added inline comments. Comment at: clang/tools/libclang/CMakeLists.txt:115 +clang_target_link_libraries(libclang + PRIVATE + ${CLANG_LIB_DEPS} beanz wrote: > tstellar wrote: > > aaronpuchert wrote: > > > This might not be correct for static builds,

[PATCH] D64991: [analyzer][WIP] Implement a primitive reaching definitions analysis

2019-09-09 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D64991#1662185 , @Szelethus wrote: > Hmm, we could make a redundant assignments checker: if a variable has > multiple reaching definitions, but those all assign the same value, emit a > warning. We could even use fixits with that.

r371476 - Fix crash mangling an explicit lambda non-type template parameter pack

2019-09-09 Thread Richard Smith via cfe-commits
Author: rsmith Date: Mon Sep 9 17:39:53 2019 New Revision: 371476 URL: http://llvm.org/viewvc/llvm-project?rev=371476&view=rev Log: Fix crash mangling an explicit lambda non-type template parameter pack that is not a pack expansion. Modified: cfe/trunk/lib/AST/ItaniumMangle.cpp cfe/trunk

[PATCH] D66796: [clang] Loop pragma vectorize(disable)

2019-09-09 Thread Hideki Saito via Phabricator via cfe-commits
hsaito added a comment. In D66796#1663868 , @SjoerdMeijer wrote: > That's exactly the reason why I think `vectorize(disable)` should disable > vectorisation for that loop. I just don't see what else a user would expect. I agree with you. Now on the pr

fixing 2 typos

2019-09-09 Thread Rayson Ho via cfe-commits
Found 2 typos when I was trying to use the context sensitive profiling feature earlier today: $ git diff docs/UsersManual.rst diff --git a/clang/docs/UsersManual.rst b/clang/docs/UsersManual.rst index f45d2d5ac0e..0f5f315cfcb

[PATCH] D67321: Respect CLANG_LINK_CLANG_DYLIB=ON in libclang and c-index-test

2019-09-09 Thread Chris Bieneman via Phabricator via cfe-commits
beanz added a comment. @aaronpuchert sounds like a reasonable approach Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67321/new/ https://reviews.llvm.org/D67321 ___ cfe-commits mailing list cfe-commits@

r371478 - Remove REQUIRES:shell from tests that pass for me on Windows

2019-09-09 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Mon Sep 9 17:50:32 2019 New Revision: 371478 URL: http://llvm.org/viewvc/llvm-project?rev=371478&view=rev Log: Remove REQUIRES:shell from tests that pass for me on Windows I see in the history for some of these tests REQUIRES:shell was used as a way to disable tests on Windows

[PATCH] D67335: [analyzer][NFC] Refactor the checker registration unit test file

2019-09-09 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added inline comments. This revision is now accepted and ready to land. Comment at: clang/unittests/StaticAnalyzer/RegisterCustomCheckersTest.cpp:84 -} -} -} +} // namespace +} // namespace ento Szelethus wrote: > Well, according

[PATCH] D67336: [analyzer][NFC] Introduce SuperChecker<>, a convenient alternative to Checker<> for storing subcheckers

2019-09-09 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. I have mixed feelings. Removing boilerplate is good, but the very fact that we're legalizing this pattern indicates that our checkers will keep bloating up, while i always wanted to actually split them instead (like, make sub-checkers into their own separate //classes//, po

Re: r359367 - Reinstate r359059, reverted in r359361, with a fix to properly prevent

2019-09-09 Thread Michael Spencer via cfe-commits
On Fri, Apr 26, 2019 at 7:56 PM Richard Smith via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Author: rsmith > Date: Fri Apr 26 19:58:17 2019 > New Revision: 359367 > > URL: http://llvm.org/viewvc/llvm-project?rev=359367&view=rev > Log: > Reinstate r359059, reverted in r359361, with a fix t

[PATCH] D67079: [analyzer] CastValueChecker: Model inheritance

2019-09-09 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/CastValueChecker.cpp:174 + +constexpr llvm::StringLiteral Vowels = "aeiou"; + Charusso wrote: > NoQ wrote: > > Omg lol nice. Did you try to figure out how do other people normally do it? > T

[PATCH] D59980: [Attributor] Deduce memory behavior argument attributes

2019-09-09 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert abandoned this revision. jdoerfert added a comment. Obsolete, D67384 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59980/new/ https://reviews.llvm.org/D59980 __

r371484 - clang-misexpect: Profile Guided Validation of Performance Annotations in LLVM

2019-09-09 Thread Petr Hosek via cfe-commits
Author: phosek Date: Mon Sep 9 20:11:39 2019 New Revision: 371484 URL: http://llvm.org/viewvc/llvm-project?rev=371484&view=rev Log: clang-misexpect: Profile Guided Validation of Performance Annotations in LLVM This patch contains the basic functionality for reporting potentially incorrect usage

[PATCH] D60076: [Attributor] Deduce memory behavior function attributes

2019-09-09 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. Obsolete, D67384 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60076/new/ https://reviews.llvm.org/D60076 ___ cfe-commits mailing list cfe-

[PATCH] D66324: clang-misexpect: Profile Guided Validation of Performance Annotations in LLVM

2019-09-09 Thread Petr Hosek via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL371484: clang-misexpect: Profile Guided Validation of Performance Annotations in LLVM (authored by phosek, committed by ). Changed prior to commit: https://reviews.llvm.org/D66324?vs=219219&id=219472#to

[PATCH] D67079: [analyzer] CastValueChecker: Model inheritance

2019-09-09 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/CastValueChecker.cpp:126 + + // If the casts have a common anchestor it could not be a succeeded downcast. + for (const auto &PreviousBase : PreviousRD->bases()) Charusso wrote: > NoQ wrot

r371488 - Revert "clang-misexpect: Profile Guided Validation of Performance Annotations in LLVM"

2019-09-09 Thread Petr Hosek via cfe-commits
Author: phosek Date: Mon Sep 9 23:25:13 2019 New Revision: 371488 URL: http://llvm.org/viewvc/llvm-project?rev=371488&view=rev Log: Revert "clang-misexpect: Profile Guided Validation of Performance Annotations in LLVM" This reverts commit r371484: this broke sanitizer-x86_64-linux-fast bot. Re

[PATCH] D65433: [clangd] DefineInline action availability checks

2019-09-09 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet marked an inline comment as done. kadircet added a comment. In D65433#1661865 , @arphaman wrote: > When fully implemented, will define inline tweak work with C++ methods in > classes as well? Yes you can see an example of it in the tests provid

[PATCH] D67292: [clang-tidy] Fix bug in bugprone-use-after-move check

2019-09-09 Thread Martin Böhme via Phabricator via cfe-commits
mboehme added inline comments. Comment at: clang-tools-extra/test/clang-tidy/bugprone-use-after-move.cpp:1198 +} + } for (int i = 0; i < 10; ++i) { gribozavr wrote: > ymandel wrote: > > gribozavr wrote: > > > Unless you think it is redundant, could you al

[PATCH] D65433: [clangd] DefineInline action availability checks

2019-09-09 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clang-tools-extra/clangd/refactor/tweaks/DefineInline.cpp:192 + Intent intent() const override { return Intent::Refactor; } + std::string title() const override { return "Inline function definition"; } + kadircet wro

[PATCH] D67274: [clangd] Improve output of semantic highlighting tests in case of failures

2019-09-09 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. nice, thanks. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67274/new/ https://reviews.llvm.org/D67274 __

[PATCH] D67277: [clangd] Replace HighlightingKind::NumKinds with LastKind. NFC

2019-09-09 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, though I think the current implementation is a common pattern. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67277/new/ https://reviews.ll

[PATCH] D67341: [clangd] Simplify semantic highlighting visitor

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. ilya-biryukov added a reviewer: hokein. Herald added subscribers: kadircet, arphaman, jkorous, MaskRay. Herald added a project: clang. - Functions to compute highlighting kinds for things are separated from the ones that add highlighting tokens. This keeps eac

[PATCH] D67277: [clangd] Replace HighlightingKind::NumKinds with LastKind. NFC

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. In D67277#1662669 , @hokein wrote: > LGTM, though I think the current implementation is a common pattern. Thanks. It's indeed a common pattern. The problem is that it forces clients to handle this extra case in every swit

[clang-tools-extra] r371373 - [clangd] Improve output of semantic highlighting tests in case of failures

2019-09-09 Thread Ilya Biryukov via cfe-commits
Author: ibiryukov Date: Mon Sep 9 01:47:05 2019 New Revision: 371373 URL: http://llvm.org/viewvc/llvm-project?rev=371373&view=rev Log: [clangd] Improve output of semantic highlighting tests in case of failures Summary: Instead of matching lists of highlightings, we annotate input code with resul

[PATCH] D67274: [clangd] Improve output of semantic highlighting tests in case of failures

2019-09-09 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL371373: [clangd] Improve output of semantic highlighting tests in case of failures (authored by ibiryukov, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed pr

Re: r369705 - [Clang][CodeGen] set alias linkage on QualType

2019-09-09 Thread Hans Wennborg via cfe-commits
Merged to release_90 in r371372 (along with the follow-up test fix). On Thu, Aug 22, 2019 at 10:45 PM Nick Desaulniers via cfe-commits wrote: > > Author: nickdesaulniers > Date: Thu Aug 22 13:47:12 2019 > New Revision: 369705 > > URL: http://llvm.org/viewvc/llvm-project?rev=369705&view=rev > Log:

[clang-tools-extra] r371375 - [clangd] Replace HighlightingKind::NumKinds with LastKind. NFC

2019-09-09 Thread Ilya Biryukov via cfe-commits
Author: ibiryukov Date: Mon Sep 9 01:57:17 2019 New Revision: 371375 URL: http://llvm.org/viewvc/llvm-project?rev=371375&view=rev Log: [clangd] Replace HighlightingKind::NumKinds with LastKind. NFC Summary: The latter simplifies the client code by avoiding the need to handle it as a separate cas

[PATCH] D67277: [clangd] Replace HighlightingKind::NumKinds with LastKind. NFC

2019-09-09 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL371375: [clangd] Replace HighlightingKind::NumKinds with LastKind. NFC (authored by ibiryukov, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commi

[PATCH] D66516: [clangd] Highlight typedefs to template parameters as template parameters

2019-09-09 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. thanks for taking care of it. Comment at: clang-tools-extra/clangd/SemanticHighlighting.cpp:129 if (const auto *TSI = TD->getTypeSourceInfo()) - addType(TD->getLoca

[PATCH] D66516: [clangd] Highlight typedefs to template parameters as template parameters

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 219301. ilya-biryukov marked 5 inline comments as done. ilya-biryukov added a comment. - Address comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D66516/new/ https://reviews.llvm.org/D66516 Files:

[clang-tools-extra] r371379 - [clangd] Highlight typedefs to template parameters as template parameters

2019-09-09 Thread Ilya Biryukov via cfe-commits
Author: ibiryukov Date: Mon Sep 9 02:37:17 2019 New Revision: 371379 URL: http://llvm.org/viewvc/llvm-project?rev=371379&view=rev Log: [clangd] Highlight typedefs to template parameters as template parameters Summary: Template parameters were handled outside `addType`, this led to lack of highl

[PATCH] D66516: [clangd] Highlight typedefs to template parameters as template parameters

2019-09-09 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL371379: [clangd] Highlight typedefs to template parameters as template parameters (authored by ibiryukov, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed pri

[PATCH] D66516: [clangd] Highlight typedefs to template parameters as template parameters

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/SemanticHighlighting.cpp:129 if (const auto *TSI = TD->getTypeSourceInfo()) - addType(TD->getLocation(), TSI->getTypeLoc().getTypePtr()); + addType(TD->getLocation(), TSI->getTypeLoc().getTyp

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/index/CanonicalIncludes.cpp:780 + // Prefer a mapping from the system symbols. + if (SystemSymbols) { +if (auto Result = SystemSymbols->mapHeader(Header, QualifiedName)) hokein wrote:

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. I had the same reaction as Haojian to the original patch, thanks for clearing that up. I do wonder whether we're microoptimizing for the tests too much, I don't think 5% on the tests is worth very much in itself, unless it's speeding up real workloads or improving th

[clang-tools-extra] r371390 - [clangd] Update clangd-vscode docs to be more user-focused.

2019-09-09 Thread Sam McCall via cfe-commits
Author: sammccall Date: Mon Sep 9 04:34:01 2019 New Revision: 371390 URL: http://llvm.org/viewvc/llvm-project?rev=371390&view=rev Log: [clangd] Update clangd-vscode docs to be more user-focused. Summary: Relegate "updating the extension" docs to a separate file. Reviewers: hokein, kadircet Sub

[PATCH] D67092: [clangd] Update clangd-vscode docs to be more user-focused.

2019-09-09 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL371390: [clangd] Update clangd-vscode docs to be more user-focused. (authored by sammccall, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D66637: [clangd] Support multifile edits as output of Tweaks

2019-09-09 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added inline comments. This revision is now accepted and ready to land. Comment at: clang-tools-extra/clangd/ClangdServer.cpp:414 + if (llvm::Error Err = reformatEdit(E, Style)) { +llvm::handleAllErrors(std::move(Err), [&](

[PATCH] D65699: [Driver] Prioritize SYSROOT/usr/include over RESOURCE_DIR/include on linux-musl

2019-09-09 Thread Rich Felker via Phabricator via cfe-commits
dalias added a comment. That's a separate issue of clang having a slight types-ABI mismatch with some 32-bit archs whose original ABIs used `long` instead of `int` for `wchar_t`. The wrong header order makes it quickly apparent, but these are independent; wrong header order is still wrong and w

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. In D67172#1662888 , @sammccall wrote: > I do wonder whether we're microoptimizing for the tests too much, I don't > think 5% on the tests is worth very much in itself, unless it's speeding up > real workloads or improving t

[PATCH] D66637: [clangd] Support multifile edits as output of Tweaks

2019-09-09 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet added inline comments. Comment at: clang-tools-extra/clangd/ClangdServer.cpp:414 + if (llvm::Error Err = reformatEdit(E, Style)) { +llvm::handleAllErrors(std::move(Err), [&](llvm::ErrorInfoBase &EIB) { + elog("Failed to format {0}: {1}", It.first(),

[PATCH] D66637: [clangd] Support multifile edits as output of Tweaks

2019-09-09 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet updated this revision to Diff 219324. kadircet marked 4 inline comments as done. kadircet added a comment. - Address comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D66637/new/ https://reviews.llvm.org/D66637 Files: clang-tools-ex

[PATCH] D65699: [Driver] Prioritize SYSROOT/usr/include over RESOURCE_DIR/include on linux-musl

2019-09-09 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a subscriber: hans. MaskRay added a comment. @hans Can this be put on your list of things for 9.0.1? I searched for `[meta] 9.0.1` on bugs.llvm.org but can't find a release blocker bug so I have to bother you directly... Repository: rL LLVM CHANGES SINCE LAST ACTION https://

[PATCH] D65699: [Driver] Prioritize SYSROOT/usr/include over RESOURCE_DIR/include on linux-musl

2019-09-09 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In D65699#1662936 , @MaskRay wrote: > @hans Can this be put on your list of things for 9.0.1? I searched for > `[meta] 9.0.1` on bugs.llvm.org but can't find a release blocker bug so I > have to bother you directly... Right, the b

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. In D67172#1662916 , @ilya-biryukov wrote: > In D67172#1662888 , @sammccall wrote: > > > I do wonder whether we're microoptimizing for the tests too much, I don't > > think 5% on the test

[PATCH] D67264: [clangd] Collect location of macro definition in the ParsedAST

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/ParsedAST.cpp:104 // *definitions* in the preamble region of the main file). class CollectMainFileMacroExpansions : public PPCallbacks { const SourceManager &SM; hokein wrote: > The na

[clang-tools-extra] r371392 - [clangd] Support multifile edits as output of Tweaks

2019-09-09 Thread Kadir Cetinkaya via cfe-commits
Author: kadircet Date: Mon Sep 9 05:28:44 2019 New Revision: 371392 URL: http://llvm.org/viewvc/llvm-project?rev=371392&view=rev Log: [clangd] Support multifile edits as output of Tweaks Summary: First patch for propogating multifile changes from tweak outputs to LSP WorkspaceEdits. Uses SM to

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. In D67172#1662945 , @sammccall wrote: > Only if it's 5% of something meaningful. If the denominator isn't something > we care about, then it's really "spending XXX usec is not ok" - which depends > on XXX I think. Agree,

[PATCH] D66637: [clangd] Support multifile edits as output of Tweaks

2019-09-09 Thread Kadir Cetinkaya via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL371392: [clangd] Support multifile edits as output of Tweaks (authored by kadircet, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: https:

[clang-tools-extra] r371394 - [clang-doc] sys::fs::F_None -> OF_None. NFC

2019-09-09 Thread Fangrui Song via cfe-commits
Author: maskray Date: Mon Sep 9 05:42:10 2019 New Revision: 371394 URL: http://llvm.org/viewvc/llvm-project?rev=371394&view=rev Log: [clang-doc] sys::fs::F_None -> OF_None. NFC F_None, F_Text and F_Append are kept for compatibility. Modified: clang-tools-extra/trunk/clang-doc/HTMLGenerator.

[clang-tools-extra] r371396 - [clang-tidy] Fix bug in bugprone-use-after-move check

2019-09-09 Thread Yitzhak Mandelbaum via cfe-commits
Author: ymandel Date: Mon Sep 9 05:59:14 2019 New Revision: 371396 URL: http://llvm.org/viewvc/llvm-project?rev=371396&view=rev Log: [clang-tidy] Fix bug in bugprone-use-after-move check Summary: The bugprone-use-after-move check exhibits false positives for certain uses of the C++17 if/switch i

[PATCH] D67292: [clang-tidy] Fix bug in bugprone-use-after-move check

2019-09-09 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. ymandel marked an inline comment as done. Closed by commit rL371396: [clang-tidy] Fix bug in bugprone-use-after-move check (authored by ymandel, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-c

[PATCH] D67292: [clang-tidy] Fix bug in bugprone-use-after-move check

2019-09-09 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel marked 3 inline comments as done. ymandel added inline comments. Comment at: clang-tools-extra/test/clang-tidy/bugprone-use-after-move.cpp:1198 +} + } for (int i = 0; i < 10; ++i) { mboehme wrote: > gribozavr wrote: > > ymandel wrote: > > > griboz

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 219335. ilya-biryukov added a comment. - Alternative approach - do not add extra classes, aim to minimize changes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67172/new/ https://reviews.llvm.org/D67172

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. The new version looks very much like the older one, with a few additions to not re-initialize data twice. PTAL and let me know what you think. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67172/new/ https://reviews.

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov marked an inline comment as done. ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/index/CanonicalIncludes.cpp:748 +llvm::StringRef CanonicalPath = Pair.second; +int Components = std::distance(llvm::sys::path::begin(Suffix), +

[PATCH] D67304: Unify checking enumerator values in ObjC, C, and MSVC modes

2019-09-09 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm with comment > The main functional change is that -fno-ms-compatibility now no longer > sends us down the hard error diagnostic code path for ObjC fixed enums. > Instead, complete-but-not-fi

[PATCH] D67321: Respect CLANG_LINK_CLANG_DYLIB=ON in libclang and c-index-test

2019-09-09 Thread Tom Stellard via Phabricator via cfe-commits
tstellar added inline comments. Comment at: clang/tools/libclang/CMakeLists.txt:115 +clang_target_link_libraries(libclang + PRIVATE + ${CLANG_LIB_DEPS} aaronpuchert wrote: > This might not be correct for static builds, I think we need `INTERFACE` here. This pat

[PATCH] D67264: [clangd] Collect location of macro definition in the ParsedAST

2019-09-09 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 219343. hokein marked 4 inline comments as done. hokein added a comment. Rename all things. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67264/new/ https://reviews.llvm.org/D67264 Files: clang-tools-extra/cl

[PATCH] D67264: [clangd] Collect location of macro definition in the ParsedAST

2019-09-09 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. Thanks for the suggestions on the new names. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67264/new/ https://reviews.llvm.org/D67264 ___ cfe-commits mailing list cfe-commits@li

[PATCH] D67290: [clangd] Add a new highlighting kind for typedefs

2019-09-09 Thread Haojian Wu via Phabricator via cfe-commits
hokein accepted this revision. hokein added inline comments. This revision is now accepted and ready to land. Comment at: clang-tools-extra/clangd/SemanticHighlighting.cpp:530 + case HighlightingKind::Typedef: +return "entity.name.type.typedef.cpp"; case HighlightingKind:

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 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. LG, though if we can drop the struct and make MaxSuffixComponents a constant it'd be simpler still. In D67172#1662957 , @ilya-biryukov wrote: >

[PATCH] D67341: [clangd] Simplify semantic highlighting visitor

2019-09-09 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. Thanks! Unfortunately, the patch is a bit large, containing refactoring changes and functionality changes, is it possible to split it into (two) smaller patches? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67341/new/ htt

[PATCH] D65699: [Driver] Prioritize SYSROOT/usr/include over RESOURCE_DIR/include on linux-musl

2019-09-09 Thread Khem Raj via Phabricator via cfe-commits
raj.khem added a comment. In D65699#1662915 , @dalias wrote: > That's a separate issue of clang having a slight types-ABI mismatch with some > 32-bit archs whose original ABIs used `long` instead of `int` for `wchar_t`. > The wrong header order makes it

[PATCH] D67290: [clangd] Add a new highlighting kind for typedefs

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 219348. ilya-biryukov marked 3 inline comments as done. ilya-biryukov added a comment. - Remove stale comment Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67290/new/ https://reviews.llvm.org/D67290 File

[PATCH] D67290: [clangd] Add a new highlighting kind for typedefs

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/SemanticHighlighting.cpp:530 + case HighlightingKind::Typedef: +return "entity.name.type.typedef.cpp"; case HighlightingKind::Namespace: hokein wrote: > ilya-biryukov wrote: > > Not

[clang-tools-extra] r371402 - [clangd] Add a new highlighting kind for typedefs

2019-09-09 Thread Ilya Biryukov via cfe-commits
Author: ibiryukov Date: Mon Sep 9 07:33:10 2019 New Revision: 371402 URL: http://llvm.org/viewvc/llvm-project?rev=371402&view=rev Log: [clangd] Add a new highlighting kind for typedefs Summary: We still attempt to highlight them as underlying types, but fallback to the generic 'typedef' highligh

[PATCH] D67290: [clangd] Add a new highlighting kind for typedefs

2019-09-09 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL371402: [clangd] Add a new highlighting kind for typedefs (authored by ibiryukov, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: https://

r371403 - Merge note_ovl_builtin_candidate diagnostics; NFC

2019-09-09 Thread Sven van Haastregt via cfe-commits
Author: svenvh Date: Mon Sep 9 07:39:20 2019 New Revision: 371403 URL: http://llvm.org/viewvc/llvm-project?rev=371403&view=rev Log: Merge note_ovl_builtin_candidate diagnostics; NFC There is no difference between the unary and binary case, so merge them. Modified: cfe/trunk/include/clang/Ba

[PATCH] D67290: [clangd] Add a new highlighting kind for typedefs

2019-09-09 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tools-extra/clangd/SemanticHighlighting.cpp:530 + case HighlightingKind::Typedef: +return "entity.name.type.typedef.cpp"; case HighlightingKind::Namespace: ilya-biryukov wrote: > hokein wrote: > > ilya-biryu

[PATCH] D65634: [RISCV] Default to ilp32d/lp64d in RISC-V Linux

2019-09-09 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. Herald added a subscriber: pzheng. I think my feeling is that this patch can land and we can change the default abi for baremetal targets in a follow-up patch. Comment at: c

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. In D67172#1663096 , @sammccall wrote: > LG, though if we can drop the struct and make MaxSuffixComponents a constant > it'd be simpler still. Done. > Sure. This is going to win a couple of percent I guess: for these cases

[PATCH] D67031: [Clang][Bundler] Error reporting improvements

2019-09-09 Thread Sergey Dmitriev via Phabricator via cfe-commits
sdmitriev added a comment. Ping CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67031/new/ https://reviews.llvm.org/D67031 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D64943: [Clang][OpenMP offload] Eliminate use of OpenMP linker script

2019-09-09 Thread Sergey Dmitriev via Phabricator via cfe-commits
sdmitriev added a comment. Ping CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64943/new/ https://reviews.llvm.org/D64943 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. In D67172#1663179 , @ilya-biryukov wrote: > > "we could try" sounds like we *don't* know how to eliminate it. Parsing > > manpages aside, I thought the main problem was these symbols are > > nonstandard and an infinitely porta

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 219360. ilya-biryukov marked 3 inline comments as done. ilya-biryukov added a comment. - Make MaxSuffixComponents a constant - Put the suffix mapping into a single constant - Initialize all StringMaps directly - Rename to Std...Mapping Repository: rG

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov marked 8 inline comments as done. ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/index/CanonicalIncludes.cpp:41 + if (!SuffixHeaderMapping) +return Header; sammccall wrote: > nit: can we write `if (SuffixHeaderMappi

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. Thanks for all suggestions. The final result is rather small and minimal. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67172/new/ https://reviews.llvm.org/D67172 ___ cfe

[clang-tools-extra] r371408 - [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Ilya Biryukov via cfe-commits
Author: ibiryukov Date: Mon Sep 9 08:32:51 2019 New Revision: 371408 URL: http://llvm.org/viewvc/llvm-project?rev=371408&view=rev Log: [clangd] Use pre-populated mappings for standard symbols Summary: This takes ~5% of time when running clangd unit tests. To achieve this, move mapping of system

[PATCH] D67172: [clangd] Use pre-populated mappings for standard symbols

2019-09-09 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL371408: [clangd] Use pre-populated mappings for standard symbols (authored by ibiryukov, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: h

r371410 - [NFC] Add aacps bitfields access test

2019-09-09 Thread Diogo N. Sampaio via cfe-commits
Author: dnsampaio Date: Mon Sep 9 08:39:45 2019 New Revision: 371410 URL: http://llvm.org/viewvc/llvm-project?rev=371410&view=rev Log: [NFC] Add aacps bitfields access test Added: cfe/trunk/test/CodeGen/aapcs-bitfield.c Added: cfe/trunk/test/CodeGen/aapcs-bitfield.c URL: http://llvm.org/v

[PATCH] D67341: [clangd] Simplify semantic highlighting visitor

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 219363. ilya-biryukov added a comment. - Turn into NFC, do not highlight lambdas differently Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67341/new/ https://reviews.llvm.org/D67341 Files: clang-tools-

[PATCH] D62731: [RFC] Add support for options -fp-model= and -fp-speculation= : specify floating point behavior

2019-09-09 Thread Melanie Blower via Phabricator via cfe-commits
mibintc marked 3 inline comments as done. mibintc added inline comments. Comment at: clang/docs/UsersManual.rst:1305 + and ``noexcept``. Note that -fp-model=[no]except can be combined with the + other three settings for this option. Details: + andrew.w.kaylor

[PATCH] D67341: [clangd] Simplify semantic highlighting visitor

2019-09-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. In D67341#1663104 , @hokein wrote: > Unfortunately, the patch is a bit large, containing refactoring changes and > functionality changes, is it possible to split it into (two) smaller patches? Done. There should be no func

[PATCH] D67264: [clangd] Collect location of macro definition in the ParsedAST

2019-09-09 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. We should probably also take a look at highlighting macros inside the preamble part of the main file. @hokein, are you planning to do this or should we just file a bug for

[PATCH] D66564: [clang-tidy] new FPGA struct pack align check

2019-09-09 Thread Frank Derry Wanye via Phabricator via cfe-commits
ffrankies updated this revision to Diff 219358. ffrankies added a comment. Herald added subscribers: kadircet, jkorous. Sorry for the delay. I was mostly having trouble building clang-tidy after pulling from master and having it recognize that the struct-pack-align check exists. I finally realiz

[PATCH] D67358: Implement semantic selections.

2019-09-09 Thread UTKARSH SAXENA via Phabricator via cfe-commits
usaxena95 created this revision. Herald added subscribers: cfe-commits, kadircet, arphaman, jkorous, mgorny. Herald added a project: clang. For a given cursor position, it returns ranges that are interesting to the user. Currently the semantic ranges correspond to the nodes of the syntax trees.

[PATCH] D62731: [RFC] Add support for options -frounding-math -fp-model= and -fp-exception-behavior= : specify floating point behavior

2019-09-09 Thread Melanie Blower via Phabricator via cfe-commits
mibintc updated this revision to Diff 219364. mibintc retitled this revision from "[RFC] Add support for options -fp-model= and -fp-speculation= : specify floating point behavior" to "[RFC] Add support for options -frounding-math -fp-model= and -fp-exception-behavior= : specify floating point be

[PATCH] D64146: [Clang Interpreter] Initial patch for the constexpr interpreter

2019-09-09 Thread Simon Pilgrim via Phabricator via cfe-commits
RKSimon added a comment. @nand The MSVC warnings are self explanatory - you've declared a number of methods (visitIndirectMember, emitConv and getPtrConstFn) but not provided definitions, as they're on template classes MSVC complains, a lot. Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D65371: do not emit -Wunused-macros warnings in -frewrite-includes mode (PR15614)

2019-09-09 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 219370. llunak added a comment. Added a test. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65371/new/ https://reviews.llvm.org/D65371 Files: clang/lib/Lex/PPDirectives.cpp clang/test/Frontend/rewrite-includes-warnings.c

[PATCH] D65371: do not emit -Wunused-macros warnings in -frewrite-includes mode (PR15614)

2019-09-09 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D65371#1659929 , @dblaikie wrote: > A test case would be good (in the clang/test directory - probably near/in the > other tests for -frewrite-includes) Done. > And does the same bug occur for other preprocessor-related warnin

[PATCH] D67358: Implement semantic selections.

2019-09-09 Thread UTKARSH SAXENA via Phabricator via cfe-commits
usaxena95 updated this revision to Diff 219381. usaxena95 added a comment. Removed logs for debugging. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67358/new/ https://reviews.llvm.org/D67358 Files: clang-tools-extra/clangd/CMakeLists.txt clan

[PATCH] D66572: [analyzer] NFC: BugReporter Separation Ep.I.

2019-09-09 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr accepted this revision. gribozavr added a comment. I think this patch is a good improvement, and I don't want to hold it back -- but like we discussed before, and like you wrote on the mailing list, I would want a more simple API for ClangTidy. Comment at: clang/in

[clang-tools-extra] r371422 - [clangd] Attempt to fix failing Windows buildbots.

2019-09-09 Thread Ilya Biryukov via cfe-commits
Author: ibiryukov Date: Mon Sep 9 10:03:49 2019 New Revision: 371422 URL: http://llvm.org/viewvc/llvm-project?rev=371422&view=rev Log: [clangd] Attempt to fix failing Windows buildbots. The assertion is failing on Windows, probably because path separator is different. For the failure see: http

[PATCH] D66796: [clang] Loop pragma vectorize(disable)

2019-09-09 Thread Florian Hahn via Phabricator via cfe-commits
fhahn added a comment. IMO it is fine to say ` pragma vectorize(disable)` disables the vectorizer completely, including interleaving. @Meinersbur, what do you think? I think it would be good to make that clear in the commit message. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D66796/n

[PATCH] D62731: [RFC] Add support for options -frounding-math, -fp-model=, and -fp-exception-behavior=, : Specify floating point behavior

2019-09-09 Thread John McCall via Phabricator via cfe-commits
rjmccall added a subscriber: scanon. rjmccall added a comment. I think this is a step in the right direction, thank you. I'd like @scanon to weigh in on the evolving design here. Comment at: clang/docs/UsersManual.rst:1314 + ``-ffp-model=strict``, or merely establish the ro

[PATCH] D67358: [clangd] Implement semantic selections.

2019-09-09 Thread UTKARSH SAXENA via Phabricator via cfe-commits
usaxena95 updated this revision to Diff 219386. usaxena95 added a comment. Create range only if it represents a valid file range. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67358/new/ https://reviews.llvm.org/D67358 Files: clang-tools-extra/c

[PATCH] D67079: [analyzer] CastValueChecker: Model inheritance

2019-09-09 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso updated this revision to Diff 219391. Charusso marked 5 inline comments as done. Charusso added a comment. - Fix. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67079/new/ https://reviews.llvm.org/D67079 Files: clang/include/clang/StaticAnalyzer/Core/PathSensitive/DynamicCast

  1   2   >