[clang] [clang-tools-extra] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll edited https://github.com/llvm/llvm-project/pull/71049 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer] Improve diagnostics from ArrayBoundCheckerV2 (PR #70056)

2023-11-02 Thread via cfe-commits
=?utf-8?q?Donát?= Nagy , =?utf-8?q?Donát?= Nagy Message-ID: In-Reply-To: @@ -174,9 +176,116 @@ compareValueToThreshold(ProgramStateRef State, NonLoc Value, NonLoc Threshold, return {nullptr, nullptr}; } -void ArrayBoundCheckerV2::checkLocation(SVal location, bool isLoad,

[libc] [clang] [lld] [clang-tools-extra] [flang] [libcxx] [llvm] [lldb] [compiler-rt] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-11-02 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll updated https://github.com/llvm/llvm-project/pull/70349 >From 7329f68092d5f8f5a5978e5a6cbad6ada87d4fe8 Mon Sep 17 00:00:00 2001 From: Vlad Serebrennikov Date: Thu, 26 Oct 2023 16:09:25 +0300 Subject: [PATCH 1/6] [clang][NFC] Annotate `Type` bit-fields with `clang::pr

[clang] [analyzer] Improve diagnostics from ArrayBoundCheckerV2 (PR #70056)

2023-11-02 Thread via cfe-commits
=?utf-8?q?Donát?= Nagy , =?utf-8?q?Donát?= Nagy Message-ID: In-Reply-To: @@ -22,23 +22,25 @@ #include "clang/StaticAnalyzer/Core/PathSensitive/DynamicExtent.h" #include "clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h" #include "llvm/ADT/SmallString.h" +#include "llvm/S

[libc] [clang] [lld] [clang-tools-extra] [flang] [libcxx] [llvm] [lldb] [compiler-rt] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-11-02 Thread Vlad Serebrennikov via cfe-commits
@@ -49,7 +49,7 @@ struct ExprDependenceScope { using ExprDependence = ExprDependenceScope::ExprDependence; struct TypeDependenceScope { - enum TypeDependence : uint8_t { + enum TypeDependence : unsigned { Endilll wrote: I reverted changes to underlying type

[clang] [llvm] [LLVM][AArch64] Add ASM constraints for reduced GPR register ranges. (PR #70970)

2023-11-02 Thread Paul Walker via cfe-commits
https://github.com/paulwalker-arm updated https://github.com/llvm/llvm-project/pull/70970 >From 500e5007a33d4ee3d594ef5ce58f8894c231f3dc Mon Sep 17 00:00:00 2001 From: Paul Walker Date: Wed, 1 Nov 2023 16:27:29 + Subject: [PATCH 1/2] [NFC][LLVM][SVE] Refactor predicate register ASM constra

[llvm] [clang] [LLVM][AArch64] Add ASM constraints for reduced GPR register ranges. (PR #70970)

2023-11-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-aarch64 @llvm/pr-subscribers-llvm-ir Author: Paul Walker (paulwalker-arm) Changes [LLVM][AArch64] Add ASM constraints for reduced GPR register ranges. The patch adds the follow ASM constraints: Uci => w8-w11 Ucj => w12-w15 These con

[clang] [llvm] [LLVM][AArch64] Add ASM constraints for reduced GPR register ranges. (PR #70970)

2023-11-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Paul Walker (paulwalker-arm) Changes [LLVM][AArch64] Add ASM constraints for reduced GPR register ranges. The patch adds the follow ASM constraints: Uci => w8-w11 Ucj => w12-w15 These constraints are required for SME load/stor

[clang] [llvm] [LLVM][AArch64] Add ASM constraints for reduced GPR register ranges. (PR #70970)

2023-11-02 Thread Paul Walker via cfe-commits
https://github.com/paulwalker-arm edited https://github.com/llvm/llvm-project/pull/70970 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [LLVM][AArch64] Add ASM constraints for reduced GPR register ranges. (PR #70970)

2023-11-02 Thread Paul Walker via cfe-commits
paulwalker-arm wrote: * Rebased. * Extended coverage to include all typical scalar types. * Updated the LangRef to document the new constraints. * Added an entry to the release note. https://github.com/llvm/llvm-project/pull/70970 ___ cfe-commits maili

[clang] [clang] Catch missing format attributes (PR #70024)

2023-11-02 Thread Budimir Aranđelović via cfe-commits
https://github.com/budimirarandjelovicsyrmia updated https://github.com/llvm/llvm-project/pull/70024 From 36477198e67e225e6fc686cf08c194438e65d39c Mon Sep 17 00:00:00 2001 From: budimirarandjelovicsyrmia Date: Fri, 13 Oct 2023 14:45:15 +0200 Subject: [PATCH] [clang] Catch missing format attribu

[clang] [clang] Catch missing format attributes (PR #70024)

2023-11-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Budimir Aranđelović (budimirarandjelovicsyrmia) Changes Enable flag -Wmissing-format-attribute to catch missing attributes. --- Full diff: https://github.com/llvm/llvm-project/pull/70024.diff 6 Files Affected: - (modified) clang/include

[clang] [clang-tools-extra] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Aaron Ballman via cfe-commits
@@ -1921,7 +1920,20 @@ bool NamedDecl::declarationReplaces(NamedDecl *OldD, bool IsKnownNewer) const { } bool NamedDecl::hasLinkage() const { - return getFormalLinkage() != NoLinkage; + switch (getFormalLinkage()) { + case Linkage::Invalid: +llvm_unreachable("Linkage h

[clang] [analyzer] Improve diagnostics from ArrayBoundCheckerV2 (PR #70056)

2023-11-02 Thread via cfe-commits
=?utf-8?q?Donát?= Nagy , =?utf-8?q?Donát?= Nagy Message-ID: In-Reply-To: @@ -217,80 +326,71 @@ void ArrayBoundCheckerV2::checkLocation(SVal location, bool isLoad, // MallocChecker that call SValBuilder::getConjuredHeapSymbolVal()) and // non-symbolic regions (e.g. a

[clang-tools-extra] [clang] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll updated https://github.com/llvm/llvm-project/pull/71049 >From 05089e60021c321b4113db7e4bdf59bdaaa19de7 Mon Sep 17 00:00:00 2001 From: Vlad Serebrennikov Date: Thu, 2 Nov 2023 14:40:12 +0300 Subject: [PATCH 1/2] [clang][NFC] Refactor `clang::Linkage` This patch introd

[llvm] [clang] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Chuanqi Xu via cfe-commits
@@ -777,6 +777,12 @@ void CodeGenFunction::EmitCoroutineBody(const CoroutineBodyStmt &S) { // LLVM require the frontend to mark the coroutine. CurFn->setPresplitCoroutine(); + + { +CXXRecordDecl *RD = FnRetTy->getAsCXXRecordDecl(); +if (RD && RD->hasAttr()) +

[clang] [analyzer] Improve diagnostics from ArrayBoundCheckerV2 (PR #70056)

2023-11-02 Thread via cfe-commits
=?utf-8?q?Donát?= Nagy , =?utf-8?q?Donát?= Nagy Message-ID: In-Reply-To: @@ -0,0 +1,149 @@ +// RUN: %clang_analyze_cc1 -Wno-array-bounds -analyzer-output=text\ +// RUN: -analyzer-checker=core,alpha.security.ArrayBoundV2,unix.Malloc,alpha.security.taint -verify %s

[clang] [clang] Add support for new loop attribute [[clang::code_align()]] (PR #70762)

2023-11-02 Thread via cfe-commits
@@ -440,6 +440,14 @@ MDNode *LoopInfo::createMetadata( Ctx, {MDString::get(Ctx, "llvm.loop.parallel_accesses"), AccGroup})); } + // Setting clang::code_align attribute. + if (Attrs.CodeAlign > 0) { smanna12 wrote: Added consumption on this IR in M

[clang] [analyzer] Improve diagnostics from ArrayBoundCheckerV2 (PR #70056)

2023-11-02 Thread via cfe-commits
=?utf-8?q?Donát?= Nagy , =?utf-8?q?Donát?= Nagy Message-ID: In-Reply-To: DonatNagyE wrote: Thanks for the suggestions; I'll probably upload the next revision tomorrow. > One remark about the review workflow, I'd prefer if the conversation starter > would resolve the conversations. Let me exp

[clang] [clang-tools-extra] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. LGTM. I didn't understand the full context in the private chat. https://github.com/llvm/llvm-project/pull/71049 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[clang] [clang-tools-extra] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 edited https://github.com/llvm/llvm-project/pull/71049 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Chuanqi Xu via cfe-commits
@@ -2214,7 +2214,7 @@ void ASTWriter::WriteDeclAbbrevs() { Abv->Add(BitCodeAbbrevOp(0)); // TSCSpec Abv->Add(BitCodeAbbrevOp(0)); // InitStyle Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 1)); // isARCPseudoStrong - Abv->Ad

[clang-tools-extra] [clang] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Chuanqi Xu via cfe-commits
@@ -2214,7 +2214,7 @@ void ASTWriter::WriteDeclAbbrevs() { Abv->Add(BitCodeAbbrevOp(0)); // TSCSpec Abv->Add(BitCodeAbbrevOp(0)); // InitStyle Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 1)); // isARCPseudoStrong - Abv->Ad

[llvm] [mlir] [libcxx] [clang] [lldb] [flang] [Flang][OpenMP] Port openmp threadprivate-use-association.f90 test to HLFIR flow (PR #71043)

2023-11-02 Thread Kiran Chandramohan via cfe-commits
https://github.com/kiranchandramohan approved this pull request. LG. Thanks. https://github.com/llvm/llvm-project/pull/71043 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Add support for new loop attribute [[clang::code_align()]] (PR #70762)

2023-11-02 Thread via cfe-commits
https://github.com/smanna12 updated https://github.com/llvm/llvm-project/pull/70762 >From 93d46d40f46663cfa30fc01da965887508684e25 Mon Sep 17 00:00:00 2001 From: "Manna, Soumi" Date: Mon, 30 Oct 2023 21:41:00 -0700 Subject: [PATCH 1/4] [clang] Add support for new loop attribute [[clang::code_a

[clang] [clang-tools-extra] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Aaron Ballman via cfe-commits
@@ -2214,7 +2214,7 @@ void ASTWriter::WriteDeclAbbrevs() { Abv->Add(BitCodeAbbrevOp(0)); // TSCSpec Abv->Add(BitCodeAbbrevOp(0)); // InitStyle Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 1)); // isARCPseudoStrong - Abv->Ad

[clang] [clang-tools-extra] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Vlad Serebrennikov via cfe-commits
@@ -2214,7 +2214,7 @@ void ASTWriter::WriteDeclAbbrevs() { Abv->Add(BitCodeAbbrevOp(0)); // TSCSpec Abv->Add(BitCodeAbbrevOp(0)); // InitStyle Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 1)); // isARCPseudoStrong - Abv->Ad

[llvm] [clang-tools-extra] [lld] [libc] [clang] [libcxx] [lldb] [compiler-rt] [flang] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-11-02 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. LGTM aside from a nit with the new macro (feel free to fix when landing). https://github.com/llvm/llvm-project/pull/70349 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.

[lld] [compiler-rt] [flang] [libcxx] [llvm] [libc] [clang] [clang-tools-extra] [lldb] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-11-02 Thread Aaron Ballman via cfe-commits
@@ -569,4 +569,12 @@ void AnnotateIgnoreWritesEnd(const char *file, int line); #define LLVM_NO_PROFILE_INSTRUMENT_FUNCTION #endif +/// \macro LLVM_PREFERRED_TYPE +/// Adjust type of bit-field in debug info. +#if __has_attribute(preferred_type) AaronBallman wro

[libcxx] [flang] [compiler-rt] [clang] [lld] [lldb] [llvm] [libc] [clang-tools-extra] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-11-02 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman edited https://github.com/llvm/llvm-project/pull/70349 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Aaron Ballman via cfe-commits
@@ -2214,7 +2214,7 @@ void ASTWriter::WriteDeclAbbrevs() { Abv->Add(BitCodeAbbrevOp(0)); // TSCSpec Abv->Add(BitCodeAbbrevOp(0)); // InitStyle Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 1)); // isARCPseudoStrong - Abv->Ad

[clang] [clang-tools-extra] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. LGTM aside from the comment nit from @ChuanqiXu9 https://github.com/llvm/llvm-project/pull/71049 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman

[clang] [clang-tools-extra] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll updated https://github.com/llvm/llvm-project/pull/71049 >From 05089e60021c321b4113db7e4bdf59bdaaa19de7 Mon Sep 17 00:00:00 2001 From: Vlad Serebrennikov Date: Thu, 2 Nov 2023 14:40:12 +0300 Subject: [PATCH 1/4] [clang][NFC] Refactor `clang::Linkage` This patch introd

[clang] [clang-tools-extra] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Vlad Serebrennikov via cfe-commits
@@ -2214,7 +2214,7 @@ void ASTWriter::WriteDeclAbbrevs() { Abv->Add(BitCodeAbbrevOp(0)); // TSCSpec Abv->Add(BitCodeAbbrevOp(0)); // InitStyle Abv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 1)); // isARCPseudoStrong - Abv->Ad

[clang] [clang-tools-extra] [clang] Refactor `clang::Linkage` (PR #71049)

2023-11-02 Thread Vlad Serebrennikov via cfe-commits
@@ -1996,7 +1996,7 @@ class alignas(TypeAlignment) Type : public ExtQualsTypeCommonBase { TypeBits.Dependence = static_cast(Dependence); TypeBits.CacheValid = false; TypeBits.CachedLocalOrUnnamed = false; -TypeBits.CachedLinkage = NoLinkage; +TypeBits.Cache

[PATCH] D153701: [Clang] Implement P2718R0 "Lifetime extension in range-based for loops"

2023-11-02 Thread Yurong via Phabricator via cfe-commits
yronglin added a comment. ping~ Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153701/new/ https://reviews.llvm.org/D153701 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/c

[llvm] [clang] [LLVM][AArch64] Add ASM constraints for reduced GPR register ranges. (PR #70970)

2023-11-02 Thread Peter Waller via cfe-commits
https://github.com/peterwaller-arm approved this pull request. https://github.com/llvm/llvm-project/pull/70970 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AArch64][Clang] Refactor code to emit SVE & SME builtins (PR #70959)

2023-11-02 Thread David Sherwood via cfe-commits
https://github.com/david-arm approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/70959 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang-tools-extra] [lldb] [libc] [clang] [libcxx] [lld] [flang] [OpenACC] Initial commits to support OpenACC (PR #70234)

2023-11-02 Thread Erich Keane via cfe-commits
@@ -0,0 +1,14 @@ +// RUN: %clang -S -### -fopenacc %s 2>&1 | FileCheck %s --check-prefix=CHECK-DRIVER +// CHECK-DRIVER: "-cc1" {{.*}} "-fopenacc" erichkeane wrote: At the moment, there should be no problem with them co-existing. Kernels can be separately gener

[llvm] [libcxx] [libc] [flang] [clang] [lldb] [clang-tools-extra] [lld] [OpenACC] Initial commits to support OpenACC (PR #70234)

2023-11-02 Thread Erich Keane via cfe-commits
@@ -1342,6 +1342,15 @@ def err_opencl_logical_exclusive_or : Error< def err_openclcxx_virtual_function : Error< "virtual functions are not supported in C++ for OpenCL">; +// OpenACC Support. +def warn_pragma_acc_ignored : Warning< + "unexpected '#pragma acc ...' in program"

[clang] [AArch64][Clang] Refactor code to emit SVE & SME builtins (PR #70959)

2023-11-02 Thread Kerry McLaughlin via cfe-commits
https://github.com/kmclaughlin-arm ready_for_review https://github.com/llvm/llvm-project/pull/70959 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[flang] [clang] [flang][windows] Add option to link against specific MSVC CRT (PR #70833)

2023-11-02 Thread Brad King via cfe-commits
@@ -281,3 +281,26 @@ add_flang_library(FortranRuntime INSTALL_WITH_TOOLCHAIN ) + +if (DEFINED MSVC) + add_flang_library(FortranRuntime.static ${sources} +LINK_LIBS +FortranDecimal.static +INSTALL_WITH_TOOLCHAIN) + set_property(TARGET FortranRuntime.static PROPE

[clang-tools-extra] [clang-tidy] Improve modernize-make-shared check (PR #70600)

2023-11-02 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 approved this pull request. https://github.com/llvm/llvm-project/pull/70600 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [compiler-rt] [libcxx] [libc] [flang] [clang] [lldb] [clang-tools-extra] [lld] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-11-02 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll updated https://github.com/llvm/llvm-project/pull/70349 >From 7329f68092d5f8f5a5978e5a6cbad6ada87d4fe8 Mon Sep 17 00:00:00 2001 From: Vlad Serebrennikov Date: Thu, 26 Oct 2023 16:09:25 +0300 Subject: [PATCH 1/7] [clang][NFC] Annotate `Type` bit-fields with `clang::pr

[flang] [clang] [flang][windows] Add option to link against specific MSVC CRT (PR #70833)

2023-11-02 Thread Brad King via cfe-commits
@@ -976,12 +976,46 @@ bool tools::addOpenMPRuntime(ArgStringList &CmdArgs, const ToolChain &TC, return true; } -void tools::addFortranRuntimeLibs(const ToolChain &TC, +void tools::addFortranRuntimeLibs(const ToolChain &TC, const ArgList &Args,

[flang] [clang] [flang][windows] Add option to link against specific MSVC CRT (PR #70833)

2023-11-02 Thread Brad King via cfe-commits
@@ -1,3 +1,21 @@ add_flang_library(Fortran_main STATIC INSTALL_WITH_TOOLCHAIN Fortran_main.c ) +if (DEFINED MSVC) +add_flang_library(Fortran_main.static STATIC INSTALL_WITH_TOOLCHAIN +Fortran_main.c +) bradking wrote: The style elsewhere

[llvm] [clang] [NFC] Remove Type::getInt8PtrTy (PR #71029)

2023-11-02 Thread Mircea Trofin via cfe-commits
mtrofin wrote: Nit: can you add in the description that this is a follow-up from the opaque pointer transition (having an explicit motivation helps read a patch). Thanks! https://github.com/llvm/llvm-project/pull/71029 ___ cfe-commits mailing list cfe

[clang] [analyzer] Fix uninitialized base class with initializer list when ctor is not declared in the base class (#70464) (PR #70792)

2023-11-02 Thread Balazs Benics via cfe-commits
steakhal wrote: I wanted to highlight that this PR resolved a bunch of open issues, namely: #61919, #59493, #54533 Thank you! So I think we should mention this in the release notes for clang-18 in some way. I'll keep this in mind. https://github.com/llvm/llvm-project/pull/70792 __

[lld] [clang] [clang-tools-extra] [flang] [libcxx] [llvm] [libc] [lldb] [OpenACC] Initial commits to support OpenACC (PR #70234)

2023-11-02 Thread Erich Keane via cfe-commits
@@ -605,6 +605,17 @@ static void InitializeStandardPredefinedMacros(const TargetInfo &TI, Builder.defineMacro("HIP_API_PER_THREAD_DEFAULT_STREAM"); } } + + if (LangOpts.OpenACC) { +// FIXME: When we have full support for OpenACC, we should set this to the +

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Erich Keane via cfe-commits
@@ -7416,3 +7416,69 @@ that ``p->array`` must have at least ``p->count`` number of elements available: }]; } + +def CoroOnlyDestroyWhenCompleteDocs : Documentation { + let Category = DocCatDecl; + let Content = [{ +The `coro_only_destroy_when_complete` attribute should be

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Erich Keane via cfe-commits
@@ -7416,3 +7416,69 @@ that ``p->array`` must have at least ``p->count`` number of elements available: }]; } + +def CoroOnlyDestroyWhenCompleteDocs : Documentation { + let Category = DocCatDecl; + let Content = [{ +The `coro_only_destroy_when_complete` attribute should be

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane commented: Didn't dig into the LLVM section of this, but the CFE section looks good delta some small documentation changes. https://github.com/llvm/llvm-project/pull/71014 ___ cfe-commits mailing list cfe-commits@lists.ll

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Erich Keane via cfe-commits
@@ -7416,3 +7416,69 @@ that ``p->array`` must have at least ``p->count`` number of elements available: }]; } + +def CoroOnlyDestroyWhenCompleteDocs : Documentation { + let Category = DocCatDecl; + let Content = [{ +The `coro_only_destroy_when_complete` attribute should be

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane edited https://github.com/llvm/llvm-project/pull/71014 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AArch64][Clang] Refactor code to emit SVE & SME builtins (PR #70959)

2023-11-02 Thread Sander de Smalen via cfe-commits
https://github.com/sdesmalen-arm approved this pull request. This patch was reviewed as part of PR #70662, so I'm happy for this patch to reland. https://github.com/llvm/llvm-project/pull/70959 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Erich Keane via cfe-commits
@@ -7416,3 +7416,69 @@ that ``p->array`` must have at least ``p->count`` number of elements available: }]; } + +def CoroOnlyDestroyWhenCompleteDocs : Documentation { + let Category = DocCatDecl; + let Content = [{ +The `coro_only_destroy_when_complete` attribute should be

[clang] [llvm] [NFC] Remove Type::getInt8PtrTy (PR #71029)

2023-11-02 Thread Paulo Matos via cfe-commits
pmatos wrote: > Nit: can you add in the description that this is a follow-up from the opaque > pointer transition (having an explicit motivation helps read a patch). Thanks! you're right. done. https://github.com/llvm/llvm-project/pull/71029 ___ cfe-

[llvm] [lld] [libc] [libcxx] [flang] [clang-tools-extra] [clang] [lldb] [OpenACC] Initial commits to support OpenACC (PR #70234)

2023-11-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane updated https://github.com/llvm/llvm-project/pull/70234 >From b3d64b3f744ccb37e334e3aae8d6874cd8391c56 Mon Sep 17 00:00:00 2001 From: erichkeane Date: Mon, 23 Oct 2023 11:09:11 -0700 Subject: [PATCH 1/6] [OpenACC] Initial commit for OpenACC Support This is the ini

[clang] [analyzer] Improve diagnostics from ArrayBoundCheckerV2 (PR #70056)

2023-11-02 Thread Balazs Benics via cfe-commits
=?utf-8?q?Donát?= Nagy , =?utf-8?q?Donát?= Nagy Message-ID: In-Reply-To: @@ -0,0 +1,149 @@ +// RUN: %clang_analyze_cc1 -Wno-array-bounds -analyzer-output=text\ +// RUN: -analyzer-checker=core,alpha.security.ArrayBoundV2,unix.Malloc,alpha.security.taint -verify %s

[clang] [clang][Interp] Handle std::move etc. builtins (PR #70772)

2023-11-02 Thread Timm Baeder via cfe-commits
Timm =?utf-8?q?Bäder?= Message-ID: In-Reply-To: tbaederr wrote: > Nice. I realise you're following the convention already established in the > test file, but have you considered compiling with `-verify=new,both` and > `-verify=ref,both`, respectively, and combining the shared diagnostics int

[clang] [llvm] [NFC] Remove Type::getInt8PtrTy (PR #71029)

2023-11-02 Thread Paulo Matos via cfe-commits
https://github.com/pmatos edited https://github.com/llvm/llvm-project/pull/71029 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 updated https://github.com/llvm/llvm-project/pull/71014 >From a2dae250abf20d47a7db4da65e25ff33bca28e67 Mon Sep 17 00:00:00 2001 From: Chuanqi Xu Date: Thu, 2 Nov 2023 11:11:59 +0800 Subject: [PATCH 1/2] [Coroutines] Introduce [[clang::coro_only_destroy_when_comple

[clang] [llvm] [AIX][TOC] Add -mtocdata/-mno-tocdata options on AIX (PR #67999)

2023-11-02 Thread via cfe-commits
@@ -265,6 +269,61 @@ bool AIXTargetCodeGenInfo::initDwarfEHRegSizeTable( return PPC_initDwarfEHRegSizeTable(CGF, Address, Is64Bit, /*IsAIX*/ true); } +void AIXTargetCodeGenInfo::setTargetAttributes( +const Decl *D, llvm::GlobalValue *GV, CodeGen::CodeGenModule &M) const

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Chuanqi Xu via cfe-commits
@@ -7416,3 +7416,69 @@ that ``p->array`` must have at least ``p->count`` number of elements available: }]; } + +def CoroOnlyDestroyWhenCompleteDocs : Documentation { + let Category = DocCatDecl; + let Content = [{ +The `coro_only_destroy_when_complete` attribute should be

[clang] [llvm] [AIX][TOC] Add -mtocdata/-mno-tocdata options on AIX (PR #67999)

2023-11-02 Thread via cfe-commits
@@ -0,0 +1,64 @@ +// RUN: %clang_cc1 %s -triple powerpc-ibm-aix-xcoff -S -mtocdata=a4,a5,a8,a9,b,c,d,e,v -emit-llvm -o - 2>&1 \ +// RUN: | FileCheck %s -check-prefixes=CHECK32 --match-full-lines +// RUN: %clang_cc1 %s -triple powerpc-ibm-aix-xcoff -S -mtocdata -emit-llv

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. CFE stuff looks good, but someone more familiar with the LLVM changes needs to do final approval. https://github.com/llvm/llvm-project/pull/71014 ___ cfe-commits mailing list cfe-commits@lists.

[clang] [llvm] [AIX][TOC] Add -mtocdata/-mno-tocdata options on AIX (PR #67999)

2023-11-02 Thread via cfe-commits
@@ -0,0 +1,69 @@ +// REQUIRES: powerpc-registered-target +// RUN: %clang_cc1 %s -triple=powerpc-ibm-aix-xcoff -S -mtocdata=h,g,f,e,d,c,b,a,globalOneWithAlias,globalTwoWithAlias,ll,t3 -verify -emit-llvm -o - | FileCheck %s -check-prefix=CHECK --match-full-lines +// RUN: %clang_cc

[clang] [analyzer] Improve diagnostics from ArrayBoundCheckerV2 (PR #70056)

2023-11-02 Thread Balazs Benics via cfe-commits
=?utf-8?q?Donát?= Nagy , =?utf-8?q?Donát?= Nagy Message-ID: In-Reply-To: @@ -217,80 +326,71 @@ void ArrayBoundCheckerV2::checkLocation(SVal location, bool isLoad, // MallocChecker that call SValBuilder::getConjuredHeapSymbolVal()) and // non-symbolic regions (e.g. a

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Chuanqi Xu via cfe-commits
@@ -7416,3 +7416,69 @@ that ``p->array`` must have at least ``p->count`` number of elements available: }]; } + +def CoroOnlyDestroyWhenCompleteDocs : Documentation { + let Category = DocCatDecl; + let Content = [{ +The `coro_only_destroy_when_complete` attribute should be

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Erich Keane via cfe-commits
erichkeane wrote: Also note: This needs a Release Note in ReleaseNotes.rst. https://github.com/llvm/llvm-project/pull/71014 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Erich Keane via cfe-commits
@@ -7416,3 +7416,69 @@ that ``p->array`` must have at least ``p->count`` number of elements available: }]; } + +def CoroOnlyDestroyWhenCompleteDocs : Documentation { + let Category = DocCatDecl; + let Content = [{ +The `coro_only_destroy_when_complete` attribute should be

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Chuanqi Xu via cfe-commits
@@ -7416,3 +7416,69 @@ that ``p->array`` must have at least ``p->count`` number of elements available: }]; } + +def CoroOnlyDestroyWhenCompleteDocs : Documentation { + let Category = DocCatDecl; + let Content = [{ +The `coro_only_destroy_when_complete` attribute should be

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Chuanqi Xu via cfe-commits
@@ -7416,3 +7416,69 @@ that ``p->array`` must have at least ``p->count`` number of elements available: }]; } + +def CoroOnlyDestroyWhenCompleteDocs : Documentation { + let Category = DocCatDecl; + let Content = [{ +The `coro_only_destroy_when_complete` attribute should be

[clang] [clang]get non-injected-class before finding instantiated decl (PR #70886)

2023-11-02 Thread Henrik G. Olsson via cfe-commits
https://github.com/hnrklssn commented: LGTM, but I'm not very familiar with the C++ specific parts of clang, so someone else ought to take a look also https://github.com/llvm/llvm-project/pull/70886 ___ cfe-commits mailing list cfe-commits@lists.llvm.

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. CFE + Release note LGTM. Again, please wait on someone to be review the LLVM changes. https://github.com/llvm/llvm-project/pull/71014 ___ cfe-commits mailing list cfe-commits@lists.llvm.org ht

[clang] [analyzer] Fix uninitialized base class with initializer list when ctor is not declared in the base class (#70464) (PR #70792)

2023-11-02 Thread Balazs Benics via cfe-commits
steakhal wrote: > As #59493 is an array, which is different from the test case I provided and > the ones in #61919 and #54533, although this pr can correctly handle the > array case, do I still need to add the array one to the test case? It would be really nice if you could. Thanks! https:/

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Erich Keane via cfe-commits
@@ -7416,3 +7416,69 @@ that ``p->array`` must have at least ``p->count`` number of elements available: }]; } + +def CoroOnlyDestroyWhenCompleteDocs : Documentation { + let Category = DocCatDecl; + let Content = [{ +The `coro_only_destroy_when_complete` attribute should be

[clang] [llvm] [AIX][TOC] Add -mtocdata/-mno-tocdata options on AIX (PR #67999)

2023-11-02 Thread via cfe-commits
@@ -0,0 +1,16 @@ +; RUN: not --crash llc -mtriple powerpc-ibm-aix-xcoff < %s 2>&1 | FileCheck %s --check-prefix CHECK-ERROR +; RUN: not --crash llc -mtriple powerpc64-ibm-aix-xcoff < %s 2>&1 | FileCheck %s --check-prefix CHECK-ERROR + +@a = global [5 x i16] zeroinitializer, alig

[clang] [analyzer] Fix uninitialized base class with initializer list when ctor is not declared in the base class (#70464) (PR #70792)

2023-11-02 Thread Ella Ma via cfe-commits
Snape3058 wrote: As #59493 is an array, which is different from the test case I provided and the ones in #61919 and #54533, although this pr can correctly handle the array case, do I still need to add the array one to the test case? ```cpp // Additional test case from issue #59493 namespace in

[flang] [clang] [libcxx] [mlir] [lldb] [llvm] [Flang][OpenMP] Port openmp threadprivate-use-association.f90 test to HLFIR flow (PR #71043)

2023-11-02 Thread chandan singh via cfe-commits
https://github.com/chandankds closed https://github.com/llvm/llvm-project/pull/71043 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-repl] [test] Make an XFAIL more precise (PR #70991)

2023-11-02 Thread Paul T Robinson via cfe-commits
pogo59 wrote: FTR, the "Worker" tab on that buildbot page will point you to the maintainer. But tagging me is also fine in general. I'm unable to repro the problem locally because my local build doesn't seem to include clang-repl.exe, so the whole clang/test/Interpreter directory is Unsupporte

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 updated https://github.com/llvm/llvm-project/pull/71014 >From a2dae250abf20d47a7db4da65e25ff33bca28e67 Mon Sep 17 00:00:00 2001 From: Chuanqi Xu Date: Thu, 2 Nov 2023 11:11:59 +0800 Subject: [PATCH 1/3] [Coroutines] Introduce [[clang::coro_only_destroy_when_comple

[clang] [llvm] [PowerPC] Add an alias for -mregnames so that full register names used in assembly. (PR #70255)

2023-11-02 Thread Stefan Pintilie via cfe-commits
https://github.com/stefanp-ibm updated https://github.com/llvm/llvm-project/pull/70255 >From c57979d3d86362df239d3d3ff8cda124d40bb79d Mon Sep 17 00:00:00 2001 From: Stefan Pintilie Date: Wed, 25 Oct 2023 15:21:11 -0500 Subject: [PATCH 1/6] [PowerPC] Add an alias for -mregnames so that full reg

[clang] [llvm] [AIX][TOC] Add -mtocdata/-mno-tocdata options on AIX (PR #67999)

2023-11-02 Thread via cfe-commits
@@ -0,0 +1,31 @@ +// RUN: %clang_cc1 %s -triple powerpc-unknown-aix -S -mtocdata=g1,g2,g3 -emit-llvm -o - | FileCheck %s -check-prefix=CHECK-MIX --match-full-lines diggerlin wrote: I am not sure the purpose of the test case, I think all the test scenario have b

[compiler-rt] [llvm] [clang] [Profile] Refactor profile correlation. (PR #70856)

2023-11-02 Thread Zequan Wu via cfe-commits
ZequanWu wrote: > @ZequanWu this seems to cause issues on macOS: > https://green.lab.llvm.org/green/job/clang-stage1-RA/36184/console > > ``` > Profile-x86_64 :: Darwin/instrprof-debug-info-correlate.c > Profile-x86_64 :: instrprof-darwin- > Profile-x86_64h :: Darwin/instrprof-debug-info-correl

[flang] [clang] [flang][windows] Add option to link against specific MSVC CRT (PR #70833)

2023-11-02 Thread David Truby via cfe-commits
https://github.com/DavidTruby updated https://github.com/llvm/llvm-project/pull/70833 >From 9e84729cada6c032c64934ee519e605407aab049 Mon Sep 17 00:00:00 2001 From: David Truby Date: Tue, 31 Oct 2023 15:07:13 + Subject: [PATCH 1/5] [flang][windows] Add option to link against specific MSVC C

[clang] [analyzer] Fix uninitialized base class with initializer list when ctor is not declared in the base class (#70464) (PR #70792)

2023-11-02 Thread Ella Ma via cfe-commits
Snape3058 wrote: Do I need to * create a new PR? * push directly to this PR on the original branch `Snape3058:issue-70464`? * commit directly without revision? Which operation is correct? (Sorry for not familiar with GitHub) -( https://github.com/llvm/llvm-project/pull/70792 __

[llvm] [clang] [AIX][TOC] Add -mtocdata/-mno-tocdata options on AIX (PR #67999)

2023-11-02 Thread via cfe-commits
@@ -421,13 +421,102 @@ void AIX::AddCXXStdlibLibArgs(const llvm::opt::ArgList &Args, llvm_unreachable("Unexpected C++ library type; only libc++ is supported."); } +// This function processes all the mtocdata options to build the final +// simplified toc data options to pass

[clang] [clang] Separate bit-field padding diagnostics into -Wpadded-bitfield (PR #70978)

2023-11-02 Thread Nico Weber via cfe-commits
https://github.com/nico approved this pull request. lgtm https://github.com/llvm/llvm-project/pull/70978 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Reland "[clang][Sema] Use original template pattern when declaring implicit deduction guides for nested template classes" (PR #69676)

2023-11-02 Thread kadir çetinkaya via cfe-commits
kadircet wrote: thanks for the revert! I also encountered certain crashes bisecting back to this patch, with a similar reproducer: ``` template struct Module { template struct Baz { template explicit Baz(X); }; Baz(int) -> Baz; }; struct Bar {}; void foo() { Module::Baz x{2}

[llvm] [clang] [AIX][TOC] Add -mtocdata/-mno-tocdata options on AIX (PR #67999)

2023-11-02 Thread via cfe-commits
https://github.com/diggerlin edited https://github.com/llvm/llvm-project/pull/67999 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang] [AMDGPU] Add code model (#70760) test for amdgpu target. (PR #71019)

2023-11-02 Thread Yaxun Liu via cfe-commits
@@ -0,0 +1,9 @@ +; RUN: not llc -verify-machineinstrs -o - -mtriple=amdgcn-unknown-amdhsa -mcpu=gfx900 -code-model=tiny < %s 2>&1 | FileCheck %s --check-prefix=TINY +; RUN: not llc -verify-machineinstrs -o - -mtriple=amdgcn-unknown-amdhsa -mcpu=gfx900 -code-model=kernel < %s 2>&

[clang] [analyzer] Fix uninitialized base class with initializer list when ctor is not declared in the base class (#70464) (PR #70792)

2023-11-02 Thread Balazs Benics via cfe-commits
steakhal wrote: > Do I need to > > * create a new PR? > > * push directly to this PR on the original branch `Snape3058:issue-70464`? > > * commit directly without revision? > > > Which operation is correct? > > (Sorry for not familiar with GitHub) -( I'd prefer a new PR, and me

[clang] [AArch64][Clang] Refactor code to emit SVE & SME builtins (PR #70959)

2023-11-02 Thread Kerry McLaughlin via cfe-commits
https://github.com/kmclaughlin-arm closed https://github.com/llvm/llvm-project/pull/70959 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Chuanqi Xu via cfe-commits
@@ -7416,3 +7416,69 @@ that ``p->array`` must have at least ``p->count`` number of elements available: }]; } + +def CoroOnlyDestroyWhenCompleteDocs : Documentation { + let Category = DocCatDecl; + let Content = [{ +The `coro_only_destroy_when_complete` attribute should be

[llvm] [clang] [WebAssembly] Mark externref as not being valid vector elements (PR #71069)

2023-11-02 Thread Paulo Matos via cfe-commits
pmatos wrote: cc: @nikic @jcranmer-intel @tlively @asb I am looking for suggestions for a way forward on this. Issue #69894 triggers the SLPVectorizer that tries to create a vector of 2 externref and calculate its cost. Externref is a WebAssembly type currently represented as a pointer to a

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-02 Thread Chuanqi Xu via cfe-commits
@@ -7416,3 +7416,69 @@ that ``p->array`` must have at least ``p->count`` number of elements available: }]; } + +def CoroOnlyDestroyWhenCompleteDocs : Documentation { + let Category = DocCatDecl; + let Content = [{ +The `coro_only_destroy_when_complete` attribute should be

[clang] [analyzer] Fix uninitialized base class with initializer list when ctor is not declared in the base class (#70464) (PR #70792)

2023-11-02 Thread Ella Ma via cfe-commits
Snape3058 wrote: OK, thanks~ https://github.com/llvm/llvm-project/pull/70792 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer] Fix assertion failure in `CXXInstanceCall::getCXXThisVal` (PR #70837)

2023-11-02 Thread via cfe-commits
@@ -30,3 +30,24 @@ void test(int i) { clang_analyzer_dump(g4); // expected-warning@-1 {{&i [as 64 bit integer]}} } + +struct A { + int n; + void set(int x) { +n = x; + } +}; +using ptr_size = decltype(sizeof(void *)); DonatNagyE wrote: Do I see it c

[clang-tools-extra] [llvm] [clang] [lldb] [flang] [IndVars] Add check of loop invariant for trunc instructions (PR #71072)

2023-11-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-llvm-transforms Author: Markos Horro (markoshorro) Changes The same idea as in 34d380e1f63a7e2cdb9ab1e6498f727fcd710a14, but for truncation instructions. Improvement for #59633. --- Full diff: https://github.com/llvm/llvm-project/pull/71072.diff 2 Fi

<    1   2   3   4   5   >