[PATCH] D139705: [clang] fix zero-initialization fix-it for variable template

2023-03-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D139705#4216449 , @tomasz-kaminski-sonarsource wrote: > In D139705#4216417 , @erichkeane > wrote: > >> In D139705#4215653 , >> @tomasz

[PATCH] D139705: [clang] fix zero-initialization fix-it for variable template

2023-03-23 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. In D139705#4216480 , @aaron.ballman wrote: > In D139705#4216449 , > @tomasz-kaminski-sonarsource wrote: > >> In D139705#4216417 , @erichkeane

[PATCH] D146701: [AMDGPU] Create Subtarget Features for some of 16 bits atomic fadd instructions

2023-03-23 Thread Jay Foad via Phabricator via cfe-commits
foad added inline comments. Comment at: llvm/lib/Target/AMDGPU/BUFInstructions.td:2891 +let SubtargetPredicate = HasAtomicFaddNoRtnInsts in { +defm BUFFER_ATOMIC_ADD_F32: MUBUF_Real_Atomic_vi <0x4d>; Is this still required? Comment at: ll

[PATCH] D146719: [Clang] Improve diagnostics when using a concept as template argument

2023-03-23 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added inline comments. Comment at: clang/test/Parser/cxx-template-template-recovery.cpp:27 + +static_assert(test); //expected-error {{too few template arguments for concept 'C1'}} +static_assert(test); //expected-error {{too few template arguments for concept 'C2'}} --

[PATCH] D139705: [clang] fix zero-initialization fix-it for variable template

2023-03-23 Thread Tomasz Kamiński via Phabricator via cfe-commits
tomasz-kaminski-sonarsource added a comment. > Since the motivation for this patch here was "make sure we're pointing to the > 'end' so we can suggest an init fixit", perhaps this SHOULD be changed to the > 'end' still, but just fix the case where the initializer was omitted. So > > /// What

[PATCH] D125171: Add a new clang-format option AlwaysBreakBeforeFunctionParameters

2023-03-23 Thread jonathan molinatto via Phabricator via cfe-commits
jrmolin added a comment. In D125171#4215910 , @MyDeveloperDay wrote: > if you go ahead an rebase your should get rG7a5b95732ade: [clang-format] NFC > Format.h and ClangFormatStyleOptions.rst are out of date >

[PATCH] D146557: [MLIR][OpenMP] Refactoring how map clause is processed

2023-03-23 Thread Akash Banerjee via Phabricator via cfe-commits
TIFitis marked 2 inline comments as done. TIFitis added inline comments. Comment at: llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp:4064-4077 +Value *BaseGEPPtr = Builder.CreateInBoundsGEP( +ArrI8PtrTy, MapperAllocas.ArgsBase, +{Builder.getInt32(0), Builder.getInt3

[PATCH] D139705: [clang] fix zero-initialization fix-it for variable template

2023-03-23 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. In D139705#4216530 , @tomasz-kaminski-sonarsource wrote: >> Since the motivation for this patch here was "make sure we're pointing to >> the 'end' so we can suggest an init fixit", perhaps this SHOULD be changed >> to the 'e

[PATCH] D146713: [clang-tidy][NFC] Improve naming convention in google-readability-avoid-underscore-in-googletest-name

2023-03-23 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko accepted this revision. Eugene.Zelenko added a comment. This revision is now accepted and ready to land. But will be good idea to give a chance to other reviewers to take a look. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146713/ne

[PATCH] D146655: [clang-tidy] Ignore DISABLED_ in test suite name in google-avoid-underscore-in-googletest-name

2023-03-23 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tools-extra/docs/ReleaseNotes.rst:237 +- Fixed an issue in :doc:`google-avoid-underscore-in-googletest-name + ` when using carlosgalvezp wrote: > PiotrZSL wrote: > > carlosgalvezp wrote: > > > Eugene.Zele

[PATCH] D139705: [clang] fix zero-initialization fix-it for variable template

2023-03-23 Thread Vincent Hong via Phabricator via cfe-commits
v1nh1shungry added a comment. In D139705#4216539 , @erichkeane wrote: > In D139705#4216530 , > @tomasz-kaminski-sonarsource wrote: > >>> Since the motivation for this patch here was "make sure we're pointing to

[clang] 0eabf59 - Enable constexpr class members that are device-mapped to not be optimized out.

2023-03-23 Thread Doru Bercea via cfe-commits
Author: Doru Bercea Date: 2023-03-23T10:17:25-04:00 New Revision: 0eabf59528f3c3f64923900cae740d9f26c45ae8 URL: https://github.com/llvm/llvm-project/commit/0eabf59528f3c3f64923900cae740d9f26c45ae8 DIFF: https://github.com/llvm/llvm-project/commit/0eabf59528f3c3f64923900cae740d9f26c45ae8.diff L

[PATCH] D145201: [clang] fixes header processing for `-fdiagnostics-format=sarif`

2023-03-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D145201#4214395 , @cjdb wrote: > swaps commits to see if that fixes CI (part 1) Oh, if this is just stacked patches confusing our precommit CI, then it's okay. I hadn't realized this was a stacked patch. Repository:

[PATCH] D146338: [MSVC compatibility][dllimport/dllexport][PS] Allow dllexport/dllimport for classes with UniqueExternalLinkage

2023-03-23 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Thanks, I like this. Could you please also add tests in CodeGenCXX/dll{ex,im}port.cpp which verify that the IR looks right? Comment at: clang/test/SemaCXX/dllexport.cpp:437 +class Base {}; +class __declspec(dllexport) ExportedClass {};

[PATCH] D146552: [Clang][OpenMP] Enable device-mapped constexpr class members to not be optimized out

2023-03-23 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
doru1004 closed this revision. doru1004 added a comment. Commit: 0eabf59528f3c3f64923900cae740d9f26c45ae8 CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146552/new/ https://reviews.llvm.org/D146552 __

[PATCH] D145201: [clang] fixes header processing for `-fdiagnostics-format=sarif`

2023-03-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM aside from a tiny variable naming nit I missed before. Comment at: clang/lib/Basic/Sarif.cpp:314-317 + llvm::sort(*Artifacts, [](const json::Value &x, con

[PATCH] D146655: [clang-tidy] Ignore DISABLED_ in test suite name in google-avoid-underscore-in-googletest-name

2023-03-23 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tools-extra/docs/ReleaseNotes.rst:237 +- Fixed an issue in :doc:`google-avoid-underscore-in-googletest-name + ` when using Eugene.Zelenko wrote: > carlosgalvezp wrote: > > PiotrZSL wrote: > > > carlosgalv

[PATCH] D146234: [clang] Fix crash when handling nested immediate invocations

2023-03-23 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added a comment. Sorry for the late review. I think this makes sense generally, i just have one question Comment at: clang/lib/Sema/SemaExpr.cpp:17979 + if (Rec.ImmediateInvocationCandidates.size() > 1 || + SemaRef.FailedImmediateInvocations.size()) { -

[PATCH] D146712: [clang-tidy] Add portability-non-portable-integer-constant check

2023-03-23 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added a comment. Please add alias entry in Release Notes. Comment at: clang-tools-extra/clang-tidy/portability/NonPortableIntegerConstantCheck.cpp:95 + + +void NonPortableIntegerConstantCheck::check( Excessive newline. Comment

[PATCH] D146686: [Driver] Fix rpath for compiler-rt

2023-03-23 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added a comment. In D146686#4215577 , @MaskRay wrote: > This change is correct for Linux. `llvm/CMakeLists.txt` says: > > if(CMAKE_SYSTEM_NAME MATCHES "BSD|Linux|OS390") > set(LLVM_ENABLE_PER_TARGET_RUNTIME_DIR_default ON) > > Some rpath usin

[PATCH] D146538: [analyzer] Fix crashing getSValFromInitListExpr for nested initlists

2023-03-23 Thread Balázs Benics via Phabricator via cfe-commits
steakhal added a comment. This has been backported to clang-16.0.1 as 1172ed57d8234990b277281b3084969fcdb38602 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146

[PATCH] D146701: [AMDGPU] Create Subtarget Features for some of 16 bits atomic fadd instructions

2023-03-23 Thread Mariusz Sikora via Phabricator via cfe-commits
mariusz-sikora-at-amd added inline comments. Comment at: llvm/lib/Target/AMDGPU/FLATInstructions.td:1915 +defm GLOBAL_ATOMIC_PK_ADD_F16 : FLAT_Global_Real_Atomics_vi <0x04e, 0>; +defm GLOBAL_ATOMIC_PK_ADD_BF16 : FLAT_Global_Real_Atomics_vi<0x52>; foad wrote: >

[PATCH] D146075: [flang][driver][openmp] Write MLIR for -save-temps

2023-03-23 Thread Greg Rodgers via Phabricator via cfe-commits
gregrodgers accepted this revision. gregrodgers added a comment. This looks good. Please merge. I found it very useful especially in the context of other generated temp files generated after llvm llinking and optimization in the offload driver. For example just listing the temp files with ls

[PATCH] D146701: [AMDGPU] Create Subtarget Features for some of 16 bits atomic fadd instructions

2023-03-23 Thread Mariusz Sikora via Phabricator via cfe-commits
mariusz-sikora-at-amd added inline comments. Comment at: llvm/lib/Target/AMDGPU/BUFInstructions.td:2891 +let SubtargetPredicate = HasAtomicFaddNoRtnInsts in { +defm BUFFER_ATOMIC_ADD_F32: MUBUF_Real_Atomic_vi <0x4d>; foad wrote: > Is this still required? No

[PATCH] D144190: [AIX][clang] Storage Locations for Constant Pointers

2023-03-23 Thread Qiongsi Wu via Phabricator via cfe-commits
qiongsiwu1 added inline comments. Comment at: clang/test/Driver/ppc-roptr.c:21 +// RUN: FileCheck %s --check-prefix=ROPTR +// RUN: %clang -### -target powerpc64-ibm-aix-xcoff -S -mroptr %s 2>&1 | \ +// RUN: FileCheck %s --check-prefix=ROPTR MaskRay wrote:

[PATCH] D146535: [Clang] Fix evaluation of parameters of lambda call operator attributes

2023-03-23 Thread Elizabeth Andrews via Phabricator via cfe-commits
eandrews added a comment. Can we merge this patch? It will fix regressions introduced by D124351 I see downstream Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146535/new/ https://reviews.llvm.org/D146535 __

[PATCH] D146671: [clang][ExtractAPI]Fix Declaration fragments for instancetype in the type position degrade to id

2023-03-23 Thread NagaChaitanya Vellanki via Phabricator via cfe-commits
chaitanyav added a comment. @dang Please review the test/output. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146671/new/ https://reviews.llvm.org/D146671 ___ cfe-commits mailing list cfe-commits@lists.

[clang] 82c83d7 - [Clang] Fix evaluation of parameters of lambda call operator attributes

2023-03-23 Thread Corentin Jabot via cfe-commits
Author: Corentin Jabot Date: 2023-03-23T16:11:58+01:00 New Revision: 82c83d7e41053b72fc0dc84de9b8bee71986ffc3 URL: https://github.com/llvm/llvm-project/commit/82c83d7e41053b72fc0dc84de9b8bee71986ffc3 DIFF: https://github.com/llvm/llvm-project/commit/82c83d7e41053b72fc0dc84de9b8bee71986ffc3.diff

[PATCH] D146535: [Clang] Fix evaluation of parameters of lambda call operator attributes

2023-03-23 Thread Corentin Jabot 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 rG82c83d7e4105: [Clang] Fix evaluation of parameters of lambda call operator attributes (authored by cor3ntin). Repository: rG LLVM Github Monorepo

[PATCH] D146671: [clang][ExtractAPI]Fix Declaration fragments for instancetype in the type position degrade to id

2023-03-23 Thread Daniel Grumberg via Phabricator via cfe-commits
dang accepted this revision. dang added a comment. Yup looks fine to me! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146671/new/ https://reviews.llvm.org/D146671 ___ cfe-commits mailing list cfe-commit

[PATCH] D146535: [Clang] Fix evaluation of parameters of lambda call operator attributes

2023-03-23 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added a comment. Sure! I didn't land it sooner because the bots were down. but apparently they were up quite fast. Thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146535/new/ https://reviews.llvm.org/D146535 ___

[PATCH] D146727: [clangd] Use expansion location for missing include diagnostics.

2023-03-23 Thread Viktoriia Bakalova via Phabricator via cfe-commits
VitaNuo created this revision. Herald added subscribers: kadircet, arphaman. Herald added a project: All. VitaNuo requested review of this revision. Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov. Herald added a project: clang-tools-extra. Repository: rG LLVM Github Monorepo http

[PATCH] D146727: [clangd] Use expansion location for missing include diagnostics.

2023-03-23 Thread Viktoriia Bakalova via Phabricator via cfe-commits
VitaNuo updated this revision to Diff 507748. VitaNuo added a comment. Remove unrelated diff. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146727/new/ https://reviews.llvm.org/D146727 Files: clang-tools-extra/clangd/IncludeCleaner.cpp clang-t

[PATCH] D146712: [clang-tidy] Add portability-non-portable-integer-constant check

2023-03-23 Thread Piotr Zegar via Phabricator via cfe-commits
PiotrZSL added inline comments. Comment at: clang-tools-extra/clang-tidy/portability/NonPortableIntegerConstantCheck.cpp:92 +void NonPortableIntegerConstantCheck::registerMatchers(MatchFinder *Finder) { + Finder->addMatcher(integerLiteral().bind("integer"), this); +} --

[PATCH] D146713: [clang-tidy][NFC] Improve naming convention in google-readability-avoid-underscore-in-googletest-name

2023-03-23 Thread Piotr Zegar via Phabricator via cfe-commits
PiotrZSL accepted this revision. PiotrZSL added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/google/avoid-underscore-in-googletest-name.cpp:10 TEST(TestCaseName, Illegal_TestName) {} // CHECK-MESSAGES: :[[@LINE-1]]:20: warning: avoid using "_" in t

[PATCH] D146503: Fix highlighting issue with _complex and initialization list with more than 2 items

2023-03-23 Thread NagaChaitanya Vellanki via Phabricator via cfe-commits
chaitanyav updated this revision to Diff 507750. chaitanyav marked an inline comment as not done. chaitanyav added a comment. one diagnostic per line when there are multiple diagnostics expected Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146503/n

[PATCH] D145868: [clang][ASTImporter] Fix import of anonymous structures

2023-03-23 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. In D145868#4189574 , @vabridgers wrote: > Hi @balazske , all LIT and unittests pass with this change. By your logic, > then we are missing some LIT or unittest cases that support your statement. > Can you think of a case that

[PATCH] D143592: [flang][driver] Rename `flang-new -flang-experimental-exec` to `flang`

2023-03-23 Thread Brad Richardson via Phabricator via cfe-commits
everythingfunctional updated this revision to Diff 507754. everythingfunctional added a comment. Update with main to see if tests have been fixed. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D143592/new/ https://reviews.llvm.org/D143592 Files: clang/include/clang/Driver/Options.td

[PATCH] D144651: [Serialization] Place command line defines in the correct file

2023-03-23 Thread Felipe de Azevedo Piovezan via Phabricator via cfe-commits
fdeazeve added a comment. > It looks like green.lab.llvm.org is down, so can't look at that log, but > doing a local build and test of lldb (on a macbook, as this test is only > enabled on macos) I don't see this failure, or any other tests failing with > this assertion. It should be back onli

[PATCH] D146549: [OpenMP][OMPIRBuilder] Make OffloadEntriesInfoManager a member of OpenMPIRBuilder

2023-03-23 Thread Jan Sjödin via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG85faee69928b: [OpenMP][OMPIRBuilder] Make OffloadEntriesInfoManager a member of… (authored by jsjodin). Herald added a project: clang. Herald added a subscriber: cfe-commits. Changed prior to commit: ht

[clang] 85faee6 - [OpenMP][OMPIRBuilder] Make OffloadEntriesInfoManager a member of OpenMPIRBuilder

2023-03-23 Thread Jan Sjodin via cfe-commits
Author: Jan Sjodin Date: 2023-03-23T11:46:28-04:00 New Revision: 85faee69928b1eeb74a0d74f374a1c74ddf236dd URL: https://github.com/llvm/llvm-project/commit/85faee69928b1eeb74a0d74f374a1c74ddf236dd DIFF: https://github.com/llvm/llvm-project/commit/85faee69928b1eeb74a0d74f374a1c74ddf236dd.diff LO

[PATCH] D145201: [clang] fixes header processing for `-fdiagnostics-format=sarif`

2023-03-23 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D145201#4216567 , @aaron.ballman wrote: > In D145201#4214395 , @cjdb wrote: > >> swaps commits to see if that fixes CI (part 1) > > Oh, if this is just stacked patches confusing our preco

[PATCH] D146075: [flang][driver][openmp] Write MLIR for -save-temps

2023-03-23 Thread Sergio Afonso via Phabricator via cfe-commits
skatrak added a comment. @awarzynski, can you confirm whether your concerns have been addressed? Thank you! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146075/new/ https://reviews.llvm.org/D146075 ___

[PATCH] D128501: [CodeGen] Make uninitialized Lvalue bit-field stores poison compatible

2023-03-23 Thread John McIver via Phabricator via cfe-commits
jmciver closed this revision. jmciver added a comment. I am closing this ticket as we are working on alternative solutions to poison based load semantics . Thanks to everyone for taking the time to discuss t

[clang-tools-extra] 2bececb - [clangd] Add provider info on symbol hover.

2023-03-23 Thread Viktoriia Bakalova via cfe-commits
Author: Viktoriia Bakalova Date: 2023-03-23T16:21:51Z New Revision: 2bececb8bed1f8fcd8d54dba831ceb117717bfcc URL: https://github.com/llvm/llvm-project/commit/2bececb8bed1f8fcd8d54dba831ceb117717bfcc DIFF: https://github.com/llvm/llvm-project/commit/2bececb8bed1f8fcd8d54dba831ceb117717bfcc.diff

[PATCH] D144976: [clangd] Add provider info on symbol hover.

2023-03-23 Thread Viktoriia Bakalova via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. VitaNuo marked 3 inline comments as done. Closed by commit rG2bececb8bed1: [clangd] Add provider info on symbol hover. (authored by VitaNuo). Changed prior to commit: https://reviews.llvm.org/D144976?vs=507034&id=507764#t

[PATCH] D146686: [Driver] Fix rpath for compiler-rt

2023-03-23 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. In D146686#4216612 , @yaxunl wrote: > In D146686#4215577 , @MaskRay wrote: > >> This change is correct for Linux. `llvm/CMakeLists.txt` says: >> >> if(CMAKE_SYSTEM_NAME MATCHES "BSD|Linu

[PATCH] D146713: [clang-tidy][NFC] Improve naming convention in google-readability-avoid-underscore-in-googletest-name

2023-03-23 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp updated this revision to Diff 507767. carlosgalvezp added a comment. Fix missing naming convention in the test. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146713/new/ https://reviews.llvm.org/D146713 Files: clang-tools-extra/cla

[PATCH] D146713: [clang-tidy][NFC] Improve naming convention in google-readability-avoid-underscore-in-googletest-name

2023-03-23 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp marked an inline comment as done. carlosgalvezp added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/google/avoid-underscore-in-googletest-name.cpp:10 TEST(TestCaseName, Illegal_TestName) {} // CHECK-MESSAGES: :[[@LINE-1]]:20: warning:

[PATCH] D146732: [include-cleaner] Attribute references to explicit specializations

2023-03-23 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet created this revision. kadircet added a reviewer: hokein. Herald added a project: All. kadircet requested review of this revision. Herald added a project: clang-tools-extra. Herald added a subscriber: cfe-commits. Fixes https://github.com/llvm/llvm-project/issues/61652 Repository: rG

[PATCH] D146655: [clang-tidy] Ignore DISABLED_ in test suite name in google-avoid-underscore-in-googletest-name

2023-03-23 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp added inline comments. Comment at: clang-tools-extra/docs/ReleaseNotes.rst:237 +- Fixed an issue in :doc:`google-avoid-underscore-in-googletest-name + ` when using Eugene.Zelenko wrote: > Eugene.Zelenko wrote: > > carlosgalvezp wrote: > > > Piotr

[PATCH] D146733: [clang] source range of variable template specialization should include initializer

2023-03-23 Thread Tomasz Kamiński via Phabricator via cfe-commits
tomasz-kaminski-sonarsource created this revision. Herald added a project: All. tomasz-kaminski-sonarsource requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch adjust the getSourceRange() for the VarTemplateSpecializationDecl and Var

[PATCH] D129542: [CodeGen] Add codegen of IR function attribute fine_grained_bitfields

2023-03-23 Thread John McIver via Phabricator via cfe-commits
jmciver abandoned this revision. jmciver added a comment. I am closing this ticket as we are working on alternative solutions to poison based load semantics . Thanks to everyone for taking the time to discus

[PATCH] D146717: [clangd] Handle the C++2b elifdef and elindef PP structure in CollectMainFileMacros.

2023-03-23 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet added a comment. thanks, LG apart from the using decls Comment at: clang-tools-extra/clangd/CollectMacros.h:69 const MacroDefinition &MD) override; + using PPCallbacks::Elifdef; + using PPCallbacks::Elifndef; why do we have these using

[PATCH] D139705: [clang] fix zero-initialization fix-it for variable template

2023-03-23 Thread Tomasz Kamiński via Phabricator via cfe-commits
tomasz-kaminski-sonarsource added a comment. >> Indeed, this would address our concern, and allow properly inserting >> initializer. This would build down to repeating the condition from here: >> https://github.com/llvm/llvm-project/blob/bbe1394c9602ab9a939d9b17199d5f538cac9d0c/clang/lib/AST/Dec

[PATCH] D146733: [clang] source range of variable template specialization should include initializer

2023-03-23 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. This needs a test and a release note. Patch otherwise looks fine to me. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146733/new/ https://reviews.llvm.org/D146733 ___ cfe-com

[PATCH] D146234: [clang] Fix crash when handling nested immediate invocations

2023-03-23 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon added inline comments. Comment at: clang/lib/Sema/SemaExpr.cpp:17979 + if (Rec.ImmediateInvocationCandidates.size() > 1 || + SemaRef.FailedImmediateInvocations.size()) { cor3ntin wrote: > Shouln't we clear `FailedImmediateInvocations` at the end

[PATCH] D146733: [clang] source range of variable template specialization should include initializer

2023-03-23 Thread Tomasz Kamiński via Phabricator via cfe-commits
tomasz-kaminski-sonarsource updated this revision to Diff 507776. tomasz-kaminski-sonarsource added a comment. Comments no longer misleading reffer to fallback to DeclatorDecl Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146733/new/ https://review

[PATCH] D146733: [clang] source range of variable template specialization should include initializer

2023-03-23 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added inline comments. Comment at: clang/lib/AST/DeclTemplate.cpp:1467 +SourceRange VarTemplatePartialSpecializationDecl::getSourceRange() const { + if (const Expr *Init = getInit()) { +SourceLocation InitEnd = Init->getEndLoc(); Looking closer...

[PATCH] D146701: [AMDGPU] Create Subtarget Features for some of 16 bits atomic fadd instructions

2023-03-23 Thread Jay Foad via Phabricator via cfe-commits
foad added inline comments. Comment at: llvm/lib/Target/AMDGPU/BUFInstructions.td:2891 +let SubtargetPredicate = HasAtomicFaddNoRtnInsts in { +defm BUFFER_ATOMIC_ADD_F32: MUBUF_Real_Atomic_vi <0x4d>; mariusz-sikora-at-amd wrote: > foad wrote: > > Is this st

[PATCH] D146733: [clang] source range of variable template specialization should include initializer

2023-03-23 Thread Tomasz Kamiński via Phabricator via cfe-commits
tomasz-kaminski-sonarsource added a comment. In D146733#4216931 , @erichkeane wrote: > This needs a test and a release note. Patch otherwise looks fine to me. Do you have any pointers for a test of source ranges? The patch that caused regression used

[PATCH] D146733: [clang] source range of variable template specialization should include initializer

2023-03-23 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. Just noticed your commit-notice reference to the 'breaking' change is incorrect, should be: https://reviews.llvm.org/D139705 As for the test, an AST-Dump test has the line/column info in it, so that should be a good enough test. Repository: rG LLVM Github Monore

[PATCH] D146733: [clang] source range of variable template specialization should include initializer

2023-03-23 Thread Tomasz Kamiński via Phabricator via cfe-commits
tomasz-kaminski-sonarsource updated this revision to Diff 507784. tomasz-kaminski-sonarsource edited the summary of this revision. tomasz-kaminski-sonarsource added a comment. Simpified condition Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146733/

[PATCH] D146733: [clang] source range of variable template specialization should include initializer

2023-03-23 Thread Tomasz Kamiński via Phabricator via cfe-commits
tomasz-kaminski-sonarsource added a comment. I have updated the description and implementation. Will look at adding a unit test tomorrow. Comment at: clang/lib/AST/DeclTemplate.cpp:1467 +SourceRange VarTemplatePartialSpecializationDecl::getSourceRange() const { + if (const Ex

[PATCH] D144190: [AIX][clang] Storage Locations for Constant Pointers

2023-03-23 Thread Qiongsi Wu via Phabricator via cfe-commits
qiongsiwu1 updated this revision to Diff 507752. qiongsiwu1 added a comment. Address code review. Thanks for your comments/suggestions @MaskRay !! - Fixing comments. - Using `--target=` in tests. - Reducing number of RUN lines in tests. @hubert.reinterpretcast I ended up having a mix of tests fo

[PATCH] D146466: [clang] diagnose function fallthrough

2023-03-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D146466#4213814 , @nickdesaulniers wrote: > In D146466#4210607 , @aaron.ballman > wrote: > >> In D146466#4208216 , @dblaikie >> wrote:

[PATCH] D146715: [NVPTX] Enforce half type support is present for builtins

2023-03-23 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: clang/lib/CodeGen/CGBuiltin.cpp:18912 + case NVPTX::BI__nvvm_ldu_h2: { +return MakeHalfType(BuiltinID, E, *this); + } We seem to be checking builtin IDs twice. Once here and then in MakeHalfType where we need to map t

[PATCH] D146603: [docs] Document -fomit-frame-pointer

2023-03-23 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 507792. MaskRay added a comment. Adjust some terms. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146603/new/ https://reviews.llvm.org/D146603 Files: clang/include/clang/Driver/Options.td Index: clang/incl

[PATCH] D146244: [clangd] Show used symbols on #include line hover.

2023-03-23 Thread Viktoriia Bakalova via Phabricator via cfe-commits
VitaNuo updated this revision to Diff 507793. VitaNuo marked 5 inline comments as done. VitaNuo added a comment. Address review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146244/new/ https://reviews.llvm.org/D146244 Files: clang-too

[PATCH] D146603: [docs] Document -fomit-frame-pointer

2023-03-23 Thread Fangrui Song via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. MaskRay marked 2 inline comments as done. Closed by commit rG5f883cdbfbe2: [docs] Document -fomit-frame-pointer (authored by MaskRay). Changed prior to commit: https

[clang] 5f883cd - [docs] Document -fomit-frame-pointer

2023-03-23 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2023-03-23T10:19:10-07:00 New Revision: 5f883cdbfbe216ec184194114676075f3633e08b URL: https://github.com/llvm/llvm-project/commit/5f883cdbfbe216ec184194114676075f3633e08b DIFF: https://github.com/llvm/llvm-project/commit/5f883cdbfbe216ec184194114676075f3633e08b.diff

[PATCH] D146244: [clangd] Show used symbols on #include line hover.

2023-03-23 Thread Viktoriia Bakalova via Phabricator via cfe-commits
VitaNuo marked an inline comment as done. VitaNuo added a comment. Thanks for the comments! Comment at: clang-tools-extra/clangd/Hover.cpp:1172 +include_cleaner::Includes ConvertedIncludes = +convertIncludes(SM, llvm::ArrayRef{Inc}); +for (const incl

[PATCH] D146655: [clang-tidy] Ignore DISABLED_ in test suite name in google-avoid-underscore-in-googletest-name

2023-03-23 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tools-extra/docs/ReleaseNotes.rst:237 +- Fixed an issue in :doc:`google-avoid-underscore-in-googletest-name + ` when using carlosgalvezp wrote: > Eugene.Zelenko wrote: > > Eugene.Zelenko wrote: > > > carl

[clang-tools-extra] 40e5d21 - [clangd] Fix indentation in HoverTests.cpp

2023-03-23 Thread Viktoriia Bakalova via cfe-commits
Author: Viktoriia Bakalova Date: 2023-03-23T17:27:10Z New Revision: 40e5d212cffd2b87f688dd441cd7c7f4084d407d URL: https://github.com/llvm/llvm-project/commit/40e5d212cffd2b87f688dd441cd7c7f4084d407d DIFF: https://github.com/llvm/llvm-project/commit/40e5d212cffd2b87f688dd441cd7c7f4084d407d.diff

[PATCH] D145642: [clang-format] Annotate lambdas with requires clauses.

2023-03-23 Thread Emilia Dreamer via Phabricator via cfe-commits
rymiel added a comment. So, it took me a while but I finally found where the logic is that makes the lambda braces stay on one line, but, now I'm not so sure if I should change it: The thing I wanted to avoid was cases like [&](T&& t) requires T { t; }; Simply because "those braces don't

[PATCH] D146408: [clang][Interp] Start supporting complex types

2023-03-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/lib/AST/Interp/ByteCodeExprGen.cpp:1595 +return true; + } else if (const auto *CE = dyn_cast(Initializer)) { +if (!this->emitDupPtr(Initializer)) Member calls as well? Comment at:

[PATCH] D146463: [CodeGen][RISCV] Change Shadow Call Stack Register to S11

2023-03-23 Thread Paul Kirth via Phabricator via cfe-commits
paulkirth updated this revision to Diff 507801. paulkirth added a comment. Address comments. - Remove `.` from warning message - use `;;` prefix in test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146463/new/ https://reviews.llvm.org/D146463 Fi

[PATCH] D76547: [WebAssembly] Add wasm-exported function attribute

2023-03-23 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 updated this revision to Diff 507802. sbc100 added a comment. Herald added a reviewer: aaron.ballman. Herald added subscribers: llvm-commits, pmatos, asb, wingo, ecnelises. Herald added projects: LLVM, All. - rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https:

[PATCH] D146463: [CodeGen][RISCV] Change Shadow Call Stack Register to S11

2023-03-23 Thread Paul Kirth via Phabricator via cfe-commits
paulkirth added a comment. ugh. I accidentally commited some temporary work here. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146463/new/ https://reviews.llvm.org/D146463 ___ cfe-commits mailing list c

[PATCH] D76547: [WebAssembly] Add wasm-exported function attribute

2023-03-23 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 added a comment. In D76547#1945094 , @sbc100 wrote: > What about your idea of using the `default` keyword rather than adding a new > clang attr? I quite liked that approach. IIRC I tried this approach but wan't able to make it works since a singl

[clang] c70e360 - [clang-format] Allow trailing return types in macros

2023-03-23 Thread Emilia Dreamer via cfe-commits
Author: Emilia Dreamer Date: 2023-03-23T19:37:53+02:00 New Revision: c70e360b355ad30a7dd299435aae0324c5033b3f URL: https://github.com/llvm/llvm-project/commit/c70e360b355ad30a7dd299435aae0324c5033b3f DIFF: https://github.com/llvm/llvm-project/commit/c70e360b355ad30a7dd299435aae0324c5033b3f.diff

[PATCH] D141811: [clang-format] Allow trailing return types in macros

2023-03-23 Thread Emilia Dreamer 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 rGc70e360b355a: [clang-format] Allow trailing return types in macros (authored by rymiel). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST A

[PATCH] D146463: [CodeGen][RISCV] Change Shadow Call Stack Register to S11

2023-03-23 Thread Paul Kirth via Phabricator via cfe-commits
paulkirth updated this revision to Diff 507805. paulkirth added a comment. Remove unrelated changes, due to bad commit. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146463/new/ https://reviews.llvm.org/D146463 Files: clang/lib/Driver/SanitizerA

[PATCH] D138247: PR58819: Correct linkage and mangling of lambdas in inline static member initializers

2023-03-23 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. The relevant text of the current Itanium ABI (which was updated in https://github.com/itanium-cxx-abi/cxx-abi/commit/d8e9d102c83f177970f0db6cc8bee170f2779bc1) > In the following contexts, however, the one-definition rule requires closure > types in different translatio

[PATCH] D76547: [WebAssembly] Add `wasm-exported` function attribute

2023-03-23 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 updated this revision to Diff 507807. sbc100 added a comment. - update test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D76547/new/ https://reviews.llvm.org/D76547 Files: clang/include/clang/Basic/Attr.td clang/include/clang/Basic/Attr

[PATCH] D146463: [CodeGen][RISCV] Change Shadow Call Stack Register to S11

2023-03-23 Thread Paul Kirth via Phabricator via cfe-commits
paulkirth updated this revision to Diff 507811. paulkirth added a comment. Restore check lines in test. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146463/new/ https://reviews.llvm.org/D146463 Files: clang/lib/Driver/SanitizerArgs.cpp compil

[PATCH] D146466: [clang] diagnose function fallthrough

2023-03-23 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added a comment. In D146466#4214770 , @efriedma wrote: >> Note how __ubsan_handle_out_of_bounds is literally marked RECOVERABLE in >> https://github.com/llvm/llvm-project/blob/fb8d894f23c5e805f0c87d89fb9d6c0eed3a0e72/compiler-rt/lib/ubsan

[PATCH] D145841: [clang][Interp] Fix diagnostics for calling non-constexpr constructors

2023-03-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM Comment at: clang/test/AST/Interp/records.cpp:353 struct YetAnotherDerived : YetAnotherBase { -using YetAnotherBase::YetAnotherBase; //ref-note {{de

[PATCH] D145803: [clang][DebugInfo] Emit DW_AT_type of preferred name if available

2023-03-23 Thread Michael Buch via Phabricator via cfe-commits
Michael137 added inline comments. Comment at: clang/lib/CodeGen/CGDebugInfo.cpp:2640 if (!D || !D->isCompleteDefinition()) -return FwdDecl; +return {FwdDecl, nullptr}; aprantl wrote: > I'm curious if this works if we encounter a forward declaration,

[PATCH] D76547: [WebAssembly] Add `wasm-exported` function attribute

2023-03-23 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 added a comment. I've limited to new attribute to only the emcripten triple. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D76547/new/ https://reviews.llvm.org/D76547 ___ cfe-commits mailing list c

[PATCH] D76547: [WebAssembly] Add `wasm-exported` function attribute

2023-03-23 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 updated this revision to Diff 507826. sbc100 edited the summary of this revision. sbc100 added a comment. - limit to emscripten Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D76547/new/ https://reviews.llvm.org/D76547 Files: clang/include/

[PATCH] D146466: [clang] diagnose function fallthrough

2023-03-23 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. There are limits to how much we can do by just changing the code clang generates... but the two particular cases you mention probably could be "fixed" by messing with the IR generated by clang. Sure, that probably makes sense to pursue. (If you're going to pick an ar

[PATCH] D146148: Float_t and double_t types shouldn't be modified by #pragma clang fp eval_method

2023-03-23 Thread Zahira Ammarguellat via Phabricator via cfe-commits
zahiraam updated this revision to Diff 507829. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146148/new/ https://reviews.llvm.org/D146148 Files: clang/docs/LanguageExtensions.rst clang/include/clang/Basic/DiagnosticSemaKinds.td clang/lib/Sema/SemaType.cpp clang/test/Sema/Inputs/m

[PATCH] D146148: Float_t and double_t types shouldn't be modified by #pragma clang fp eval_method

2023-03-23 Thread Zahira Ammarguellat via Phabricator via cfe-commits
zahiraam added a comment. In D146148#4213475 , @rjmccall wrote: > The user isn't modifying the `float_t` type definition, they're using it. I > think the diagnostic should say something like `cannot use type 'float_t' > within '#pragma clang fp eval_me

[PATCH] D76547: [WebAssembly] Add `wasm-exported` function attribute

2023-03-23 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 added a comment. I just figured out that this cannot replace the current use of `__attribute__((used))` in emscripten because function attributes only work for functions and we need this mechanism to work for global data addresses too. There is simply no way to do something like `Fn-

[PATCH] D146466: [clang] diagnose function fallthrough

2023-03-23 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added a comment. In D146466#4217363 , @efriedma wrote: > There are limits to how much we can do by just changing the code clang > generates... but the two particular cases you mention probably could be > "fixed" by messing with the IR ge

[PATCH] D145860: [clang][Interp] Fix initializing fields after base class members

2023-03-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM with a bit more testing. Comment at: clang/test/AST/Interp/cxx20.cpp:600 + + constexpr C c = {1,2,3}; +} Repository: rG LLVM Github

[PATCH] D146669: [-Wunsafe-buffer-usage] Hide fixits/suggestions behind an extra flag, -fsafe-buffer-usage-suggestions.

2023-03-23 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 added inline comments. Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:1139 UnsafeBufferUsageHandler &Handler, + bool EmitSuggestions, bool EmitFixits) { --

[PATCH] D146669: [-Wunsafe-buffer-usage] Hide fixits/suggestions behind an extra flag, -fsafe-buffer-usage-suggestions.

2023-03-23 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 added inline comments. Comment at: clang/lib/Sema/AnalysisBasedWarnings.cpp:2203 +if (IsRelatedToDecl) { + assert(!SuggestSuggestions && + "Variables blamed for unsafe buffer usage without suggestions!"); nitpick: I was a bit co

[PATCH] D146148: Float_t and double_t types shouldn't be modified by #pragma clang fp eval_method

2023-03-23 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In D146148#4217382 , @zahiraam wrote: > In D146148#4213475 , @rjmccall > wrote: > >> The user isn't modifying the `float_t` type definition, they're using it. I >> think the diagnostic

<    1   2   3   >