[PATCH] D14484: [clang-format] Formatting constructor initializer lists by putting them always on different lines

2021-06-01 Thread Nikolai Hlubek via Phabricator via cfe-commits
nhlubek added a comment. In order to push this forward I have written a bug ticket that highlights this issue: https://bugs.llvm.org/show_bug.cgi?id=50549 The patch is also really simple with the clang-format options that are available nowadays https://github.com/Nikolai-Hlubek/clang/tree/Cons

[PATCH] D103025: [analyzer] Handle NTTP invocation in CallContext.getCalleeDecl()

2021-06-01 Thread Tomasz Kamiński via Phabricator via cfe-commits
tomasz-kaminski-sonarsource added a comment. Ping, Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103025/new/ https://reviews.llvm.org/D103025 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https

[PATCH] D103434: [analyzer] Allow visitors to run callbacks on completion

2021-06-01 Thread Valeriy Savchenko via Phabricator via cfe-commits
vsavchenko added inline comments. Comment at: clang/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp:895 +using VisitorCallback = llvm::function_ref; `function_ref` is a reference, it doesn't own the function. It means that it shouldn't outlive the actual funct

[PATCH] D90232: [clang-format] Formatting constructor initializer lists by putting them always on different lines (update to D14484)

2021-06-01 Thread Nikolai Hlubek via Phabricator via cfe-commits
nhlubek added a comment. I tried to highlight the story with this bug that this commit tries to fix in the following bug report: https://bugs.llvm.org/show_bug.cgi?id=50549 It goes back to 2015 and several people have tried to come up with solutions. The solutions are not complicated but due to

[PATCH] D103142: [clang][clangd] Use reverse header map lookup in suggestPathToFileForDiagnostics

2021-06-01 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin updated this revision to Diff 348900. DmitryPolukhin marked 2 inline comments as done. DmitryPolukhin added a comment. Resolved comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103142/new/ https://reviews.llvm.org/D103142 File

[PATCH] D103142: [clang][clangd] Use reverse header map lookup in suggestPathToFileForDiagnostics

2021-06-01 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin added inline comments. Comment at: clang/lib/Lex/HeaderMap.cpp:245 +StringRef HeaderMapImpl::reverseLookupFilename(StringRef DestPath) const { + if (ReverseMap.empty()) { +const HMapHeader &Hdr = getHeader(); bruno wrote: > Please rewrite this

[clang-tools-extra] 5b74719 - [clangd] Fix -Wunused-variable warning (NFC)

2021-06-01 Thread Yang Fan via cfe-commits
Author: Yang Fan Date: 2021-06-01T16:15:09+08:00 New Revision: 5b747197f8fb83bb7c256fa6cb2010445deb0a85 URL: https://github.com/llvm/llvm-project/commit/5b747197f8fb83bb7c256fa6cb2010445deb0a85 DIFF: https://github.com/llvm/llvm-project/commit/5b747197f8fb83bb7c256fa6cb2010445deb0a85.diff LOG:

[PATCH] D103440: [WIP][analyzer] Introduce range-based reasoning for addition operator

2021-06-01 Thread Manas Gupta via Phabricator via cfe-commits
manas created this revision. Herald added subscribers: steakhal, ASDenysPetrov, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: teemperor. manas requested review of this revision. Herald added a project: clang. Herald added

[PATCH] D103393: [clangd] Bump recommended gRPC version (1.33.2 -> 1.36.3)

2021-06-01 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev planned changes to this revision. kbobyrev added a comment. Makes sense, thanks! Putting this on hold. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103393/new/ https://reviews.llvm.org/D103393

[PATCH] D103184: [AArch64] handle -Wa,-march=

2021-06-01 Thread David Spickett via Phabricator via cfe-commits
DavidSpickett added a comment. Thanks for taking this up! I never got the time for it. I'd like to see the test check that there are no unused argument warnings when there are multiple values. I missed that with another patch in this area. Beyond that I'm not sure the logic is right here. You'v

[PATCH] D90232: [clang-format] Formatting constructor initializer lists by putting them always on different lines (update to D14484)

2021-06-01 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. > A small task that will make a lot of people happy Its not the happy people that concern me, its those who end up not happy that cause us the most pain ;-) 1. I question if the rst was generated via docs/tools/dump_format_style.py or by hand, it has to be gener

[PATCH] D103097: Add DWARF address spaces mapping for SPIR

2021-06-01 Thread Jason Zheng via Phabricator via cfe-commits
jzzheng22 updated this revision to Diff 348910. jzzheng22 added a comment. Simplified test following review comments. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103097/new/ https://reviews.llvm.org/D103097 Files: clang/lib/Basic/Targets/SPIR.h clang/test/CodeGenOpenCL/spir-debug

[PATCH] D103401: [OpenCL] Add support of __opencl_c_generic_address_space feature macro

2021-06-01 Thread Sven van Haastregt via Phabricator via cfe-commits
svenvh added inline comments. Comment at: clang/lib/Basic/TargetInfo.cpp:405 + const auto &OpenCLFeaturesMap = getSupportedOpenCLOpts(); + Opts.OpenCLGenericAddressSpace = hasFeatureEnabled( + OpenCLFeaturesMap, "__opencl_c_generic_address_space");

[PATCH] D101140: [WebAssembly][CodeGen] IR support for WebAssembly local variables

2021-06-01 Thread Andy Wingo via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG82f92e35c646: [WebAssembly][CodeGen] IR support for WebAssembly local variables (authored by wingo). Repository: rG LLVM Github Monorepo CHANGES

[PATCH] D102689: [C++4OpenCL] Allow address space conversion in reinterpret_cast

2021-06-01 Thread Ole Strohm via Phabricator via cfe-commits
olestrohm added inline comments. Comment at: clang/lib/Sema/SemaCast.cpp:2359 - if (SrcType == DestType) { + if (SrcType == Self.Context.removeAddrSpaceQualType(DestType)) { // C++ 5.2.10p2 has a note that mentions that, subject to all other rjmccall wro

[PATCH] D103387: [clangd] Fix feature modules to drop diagnostics

2021-06-01 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/Diagnostics.cpp:732 +if (Adjuster) DiagLevel = Adjuster(DiagLevel, Info); If I'm reading this rig

[PATCH] D99523: [clangd] Use command line adjusters for inserting compile flags

2021-06-01 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. Herald added a subscriber: cfe-commits. Thanks for fixing! Comment at: clang-tools-extra/clangd/CompileCommands.cpp:225 + Cmd = tooling::getInsertArgumentAdjuster( +

[PATCH] D103377: [clangd] Add ability to change storage directory of index files

2021-06-01 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. This is definitely an interface that makes sense for the purpose you describe (profiling index performance) but I'm less convinced it makes sense for clangd's *primary* use cases. For example, our default policy gives different answers for code in different paths, wh

[PATCH] D103252: [C++4OpenCL] Fix missing address space on implicit move assignment operator

2021-06-01 Thread Sven van Haastregt via Phabricator via cfe-commits
svenvh added a comment. > I also added a new test file to check the output AST. If there's a better > place for this test I will move it there. If you're primarily interested in the AST, then it doesn't have to be a Sema test I guess. In that case `clang/test/AST` seems to be a better place, a

[PATCH] D103440: [WIP][analyzer] Introduce range-based reasoning for addition operator

2021-06-01 Thread Valeriy Savchenko via Phabricator via cfe-commits
vsavchenko added a comment. Hey, great start! I added my comments inline and other mentors as reviewers. Comment at: clang/test/Analysis/constant-folding.c:275 + +if (a <= UINT_MAX && b <= UINT_MAX) { + clang_analyzer_eval((a + b) < 0); // expected-warning{{UNKNOWN}} -

[PATCH] D103449: [clangd][Protocol] Drop optional from WorkspaceEdit::changes

2021-06-01 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet created this revision. kadircet added a reviewer: sammccall. Herald added subscribers: usaxena95, arphaman. kadircet requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang-tools-extra. This is causing weird code patt

[PATCH] D102849: [flang][driver] Add support for the "-init-only" option

2021-06-01 Thread Chirag Khandelwal via Phabricator via cfe-commits
AMDChirag added a comment. LGTM. I'll let someone else take a look too. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102849/new/ https://reviews.llvm.org/D102849 ___ cfe-commits mailing list cfe-commits

[PATCH] D103401: [OpenCL] Add support of __opencl_c_generic_address_space feature macro

2021-06-01 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia added inline comments. Comment at: clang/lib/Basic/TargetInfo.cpp:405 + const auto &OpenCLFeaturesMap = getSupportedOpenCLOpts(); + Opts.OpenCLGenericAddressSpace = hasFeatureEnabled( + OpenCLFeaturesMap, "__opencl_c_generic_address_space"); -

[PATCH] D103452: [clang] Fix reading long doubles with va_arg on x86_64 mingw

2021-06-01 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo created this revision. mstorsjo added reviewers: rnk, mati865. Herald added a subscriber: pengfei. mstorsjo requested review of this revision. Herald added a project: clang. On x86_64 mingw, long doubles are always passed indirectly as arguments (see an existing case in WinX86_64ABIInfo::

[PATCH] D103191: [OpenCL] Add support of __opencl_c_program_scope_global_variables feature macro

2021-06-01 Thread Anton Zabaznov via Phabricator via cfe-commits
azabaznov added inline comments. Comment at: clang/test/SemaOpenCL/storageclass.cl:22 +extern generic float g_generic_extern_var; +#ifndef __opencl_c_program_scope_global_variables +// expected-error@-17 {{program scope variable must reside in constant address space}} --

[PATCH] D103241: [OpenCL] Add memory_scope_all_devices

2021-06-01 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia added inline comments. Comment at: clang/include/clang/Basic/OpenCLExtensions.def:113 OPENCL_OPTIONALCOREFEATURE(__opencl_c_atomic_order_seq_cst, false, 300, OCL_C_30) +OPENCL_OPTIONALCOREFEATURE(__opencl_c_atomic_scope_all_devices, false, 300, OCL_C_30) OPENCL_OPTI

[PATCH] D103314: [Analyzer][solver] Simplify existing constraints when a new constraint is added

2021-06-01 Thread Gabor Marton via Phabricator via cfe-commits
martong marked 5 inline comments as done. martong added a comment. In D103314#2789754 , @vsavchenko wrote: > I had another thought, `merge` is usually called in situations when we found > out that two symbols should be marked equal (and checked that it'

[PATCH] D103314: [Analyzer][solver] Simplify existing constraints when a new constraint is added

2021-06-01 Thread Gabor Marton via Phabricator via cfe-commits
martong updated this revision to Diff 348945. martong marked 2 inline comments as done. martong added a comment. - Simplify equivalence classes when iterate over ClassMap, simplify constraints by iterating over the ConstraintsMap Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D103401: [OpenCL] Add support of __opencl_c_generic_address_space feature macro

2021-06-01 Thread Anton Zabaznov via Phabricator via cfe-commits
azabaznov added inline comments. Comment at: clang/lib/Basic/TargetInfo.cpp:405 + const auto &OpenCLFeaturesMap = getSupportedOpenCLOpts(); + Opts.OpenCLGenericAddressSpace = hasFeatureEnabled( + OpenCLFeaturesMap, "__opencl_c_generic_address_space"); -

[PATCH] D103386: [PowerPC] Fix x86 vector intrinsics wrapper compilation under C++

2021-06-01 Thread Bjorn Pettersson via Phabricator via cfe-commits
bjope added subscribers: phosek, bjope. bjope added inline comments. Comment at: clang/test/CodeGen/ppc-xmmintrin.c:10 // RUN: -fno-discard-value-names -mllvm -disable-llvm-optzns -o - | llvm-cxxfilt -n | FileCheck %s --check-prefixes=CHECK,CHECK-LE +// RUN: %clang -x c++ -fs

[PATCH] D102723: [HIP] Tighten checks in hip-include-path.hip test case

2021-06-01 Thread Hubert Tong via Phabricator via cfe-commits
hubert.reinterpretcast added a subscriber: gkistanova. hubert.reinterpretcast added a comment. In D102723#2790047 , @bjope wrote: > But it looks like the workers here > (https://lab.llvm.org/staging/#/workers/109) are paused so hard to tell if it > help

[clang] 94b0aec - [OpenCL] Fix ICE with invalid use of half

2021-06-01 Thread Ole Strohm via cfe-commits
Author: Ole Strohm Date: 2021-06-01T13:43:07+01:00 New Revision: 94b0aec0f5c6b4f6a27cf3a542f795bbba72e851 URL: https://github.com/llvm/llvm-project/commit/94b0aec0f5c6b4f6a27cf3a542f795bbba72e851 DIFF: https://github.com/llvm/llvm-project/commit/94b0aec0f5c6b4f6a27cf3a542f795bbba72e851.diff LO

[PATCH] D103175: [C++4OpenCL] Fix ICE with invalid use of half

2021-06-01 Thread Ole Strohm via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG94b0aec0f5c6: [OpenCL] Fix ICE with invalid use of half (authored by olestrohm). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D103314: [Analyzer][solver] Simplify existing constraints when a new constraint is added

2021-06-01 Thread Gabor Marton via Phabricator via cfe-commits
martong marked 2 inline comments as done. martong added a comment. I was wondering if there is a direct way to check the equivalence classes? I am thinking about to add a `clang_annalyzer_dump_equivalence_classes` function to the ExprInspection checker. Repository: rG LLVM Github Monorepo CH

[clang] 97d2349 - [clang][Parse] Add parsing support for C++ attributes on using-declarations

2021-06-01 Thread Louis Dionne via cfe-commits
Author: Louis Dionne Date: 2021-06-01T08:47:50-04:00 New Revision: 97d234935f1514af128277943f30efc469525371 URL: https://github.com/llvm/llvm-project/commit/97d234935f1514af128277943f30efc469525371 DIFF: https://github.com/llvm/llvm-project/commit/97d234935f1514af128277943f30efc469525371.diff

[PATCH] D91630: [Parse] Add parsing support for C++ attributes on using-declarations

2021-06-01 Thread Louis Dionne via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG97d234935f15: [clang][Parse] Add parsing support for C++ attributes on using-declarations (authored by ldionne). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org

[PATCH] D90188: Add support for attribute 'using_if_exists'

2021-06-01 Thread Louis Dionne via Phabricator via cfe-commits
ldionne updated this revision to Diff 348952. ldionne added a comment. Rebase onto main to trigger CI. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D90188/new/ https://reviews.llvm.org/D90188 Files: clang/include/clang/AST/DeclCXX.h clang/incl

[PATCH] D103314: [Analyzer][solver] Simplify existing constraints when a new constraint is added

2021-06-01 Thread Valeriy Savchenko via Phabricator via cfe-commits
vsavchenko added a comment. Awesome! I know, I said that we are ready to land, but I think I was too excited about this change. We probably should have some data on how it performs on real-life codebases. Comment at: clang/lib/StaticAnalyzer/Core/RangeConstraintManager.cpp:15

[PATCH] D102849: [flang][driver] Add support for the "-init-only" option

2021-06-01 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Hi @stuartellis , Thank you for preparing this! This looks good to me, but I would appreciate a comment somewhere (e.g. in the commit message) comparing `-init-only` and `-test-io`. Essentially, both options are for testing purposes only. IMHO, we should only requir

[PATCH] D103286: [clang-format] Add PPIndentWidth option

2021-06-01 Thread Gerhard Gappmeier via Phabricator via cfe-commits
gergap updated this revision to Diff 348955. gergap added a comment. trigger build again Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103286/new/ https://reviews.llvm.org/D103286 Files: clang/docs/ClangFormatStyleOptions.rst clang/docs/Releas

[PATCH] D103457: [analyzer] Add forwarding `addVisitor` method

2021-06-01 Thread Valeriy Savchenko via Phabricator via cfe-commits
vsavchenko created this revision. vsavchenko added reviewers: NoQ, xazax.hun, martong, steakhal, Szelethus, manas, RedDocMD. Herald added subscribers: ASDenysPetrov, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware. vsavchenko requested review of this revision.

[PATCH] D103165: Threading: use independent llvm::thread implementation on Apple platforms to increase stack size

2021-06-01 Thread Tim Northover via Phabricator via cfe-commits
t.p.northover updated this revision to Diff 348958. t.p.northover added a comment. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, hiraditya. Herald added a project: clang-tools-extra. - Add `llvm::thread` for all potential platforms, allowing stack size to be specified. - `

[PATCH] D103165: Threading: use independent llvm::thread implementation on Apple platforms to increase stack size

2021-06-01 Thread Tim Northover via Phabricator via cfe-commits
t.p.northover added inline comments. Comment at: llvm/include/llvm/Support/thread.h:168 +/// stack size request. +class thread { +public: An alternative here would have been to inherit from `std::thread` but that seemed a bit icky to me. Happy to switch if the c

[PATCH] D103188: [clang-tidy] modernize-loop-convert: limit use of auto

2021-06-01 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added a comment. Frankly, I don't think that length-based criteria is reasonable one. Readability of code is much more important than line/file length. Comment at: clang-tools-extra/clang-tidy/modernize/LoopConvertCheck.cpp:633 + if (!Descriptor.ElemType.isNull

[PATCH] D103142: [clang][clangd] Use reverse header map lookup in suggestPathToFileForDiagnostics

2021-06-01 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin updated this revision to Diff 348965. DmitryPolukhin added a comment. Rebase + try build on Windows again Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103142/new/ https://reviews.llvm.org/D103142 Files: clang/include/clang/Lex/He

[PATCH] D102923: [clang][lex] Remark for used header search paths

2021-06-01 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D102923#2787702 , @dexonsmith wrote: > Yup, seems like something that could be added as a follow up (although > probably using the same remark). Is there a good place to leave behind a > FIXME? I'll put a FIXME at an a

[PATCH] D103461: [clang][deps] NFC: Do not adjust the original action

2021-06-01 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, arphaman. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch stops adjusting the frontend action when `clang-scan-deps` is config

[PATCH] D103252: [C++4OpenCL] Fix missing address space on implicit move assignment operator

2021-06-01 Thread Ole Strohm via Phabricator via cfe-commits
olestrohm updated this revision to Diff 348969. olestrohm added a comment. Cleaned up the test by renaming the struct and making the test compile. The test has also been moved to `clang/test/AST` as suggested, since it really just makes sure that the generated AST contains the correct implicit me

[PATCH] D99523: [clangd] Use command line adjusters for inserting compile flags

2021-06-01 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet marked an inline comment as done. kadircet added inline comments. Comment at: clang-tools-extra/clangd/ConfigCompile.cpp:271 Out.Apply.push_back([Add(std::move(Add))](const Params &, Config &C) { C.CompileFlags.Edits.push_back([Add](std::vector &Args) { +

[PATCH] D99523: [clangd] Use command line adjusters for inserting compile flags

2021-06-01 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet updated this revision to Diff 348972. kadircet added a comment. - Address comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99523/new/ https://reviews.llvm.org/D99523 Files: clang-tools-extra/clangd/CompileCommands.cpp clang-tool

[PATCH] D101645: [clang] RecursiveASTVisitor visits ObjCPropertyRefExpr's class receiver

2021-06-01 Thread David Goldman via Phabricator via cfe-commits
dgoldman added a comment. Friendly ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D101645/new/ https://reviews.llvm.org/D101645 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.ll

[PATCH] D103252: [C++4OpenCL] Fix missing address space on implicit move assignment operator

2021-06-01 Thread Sven van Haastregt via Phabricator via cfe-commits
svenvh accepted this revision. svenvh added a comment. This revision is now accepted and ready to land. LGTM! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103252/new/ https://reviews.llvm.org/D103252 ___ cfe-commits mailing list cfe-commits@

[PATCH] D103179: [clangd] Handle queries without an originating file in ProjectAwareIndex

2021-06-01 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Sorry for lots of comments on a fairly small patch. --- I want to mention one alternative we haven't considered. Ultimately the problem here is that we have actions that depend on config but we don't know what file to pull the config from. This corresponds to passing

[PATCH] D95425: Implementation of global.get/set for reftypes in LLVM IR

2021-06-01 Thread Paulo Matos via Phabricator via cfe-commits
pmatos added a comment. @tlively thanks for the comments. I am currently taking some time off but I will address your concerns upon my return. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95425/new/ https://reviews.llvm.org/D95425 __

[PATCH] D103080: [CMake] Ignore arm_*.h for non-ARM build

2021-06-01 Thread Kristof Beyls via Phabricator via cfe-commits
kristof.beyls added a comment. In D103080#2790139 , @sunlin wrote: > Hi @kristof.beyls The original `lib/clang/12.0.1/include` is about total > ~10M, and the `arm*.h` take about ~5M. Ignore these unused header files will > save the developers who work

[PATCH] D103387: [clangd] Fix feature modules to drop diagnostics

2021-06-01 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet added inline comments. Comment at: clang-tools-extra/clangd/Diagnostics.cpp:732 +if (Adjuster) DiagLevel = Adjuster(DiagLevel, Info); sammccall wrote: > If I'm reading this right: > - we previously discarded the diagnostic "quickly" without

[PATCH] D101645: [clang] RecursiveASTVisitor visits ObjCPropertyRefExpr's class receiver

2021-06-01 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. This looks good from my side, thanks for fixing! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D101645/new/ https://reviews.llvm.org/D10164

[PATCH] D103080: [CMake] Ignore arm_*.h for non-ARM build

2021-06-01 Thread Momchil Velikov via Phabricator via cfe-commits
chill added a comment. IMHO, it's possible to write a frontend test, which includes, say `arm_neon.h`, but does not really require the `ARM` or `AArch64` backends to be configured (e.g. `CodeGen/arm-vector-align.c`?) If `arm_neon.h` is not built, then the test would need the appropriate `REQUIR

[PATCH] D103380: [C++20] Support for lambdas in unevaluated context

2021-06-01 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. Thanks for working on this! > It does not implement temp.deduct/9. Is there a reason why? Comment at: clang/lib/Sema/SemaConcept.cpp:44 } else if (auto *OO = dyn_cast(E)) { - Op = OO->getOperator(); - LHS = OO->getArg(0); - R

[PATCH] D103401: [OpenCL] Add support of __opencl_c_generic_address_space feature macro

2021-06-01 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia added inline comments. Comment at: clang/lib/Basic/TargetInfo.cpp:405 + const auto &OpenCLFeaturesMap = getSupportedOpenCLOpts(); + Opts.OpenCLGenericAddressSpace = hasFeatureEnabled( + OpenCLFeaturesMap, "__opencl_c_generic_address_space"); -

[PATCH] D101816: [clangd] don't rename if the triggering loc is not actually being renamed.

2021-06-01 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/refactor/Rename.cpp:250 +case ReasonToReject::UnrenamableLoc: + return "no rename at the given location"; } -

[PATCH] D101192: Add support for #elifdef and #elifndef

2021-06-01 Thread Bjorn Pettersson via Phabricator via cfe-commits
bjope added inline comments. Comment at: clang/lib/Lex/PPDirectives.cpp:594 +if (CondInfo.FoundElse) + Diag(Tok, diag::pp_err_elif_after_else) << PED_Elif; Hi @aaron.ballman This change is missing from https://reviews.llvm.org/rG8edd3464afbf

[PATCH] D100798: [clangd][ObjC] Fix issue completing a method decl by name

2021-06-01 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. Thanks for the detailed comments, this makes a lot more sense to me now! Comment at: clang-tools-extra/clangd/CodeCompletionStrings.cpp:160 + // + //

[PATCH] D103221: [HIP] Change default lang std to c++14

2021-06-01 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: clang/include/clang/Basic/LangStandards.def:196-197 // CUDA LANGSTANDARD(cuda, "cuda", CUDA, "NVIDIA CUDA(tm)", LineComment | CPlusPlus | Digraphs) It would make sense to bump C++ version for CUDA as well.

[PATCH] D103465: [OpaquePtr] Track pointee types in Clang

2021-06-01 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks created this revision. aeubanks added reviewers: dblaikie, rsmith. aeubanks published this revision for review. aeubanks added a comment. Herald added a project: clang. Herald added a subscriber: cfe-commits. This is definitely WIP, but I'd like to make sure that this is the right direct

[PATCH] D102325: [clang-tidy] cppcoreguidelines-virtual-base-class-destructor: a new check

2021-06-01 Thread Marco Gartmann via Phabricator via cfe-commits
mgartmann updated this revision to Diff 348988. mgartmann added a comment. - added fixes for private destructors - separated fixes for private destructors into notes - added a test case for a `= default;` constructor Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://revi

[PATCH] D103097: Add DWARF address spaces mapping for SPIR

2021-06-01 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia accepted this revision. Anastasia added a comment. This revision is now accepted and ready to land. LGTM! Thanks! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103097/new/ https://reviews.llvm.org/D103097 ___ cfe-commits mailing lis

[PATCH] D102850: [C++4OpenCL] Fix overloading resolution of addrspace constructors

2021-06-01 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia added inline comments. Comment at: clang/lib/Sema/SemaOverload.cpp:9870 + if (S.getLangOpts().OpenCL) { +if (const auto *CD1 = dyn_cast_or_null(Cand1.Function)) { olestrohm wrote: > Anastasia wrote: > > olestrohm wrote: > > > Anastasia wrote: >

[PATCH] D103080: [CMake] Ignore arm_*.h for non-ARM build

2021-06-01 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. I think I'm fine with the general direction, but it would be nice to have a CMake option to force the headers for all targets to be built if someone needs them. For static analysis or something like that, I can imagine someone building LLVM without any backends at all

[PATCH] D103048: [IR] make -stack-alignment= into a module attr

2021-06-01 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added a comment. bumping for review (or suggestions of additional reviewers) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103048/new/ https://reviews.llvm.org/D103048 ___ cfe-commits mai

[PATCH] D103195: Add matchers for gtest's ASSERT_THAT, EXPECT_THAT, ON_CALL and EXPECT_CALL

2021-06-01 Thread Zhaomo Yang via Phabricator via cfe-commits
zhaomo updated this revision to Diff 348998. zhaomo marked an inline comment as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103195/new/ https://reviews.llvm.org/D103195 Files: clang/include/clang/ASTMatchers/GtestMatchers.h clang/lib/ASTMatchers/GtestMatchers.cpp clang/unit

[PATCH] D103195: Add matchers for gtest's ASSERT_THAT, EXPECT_THAT, ON_CALL and EXPECT_CALL

2021-06-01 Thread Zhaomo Yang via Phabricator via cfe-commits
zhaomo added inline comments. Comment at: clang/lib/ASTMatchers/GtestMatchers.cpp:41 } - llvm_unreachable("Unhandled GtestCmp enum"); } hokein wrote: > zhaomo wrote: > > hokein wrote: > > > why remove this `llvm_unreachable`? I think this is a common practic

[PATCH] D103380: [C++20] Support for lambdas in unevaluated context

2021-06-01 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin updated this revision to Diff 349000. cor3ntin added a comment. Typos, add more tests Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103380/new/ https://reviews.llvm.org/D103380 Files: clang/lib/Sema/SemaConcept.cpp clang/lib/Sema/Sema

[PATCH] D103465: [OpaquePtr] Track pointee types in Clang

2021-06-01 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. The changes look like the right direction to me - though I don't know/couldn't confirm whether more changes will be needed in other places. Comment at: clang/lib/CodeGen/Address.h:29-30 public: Address(llvm::Value *pointer, CharUnits alignment) -

[PATCH] D103380: [C++20] Support for lambdas in unevaluated context

2021-06-01 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin updated this revision to Diff 349002. cor3ntin added a comment. Move tests to SemaCXX Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103380/new/ https://reviews.llvm.org/D103380 Files: clang/lib/Sema/SemaConcept.cpp clang/lib/Sema/Sema

[PATCH] D103131: support debug info for alias variable

2021-06-01 Thread Paul Robinson via Phabricator via cfe-commits
probinson added a comment. In D103131#2789493 , @probinson wrote: >> Mixed feelings - somewhat in favor of "do the thing that's probably already >> fairly tested/known to work" (GCC's thing). But open to the idea that that >> approach has problems, for

[PATCH] D103131: support debug info for alias variable

2021-06-01 Thread Paul Robinson via Phabricator via cfe-commits
probinson added a comment. Of course, if it turns out that gdb can't handle the imported_declaration, we might end up having to do this two different ways under the tuning option. I'd *really* prefer not to do that though, and I'd argue it's a gdb bug if it cannot understand imported_declarati

[PATCH] D103188: [clang-tidy] modernize-loop-convert: limit use of auto

2021-06-01 Thread Edward O via Phabricator via cfe-commits
eddy-geek added a subscriber: Eugene.Zelenko. eddy-geek added a comment. @Eugene.Zelenko wrote: > Frankly, I don't think that length-based criteria is reasonable one. > Readability of code is much more important than line/file length. It provides an added configuration flexibility without being

[PATCH] D98995: [CGAtomic] Lift stronger requirements on cmpxch and add support for acquire failure mode

2021-06-01 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. @yln sorry, I didn't get notifications for this somehow. This got fixed as part of the more general support in https://github.com/llvm/llvm-project/commit/819e0d105e84c6081cfcfa0e38fd257b6124553a Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://

[PATCH] D90188: Add support for attribute 'using_if_exists'

2021-06-01 Thread Louis Dionne via Phabricator via cfe-commits
ldionne updated this revision to Diff 349010. ldionne added a comment. Run clang-format. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D90188/new/ https://reviews.llvm.org/D90188 Files: clang/include/clang/AST/DeclCXX.h clang/include/clang/AST/

[PATCH] D100798: [clangd][ObjC] Fix issue completing a method decl by name

2021-06-01 Thread David Goldman via Phabricator via cfe-commits
dgoldman updated this revision to Diff 349014. dgoldman added a comment. Add another test for a simple method decl (no arg selector) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100798/new/ https://reviews.llvm.org/D100798 Files: clang-tools-ex

[PATCH] D100798: [clangd][ObjC] Fix issue completing a method decl by name

2021-06-01 Thread David Goldman via Phabricator via cfe-commits
dgoldman marked an inline comment as done. dgoldman added inline comments. Comment at: clang-tools-extra/clangd/CodeCompletionStrings.cpp:160 + // + // e.g. to complete `- (void)doSomething:(id)argument`: + // - Completion name: `doSomething:` -

[clang-tools-extra] 2a030e6 - [clangd][ObjC] Fix issue completing a method decl by name

2021-06-01 Thread David Goldman via cfe-commits
Author: David Goldman Date: 2021-06-01T13:35:05-04:00 New Revision: 2a030e680e0812c652ed4ae2b012e285a5514ffa URL: https://github.com/llvm/llvm-project/commit/2a030e680e0812c652ed4ae2b012e285a5514ffa DIFF: https://github.com/llvm/llvm-project/commit/2a030e680e0812c652ed4ae2b012e285a5514ffa.diff

[PATCH] D100798: [clangd][ObjC] Fix issue completing a method decl by name

2021-06-01 Thread David Goldman via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. dgoldman marked an inline comment as done. Closed by commit rG2a030e680e08: [clangd][ObjC] Fix issue completing a method decl by name (authored by dgoldman). Repositor

[PATCH] D103472: [clang] Fix a crash during code completion

2021-06-01 Thread Adam Czachorowski via Phabricator via cfe-commits
adamcz created this revision. adamcz requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. During code completion, lookupInDeclContext() calls CodeCompletionDeclConsumer::FoundDecl(),which can mutate StoredDeclsMap, over which lookupInDeclContext

[PATCH] D103472: [clang] Fix a crash during code completion

2021-06-01 Thread Adam Czachorowski via Phabricator via cfe-commits
adamcz added a reviewer: kadircet. adamcz added a comment. This is https://github.com/clangd/clangd/issues/771 Sending for review mostly to see if you have any comments on this approach. Trying to reproduce this without , or something like this didn't work for me so far, I must be holding it w

[clang] baa2b8d - Fix a git apply that went bad somehow.

2021-06-01 Thread Aaron Ballman via cfe-commits
Author: Aaron Ballman Date: 2021-06-01T14:06:39-04:00 New Revision: baa2b8d08502acfa91a8dfd699d25f7b4e25edbb URL: https://github.com/llvm/llvm-project/commit/baa2b8d08502acfa91a8dfd699d25f7b4e25edbb DIFF: https://github.com/llvm/llvm-project/commit/baa2b8d08502acfa91a8dfd699d25f7b4e25edbb.diff

[PATCH] D101192: Add support for #elifdef and #elifndef

2021-06-01 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/lib/Lex/PPDirectives.cpp:594 +if (CondInfo.FoundElse) + Diag(Tok, diag::pp_err_elif_after_else) << PED_Elif; bjope wrote: > Hi @aaron.ballman > > This change is missing from > https://re

[PATCH] D103401: [OpenCL] Add support of __opencl_c_generic_address_space feature macro

2021-06-01 Thread Anton Zabaznov via Phabricator via cfe-commits
azabaznov added inline comments. Comment at: clang/lib/Basic/TargetInfo.cpp:405 + const auto &OpenCLFeaturesMap = getSupportedOpenCLOpts(); + Opts.OpenCLGenericAddressSpace = hasFeatureEnabled( + OpenCLFeaturesMap, "__opencl_c_generic_address_space"); -

[PATCH] D103476: [clangd] TUScheduler uses last active file for file-less queries

2021-06-01 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet created this revision. kadircet added a reviewer: sammccall. Herald added subscribers: usaxena95, jfb, arphaman, javed.absar. kadircet requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang-tools-extra. This enables

[PATCH] D103195: Add matchers for gtest's ASSERT_THAT, EXPECT_THAT, ON_CALL and EXPECT_CALL

2021-06-01 Thread Zhaomo Yang via Phabricator via cfe-commits
zhaomo updated this revision to Diff 349030. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103195/new/ https://reviews.llvm.org/D103195 Files: clang/include/clang/ASTMatchers/GtestMatchers.h clang/lib/ASTMatchers/GtestMatchers.cpp clang/unittests/ASTMatchers/GtestMatchersTest.cpp

[PATCH] D103477: [Fuchsia] Add compat multilibs to cache file

2021-06-01 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan created this revision. leonardchan added reviewers: phosek, mcgrathr. leonardchan added a project: clang. Herald added a subscriber: mgorny. leonardchan requested review of this revision. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D103477 Files: clang/cmake/cach

[PATCH] D101192: Add support for #elifdef and #elifndef

2021-06-01 Thread Bjorn Pettersson via Phabricator via cfe-commits
bjope added inline comments. Comment at: clang/lib/Lex/PPDirectives.cpp:594 +if (CondInfo.FoundElse) + Diag(Tok, diag::pp_err_elif_after_else) << PED_Elif; aaron.ballman wrote: > bjope wrote: > > Hi @aaron.ballman > > > > This change is missi

[PATCH] D101645: [clang] RecursiveASTVisitor visits ObjCPropertyRefExpr's class receiver

2021-06-01 Thread David Goldman via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG13a8aa3ee15a: [clang] RecursiveASTVisitor visits ObjCPropertyRefExpr's class receiver (authored by dgoldman). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D1

[clang] 13a8aa3 - [clang] RecursiveASTVisitor visits ObjCPropertyRefExpr's class receiver

2021-06-01 Thread David Goldman via cfe-commits
Author: David Goldman Date: 2021-06-01T14:45:25-04:00 New Revision: 13a8aa3ee15a67048deeb193fe8b86005fdf9d10 URL: https://github.com/llvm/llvm-project/commit/13a8aa3ee15a67048deeb193fe8b86005fdf9d10 DIFF: https://github.com/llvm/llvm-project/commit/13a8aa3ee15a67048deeb193fe8b86005fdf9d10.diff

[PATCH] D101192: Add support for #elifdef and #elifndef

2021-06-01 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/lib/Lex/PPDirectives.cpp:594 +if (CondInfo.FoundElse) + Diag(Tok, diag::pp_err_elif_after_else) << PED_Elif; bjope wrote: > aaron.ballman wrote: > > bjope wrote: > > > Hi @aaron.ballman >

[PATCH] D100276: [clang] p1099 3/5: using Enum::member

2021-06-01 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 349044. urnathan added a comment. Rebase and fix conflict CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100276/new/ https://reviews.llvm.org/D100276 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/include/clang/Sema/Sema.h clan

[PATCH] D102241: [clang] p1099 4/5: using enum EnumTag

2021-06-01 Thread Nathan Sidwell via Phabricator via cfe-commits
urnathan updated this revision to Diff 349045. urnathan added a comment. rebase and fix conflict CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102241/new/ https://reviews.llvm.org/D102241 Files: clang-tools-extra/clangd/FindTarget.cpp clang/include/clang/AST/ASTContext.h clang/in

[PATCH] D101630: [HIP] Fix device-only compilation

2021-06-01 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In D101630#2787714 , @yaxunl wrote: > How does nvcc --genco behave when there are multiple GPU arch's? Does it > output a fat binary containing multiple ISA's? Also, does it support > device-only compilation for intermediate outputs

[PATCH] D102923: [clang][lex] Remark for used header search paths

2021-06-01 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added inline comments. Comment at: clang/include/clang/Basic/DiagnosticLexKinds.td:427 +def remark_pp_include_header_search_usage : Remark< + "user-provided search path used: '%0'">, + InGroup>; jansvoboda11 wrote: > dexonsmith wrote: > > I suggest,

  1   2   >