[PATCH] D43197: [OpenMP] Add flag for linking runtime bitcode library

2018-03-09 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld added inline comments. Comment at: lib/Driver/ToolChains/Cuda.cpp:536-542 + StringRef CompilerPath = env; + while (!CompilerPath.empty()) { +std::pair Split = +CompilerPath.split(llvm::sys::EnvPathSeparator); +LibraryPaths.push_back(

[PATCH] D44293: [clangd] Fix irrelevant declaratations in goto definition (on macros).

2018-03-09 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. hokein added a reviewer: ilya-biryukov. Herald added subscribers: ioeric, jkorous-apple, klimek. DeclrationAndMacrosFinder will find some declarations (not macro!) that are referened inside the macro somehow, isSearchedLocation() is not sufficient, we don't know wheth

[PATCH] D44272: [clangd] Support incremental document syncing

2018-03-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov requested changes to this revision. ilya-biryukov added inline comments. This revision now requires changes to proceed. Comment at: clangd/ClangdLSPServer.cpp:101 json::obj{ -{"textDocumentSync", 1}, +{"textDocumentSync", 2},

[PATCH] D44217: [clang-tidy] Enable Python 3 support for add_new_check.py

2018-03-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. Thanks for the fix! https://reviews.llvm.org/D44217 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm

[PATCH] D44294: [clangd] Fix diagnostic errors in the test code, NFC.

2018-03-09 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. hokein added a reviewer: ilya-biryukov. Herald added subscribers: ioeric, jkorous-apple, klimek. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44294 Files: unittests/clangd/XRefsTests.cpp Index: unittests/clangd/XRefsTests.cpp ==

[PATCH] D44272: [clangd] Support incremental document syncing

2018-03-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clangd/ClangdServer.cpp:557 // 64-bit unsigned integer. if (Version < LastReportedDiagsVersion) return; When you'll try remove the `DraftMgr`, this piece of code will be hard to refactor because i

[PATCH] D44295: Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-09 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added reviewers: klimek, alexfh. zinovy.nis added a project: clang-tools-extra. Herald added a subscriber: mgorny. Warns if one calls grand-..parent's virtual method in child's virtual method instead of parent's. Can automatically fix such cases by ret

[PATCH] D44294: [clangd] Fix diagnostic errors in the test code, NFC.

2018-03-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: unittests/clangd/XRefsTests.cpp:587 - const char *HeaderContents = R"cpp([[]]int a;)cpp"; + const char *HeaderContents = R"cpp([[]]#ifndef TEST_H_ + #define TEST_H_ I would g

[PATCH] D43162: [Parser] (C++) Make -Wextra-semi slightly more useful

2018-03-09 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Ping Repository: rC Clang https://reviews.llvm.org/D43162 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D43015: clang-format: Introduce BreakInheritanceList option

2018-03-09 Thread Francois Ferrand via Phabricator via cfe-commits
Typz added a comment. ping? Repository: rC Clang https://reviews.llvm.org/D43015 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D43290: clang-format: tweak formatting of variable initialization blocks

2018-03-09 Thread Francois Ferrand via Phabricator via cfe-commits
Typz added a comment. ping? Repository: rC Clang https://reviews.llvm.org/D43290 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D42684: clang-format: Allow optimizer to break template declaration.

2018-03-09 Thread Francois Ferrand via Phabricator via cfe-commits
Typz added a comment. ping? Repository: rC Clang https://reviews.llvm.org/D42684 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] r327111 - [clang-tidy] Add check: replace string::find(...) == 0 with absl::StartsWith

2018-03-09 Thread Haojian Wu via cfe-commits
Author: hokein Date: Fri Mar 9 02:47:14 2018 New Revision: 327111 URL: http://llvm.org/viewvc/llvm-project?rev=327111&view=rev Log: [clang-tidy] Add check: replace string::find(...) == 0 with absl::StartsWith Patch by Niko Weh! Reviewers: hokein Subscribers: klimek, cfe-commits, ioeric, ilya-b

[PATCH] D43847: [clang-tidy] Add check: replace string::find(...) == 0 with absl::StartsWith

2018-03-09 Thread Haojian Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE327111: [clang-tidy] Add check: replace string::find(...) == 0 with absl::StartsWith (authored by hokein, committed by ). Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D43847 Files:

[PATCH] D44294: [clangd] Fix diagnostic errors in the test code, NFC.

2018-03-09 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 137712. hokein marked an inline comment as done. hokein added a comment. Use #program once Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44294 Files: unittests/clangd/XRefsTests.cpp Index: unittests/clangd/XRefsTests.cpp ===

[PATCH] D44294: [clangd] Fix diagnostic errors in the test code, NFC.

2018-03-09 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: unittests/clangd/XRefsTests.cpp:587 - const char *HeaderContents = R"cpp([[]]int a;)cpp"; + const char *HeaderContents = R"cpp([[]]#ifndef TEST_H_ + #define TEST_H_ ilya-biryukov wr

[PATCH] D41102: Setup clang-doc frontend framework

2018-03-09 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Might have been better to not start landing until the all differentials are understood/accepted, but i understand that it is not really up to me to decide. Let's hope nothing in the next differentials will require changes to this initial code :) Co

[PATCH] D44247: [clangd] Use identifier range as the definition range.

2018-03-09 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 137720. hokein marked 7 inline comments as done. hokein added a comment. Herald added a subscriber: mgorny. Address review comments. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44247 Files: clangd/AST.cpp clangd/AST.h clangd/CMakeLi

[PATCH] D44247: [clangd] Use identifier range as the definition range.

2018-03-09 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. Thanks for the comments! Comment at: clangd/SourceCode.cpp:55 + const auto& SM = D->getASTContext().getSourceManager(); + SourceLocation SpellingLoc = SM.getSpellingLoc(D->getLocation()); + if (D->getLocation().isMacroID()) { sammccal

[clang-tools-extra] r327115 - [clang-tidy] fix header guard

2018-03-09 Thread Sam McCall via cfe-commits
Author: sammccall Date: Fri Mar 9 03:47:37 2018 New Revision: 327115 URL: http://llvm.org/viewvc/llvm-project?rev=327115&view=rev Log: [clang-tidy] fix header guard Modified: clang-tools-extra/trunk/clang-tidy/abseil/StringFindStartswithCheck.h Modified: clang-tools-extra/trunk/clang-tidy/a

Expose clang_getOverriddenCursors to python clang module

2018-03-09 Thread Andrew Nelson via cfe-commits
This patch exposes an interface to libclang's clang_getOverriddenCursors and clang_disposeOverriddenCursors functions to the python api. The patch is adapted from this stack overflow response but cleaned up to fit within the existing cindex.py codebase https://stackoverflow.com/questions/35962473/

[PATCH] D44298: [clangd] Don't index template specializations.

2018-03-09 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added a reviewer: ioeric. Herald added subscribers: cfe-commits, jkorous-apple, ilya-biryukov, klimek. These have different USRs than the underlying entity, but are not typically interesting in their own right and can be numerous (e.g. generated traits).

[PATCH] D44298: [clangd] Don't index template specializations.

2018-03-09 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 137729. sammccall added a comment. merge matchers Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44298 Files: clangd/index/SymbolCollector.cpp unittests/clangd/SymbolCollectorTests.cpp Index: unittests/clangd/SymbolCollectorTests.cp

[PATCH] D44298: [clangd] Don't index template specializations.

2018-03-09 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 137731. sammccall added a comment. verify that we don't emit extra symbols in other template-related cases Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44298 Files: clangd/index/SymbolCollector.cpp unittests/clangd/SymbolCollectorTe

[PATCH] D44298: [clangd] Don't index template specializations.

2018-03-09 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: unittests/clangd/SymbolCollectorTests.cpp:200 + UnorderedElementsAreArray( + {QName("Foo"), QName("f1"), QName("f2"), QName("KInt"), QName("Tm

[clang-tools-extra] r327127 - [clangd] Don't index template specializations.

2018-03-09 Thread Sam McCall via cfe-commits
Author: sammccall Date: Fri Mar 9 05:25:29 2018 New Revision: 327127 URL: http://llvm.org/viewvc/llvm-project?rev=327127&view=rev Log: [clangd] Don't index template specializations. Summary: These have different USRs than the underlying entity, but are not typically interesting in their own righ

[PATCH] D44298: [clangd] Don't index template specializations.

2018-03-09 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL327127: [clangd] Don't index template specializations. (authored by sammccall, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D44298?vs=137731

[PATCH] D44231: [clang-tidy] Check for sizeof that call functions

2018-03-09 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D44231#1032011, @pfultz2 wrote: > > If the return type of foo() is changed, then the use for s1 will be > > automatically updated > > But usually you write it as: > > using foo_return = uint16_t; > foo_return foo(); > ... > size_

[clang-tools-extra] r327129 - [clangd] Use identifier range as the definition range.

2018-03-09 Thread Haojian Wu via cfe-commits
Author: hokein Date: Fri Mar 9 06:00:34 2018 New Revision: 327129 URL: http://llvm.org/viewvc/llvm-project?rev=327129&view=rev Log: [clangd] Use identifier range as the definition range. Summary: This also matches the range in symbol index. Reviewers: sammccall Subscribers: klimek, ilya-biryuk

[PATCH] D44247: [clangd] Use identifier range as the definition range.

2018-03-09 Thread Haojian Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE327129: [clangd] Use identifier range as the definition range. (authored by hokein, committed by ). Changed prior to commit: https://reviews.llvm.org/D44247?vs=137720&id=137736#toc Repository: rL L

[PATCH] D44247: [clangd] Use identifier range as the definition range.

2018-03-09 Thread Haojian Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL327129: [clangd] Use identifier range as the definition range. (authored by hokein, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D44247?vs=1

[clang-tools-extra] r327130 - [clangd-vscode] Add package-lock.json to .gitignore

2018-03-09 Thread Eric Liu via cfe-commits
Author: ioeric Date: Fri Mar 9 06:06:43 2018 New Revision: 327130 URL: http://llvm.org/viewvc/llvm-project?rev=327130&view=rev Log: [clangd-vscode] Add package-lock.json to .gitignore Modified: clang-tools-extra/trunk/clangd/clients/clangd-vscode/.gitignore Modified: clang-tools-extra/trunk

[clang-tools-extra] r327131 - [clangd] Fix failing lit test.

2018-03-09 Thread Haojian Wu via cfe-commits
Author: hokein Date: Fri Mar 9 06:16:46 2018 New Revision: 327131 URL: http://llvm.org/viewvc/llvm-project?rev=327131&view=rev Log: [clangd] Fix failing lit test. This test is missed in r327129. Modified: clang-tools-extra/trunk/test/clangd/xrefs.test Modified: clang-tools-extra/trunk/test

[PATCH] D44300: [SemaOverload] Fixed crash on code completion

2018-03-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. ilya-biryukov added reviewers: bkramer, sammccall, ioeric, hokein. The relevant failing assertion message is: ../tools/clang/lib/Sema/SemaInit.cpp:8411: PerformCopyInitialization(): Assertion `InitE && "No initialization expression?"' failed. See the added te

[PATCH] D44300: [SemaOverload] Fixed crash on code completion

2018-03-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: lib/Sema/SemaOverload.cpp:6251 + : P->getDefaultArg(); + if (!DefArg) +return false; comment this

[PATCH] D44300: [SemaOverload] Fixed crash on code completion

2018-03-09 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 137743. ilya-biryukov added a comment. - Added a comment Repository: rC Clang https://reviews.llvm.org/D44300 Files: lib/Sema/SemaOverload.cpp test/CodeCompletion/enable-if-attr-crash.cpp Index: test/CodeCompletion/enable-if-attr-crash.cpp ==

r327134 - [SemaOverload] Fixed crash on code completion

2018-03-09 Thread Ilya Biryukov via cfe-commits
Author: ibiryukov Date: Fri Mar 9 06:43:29 2018 New Revision: 327134 URL: http://llvm.org/viewvc/llvm-project?rev=327134&view=rev Log: [SemaOverload] Fixed crash on code completion Summary: The relevant failing assertion message is: ../tools/clang/lib/Sema/SemaInit.cpp:8411: PerformCopyInitializ

[PATCH] D44300: [SemaOverload] Fixed crash on code completion

2018-03-09 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL327134: [SemaOverload] Fixed crash on code completion (authored by ibiryukov, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D44300 Files: cfe/

Re: r327105 - CodeGen: simplify and validate exception personalities

2018-03-09 Thread Nico Weber via cfe-commits
Looks like this broke the Windows bot: http://lab.llvm.org:8011/builders/clang-x64-ninja-win7/builds/9365 Can you fix or revert, please? On Fri, Mar 9, 2018 at 2:06 AM, Saleem Abdulrasool via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Author: compnerd > Date: Thu Mar 8 23:06:42 2018 > Ne

RE: [llvm] r325653 - [mips] Spectre variant two mitigation for MIPSR2

2018-03-09 Thread Simon Dardis via cfe-commits
Hi, Any downstream users should be able to apply this, the corresponding clang patch (r325651) and the LLD patch (r325657, and r325713) cleanly to the release sources of LLVM 6.0, should they require it. Thanks, Simon Author: sdardis Date: Tue Feb 20 16:06:53 2018 New Revision: 325653 URL: http

[PATCH] D43197: [OpenMP] Add flag for linking runtime bitcode library

2018-03-09 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: lib/Driver/ToolChains/Cuda.cpp:592 +Twine("lib") + CLANG_LIBDIR_SUFFIX); +LibraryPaths.emplace_back(DefaultLibPath.c_str()); + Do you still need `.c_str()` here? Comment at: test/Driver/ope

[PATCH] D43197: [OpenMP] Add flag for linking runtime bitcode library

2018-03-09 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea marked an inline comment as done. gtbercea added inline comments. Comment at: lib/Driver/ToolChains/Cuda.cpp:536-542 + StringRef CompilerPath = env; + while (!CompilerPath.empty()) { +std::pair Split = +CompilerPath.split(llvm::sys::EnvPathS

r327136 - [OPENMP] Fix the address of the original variable in task reductions.

2018-03-09 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Fri Mar 9 07:20:30 2018 New Revision: 327136 URL: http://llvm.org/viewvc/llvm-project?rev=327136&view=rev Log: [OPENMP] Fix the address of the original variable in task reductions. If initialization of the task reductions requires pointer to original variable, which is stor

[PATCH] D43197: [OpenMP] Add flag for linking runtime bitcode library

2018-03-09 Thread George Rokos via Phabricator via cfe-commits
grokos added inline comments. Comment at: test/Driver/openmp-offload-gpu.c:150 +/// bitcode library and add it to the LIBRARY_PATH. +// RUN: touch %T/libomptarget-nvptx-sm_60.bc +// RUN: env LIBRARY_PATH=%T %clang -### -fopenmp=libomp -fopenmp-targets=nvptx64-nvidia-cuda \ -

[PATCH] D44305: [clangd] Add an interface that finds symbol by SymbolID in SymbolIndex.

2018-03-09 Thread Eric Liu via Phabricator via cfe-commits
ioeric created this revision. ioeric added a reviewer: sammccall. Herald added subscribers: cfe-commits, jkorous-apple, ilya-biryukov, klimek. Potential use case: argument go-to-definition result with symbol information (e.g. function definition in cc file) that might not be in the AST. Reposito

[PATCH] D43197: [OpenMP] Add flag for linking runtime bitcode library

2018-03-09 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 137754. gtbercea added a comment. Change test. Repository: rC Clang https://reviews.llvm.org/D43197 Files: include/clang/Basic/DiagnosticDriverKinds.td lib/Driver/ToolChains/Cuda.cpp test/Driver/Inputs/lib/libomptarget-nvptx-sm_60.bc test/Driver

[PATCH] D43197: [OpenMP] Add flag for linking runtime bitcode library

2018-03-09 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld added inline comments. Comment at: test/Driver/openmp-offload-gpu.c:150 +/// bitcode library and add it to the LIBRARY_PATH. +// RUN: touch %T/libomptarget-nvptx-sm_60.bc +// RUN: env LIBRARY_PATH=%T %clang -### -fopenmp=libomp -fopenmp-targets=nvptx64-nvidia-cuda \

[PATCH] D43197: [OpenMP] Add flag for linking runtime bitcode library

2018-03-09 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added inline comments. Comment at: lib/Driver/ToolChains/Cuda.cpp:592 +Twine("lib") + CLANG_LIBDIR_SUFFIX); +LibraryPaths.emplace_back(DefaultLibPath.c_str()); + ABataev wrote: > Do you still need `.c_str()` here? Doesn't compile without it b

[PATCH] D43197: [OpenMP] Add flag for linking runtime bitcode library

2018-03-09 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 137755. gtbercea added a comment. Revert to c_str(). Repository: rC Clang https://reviews.llvm.org/D43197 Files: include/clang/Basic/DiagnosticDriverKinds.td lib/Driver/ToolChains/Cuda.cpp test/Driver/Inputs/lib/libomptarget-nvptx-sm_60.bc test/

[PATCH] D43197: [OpenMP] Add flag for linking runtime bitcode library

2018-03-09 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added inline comments. Comment at: test/Driver/openmp-offload-gpu.c:150 +/// bitcode library and add it to the LIBRARY_PATH. +// RUN: touch %T/libomptarget-nvptx-sm_60.bc +// RUN: env LIBRARY_PATH=%T %clang -### -fopenmp=libomp -fopenmp-targets=nvptx64-nvidia-cuda \

[PATCH] D44231: [clang-tidy] Check for sizeof that call functions

2018-03-09 Thread Paul Fultz II via Phabricator via cfe-commits
pfultz2 added a comment. > Again, that only works for C++ and not C. Typedef has always worked in C. > Did it report any true positives that would need correcting? Not for LLVM, but it has in other projects like I mentioned. > Can you check some other large repos (both C++ and C), such as: Qt,

[PATCH] D44272: [clangd] Support incremental document syncing

2018-03-09 Thread Simon Marchi via Phabricator via cfe-commits
simark marked 2 inline comments as done. simark added inline comments. Comment at: clangd/ClangdLSPServer.cpp:101 json::obj{ -{"textDocumentSync", 1}, +{"textDocumentSync", 2}, {"documentFormattingProvider", true}, il

RE: [llvm] r325653 - [mips] Spectre variant two mitigation for MIPSR2

2018-03-09 Thread Simon Dardis via cfe-commits
Apoloiges all, I spoke too soon. Some tests fail due to mir changes, and one which a slight different version of the memset intrinsic. Attached is a patch which resolves the failures. Thanks, Simon From: llvm-commits [llvm-commits-boun...@lists.llvm.org]

[PATCH] D43197: [OpenMP] Add flag for linking runtime bitcode library

2018-03-09 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld added inline comments. Comment at: test/Driver/openmp-offload-gpu.c:150 +/// bitcode library and add it to the LIBRARY_PATH. +// RUN: touch %T/libomptarget-nvptx-sm_60.bc +// RUN: env LIBRARY_PATH=%T %clang -### -fopenmp=libomp -fopenmp-targets=nvptx64-nvidia-cuda \

[PATCH] D44272: [clangd] Support incremental document syncing

2018-03-09 Thread Simon Marchi via Phabricator via cfe-commits
simark marked 2 inline comments as done. simark added inline comments. Comment at: clangd/ClangdServer.h:159 /// constructor will receive onDiagnosticsReady callback. void addDocument(PathRef File, StringRef Contents, + WantDiagnostics WantDiags = WantDiag

[PATCH] D43764: [clang-apply-replacements] Convert tooling::Replacements to tooling::AtomicChange for conflict resolving of changes, code cleanup, and code formatting.

2018-03-09 Thread Eric Liu via Phabricator via cfe-commits
ioeric added inline comments. Comment at: clang-apply-replacements/lib/Tooling/ApplyReplacements.cpp:188 -bool mergeAndDeduplicate(const TUReplacements &TUs, - FileToReplacementsMap &GroupedReplacements, - clang::SourceManager &SM

[PATCH] D43197: [OpenMP] Add flag for linking runtime bitcode library

2018-03-09 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 137769. gtbercea added a comment. Fix test. Repository: rC Clang https://reviews.llvm.org/D43197 Files: include/clang/Basic/DiagnosticDriverKinds.td lib/Driver/ToolChains/Cuda.cpp test/Driver/Inputs/lib/libomptarget-nvptx-sm_20.bc test/Driver/op

[PATCH] D43197: [OpenMP] Add flag for linking runtime bitcode library

2018-03-09 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added inline comments. Comment at: test/Driver/openmp-offload-gpu.c:150 +/// bitcode library and add it to the LIBRARY_PATH. +// RUN: touch %T/libomptarget-nvptx-sm_60.bc +// RUN: env LIBRARY_PATH=%T %clang -### -fopenmp=libomp -fopenmp-targets=nvptx64-nvidia-cuda \

Re: [PATCH] D44103: Adding additional UNSUPPORTED platform in libcxx/test/std/strings/basic.string/string.cons/iter_alloc_deduction.fail.cpp

2018-03-09 Thread Mike Edwards via cfe-commits
Eric, Any chance you could have one more look at this and let me know if the patch is acceptable? Thanks, Mike On Mon, Mar 5, 2018 at 4:16 PM, Mike Edwards via Phabricator < revi...@reviews.llvm.org> wrote: > sqlbyme updated this revision to Diff 137104. > sqlbyme added a comment. > > I copied w

[PATCH] D44231: [clang-tidy] Check for sizeof that call functions

2018-03-09 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D44231#1032782, @pfultz2 wrote: > > Again, that only works for C++ and not C. > > Typedef has always worked in C. This is true. I think what I'm struggling to say is: I don't think this is a common pattern in either C or C++. It's als

[PATCH] D44295: Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-09 Thread Malcolm Parsons via Phabricator via cfe-commits
malcolm.parsons added inline comments. Comment at: clang-tidy/bugprone/ParentVirtualCallCheck.cpp:152 +Member->getQualifierLoc().getSourceRange(), +GetNameAsString(*(Parents.front())) + "::"); + } What does this do for templated parent classes?

[PATCH] D44093: [BUILTINS] structure pretty printer

2018-03-09 Thread Paul Semel via Phabricator via cfe-commits
paulsemel added inline comments. Comment at: lib/CodeGen/CGBuiltin.cpp:1252 + Types[getContext().getPointerType(getContext().CharTy)] = "%s"; + GENERATE_TYPE_QUALIFIERS_NO_RESTRICT(getContext().CharTy, "%s") +} aaron.ballman wrote: > paulsemel wrote

[PATCH] D44093: [BUILTINS] structure pretty printer

2018-03-09 Thread Paul Semel via Phabricator via cfe-commits
paulsemel updated this revision to Diff 137775. paulsemel added a comment. Added recursive type pretty-printing as suggested by Aaron. Repository: rC Clang https://reviews.llvm.org/D44093 Files: include/clang/Basic/Builtins.def lib/CodeGen/CGBuiltin.cpp lib/Sema/SemaChecking.cpp Index

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-09 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 137783. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44295 Files: clang-tidy/bugprone/BugproneTidyModule.cpp clang-tidy/bugprone/CMakeLists.txt clang-tidy/bugprone/ParentVirtualCallCheck.cpp clang-tidy/bugprone/ParentVirtualCallC

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-09 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 137781. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44295 Files: clang-tidy/bugprone/BugproneTidyModule.cpp clang-tidy/bugprone/CMakeLists.txt clang-tidy/bugprone/ParentVirtualCallCheck.cpp clang-tidy/bugprone/ParentVirtualCallC

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-09 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added inline comments. Comment at: clang-tidy/bugprone/ParentVirtualCallCheck.cpp:152 +Member->getQualifierLoc().getSourceRange(), +GetNameAsString(*(Parents.front())) + "::"); + } malcolm.parsons wrote: > What does this do for templat

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-09 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 137787. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44295 Files: clang-tidy/bugprone/BugproneTidyModule.cpp clang-tidy/bugprone/CMakeLists.txt clang-tidy/bugprone/ParentVirtualCallCheck.cpp clang-tidy/bugprone/ParentVirtualCallC

[PATCH] D44314: [clangd] Collect the number of files referencing a symbol in the static index.

2018-03-09 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. Herald added subscribers: cfe-commits, ioeric, jkorous-apple, ilya-biryukov, klimek. This is an important ranking signal. It's off for the dynamic index for now. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44314 Files: clangd/global-symbol

[PATCH] D44315: [clangd] Collect the number of files referencing a symbol in the static index.

2018-03-09 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added reviewers: ioeric, hokein. Herald added subscribers: cfe-commits, jkorous-apple, ilya-biryukov, klimek. This is an important ranking signal. It's off for the dynamic index for now. Correspondingly, tell the index infrastructure only to report declar

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-09 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tidy/bugprone/ParentVirtualCallCheck.cpp:26 + +bool IsParentOf(const CXXRecordDecl *Parent, const CXXRecordDecl *ThisClass) { + assert(Parent); Please make this function static and remove anonymous namespac

[PATCH] D44059: [analyzer] AST-matching checker to detect global central dispatch performance anti-pattern

2018-03-09 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin added a comment. This looks good. Some minor post-commit review inline. Comment at: include/clang/StaticAnalyzer/Checkers/Checkers.td:615 + +def GCDAsyncSemaphoreChecker : Checker<"GCDAsyncSemaphore">, + HelpText<"Checker for performance anti-pattern when using semap

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-09 Thread Malcolm Parsons via Phabricator via cfe-commits
malcolm.parsons added inline comments. Comment at: clang-tidy/bugprone/ParentVirtualCallCheck.cpp:152 +Member->getQualifierLoc().getSourceRange(), +GetNameAsString(*(Parents.front())) + "::"); + } zinovy.nis wrote: > malcolm.parsons wrote: > > Wh

[PATCH] D43494: [Modules] Fix creating fake definition data for lambdas.

2018-03-09 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai updated this revision to Diff 137801. vsapsai added a comment. - Claim the definition data more eagerly. Not sure that added "different" in the existing comment is actually useful. It makes sense to me but don't know about others. https://reviews.llvm.org/D43494 Files: clang/lib/Seri

[PATCH] D16008: [clang-tidy] Add calling virtual functions in constructors/destructors check.

2018-03-09 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Herald added subscribers: llvm-commits, xazax.hun, mgorny, klimek. Any further thoughts here? I was slightly bitten by this recently, and i though that it already existed as a clang-tidy check (: Repository: rL LLVM https://reviews.llvm.org/D16008 _

[PATCH] D44281: [analyzer] Suppress more MallocChecker positives in reference counting pointer destructors.

2018-03-09 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. > we often run out of inlining stack depth limit Can we consider increasing that limit? I'd much rather have a limit on maximum path *length* (which we currently don't have), as longer paths are more likely to be false positives. On the other hand, I don't see

[PATCH] D43898: Preliminary refactoring in service of -Wreturn-std-move. NFC.

2018-03-09 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone added a comment. @rtrieu ping? Repository: rC Clang https://reviews.llvm.org/D43898 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r327165 - Don't use -pie in relocatable link.

2018-03-09 Thread Evgeniy Stepanov via cfe-commits
Author: eugenis Date: Fri Mar 9 11:35:16 2018 New Revision: 327165 URL: http://llvm.org/viewvc/llvm-project?rev=327165&view=rev Log: Don't use -pie in relocatable link. Summary: Android, in particular, got PIE enabled by default in r316606. It resulted in relocatable links passing both -r and -p

[PATCH] D44229: Don't use -pie in relocatable link.

2018-03-09 Thread Evgenii Stepanov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC327165: Don't use -pie in relocatable link. (authored by eugenis, committed by ). Changed prior to commit: https://reviews.llvm.org/D44229?vs=137493&id=137809#toc Repository: rC Clang https://review

r327166 - Fix Clang test case.

2018-03-09 Thread Peter Collingbourne via cfe-commits
Author: pcc Date: Fri Mar 9 11:37:28 2018 New Revision: 327166 URL: http://llvm.org/viewvc/llvm-project?rev=327166&view=rev Log: Fix Clang test case. Modified: cfe/trunk/test/CodeGen/thinlto-distributed-cfi-devirt.ll Modified: cfe/trunk/test/CodeGen/thinlto-distributed-cfi-devirt.ll URL: h

[PATCH] D43494: [Modules] Fix creating fake definition data for lambdas.

2018-03-09 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: clang/lib/Serialization/ASTReaderDecl.cpp:1789 + // set fake one. + if (!Canon->DefinitionData) { +Canon->DefinitionData = DD; No braces around single-line `if` bodies, please. Comment at: clang/l

[PATCH] D44231: [clang-tidy] Check for sizeof that call functions

2018-03-09 Thread Paul Fultz II via Phabricator via cfe-commits
pfultz2 added a comment. > I don't have a script for it. I've used "bear" with at least some of those > projects because they use makefiles rather than cmake > (https://github.com/rizsotto/Bear). I'm not tied to those projects > specifically, either, so if you have a different corpus you'd pref

[PATCH] D44093: [BUILTINS] structure pretty printer

2018-03-09 Thread Francis Visoiu Mistrih via Phabricator via cfe-commits
thegameg added a comment. Thanks for working on this! Few remarks in the comments. Comment at: lib/CodeGen/CGBuiltin.cpp:934 +static Value *dumpRecord(CodeGenFunction &CGF, QualType RType, + Value*& RecordPtr, CharUnits Align, `llvm::V

[PATCH] D44231: [clang-tidy] Check for sizeof that call functions

2018-03-09 Thread Paul Fultz II via Phabricator via cfe-commits
pfultz2 updated this revision to Diff 137822. https://reviews.llvm.org/D44231 Files: clang-tidy/misc/SizeofExpressionCheck.cpp clang-tidy/misc/SizeofExpressionCheck.h docs/clang-tidy/checks/misc-sizeof-expression.rst test/clang-tidy/misc-sizeof-expression.cpp Index: test/clang-tidy/misc-

[PATCH] D43281: [AMDGPU] fixes for lds f32 builtins

2018-03-09 Thread Daniil Fukalov via Phabricator via cfe-commits
dfukalov added a comment. ping... Repository: rC Clang https://reviews.llvm.org/D43281 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-09 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tidy/bugprone/ParentVirtualCallCheck.cpp:12 + +#include +#include Please run Clang-format and remove empty line between headers. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44295 _

[PATCH] D43281: [AMDGPU] fixes for lds f32 builtins

2018-03-09 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added a comment. In https://reviews.llvm.org/D43281#1023962, @dfukalov wrote: > The problem is that if set addrspace "2" in description string, > CanT.getAddressSpace() returns target addrspace value "11" (shifted in the > enum) and compares it with input LangAS addrspace ("2", "opencl_l

[PATCH] D44327: ObjCARC: teach the cloner about funclets

2018-03-09 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd created this revision. compnerd added a reviewer: gottesmm. Herald added a subscriber: cfe-commits. compnerd added a reviewer: ahatanak. compnerd added subscribers: rnk, majnemer. In the case that the CallInst that is being moved has an associated operand bundle which is a funclet, the mo

[PATCH] D44103: XFAIL: libcpp-no-deduction-guides in libcxx/test/std/strings/basic.string/string.cons/iter_alloc_deduction.fail.cpp

2018-03-09 Thread Mike Edwards via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL327178: XFAIL: libcpp-no-deduction-guides in libcxx/test/std/strings/basic. (authored by sqlbyme, committed by ). Herald added subscribers: llvm-commits, christof. Changed prior to commit: https://revie

[libcxx] r327178 - XFAIL: libcpp-no-deduction-guides in libcxx/test/std/strings/basic.string/string.cons/iter_alloc_deduction.fail.cpp

2018-03-09 Thread Mike Edwards via cfe-commits
Author: sqlbyme Date: Fri Mar 9 14:13:12 2018 New Revision: 327178 URL: http://llvm.org/viewvc/llvm-project?rev=327178&view=rev Log: XFAIL: libcpp-no-deduction-guides in libcxx/test/std/strings/basic.string/string.cons/iter_alloc_deduction.fail.cpp Summary: Refactor the previous version method

[PATCH] D44327: ObjCARC: teach the cloner about funclets

2018-03-09 Thread David Majnemer via Phabricator via cfe-commits
majnemer added inline comments. Comment at: lib/Transforms/ObjCARC/ObjCARCOpts.cpp:701 + + if (auto *CleanupPad = dyn_cast(BB.getFirstNonPHI())) +OpBundles.emplace_back("funclet", CleanupPad); What if the cleanuppad was introduced in a block which branched t

[PATCH] D43797: [CMake] Copy the generated __config header into build directory

2018-03-09 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd accepted this revision. compnerd added inline comments. This revision is now accepted and ready to land. Comment at: libcxx/include/CMakeLists.txt:19 +DEPENDS ${LIBCXX_BINARY_DIR}/__generated_config) + set(generated_config_deps generate_config_header) +endif() -

[PATCH] D44330: CMake option to allow enabling experimental new pass manager by default

2018-03-09 Thread Petr Hosek via Phabricator via cfe-commits
phosek created this revision. phosek added a reviewer: chandlerc. Herald added subscribers: cfe-commits, mgorny. This CMake flag allows setting the default value for the -f[no]-experimental-new-pass-manager flag. Repository: rC Clang https://reviews.llvm.org/D44330 Files: clang/CMakeLists

[PATCH] D43797: [CMake] Copy the generated __config header into build directory

2018-03-09 Thread Petr Hosek via Phabricator via cfe-commits
phosek added inline comments. Comment at: libcxx/include/CMakeLists.txt:19 +DEPENDS ${LIBCXX_BINARY_DIR}/__generated_config) + set(generated_config_deps generate_config_header) +endif() compnerd wrote: > Where is `generated_config_deps` used? Line 69 Repos

r327183 - test: repair windows build after SVN r327105

2018-03-09 Thread Saleem Abdulrasool via cfe-commits
Author: compnerd Date: Fri Mar 9 15:00:29 2018 New Revision: 327183 URL: http://llvm.org/viewvc/llvm-project?rev=327183&view=rev Log: test: repair windows build after SVN r327105 Thanks to Nico Weber for pointing out the failure. Add an explicit target for the test. Modified: cfe/trunk/tes

[clang-tools-extra] r327184 - [clangd-fuzzer] Update ClangdLSPServer constructor call.

2018-03-09 Thread Matt Morehouse via cfe-commits
Author: morehouse Date: Fri Mar 9 15:02:22 2018 New Revision: 327184 URL: http://llvm.org/viewvc/llvm-project?rev=327184&view=rev Log: [clangd-fuzzer] Update ClangdLSPServer constructor call. Build was broken by r326719. Modified: clang-tools-extra/trunk/clangd/fuzzer/ClangdFuzzer.cpp Modi

[clang-tools-extra] r327186 - [clang-tidy] Update run-clang-tidy.py with config arg

2018-03-09 Thread Julie Hockett via cfe-commits
Author: juliehockett Date: Fri Mar 9 15:26:56 2018 New Revision: 327186 URL: http://llvm.org/viewvc/llvm-project?rev=327186&view=rev Log: [clang-tidy] Update run-clang-tidy.py with config arg Updating the run-clang-tidy.py script to allow specification of the config argument to the clang-tidy in

[PATCH] D43538: [clang-tidy] Update run-clang-tidy.py with config arg

2018-03-09 Thread Julie Hockett via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. juliehockett marked an inline comment as done. Closed by commit rCTE327186: [clang-tidy] Update run-clang-tidy.py with config arg (authored by juliehockett, committed by ). Changed prior to commit: https://reviews.llvm.or

r327189 - [ARM] Add ARMv8.2-A FP16 vector intrinsic

2018-03-09 Thread Abderrazek Zaafrani via cfe-commits
Author: az Date: Fri Mar 9 15:39:34 2018 New Revision: 327189 URL: http://llvm.org/viewvc/llvm-project?rev=327189&view=rev Log: [ARM] Add ARMv8.2-A FP16 vector intrinsic Add the fp16 neon vector intrinsic for ARM as described in the ARM ACLE document. Reviews in https://reviews.llvm.org/D43650

[PATCH] D43494: [Modules] Fix creating fake definition data for lambdas.

2018-03-09 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added inline comments. Comment at: clang/lib/Serialization/ASTReaderDecl.cpp:1811 if (Update || Canon != D) { Canon->DefinitionData = D->DefinitionData; Reader.PendingDefinitions.insert(D); This store seems to be dead too. Need to spend more

[PATCH] D44327: ObjCARC: teach the cloner about funclets

2018-03-09 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd updated this revision to Diff 137867. compnerd added a comment. Use the BB colorizer to detect the token. Fortunately, there is no BB removal/splitting happening here, so there is no state to maintain. Repository: rL LLVM https://reviews.llvm.org/D44327 Files: lib/Transforms/Obj

  1   2   >