[clang] [llvm] [ARM] Emit an error when the hard-float ABI is enabled but can't be used. (PR #111334)

2024-11-22 Thread Chris Copeland via cfe-commits
@@ -16,7 +16,7 @@ // RUN: %clang --target=arm-none-eabi -mcpu=cortex-m33 -mfloat-abi=hard -O1 %s -flto=thin -c -o %t.call_thin.bc -DCALL_LIB // RUN: %clang --target=arm-none-eabi -mcpu=cortex-m33 -mfloat-abi=hard -O1 %s -flto=thin -c -o %t.define_thin.bc -DDEFINE_LIB -// RUN

[clang] [llvm] [ARM] Emit an error when the hard-float ABI is enabled but can't be used. (PR #111334)

2024-11-22 Thread Chris Copeland via cfe-commits
https://github.com/chrisnc edited https://github.com/llvm/llvm-project/pull/111334 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [IR] Add TargetExtType::CanBeLocal property (PR #99016)

2024-11-22 Thread Jay Foad via cfe-commits
@@ -838,12 +838,14 @@ static TargetTypeInfo getTargetTypeInfo(const TargetExtType *Ty) { return TargetTypeInfo(PointerType::get(C, 0), TargetExtType::CanBeGlobal); jayfoad wrote: I'm now using the newly added `amdgcn.named.barrier` for testing. https://git

[libcxx] [libcxxabi] [libunwind] [llvm] [runtimes] Probe for -nostdlib++ and -nostdinc++ with the C compiler (PR #108357)

2024-11-22 Thread Martin Storsjö via cfe-commits
mstorsjo wrote: > > > Actually this PR is the case of > > > https://lab.llvm.org/buildbot/#/builders/164/builds/3908, not #113491 > > > > > > Sorry about that. > > Are you able to dig up any of the cmake configure logs from these builds, > > so that we can figure out how this ends up breaking

[clang] 294c5cb - [IR] Add TargetExtType::CanBeLocal property (#99016)

2024-11-22 Thread via cfe-commits
Author: Jay Foad Date: 2024-11-22T10:02:43Z New Revision: 294c5cb2bea88fa048e00757188749f074c5b09f URL: https://github.com/llvm/llvm-project/commit/294c5cb2bea88fa048e00757188749f074c5b09f DIFF: https://github.com/llvm/llvm-project/commit/294c5cb2bea88fa048e00757188749f074c5b09f.diff LOG: [IR]

[clang] [llvm] [IR] Add TargetExtType::CanBeLocal property (PR #99016)

2024-11-22 Thread Jay Foad via cfe-commits
https://github.com/jayfoad closed https://github.com/llvm/llvm-project/pull/99016 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [LoongArch] Support LA V1.1 feature ld-seq-sa that don't generate dbar 0x700. (PR #116762)

2024-11-22 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `openmp-offload-libc-amdgpu-runtime` running on `omp-vega20-1` while building `clang,llvm` at step 10 "Add check check-offload". Full details are available at: https://lab.llvm.org/buildbot/#/builders/73/builds/8976 Here is

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Gábor Horváth via cfe-commits
https://github.com/Xazax-hun edited https://github.com/llvm/llvm-project/pull/117122 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Gábor Horváth via cfe-commits
@@ -7,3 +7,106 @@ struct S { }; // CHECK: CXXMethodDecl {{.*}}clang::lifetime_capture_by(a, b, global) + +// +// Infer annotation for STL container methods. +// ***

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
@@ -268,6 +268,40 @@ void Sema::inferLifetimeBoundAttribute(FunctionDecl *FD) { } } +static bool IsPointerLikeType(QualType QT) { + QT = QT.getNonReferenceType(); + if (QT->isPointerType()) +return true; + auto *RD = QT->getAsCXXRecordDecl(); + if (!RD) +return f

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Gábor Horváth via cfe-commits
https://github.com/Xazax-hun approved this pull request. Once @hokein's comments are addressed, it looks good to me. https://github.com/llvm/llvm-project/pull/117122 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bi

[clang] [clang] Check specialization for annotation (PR #117315)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 created https://github.com/llvm/llvm-project/pull/117315 None >From e30ae8a6e0c1df8e33c2add6502342cb269c1cfd Mon Sep 17 00:00:00 2001 From: Utkarsh Saxena Date: Fri, 22 Nov 2024 11:02:49 + Subject: [PATCH] [clang] Check specialization for annotation --- clang/lib

[clang] [clang] Check specialization for annotation (PR #117315)

2024-11-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Utkarsh Saxena (usx95) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/117315.diff 1 Files Affected: - (modified) clang/lib/Sema/CheckExprLifetime.cpp (+6-3) ``diff diff --git a/clang/lib/Sema/CheckExprLifet

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 updated https://github.com/llvm/llvm-project/pull/117122 >From 9a57223b06a8331a0ef123739a430863dee19d98 Mon Sep 17 00:00:00 2001 From: Utkarsh Saxena Date: Thu, 21 Nov 2024 07:00:56 + Subject: [PATCH 1/3] [clang] Infer lifetime_capture_by for STL containers --- cl

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
@@ -268,6 +268,40 @@ void Sema::inferLifetimeBoundAttribute(FunctionDecl *FD) { } } +static bool IsPointerLikeType(QualType QT) { + QT = QT.getNonReferenceType(); + if (QT->isPointerType()) +return true; + auto *RD = QT->getAsCXXRecordDecl(); + if (!RD) +return f

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/117122 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Warn const integer-overflow of member in temporary struct bound to rvalue reference (PR #117225)

2024-11-22 Thread Youngsuk Kim via cfe-commits
https://github.com/JOE1994 updated https://github.com/llvm/llvm-project/pull/117225 >From 08e1a3388e9d98f2469687d2367472342b05c47e Mon Sep 17 00:00:00 2001 From: Youngsuk Kim Date: Thu, 21 Nov 2024 13:05:20 -0600 Subject: [PATCH 1/2] [clang] Warn const integer-overflow of member in temporary s

[clang] 1d46020 - [LoongArch] Support LA V1.1 feature ld-seq-sa that don't generate dbar 0x700. (#116762)

2024-11-22 Thread via cfe-commits
Author: tangaac Date: 2024-11-22T17:34:15+08:00 New Revision: 1d4602070f96c9a6921d51a3b907f90cd2e3ae32 URL: https://github.com/llvm/llvm-project/commit/1d4602070f96c9a6921d51a3b907f90cd2e3ae32 DIFF: https://github.com/llvm/llvm-project/commit/1d4602070f96c9a6921d51a3b907f90cd2e3ae32.diff LOG:

[clang] [llvm] [LoongArch] Support LA V1.1 feature ld-seq-sa that don't generate dbar 0x700. (PR #116762)

2024-11-22 Thread Lu Weining via cfe-commits
https://github.com/SixWeining approved this pull request. https://github.com/llvm/llvm-project/pull/116762 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [LoongArch] Support LA V1.1 feature ld-seq-sa that don't generate dbar 0x700. (PR #116762)

2024-11-22 Thread Lu Weining via cfe-commits
https://github.com/SixWeining closed https://github.com/llvm/llvm-project/pull/116762 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Haojian Wu via cfe-commits
@@ -268,6 +268,40 @@ void Sema::inferLifetimeBoundAttribute(FunctionDecl *FD) { } } +static bool IsPointerLikeType(QualType QT) { + QT = QT.getNonReferenceType(); + if (QT->isPointerType()) +return true; + auto *RD = QT->getAsCXXRecordDecl(); + if (!RD) +return f

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Haojian Wu via cfe-commits
@@ -7,3 +7,106 @@ struct S { }; // CHECK: CXXMethodDecl {{.*}}clang::lifetime_capture_by(a, b, global) + +// +// Infer annotation for STL container methods. +// ***

[clang] [llvm] [ARM] Emit an error when the hard-float ABI is enabled but can't be used. (PR #111334)

2024-11-22 Thread Chris Copeland via cfe-commits
https://github.com/chrisnc edited https://github.com/llvm/llvm-project/pull/111334 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Implement RWBuffer::operator[] via __builtin_hlsl_resource_getpointer (PR #117017)

2024-11-22 Thread Justin Bogner via cfe-commits
https://github.com/bogner updated https://github.com/llvm/llvm-project/pull/117017 >From a4e932c29bddb78bd287cabca2e9ea0da6c96337 Mon Sep 17 00:00:00 2001 From: Justin Bogner Date: Wed, 13 Nov 2024 17:04:30 -0800 Subject: [PATCH 1/3] [HLSL] Implement RWBuffer::operator[] via __builtin_hlsl_res

[clang] [llvm] [ARM] Emit an error when the hard-float ABI is enabled but can't be used. (PR #111334)

2024-11-22 Thread via cfe-commits
workingjubilee wrote: > I agree but was having trouble putting it into words. I don't have a > reference I can put my hands on, but we have generally considered the llvm > error messages to be a poor substitute to those produced by clang and have > often gone the other way, converting llvm err

[clang] [HLSL] Implement RWBuffer::operator[] via __builtin_hlsl_resource_getpointer (PR #117017)

2024-11-22 Thread Justin Bogner via cfe-commits
@@ -12487,6 +12487,7 @@ def err_hlsl_pointers_unsupported : Error< "%select{pointers|references}0 are unsupported in HLSL">; def err_hlsl_missing_resource_class : Error<"HLSL resource needs to have [[hlsl::resource_class()]] attribute">; def err_hlsl_attribute_needs_intangib

[clang] [HLSL] Implement RWBuffer::operator[] via __builtin_hlsl_resource_getpointer (PR #117017)

2024-11-22 Thread Justin Bogner via cfe-commits
@@ -4738,6 +4738,12 @@ def GetDeviceSideMangledName : LangBuiltin<"CUDA_LANG"> { } // HLSL +def HLSLTypedBufferPointer : LangBuiltin<"HLSL_LANG"> { + let Spellings = ["__builtin_hlsl_resource_getpointer"]; bogner wrote: All buffer types, the name was leftove

[clang] [clang] Warn const integer-overflow of member in temporary struct bound to rvalue reference (PR #117225)

2024-11-22 Thread Youngsuk Kim via cfe-commits
https://github.com/JOE1994 updated https://github.com/llvm/llvm-project/pull/117225 >From 08e1a3388e9d98f2469687d2367472342b05c47e Mon Sep 17 00:00:00 2001 From: Youngsuk Kim Date: Thu, 21 Nov 2024 13:05:20 -0600 Subject: [PATCH 1/2] [clang] Warn const integer-overflow of member in temporary s

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Haojian Wu via cfe-commits
@@ -7,3 +7,106 @@ struct S { }; // CHECK: CXXMethodDecl {{.*}}clang::lifetime_capture_by(a, b, global) + +// +// Infer annotation for STL container methods. +// ***

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/117122 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] c11b6b1 - [RISCV] Support __builtin_cpu_is

2024-11-22 Thread via cfe-commits
Author: Pengcheng Wang Date: 2024-11-22T20:04:57+08:00 New Revision: c11b6b1b8af7454b35eef342162dc2cddf54b4de URL: https://github.com/llvm/llvm-project/commit/c11b6b1b8af7454b35eef342162dc2cddf54b4de DIFF: https://github.com/llvm/llvm-project/commit/c11b6b1b8af7454b35eef342162dc2cddf54b4de.diff

[clang] [llvm] [RISCV] Support __builtin_cpu_is (PR #116231)

2024-11-22 Thread Pengcheng Wang via cfe-commits
https://github.com/wangpc-pp closed https://github.com/llvm/llvm-project/pull/116231 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Support __builtin_cpu_is (PR #116231)

2024-11-22 Thread Pengcheng Wang via cfe-commits
https://github.com/wangpc-pp edited https://github.com/llvm/llvm-project/pull/116231 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-cl] [Sema] Support MSVC non-const lvalue to user-defined temporary reference (PR #99833)

2024-11-22 Thread Roger Sanders via cfe-commits
RogerSanders wrote: I'd like to see this change make it into the repo, as I'm in a similar situation with a 6+ million line codebase. What's the next steps to advance this? https://github.com/llvm/llvm-project/pull/99833 ___ cfe-commits mailing list

[clang] [analyzer] Print the PostInitializer target in exploded-graph-rewriter (PR #116034)

2024-11-22 Thread Balazs Benics via cfe-commits
steakhal wrote: Ping @NagyDonat https://github.com/llvm/llvm-project/pull/116034 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Warn const integer-overflow of member in temporary struct bound to rvalue reference (PR #117225)

2024-11-22 Thread Youngsuk Kim via cfe-commits
https://github.com/JOE1994 closed https://github.com/llvm/llvm-project/pull/117225 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] ef20644 - [clang] Warn const integer-overflow of member in temporary struct bound to rvalue reference (#117225)

2024-11-22 Thread via cfe-commits
Author: Youngsuk Kim Date: 2024-11-22T04:51:09-05:00 New Revision: ef206446f2bbcb1bacc73d7611a96c457f59499f URL: https://github.com/llvm/llvm-project/commit/ef206446f2bbcb1bacc73d7611a96c457f59499f DIFF: https://github.com/llvm/llvm-project/commit/ef206446f2bbcb1bacc73d7611a96c457f59499f.diff

[clang] [clang] Allow delayed function instantiation at TU end if initial instantiation fails (PR #117167)

2024-11-22 Thread via cfe-commits
https://github.com/StefanPaulet updated https://github.com/llvm/llvm-project/pull/117167 >From 54199baf4a6a205e0b85f9f528a90b8170a960fa Mon Sep 17 00:00:00 2001 From: StefanPaulet Date: Thu, 21 Nov 2024 15:32:56 +0200 Subject: [PATCH 1/3] [clang] Allow delayed function instantiation at TU end i

[clang] [llvm] [llvm][NFC] `APFloat`: Add missing semantics to enum (PR #117291)

2024-11-22 Thread Durgadoss R via cfe-commits
durga4github wrote: Hi @matthias-springer , Can we split this into at least two separate PRs? One for the first two items in the commit message. And one (or two) PRs for the rest of the changes. https://github.com/llvm/llvm-project/pull/117291 ___ c

[clang] [clang] Allow delayed function instantiation at TU end if initial instantiation fails (PR #117167)

2024-11-22 Thread via cfe-commits
https://github.com/StefanPaulet updated https://github.com/llvm/llvm-project/pull/117167 >From d4ab1ecd5672f7bd3e90230b1739deb981e6353c Mon Sep 17 00:00:00 2001 From: StefanPaulet Date: Thu, 21 Nov 2024 15:32:56 +0200 Subject: [PATCH] [clang] Allow delayed function instantiation at TU end if i

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
@@ -268,6 +268,40 @@ void Sema::inferLifetimeBoundAttribute(FunctionDecl *FD) { } } +static bool IsPointerLikeType(QualType QT) { + QT = QT.getNonReferenceType(); + if (QT->isPointerType()) +return true; + auto *RD = QT->getAsCXXRecordDecl(); + if (!RD) +return f

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/117122 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/117122 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [SYCL] change sycl version accrodnig to standard (PR #114790)

2024-11-22 Thread via cfe-commits
https://github.com/dklochkov-emb updated https://github.com/llvm/llvm-project/pull/114790 >From dafdcfe5832f842aae275d9c644c8a9d722c7acb Mon Sep 17 00:00:00 2001 From: "Klochkov, Denis" Date: Mon, 4 Nov 2024 04:58:30 -0800 Subject: [PATCH] [SYCL] change sycl version accrodnig to standard [SYCL

[clang-tools-extra] 5518bb2 - [clangd] Check getFunctionTypeLoc() for validity in InlayHintVisitor (#117296)

2024-11-22 Thread via cfe-commits
Author: Nathan Ridge Date: 2024-11-22T03:11:07-05:00 New Revision: 5518bb215b51cc339c3ecac064032f6791ae6476 URL: https://github.com/llvm/llvm-project/commit/5518bb215b51cc339c3ecac064032f6791ae6476 DIFF: https://github.com/llvm/llvm-project/commit/5518bb215b51cc339c3ecac064032f6791ae6476.diff

[clang] [HLSL] Get the index for resource bindings from the slot (PR #117303)

2024-11-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Justin Bogner (bogner) Changes Resource bindings are indexed from the beginning of the binding space, not from the binding itself. This means that we need to populate the index for non-array resources with the same value as the slot numbe

[clang] [clang][bytecode][NFC] Avoid a getSource() call (PR #117311)

2024-11-22 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/117311 This is only needed when we actually emit a diagnostic, so move the getSource() after the early return. >From bf0c37684268d7afa41beb6035aa137d633ea596 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der

[clang] [clang][bytecode][NFC] Avoid a getSource() call (PR #117311)

2024-11-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes This is only needed when we actually emit a diagnostic, so move the getSource() after the early return. --- Full diff: https://github.com/llvm/llvm-project/pull/117311.diff 1 Files Affected: - (modified)

[clang] [clang][bytecode] Support ImplicitValueInitExpr for multi-dim arrays (PR #117312)

2024-11-22 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/117312 The attached test case from https://github.com/llvm/llvm-project/issues/117294 used to cause an assertion because we called classifPrim() on an array type. The new result doesn't crash but isn't exactly perfec

[clang] [clang][bytecode] Support ImplicitValueInitExpr for multi-dim arrays (PR #117312)

2024-11-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes The attached test case from https://github.com/llvm/llvm-project/issues/117294 used to cause an assertion because we called classifPrim() on an array type. The new result doesn't crash but isn't exactly perf

[clang] [Clang] Enable -fpointer-tbaa by default. (PR #117244)

2024-11-22 Thread Florian Hahn via cfe-commits
fhahn wrote: > This seems reasonable to me. Since it's standards-compliant, has a specific > opt-out flag, and is overridden by the general `-fno-strict-aliasing` flag, I > don't see any need for the RFC process. Still, you should definitely wait for > more feedback, especially from @AaronBall

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
@@ -7,3 +7,106 @@ struct S { }; // CHECK: CXXMethodDecl {{.*}}clang::lifetime_capture_by(a, b, global) + +// +// Infer annotation for STL container methods. +// ***

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 updated https://github.com/llvm/llvm-project/pull/117122 >From 9a57223b06a8331a0ef123739a430863dee19d98 Mon Sep 17 00:00:00 2001 From: Utkarsh Saxena Date: Thu, 21 Nov 2024 07:00:56 + Subject: [PATCH 1/4] [clang] Infer lifetime_capture_by for STL containers --- cl

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
@@ -7,3 +7,106 @@ struct S { }; // CHECK: CXXMethodDecl {{.*}}clang::lifetime_capture_by(a, b, global) + +// +// Infer annotation for STL container methods. +// ***

[clang] [clang] Allow delayed function instantiation at TU end if initial instantiation fails (PR #117167)

2024-11-22 Thread via cfe-commits
https://github.com/StefanPaulet updated https://github.com/llvm/llvm-project/pull/117167 >From 54199baf4a6a205e0b85f9f528a90b8170a960fa Mon Sep 17 00:00:00 2001 From: StefanPaulet Date: Thu, 21 Nov 2024 15:32:56 +0200 Subject: [PATCH 1/4] [clang] Allow delayed function instantiation at TU end i

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Haojian Wu via cfe-commits
@@ -268,6 +268,40 @@ void Sema::inferLifetimeBoundAttribute(FunctionDecl *FD) { } } +static bool IsPointerLikeType(QualType QT) { + QT = QT.getNonReferenceType(); + if (QT->isPointerType()) +return true; + auto *RD = QT->getAsCXXRecordDecl(); + if (!RD) +return f

[clang-tools-extra] [clangd] Check getFunctionTypeLoc() for validity in InlayHintVisitor (PR #117296)

2024-11-22 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/117296 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [ARM] Emit an error when the hard-float ABI is enabled but can't be used. (PR #111334)

2024-11-22 Thread Chris Copeland via cfe-commits
https://github.com/chrisnc edited https://github.com/llvm/llvm-project/pull/111334 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [LoongArch] Support LA V1.1 feature ld-seq-sa that don't generate dbar 0x700. (PR #116762)

2024-11-22 Thread Lu Weining via cfe-commits
@@ -2011,8 +2011,9 @@ const StringMap sys::getHostCPUFeatures() { const StringMap sys::getHostCPUFeatures() { unsigned long hwcap = getauxval(AT_HWCAP); bool HasFPU = hwcap & (1UL << 3); // HWCAP_LOONGARCH_FPU - uint32_t cpucfg2 = 0x2; + uint32_t cpucfg2 = 0x2, cpucfg3 =

[clang] [llvm] [LoongArch] Support LA V1.1 feature ld-seq-sa that don't generate dbar 0x700. (PR #116762)

2024-11-22 Thread Lu Weining via cfe-commits
https://github.com/SixWeining approved this pull request. LGTM except a nit. https://github.com/llvm/llvm-project/pull/116762 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [LoongArch] Support LA V1.1 feature ld-seq-sa that don't generate dbar 0x700. (PR #116762)

2024-11-22 Thread Lu Weining via cfe-commits
https://github.com/SixWeining edited https://github.com/llvm/llvm-project/pull/116762 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][bytecode] Fix bitcasting from null pointers (PR #116999)

2024-11-22 Thread Timm Baeder via cfe-commits
tbaederr wrote: This needs to incorporate the resolution from https://github.com/llvm/llvm-project/issues/117166, but that doesn't work properly without https://github.com/llvm/llvm-project/pull/116843 mergged first. https://github.com/llvm/llvm-project/pull/116999

[clang] [llvm] [ARM] Emit an error when the hard-float ABI is enabled but can't be used. (PR #111334)

2024-11-22 Thread Chris Copeland via cfe-commits
https://github.com/chrisnc edited https://github.com/llvm/llvm-project/pull/111334 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 updated https://github.com/llvm/llvm-project/pull/117122 >From 9a57223b06a8331a0ef123739a430863dee19d98 Mon Sep 17 00:00:00 2001 From: Utkarsh Saxena Date: Thu, 21 Nov 2024 07:00:56 + Subject: [PATCH 1/2] [clang] Infer lifetime_capture_by for STL containers --- cl

[clang] [HLSL] Get the index for resource bindings from the slot (PR #117303)

2024-11-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-hlsl Author: Justin Bogner (bogner) Changes Resource bindings are indexed from the beginning of the binding space, not from the binding itself. This means that we need to populate the index for non-array resources with the same value as the slot number

[clang] [HLSL] Get the index for resource bindings from the slot (PR #117303)

2024-11-22 Thread Justin Bogner via cfe-commits
https://github.com/bogner created https://github.com/llvm/llvm-project/pull/117303 Resource bindings are indexed from the beginning of the binding space, not from the binding itself. This means that we need to populate the index for non-array resources with the same value as the slot number (a

[clang] [llvm] [ARM] Emit an error when the hard-float ABI is enabled but can't be used. (PR #111334)

2024-11-22 Thread Chris Copeland via cfe-commits
chrisnc wrote: > One use case I'd want to keep working is where we have two functions in the > same object that are hardfp with hardware registers, and soft (with or > without hardware registers). Something like: > > ``` > __attribute__((target("arch=cortex-m33"))) __attribute__((pcs("aapcs-vf

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
@@ -268,6 +268,40 @@ void Sema::inferLifetimeBoundAttribute(FunctionDecl *FD) { } } +static bool IsPointerLikeType(QualType QT) { + QT = QT.getNonReferenceType(); + if (QT->isPointerType()) +return true; + auto *RD = QT->getAsCXXRecordDecl(); + if (!RD) +return f

[clang] b36fcf4 - [RISCV] Rename variable CPUModel to Model

2024-11-22 Thread Wang Pengcheng via cfe-commits
Author: Wang Pengcheng Date: 2024-11-22T20:12:28+08:00 New Revision: b36fcf4f493ad9d30455e178076d91be99f3a7d8 URL: https://github.com/llvm/llvm-project/commit/b36fcf4f493ad9d30455e178076d91be99f3a7d8 DIFF: https://github.com/llvm/llvm-project/commit/b36fcf4f493ad9d30455e178076d91be99f3a7d8.diff

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/117122 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Utkarsh Saxena via cfe-commits
@@ -7,3 +7,106 @@ struct S { }; // CHECK: CXXMethodDecl {{.*}}clang::lifetime_capture_by(a, b, global) + +// +// Infer annotation for STL container methods. +// ***

[clang] [C++20][Modules] Load function body from the module that gives canonical decl (PR #111992)

2024-11-22 Thread Ilya Biryukov via cfe-commits
ilya-biryukov wrote: I have managed to get a small example, but it only crashes for me if I run it directly through our internal build system (not even if I use the exact same Clang binary). There are a few things that might affect that: - the names of the modules used internally are different

[clang] [llvm] Codegen changes for strict modifier with grainsize/num_tasks of taskloop construct (PR #117196)

2024-11-22 Thread CHANDRA GHALE via cfe-commits
https://github.com/chandraghale updated https://github.com/llvm/llvm-project/pull/117196 >From d19f41d39237b3d4fd2923f037743ddd495d5c9f Mon Sep 17 00:00:00 2001 From: Chandra Ghale Date: Thu, 21 Nov 2024 11:15:11 -0600 Subject: [PATCH 1/3] Initial Codegen changes for strict modifier with grain

[clang] f849034 - [AMDGPU] Do not allow the region address space to be converted to generic (#117171)

2024-11-22 Thread via cfe-commits
Author: Joseph Huber Date: 2024-11-22T07:13:49-06:00 New Revision: f84903486cd174e39fb36fa88c98c9563b671c7e URL: https://github.com/llvm/llvm-project/commit/f84903486cd174e39fb36fa88c98c9563b671c7e DIFF: https://github.com/llvm/llvm-project/commit/f84903486cd174e39fb36fa88c98c9563b671c7e.diff

[clang] [AMDGPU] Do not allow the region address space to be converted to generic (PR #117171)

2024-11-22 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/117171 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AMDGPU] Do not allow the region address space to be converted to generic (PR #117171)

2024-11-22 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > Should also forbid the buffers (probably should forbid using the buffers at > all) I think the logic currently allows 0, 1, 3, 4, and 5. https://github.com/llvm/llvm-project/pull/117171 ___ cfe-commits mailing list cfe-commits@lists.

[clang-tools-extra] [clang-tidy] New option `CompilationArgsToRemoveRegex` to remove arguments from the command line (PR #111453)

2024-11-22 Thread Aaron Ballman via cfe-commits
=?utf-8?q?Félix-Antoine?= Constantin Message-ID: In-Reply-To: AaronBallman wrote: > I too have the feeling that this feature is a responsibility of the build > system, not of clang-tidy. What do you think @AaronBallman ? If I understand correctly, this situation is when CMake is configured fo

[clang] [Clang] Add Doug Wyatt and myself as maintainers for function effect analysis (PR #117324)

2024-11-22 Thread via cfe-commits
https://github.com/Sirraide updated https://github.com/llvm/llvm-project/pull/117324 >From 8d1e4b65069c81ffdb05ffdd5308b4dd44451155 Mon Sep 17 00:00:00 2001 From: Sirraide Date: Fri, 22 Nov 2024 13:46:56 +0100 Subject: [PATCH 1/3] [Clang] Add myself and Doug Wyatt as maintainers for function e

[clang] Add Clang attribute to ensure that fields are initialized explicitly (PR #102040)

2024-11-22 Thread via cfe-commits
https://github.com/higher-performance updated https://github.com/llvm/llvm-project/pull/102040 >From e98e6f210f02af0813393d88e1bc4f02c0682e5f Mon Sep 17 00:00:00 2001 From: higher-performance Date: Mon, 5 Aug 2024 15:04:19 -0400 Subject: [PATCH 01/11] Add Clang attribute to ensure that fields a

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-22 Thread Haojian Wu via cfe-commits
https://github.com/hokein approved this pull request. https://github.com/llvm/llvm-project/pull/117122 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Added more descriptive message (issue 116808) (PR #117201)

2024-11-22 Thread via cfe-commits
github-actions[bot] wrote: @tlemy Congratulations on having your first Pull Request (PR) merged into the LLVM Project! Your changes will be combined with recent changes from other authors, then tested by our [build bots](https://lab.llvm.org/buildbot/). If there is a problem with a build, y

[clang] 61f1dc0 - Added more descriptive message (issue 116808) (#117201)

2024-11-22 Thread via cfe-commits
Author: tlemy Date: 2024-11-22T12:24:17-05:00 New Revision: 61f1dc05a88de38afcb337ef194cfdb7dc798197 URL: https://github.com/llvm/llvm-project/commit/61f1dc05a88de38afcb337ef194cfdb7dc798197 DIFF: https://github.com/llvm/llvm-project/commit/61f1dc05a88de38afcb337ef194cfdb7dc798197.diff LOG: Ad

[clang] Added more descriptive message (issue 116808) (PR #117201)

2024-11-22 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/117201 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Added more descriptive message (issue 116808) (PR #117201)

2024-11-22 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman closed https://github.com/llvm/llvm-project/pull/117201 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [clang] Implement pragma clang section on COFF targets (PR #112714)

2024-11-22 Thread Vinicius Tadeu Zein via cfe-commits
@@ -1677,6 +1677,22 @@ MCSection *TargetLoweringObjectFileCOFF::getExplicitSectionGlobal( Name == getInstrProfSectionName(IPSK_covname, Triple::COFF, /*AddSegmentInfo=*/false)) Kind = SectionKind::getMetadata(); + + const Global

[clang] b71038a - [AIX] Fix AIX BuildBot failure as AIX linker doesn't support version script. (#117342)

2024-11-22 Thread via cfe-commits
Author: Daniel Chen Date: 2024-11-22T12:26:44-05:00 New Revision: b71038a69ee95f5dd740f99a1cb7aefde0859562 URL: https://github.com/llvm/llvm-project/commit/b71038a69ee95f5dd740f99a1cb7aefde0859562 DIFF: https://github.com/llvm/llvm-project/commit/b71038a69ee95f5dd740f99a1cb7aefde0859562.diff L

[clang] [libcxx] [clang] Warn about memset/memcpy to NonTriviallyCopyable types (PR #111434)

2024-11-22 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: CC @serge-sans-paille on the request for a separate flag https://github.com/llvm/llvm-project/pull/111434 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][codegen] Mention the invariant that LLVM demangler should be … (PR #117346)

2024-11-22 Thread James Y Knight via cfe-commits
@@ -2047,6 +2047,14 @@ StringRef CodeGenModule::getMangledName(GlobalDecl GD) { GD.getWithKernelReferenceKind(KernelReferenceKind::Kernel), ND)); + // This invariant should hold true in the future. + // Prior work: + // https://discourse.l

[clang] [clang] Allow delayed function instantiation at TU end if initial instantiation fails (PR #117167)

2024-11-22 Thread via cfe-commits
StefanPaulet wrote: @erichkeane https://github.com/llvm/llvm-project/pull/117167 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Add Doug Wyatt and myself as maintainers for function effect analysis (PR #117324)

2024-11-22 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/117324 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Add Doug Wyatt and myself as maintainers for function effect analysis (PR #117324)

2024-11-22 Thread Aaron Ballman via cfe-commits
@@ -176,6 +176,14 @@ Thread Safety Analysis | aaron.puchert\@sap.com (email), aaronpuchert (GitHub), aaronpuchert (Discourse) +Function Effect Analysis + +| Doug Wyatt +| dwyatt\@apple.com (email), dougsonos (GitHub), dougsonos (Discourse) + +| Sirrai

[clang] [Clang] Add Doug Wyatt and myself as maintainers for function effect analysis (PR #117324)

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

[clang] clang: Relax LangOpts checks when lexing quoted numbers during preprocessing (PR #95798)

2024-11-22 Thread Aaron Ballman via cfe-commits
@@ -2068,7 +2068,8 @@ bool Lexer::LexNumericConstant(Token &Result, const char *CurPtr) { } // If we have a digit separator, continue. - if (C == '\'' && (LangOpts.CPlusPlus14 || LangOpts.C23)) { + if (C == '\'' && + (LangOpts.CPlusPlus14 || LangOpts.C23 || Parsing

[clang] [analyzer] Print the PostInitializer target in exploded-graph-rewriter (PR #116034)

2024-11-22 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat approved this pull request. Sorry for missing this review, I didn't noticed that this is distinct from the similar `CallEnter` change. https://github.com/llvm/llvm-project/pull/116034 ___ cfe-commits mailing list cfe-commi

[clang] [Clang] Add Doug Wyatt and myself as maintainers for function effect analysis (PR #117324)

2024-11-22 Thread via cfe-commits
https://github.com/Sirraide created https://github.com/llvm/llvm-project/pull/117324 Doug implemented quite literally all of it and has been continuously improving the implementation by handling more language constructs we had initially missed. I spent a lot of time reviewing the implementatio

[clang] [Clang] Add Doug Wyatt and myself as maintainers for function effect analysis (PR #117324)

2024-11-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (Sirraide) Changes Doug implemented quite literally all of it and has been continuously improving the implementation by handling more language constructs we had initially missed. I spent a lot of time reviewing the implementation of

[clang-tools-extra] [clang-tidy] Enhance modernize-use-starts-ends-with to handle substr patterns (PR #116033)

2024-11-22 Thread Helmut Januschka via cfe-commits
https://github.com/hjanuschka updated https://github.com/llvm/llvm-project/pull/116033 >From 23b4bcdf52041aad1c5581e0f7dc01028770a154 Mon Sep 17 00:00:00 2001 From: Helmut Januschka Date: Wed, 13 Nov 2024 12:52:36 +0100 Subject: [PATCH 1/9] [clang-tidy] Enhance modernize-use-starts-ends-with wi

[clang-tools-extra] [clang-tidy] Enhance modernize-use-starts-ends-with to handle substr patterns (PR #116033)

2024-11-22 Thread Helmut Januschka via cfe-commits
@@ -183,40 +210,45 @@ void UseStartsEndsWithCheck::check(const MatchFinder::MatchResult &Result) { const auto *EndsWithFunction = Result.Nodes.getNodeAs("ends_with_fun"); assert(bool(StartsWithFunction) != bool(EndsWithFunction)); + const CXXMethodDecl *Replacemen

[clang-tools-extra] [clang-tidy] New option `CompilationArgsToRemoveRegex` to remove arguments from the command line (PR #111453)

2024-11-22 Thread Carlos Galvez via cfe-commits
=?utf-8?q?Félix-Antoine?= Constantin Message-ID: In-Reply-To: carlosgalvezp wrote: I too have the feeling that this feature is a responsibility of the build system, not of clang-tidy. What do you think @AaronBallman ? https://github.com/llvm/llvm-project/pull/111453 __

[clang] Add Clang attribute to ensure that fields are initialized explicitly (PR #102040)

2024-11-22 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman commented: There's still a failure being caught by precommit CI that is related: ``` TEST 'Clang :: SemaCXX/uninitialized.cpp' FAILED Exit Code: 1 Command Output (stderr): -- RUN: at line 1: /var/lib/buildkite-agent/build

  1   2   3   4   5   >