[clang] Bugfix for chosing the correct deduction guide (PR #66487)

2023-10-03 Thread Shafik Yaghmour via cfe-commits
@@ -85,3 +85,13 @@ int main() { } + +namespace deduceTemplatedConstructor{ shafik wrote: I apologize for asking you to do additional work here but can you add the rest of the examples from [over.match.best.general p2.13](http://eel.is/c++draft/over.match.b

[clang] [clang][RelativeVTables] Make the rtti_proxy LinkOnceODR instead of External linkage (PR #67755)

2023-10-03 Thread Petr Hosek via cfe-commits
@@ -639,8 +639,16 @@ void CodeGenVTables::addRelativeComponent(ConstantArrayBuilder &builder, // want the stub/proxy to be emitted for properly calculating the offset. // Examples where there would be no symbol emitted are available_externally // and private linkages. -

[clang] [clang][RelativeVTables] Make the rtti_proxy LinkOnceODR instead of External linkage (PR #67755)

2023-10-03 Thread Petr Hosek via cfe-commits
@@ -639,8 +639,16 @@ void CodeGenVTables::addRelativeComponent(ConstantArrayBuilder &builder, // want the stub/proxy to be emitted for properly calculating the offset. // Examples where there would be no symbol emitted are available_externally // and private linkages. -

[clang] [clang][modules] Remove preloaded SLocEntries from PCM files (PR #66962)

2023-10-03 Thread Jan Svoboda via cfe-commits
@@ -701,6 +701,10 @@ class SourceManager : public RefCountedBase { /// use (-ID - 2). SmallVector LoadedSLocEntryTable; + /// For each allocation in LoadedSLocEntryTable, we keep the new size. This + /// can be used to determine whether two FileIDs come from the same AS

[clang] [mlir][sparse] Print new syntax (PR #68130)

2023-10-03 Thread Aart Bik via cfe-commits
@@ -472,8 +472,11 @@ class SparseInsertGenerator llvm::raw_svector_ostream nameOstream(nameBuffer); nameOstream << kInsertFuncNamePrefix; const Level lvlRank = stt.getLvlRank(); -for (Level l = 0; l < lvlRank; l++) - nameOstream << toMLIRString(stt.getLvlTy

[clang] [mlir][sparse] Print new syntax (PR #68130)

2023-10-03 Thread Aart Bik via cfe-commits
@@ -586,30 +586,56 @@ Attribute SparseTensorEncodingAttr::parse(AsmParser &parser, Type type) { } void SparseTensorEncodingAttr::print(AsmPrinter &printer) const { - // Print the struct-like storage in dictionary fashion. - printer << "<{ lvlTypes = [ "; - llvm::interleave

[clang] [mlir][sparse] Print new syntax (PR #68130)

2023-10-03 Thread Peiming Liu via cfe-commits
@@ -586,30 +586,56 @@ Attribute SparseTensorEncodingAttr::parse(AsmParser &parser, Type type) { } void SparseTensorEncodingAttr::print(AsmPrinter &printer) const { - // Print the struct-like storage in dictionary fashion. - printer << "<{ lvlTypes = [ "; - llvm::interleave

[clang] [IRPGO][ValueProfile] Instrument virtual table address that could be used to do virtual table address comparision for indirect-call-promotion. (PR #66825)

2023-10-03 Thread via cfe-commits
@@ -19,20 +19,38 @@ namespace llvm { // Visitor class that finds all indirect call. struct PGOIndirectCallVisitor : public InstVisitor { std::vector IndirectCalls; + std::vector VTableAddrs; PGOIndirectCallVisitor() = default; void visitCallBase(CallBase &Call) {

[clang] [IRPGO][ValueProfile] Instrument virtual table address that could be used to do virtual table address comparision for indirect-call-promotion. (PR #66825)

2023-10-03 Thread via cfe-commits
@@ -43,19 +45,15 @@ int main(int argc, const char *argv[]) { uint64_t bufsize = __llvm_profile_get_size_for_buffer_internal( __llvm_profile_begin_data(), __llvm_profile_end_data(), __llvm_profile_begin_counters(), __llvm_profile_end_counters(), - __llvm_profi

[clang] [IRPGO][ValueProfile] Instrument virtual table address that could be used to do virtual table address comparision for indirect-call-promotion. (PR #66825)

2023-10-03 Thread via cfe-commits
modiking wrote: > Yes there are tradeoffs to doing this purely with whole program class > hierarchy analysis vs with profiled type info, and in fact they can be > complementary. For example, the profile info can indicate what order to do > the vtable comparisons (i.e. descending order of hotne

[PATCH] D158561: [-Wunsafe-buffer-usage] Add AST info to the unclaimed DRE debug notes for analysis

2023-10-03 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 updated this revision to Diff 557579. ziqingluo-90 added a comment. address comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D158561/new/ https://reviews.llvm.org/D158561 Files: clang/lib/Analysis/UnsafeBufferUsage.cpp clang/test/SemaCXX/warn-unsafe-buffer-usage-d

[clang] [clang][modules] Remove preloaded SLocEntries from PCM files (PR #66962)

2023-10-03 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 edited https://github.com/llvm/llvm-project/pull/66962 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [libc++] Implement ranges::contains (PR #65148)

2023-10-03 Thread via cfe-commits
@@ -0,0 +1,61 @@ +//===--===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apac

[clang] [clang][modules] Remove preloaded SLocEntries from PCM files (PR #66962)

2023-10-03 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 edited https://github.com/llvm/llvm-project/pull/66962 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][RelativeVTables] Make the rtti_proxy LinkOnceODR instead of External linkage (PR #67755)

2023-10-03 Thread via cfe-commits
https://github.com/PiJoules updated https://github.com/llvm/llvm-project/pull/67755 >From 2607a99be986215fa27c053755e96c81bb2033e7 Mon Sep 17 00:00:00 2001 From: Leonard Chan Date: Fri, 29 Sep 2023 00:25:44 + Subject: [PATCH] [clang][RelativeVTables] Make the rtti_proxy LinkOnceODR instead

[clang] [clang][RelativeVTables] Make the rtti_proxy LinkOnceODR instead of External linkage (PR #67755)

2023-10-03 Thread via cfe-commits
https://github.com/PiJoules closed https://github.com/llvm/llvm-project/pull/67755 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 496d00b - [clang][RelativeVTables] Make the rtti_proxy LinkOnceODR instead of External linkage (#67755)

2023-10-03 Thread via cfe-commits
Author: PiJoules Date: 2023-10-03T17:05:21-07:00 New Revision: 496d00b2677593066f5119e93cf0e9316a04277a URL: https://github.com/llvm/llvm-project/commit/496d00b2677593066f5119e93cf0e9316a04277a DIFF: https://github.com/llvm/llvm-project/commit/496d00b2677593066f5119e93cf0e9316a04277a.diff LOG:

[clang] [libc++] Implement ranges::contains (PR #65148)

2023-10-03 Thread via cfe-commits
https://github.com/ZijunZhaoCCK updated https://github.com/llvm/llvm-project/pull/65148 >From 02e9afd761228f401df4d9f8dfaaca44ffae0c6e Mon Sep 17 00:00:00 2001 From: zijunzhao Date: Thu, 31 Aug 2023 20:08:32 + Subject: [PATCH 01/12] [libc++] Implement ranges::contains Differential Revision

[PATCH] D133361: [BPF] Attribute preserve_static_offset for structs

2023-10-03 Thread Eduard Zingerman via Phabricator via cfe-commits
eddyz87 added inline comments. Comment at: clang/lib/CodeGen/CGExpr.cpp:3701 + QualType PointeeType = E->getType()->getPointeeType(); + if (PointeeType.isNull()) +return false; erichkeane wrote: > We override `operator bool` to make this work. Sorry, just t

[clang] [analyzer] Fix false negative when accessing a nonnull property from … (PR #67563)

2023-10-03 Thread via cfe-commits
https://github.com/tripleCC closed https://github.com/llvm/llvm-project/pull/67563 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 1dceba3 - [analyzer] Fix false negative when accessing a nonnull property from … (#67563)

2023-10-03 Thread via cfe-commits
Author: tripleCC Date: 2023-10-04T08:38:10+08:00 New Revision: 1dceba3a3684d12394731e09a6cf3efcebf07a3a URL: https://github.com/llvm/llvm-project/commit/1dceba3a3684d12394731e09a6cf3efcebf07a3a DIFF: https://github.com/llvm/llvm-project/commit/1dceba3a3684d12394731e09a6cf3efcebf07a3a.diff LOG:

[clang] Fixes and closes #53952. Setting the ASTHasCompilerErrors member variable correctly based on the PP diagnostics. (PR #68127)

2023-10-03 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik commented: The fix does not look correct but perhaps someone else will have more insight. https://github.com/llvm/llvm-project/pull/68127 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/m

[clang] Fixes and closes #53952. Setting the ASTHasCompilerErrors member variable correctly based on the PP diagnostics. (PR #68127)

2023-10-03 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik edited https://github.com/llvm/llvm-project/pull/68127 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fixes and closes #53952. Setting the ASTHasCompilerErrors member variable correctly based on the PP diagnostics. (PR #68127)

2023-10-03 Thread Shafik Yaghmour via cfe-commits
@@ -4628,6 +4628,12 @@ ASTFileSignature ASTWriter::WriteAST(Sema &SemaRef, StringRef OutputFile, WritingAST = true; ASTHasCompilerErrors = hasErrors; + bool trueHasErrors = SemaRef.PP.getDiagnostics().hasUncompilableErrorOccurred(); shafik wrote: So th

[libunwind] [libc++] Implement ranges::contains (PR #65148)

2023-10-03 Thread Konstantin Varlamov via cfe-commits
@@ -0,0 +1,61 @@ +//===--===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apac

[clang] [libc++] Implement ranges::contains (PR #65148)

2023-10-03 Thread Konstantin Varlamov via cfe-commits
@@ -0,0 +1,61 @@ +//===--===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apac

[clang-tools-extra] [libc++] Implement ranges::contains (PR #65148)

2023-10-03 Thread Konstantin Varlamov via cfe-commits
@@ -0,0 +1,61 @@ +//===--===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apac

[clang] 6a621ed - [clang-format] Annotate ctors/dtors as CtorDtorDeclName instead (#67955)

2023-10-03 Thread via cfe-commits
Author: Owen Pan Date: 2023-10-03T18:02:09-07:00 New Revision: 6a621ed8e4cb02bd55fe4a4a0254615576b70a55 URL: https://github.com/llvm/llvm-project/commit/6a621ed8e4cb02bd55fe4a4a0254615576b70a55 DIFF: https://github.com/llvm/llvm-project/commit/6a621ed8e4cb02bd55fe4a4a0254615576b70a55.diff LOG:

[clang] [clang-format] Annotate ctors/dtors as CtorDtorDeclName instead (PR #67955)

2023-10-03 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/67955 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][CodeGen] Fix use of CXXThisValue with StrictVTablePointers (PR #68169)

2023-10-03 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov created https://github.com/llvm/llvm-project/pull/68169 When emitting non-virtual base initializers for the constructor prologue, we would potentially use a re-laundered this pointer value from a previous block, which subsequently would not dominate this use. With th

[clang] [Clang][CodeGen] Fix use of CXXThisValue with StrictVTablePointers (PR #68169)

2023-10-03 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Changes When emitting non-virtual base initializers for the constructor prologue, we would potentially use a re-laundered this pointer value from a previous block, which subsequently would not dominate this use. With this fix, we always lau

[clang] [clang-format] Annotate ctors/dtors as CtorDtorDeclName instead (PR #67955)

2023-10-03 Thread via cfe-commits
dyung wrote: I'm seeing the same failures on our linux/Windows build bots: https://lab.llvm.org/buildbot/#/builders/139/builds/50966 https://lab.llvm.org/buildbot/#/builders/216/builds/28315 https://github.com/llvm/llvm-project/pull/67955 ___ cfe-commi

[clang] d08fcc8 - Revert "[clang-format] Annotate ctors/dtors as CtorDtorDeclName instead (#67955)"

2023-10-03 Thread Owen Pan via cfe-commits
Author: Owen Pan Date: 2023-10-03T18:19:23-07:00 New Revision: d08fcc817eba7f0186620688eee73f6d25fa90e8 URL: https://github.com/llvm/llvm-project/commit/d08fcc817eba7f0186620688eee73f6d25fa90e8 DIFF: https://github.com/llvm/llvm-project/commit/d08fcc817eba7f0186620688eee73f6d25fa90e8.diff LOG:

[clang] [analyzer] WebKit checkers: support ref and deref defined on different classes. (PR #68170)

2023-10-03 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ created https://github.com/llvm/llvm-project/pull/68170 Patch by Ryosuke Niwa! >From fc5a447a0dd4203ee69a506cfc791255d555462a Mon Sep 17 00:00:00 2001 From: Ryosuke Niwa Date: Tue, 3 Oct 2023 18:13:21 -0700 Subject: [PATCH] [analyzer] WebKit checkers: support ref and

[clang] [analyzer] WebKit checkers: support ref and deref defined on different classes. (PR #68170)

2023-10-03 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Changes Patch by Ryosuke Niwa! --- Full diff: https://github.com/llvm/llvm-project/pull/68170.diff 5 Files Affected: - (modified) clang/lib/StaticAnalyzer/Checkers/WebKit/PtrTypesSemantics.cpp (+62-28) - (modified) clang/lib/StaticAnalyzer/Che

[clang] [clang-format] Annotate ctors/dtors as CtorDtorDeclName instead (PR #67955)

2023-10-03 Thread Owen Pan via cfe-commits
owenca wrote: Reverted in d08fcc817eba. https://github.com/llvm/llvm-project/pull/67955 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][Sema] Fix a bug when instantiating a lambda with requires clause (PR #65193)

2023-10-03 Thread via cfe-commits
0x59616e wrote: Thank you for your review. I appreciate your feedback ;) https://github.com/llvm/llvm-project/pull/65193 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 548d67a - [clang][Sema] Fix a bug when instantiating a lambda with requires clause (#65193)

2023-10-03 Thread via cfe-commits
Author: Sheng Date: 2023-10-04T10:19:35+08:00 New Revision: 548d67a0393c7bd200e335ada0a3d684750c2697 URL: https://github.com/llvm/llvm-project/commit/548d67a0393c7bd200e335ada0a3d684750c2697 DIFF: https://github.com/llvm/llvm-project/commit/548d67a0393c7bd200e335ada0a3d684750c2697.diff LOG: [c

[clang] [clang][Sema] Fix a bug when instantiating a lambda with requires clause (PR #65193)

2023-10-03 Thread via cfe-commits
https://github.com/0x59616e closed https://github.com/llvm/llvm-project/pull/65193 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CLang][Driver] Add new flags to control IR verification (PR #68172)

2023-10-03 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov created https://github.com/llvm/llvm-project/pull/68172 None >From 4aec8113bc23d361164f1e164c8e4e36a9eb0ad0 Mon Sep 17 00:00:00 2001 From: Matheus Izvekov Date: Wed, 4 Oct 2023 04:39:11 +0200 Subject: [PATCH] [CLang][Driver] Add new flags to control IR verification

[clang] [Clang][Driver] Add new flags to control IR verification (PR #68172)

2023-10-03 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov edited https://github.com/llvm/llvm-project/pull/68172 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fixes and closes #53952. Setting the ASTHasCompilerErrors member variable correctly based on the PP diagnostics. (PR #68127)

2023-10-03 Thread Rajkumar Ananthu via cfe-commits
@@ -4628,6 +4628,12 @@ ASTFileSignature ASTWriter::WriteAST(Sema &SemaRef, StringRef OutputFile, WritingAST = true; ASTHasCompilerErrors = hasErrors; + bool trueHasErrors = SemaRef.PP.getDiagnostics().hasUncompilableErrorOccurred(); rajkumarananthu wrot

[clang] Fixes and closes #53952. Setting the ASTHasCompilerErrors member variable correctly based on the PP diagnostics. (PR #68127)

2023-10-03 Thread Rajkumar Ananthu via cfe-commits
https://github.com/rajkumarananthu edited https://github.com/llvm/llvm-project/pull/68127 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Support] Rename HashBuilderImpl to HashBuilder (NFC) (PR #68173)

2023-10-03 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/68173 Commit 9370271ec5debcb59e34629d5bd357c44213b2d3 made HashBuilder an alias for HashBuilderImpl: template using HashBuilder = HashBuilderImpl; This patch renames HashBuilderImpl to HashBuilder while re

[clang] [Support] Rename HashBuilderImpl to HashBuilder (NFC) (PR #68173)

2023-10-03 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Changes Commit 9370271ec5debcb59e34629d5bd357c44213b2d3 made HashBuilder an alias for HashBuilderImpl: template using HashBuilder = HashBuilderImpl; This patch renames HashBu

[clang] llvm-canon (PR #68176)

2023-10-03 Thread Justin Fargnoli via cfe-commits
https://github.com/justinfargnoli created https://github.com/llvm/llvm-project/pull/68176 Add the llvm-canon tool. Description from the [original PR](https://reviews.llvm.org/D66029#change-wZv3yOpDdxIu): > Added a new llvm-canon tool which aims to transform LLVM Modules into a > canonical for

[clang-tools-extra] [clangd] Adapt Inlay Hint support for Deducing This (PR #68177)

2023-10-03 Thread via cfe-commits
https://github.com/zyn0217 created https://github.com/llvm/llvm-project/pull/68177 This is a follow-up for D140828, making Clangd omit the explicit object parameter in a call to member function with Deducing This. Given that the parent patch is still in its infancy and might undergo several r

[clang-tools-extra] [clangd] Adapt Inlay Hint support for Deducing This (PR #68177)

2023-10-03 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clangd Changes This is a follow-up for D140828, making Clangd omit the explicit object parameter in a call to member function with Deducing This. Given that the parent patch is still in its infancy and might undergo several reverting-relanding processe

[clang-tools-extra] [clangd] Adapt Inlay Hint support for Deducing This (PR #68177)

2023-10-03 Thread via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/68177 >From 5e75d4d99cec39fdc3139f1e92036712aea90f57 Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Wed, 4 Oct 2023 11:59:31 +0800 Subject: [PATCH 1/2] [clangd] Adapt Inlay Hint support for Deducing This This is a

[clang-tools-extra] [clang-tidy][libc] Fix namespace check with macro (PR #68134)

2023-10-03 Thread via cfe-commits
EugeneZelenko wrote: Shouldn't documentation be updated too? https://github.com/llvm/llvm-project/pull/68134 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Adapt Inlay Hint support for Deducing This (PR #68177)

2023-10-03 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff 8641cdf397d86f33ac45e4c691ca4f843c359370 5e75d4d99cec39fdc3139f1e92036712aea90f57 --

[clang] llvm-canon (PR #68176)

2023-10-03 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff 8641cdf397d86f33ac45e4c691ca4f843c359370 90912d2b40121936c239f9275bebd52db5d3a116 --

[clang-tools-extra] llvm-canon (PR #68176)

2023-10-03 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff 8641cdf397d86f33ac45e4c691ca4f843c359370 90912d2b40121936c239f9275bebd52db5d3a116 --

[clang] llvm-canon (PR #68176)

2023-10-03 Thread Michal Paszkowski via cfe-commits
michalpaszkowski wrote: Thank you @justinfargnoli and @AidanGoldfarb for taking over this work and reaching out! I will review your changes in the coming week. CC @ChrisCummins FYI https://github.com/llvm/llvm-project/pull/68176 ___ cfe-commits maili

[clang-tools-extra] llvm-canon (PR #68176)

2023-10-03 Thread Michal Paszkowski via cfe-commits
michalpaszkowski wrote: Thank you @justinfargnoli and @AidanGoldfarb for taking over this work and reaching out! I will review your changes in the coming week. CC @ChrisCummins FYI https://github.com/llvm/llvm-project/pull/68176 ___ cfe-commits maili

[clang] llvm-canon (PR #68176)

2023-10-03 Thread Michal Paszkowski via cfe-commits
@@ -0,0 +1,638 @@ +//===--- IRCanonicalizer.cpp - IR Canonicalizer ---===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] llvm-canon (PR #68176)

2023-10-03 Thread Michal Paszkowski via cfe-commits
@@ -0,0 +1,638 @@ +//===--- IRCanonicalizer.cpp - IR Canonicalizer ---===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang] llvm-canon (PR #68176)

2023-10-03 Thread Justin Fargnoli via cfe-commits
https://github.com/justinfargnoli updated https://github.com/llvm/llvm-project/pull/68176 >From f792a030ac1761a96176332fea906cd2d1826c7b Mon Sep 17 00:00:00 2001 From: justinfargnoli Date: Sat, 12 Aug 2023 10:58:45 -0700 Subject: [PATCH 01/15] Add IRCanonicalizer.cpp --- llvm/lib/Transforms/U

[clang-tools-extra] llvm-canon (PR #68176)

2023-10-03 Thread Justin Fargnoli via cfe-commits
https://github.com/justinfargnoli updated https://github.com/llvm/llvm-project/pull/68176 >From f792a030ac1761a96176332fea906cd2d1826c7b Mon Sep 17 00:00:00 2001 From: justinfargnoli Date: Sat, 12 Aug 2023 10:58:45 -0700 Subject: [PATCH 01/15] Add IRCanonicalizer.cpp --- llvm/lib/Transforms/U

[clang-tools-extra] [clang-tidy][libc] Fix namespace check with macro (PR #68134)

2023-10-03 Thread Piotr Zegar via cfe-commits
@@ -321,6 +321,11 @@ Changes in existing checks ` check to identify calls to static member functions with out-of-class inline definitions. +- Improved :doc:`llvmlibc-callee-namespace PiotrZSL wrote: Put this in alphabetical order. https://github.com/llv

[clang-tools-extra] [clang-tidy][libc] Fix namespace check with macro (PR #68134)

2023-10-03 Thread Piotr Zegar via cfe-commits
@@ -45,18 +45,20 @@ void CalleeNamespaceCheck::check(const MatchFinder::MatchResult &Result) { if (FuncDecl->getBuiltinID() != 0) return; - // If the outermost namespace of the function is __llvm_libc, we're good. + // If the outermost namespace of the function starts

[clang-tools-extra] [clang-tidy][libc] Fix namespace check with macro (PR #68134)

2023-10-03 Thread Piotr Zegar via cfe-commits
@@ -45,18 +45,20 @@ void CalleeNamespaceCheck::check(const MatchFinder::MatchResult &Result) { if (FuncDecl->getBuiltinID() != 0) return; - // If the outermost namespace of the function is __llvm_libc, we're good. + // If the outermost namespace of the function starts

[clang-tools-extra] [clang-tidy][libc] Fix namespace check with macro (PR #68134)

2023-10-03 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL edited https://github.com/llvm/llvm-project/pull/68134 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy][libc] Fix namespace check with macro (PR #68134)

2023-10-03 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL requested changes to this pull request. Order of changes, test, documentation is missing https://github.com/llvm/llvm-project/pull/68134 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/

[clang] [clang] Preserve UDL nodes in RemoveNestedImmediateInvocation (PR #66641)

2023-10-03 Thread via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/66641 >From ba9aa0ffe006ecdd8685c7e62be8c4c776391ec2 Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Mon, 18 Sep 2023 19:55:45 +0800 Subject: [PATCH 1/2] [clang] Preserve UDL nodes in RemoveNestedImmediateInvocation

[clang] [clang] Preserve UDL nodes in RemoveNestedImmediateInvocation (PR #66641)

2023-10-03 Thread via cfe-commits
zyn0217 wrote: No problem! And here it is. PTAL, thanks! @cor3ntin https://github.com/llvm/llvm-project/pull/66641 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 2176c5e - [Clang][Sema] Fix display of characters on static assertion failure

2023-10-03 Thread Takuya Shimizu via cfe-commits
Author: Takuya Shimizu Date: 2023-10-04T14:09:06+09:00 New Revision: 2176c5e510e3bfcbc75afb13e78d287141f239a7 URL: https://github.com/llvm/llvm-project/commit/2176c5e510e3bfcbc75afb13e78d287141f239a7 DIFF: https://github.com/llvm/llvm-project/commit/2176c5e510e3bfcbc75afb13e78d287141f239a7.diff

[clang] [clang][tidy] Ensure rewriter has the correct CWD (PR #67839)

2023-10-03 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL approved this pull request. Clang part looks fine. For a clang-tidy part, is there a way to test this part ? What changes because we use now a absolute build directory. I'm missing some tests for that part. https://github.com/llvm/llvm-project/pull/67839

[clang] [clang] Preserve UDL nodes in RemoveNestedImmediateInvocation (PR #66641)

2023-10-03 Thread via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/66641 >From ef66dbe5f9a5b9071e994a5d8f2b6b48b6d5b446 Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Mon, 18 Sep 2023 19:55:45 +0800 Subject: [PATCH 1/2] [clang] Preserve UDL nodes in RemoveNestedImmediateInvocation

[PATCH] D155610: [Clang][Sema] Fix display of characters on static assertion failure

2023-10-03 Thread Takuya Shimizu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG2176c5e510e3: [Clang][Sema] Fix display of characters on static assertion failure (authored by hazohelet). Changed prior to commit: https://reviews.llvm.org/D155610?vs=557524&id=557581#toc Repository:

[clang-tools-extra] [clang-tidy]: Add TagDecl into LastTagDeclRanges in UseUsingCheck only when it is a definition (PR #67639)

2023-10-03 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/67639 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 7e856d1 - Reland "[clang-format] Annotate ctors/dtors as CtorDtorDeclName instead (#67955)"

2023-10-03 Thread via cfe-commits
Author: Owen Pan Date: 2023-10-03T22:26:48-07:00 New Revision: 7e856d18943f637b8c83f0bf8cbb506c5f7e94af URL: https://github.com/llvm/llvm-project/commit/7e856d18943f637b8c83f0bf8cbb506c5f7e94af DIFF: https://github.com/llvm/llvm-project/commit/7e856d18943f637b8c83f0bf8cbb506c5f7e94af.diff LOG:

[clang] [Support] Rename HashBuilderImpl to HashBuilder (NFC) (PR #68173)

2023-10-03 Thread Markus Böck via cfe-commits
https://github.com/zero9178 approved this pull request. https://github.com/llvm/llvm-project/pull/68173 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][Interp] Emit dummy values for unknown C variables (PR #66749)

2023-10-03 Thread Timm Baeder via cfe-commits
tbaederr wrote: Ping https://github.com/llvm/llvm-project/pull/66749 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Avoid evaluating the BitWidth expression over and over again (PR #66203)

2023-10-03 Thread Timm Baeder via cfe-commits
tbaederr wrote: Ping https://github.com/llvm/llvm-project/pull/66203 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [IRPGO][ValueProfile] Instrument virtual table address that could be used to do virtual table address comparision for indirect-call-promotion. (PR #66825)

2023-10-03 Thread Mingming Liu via cfe-commits
@@ -309,9 +323,16 @@ lprofWriteDataImpl(ProfDataWriter *Writer, const __llvm_profile_data *DataBegin, return -1; /* Write the binary id lengths and data. */ - if (__llvm_write_binary_ids(Writer) == -1) + int binary_id_size = __llvm_write_binary_ids(Writer); + if (bin

[clang] [IRPGO][ValueProfile] Instrument virtual table address that could be used to do virtual table address comparision for indirect-call-promotion. (PR #66825)

2023-10-03 Thread Mingming Liu via cfe-commits
@@ -43,19 +45,15 @@ int main(int argc, const char *argv[]) { uint64_t bufsize = __llvm_profile_get_size_for_buffer_internal( __llvm_profile_begin_data(), __llvm_profile_end_data(), __llvm_profile_begin_counters(), __llvm_profile_end_counters(), - __llvm_profi

[clang] [IRPGO][ValueProfile] Instrument virtual table address that could be used to do virtual table address comparision for indirect-call-promotion. (PR #66825)

2023-10-03 Thread Mingming Liu via cfe-commits
@@ -519,13 +591,20 @@ class InstrProfSymtab { /// will be represented using the same StringRef value. inline StringRef getFuncNameOrExternalSymbol(uint64_t FuncMD5Hash); + /// Just like getFuncName, except that it will return a non-empty StringRef minglot

[clang] [IRPGO][ValueProfile] Instrument virtual table address that could be used to do virtual table address comparision for indirect-call-promotion. (PR #66825)

2023-10-03 Thread Mingming Liu via cfe-commits
@@ -19,20 +19,38 @@ namespace llvm { // Visitor class that finds all indirect call. struct PGOIndirectCallVisitor : public InstVisitor { std::vector IndirectCalls; + std::vector VTableAddrs; PGOIndirectCallVisitor() = default; void visitCallBase(CallBase &Call) {

[clang] [IRPGO][ValueProfile] Instrument virtual table address that could be used to do virtual table address comparision for indirect-call-promotion. (PR #66825)

2023-10-03 Thread Mingming Liu via cfe-commits
https://github.com/minglotus-6 edited https://github.com/llvm/llvm-project/pull/66825 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
@@ -1,33 +1,151 @@ -; RUN: llc < %s -asm-verbose=false -verify-machineinstrs | FileCheck %s -; RUN: llc < %s -asm-verbose=false -fast-isel -fast-isel-abort=1 -verify-machineinstrs | FileCheck %s +; The assertions in this file were autogenerated by +; utils/update_llc_test_checks.

[clang-tools-extra] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
@@ -1,33 +1,151 @@ -; RUN: llc < %s -asm-verbose=false -verify-machineinstrs | FileCheck %s -; RUN: llc < %s -asm-verbose=false -fast-isel -fast-isel-abort=1 -verify-machineinstrs | FileCheck %s +; The assertions in this file were autogenerated by +; utils/update_llc_test_checks.

[clang] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
@@ -1,33 +1,151 @@ -; RUN: llc < %s -asm-verbose=false -verify-machineinstrs | FileCheck %s -; RUN: llc < %s -asm-verbose=false -fast-isel -fast-isel-abort=1 -verify-machineinstrs | FileCheck %s +; The assertions in this file were autogenerated by +; utils/update_llc_test_checks.

[clang] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
@@ -1,33 +1,151 @@ -; RUN: llc < %s -asm-verbose=false -verify-machineinstrs | FileCheck %s -; RUN: llc < %s -asm-verbose=false -fast-isel -fast-isel-abort=1 -verify-machineinstrs | FileCheck %s +; The assertions in this file were autogenerated by +; utils/update_llc_test_checks.

[clang-tools-extra] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
@@ -1,33 +1,151 @@ -; RUN: llc < %s -asm-verbose=false -verify-machineinstrs | FileCheck %s -; RUN: llc < %s -asm-verbose=false -fast-isel -fast-isel-abort=1 -verify-machineinstrs | FileCheck %s +; The assertions in this file were autogenerated by +; utils/update_llc_test_checks.

[clang] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
@@ -1,33 +1,151 @@ -; RUN: llc < %s -asm-verbose=false -verify-machineinstrs | FileCheck %s -; RUN: llc < %s -asm-verbose=false -fast-isel -fast-isel-abort=1 -verify-machineinstrs | FileCheck %s +; The assertions in this file were autogenerated by +; utils/update_llc_test_checks.

[clang] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
@@ -1,33 +1,151 @@ -; RUN: llc < %s -asm-verbose=false -verify-machineinstrs | FileCheck %s -; RUN: llc < %s -asm-verbose=false -fast-isel -fast-isel-abort=1 -verify-machineinstrs | FileCheck %s +; The assertions in this file were autogenerated by +; utils/update_llc_test_checks.

[clang] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
@@ -1,33 +1,151 @@ -; RUN: llc < %s -asm-verbose=false -verify-machineinstrs | FileCheck %s -; RUN: llc < %s -asm-verbose=false -fast-isel -fast-isel-abort=1 -verify-machineinstrs | FileCheck %s +; The assertions in this file were autogenerated by +; utils/update_llc_test_checks.

[clang-tools-extra] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
@@ -1,33 +1,151 @@ -; RUN: llc < %s -asm-verbose=false -verify-machineinstrs | FileCheck %s -; RUN: llc < %s -asm-verbose=false -fast-isel -fast-isel-abort=1 -verify-machineinstrs | FileCheck %s +; The assertions in this file were autogenerated by +; utils/update_llc_test_checks.

[clang-tools-extra] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
@@ -1,33 +1,151 @@ -; RUN: llc < %s -asm-verbose=false -verify-machineinstrs | FileCheck %s -; RUN: llc < %s -asm-verbose=false -fast-isel -fast-isel-abort=1 -verify-machineinstrs | FileCheck %s +; The assertions in this file were autogenerated by +; utils/update_llc_test_checks.

[clang] [IRPGO][ValueProfile] Instrument virtual table address that could be used to do virtual table address comparision for indirect-call-promotion. (PR #66825)

2023-10-03 Thread Mingming Liu via cfe-commits
minglotus-6 wrote: > > Yes there are tradeoffs to doing this purely with whole program class > > hierarchy analysis vs with profiled type info, and in fact they can be > > complementary. For example, the profile info can indicate what order to do > > the vtable comparisons (i.e. descending ord

[clang] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
https://github.com/aheejin edited https://github.com/llvm/llvm-project/pull/65876 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
https://github.com/aheejin edited https://github.com/llvm/llvm-project/pull/65876 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
https://github.com/aheejin edited https://github.com/llvm/llvm-project/pull/65876 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] Ensure NoTrapAfterNoreturn is false for the wasm backend (PR #65876)

2023-10-03 Thread Heejin Ahn via cfe-commits
https://github.com/aheejin edited https://github.com/llvm/llvm-project/pull/65876 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer][clangsa] Add new option to alpha.security.cert.InvalidPtrChecker (PR #67663)

2023-10-03 Thread Endre Fülöp via cfe-commits
https://github.com/gamesh411 updated https://github.com/llvm/llvm-project/pull/67663 From 9aea93ddeb70245a07984188aa98577d54e8e560 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Endre=20F=C3=BCl=C3=B6p?= Date: Fri, 8 Sep 2023 14:20:00 +0200 Subject: [PATCH 1/8] [analyzer][clangsa] Add new option to

[clang] [clang] Preserve UDL nodes in RemoveNestedImmediateInvocation (PR #66641)

2023-10-03 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. LGTM, thanks! https://github.com/llvm/llvm-project/pull/66641 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][driver] Use platform specific calls to get the executable absolute path (PR #68091)

2023-10-03 Thread Martin Storsjö via cfe-commits
mstorsjo wrote: > I'm convinced that such links were occasionally used before, just that the > result was not necessarily an error, I would say that in most cases using the > system libraries is functional, and this explains why such cases were not > reported till now. Not necessarily; this d

<    1   2   3   4   5