[clang] [CIR] Upstream basic alloca and load support (PR #128792)

2025-02-26 Thread Bruno Cardoso Lopes via cfe-commits
@@ -0,0 +1,82 @@ +//===--===// +// +// 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] [CIR] Upstream basic alloca and load support (PR #128792)

2025-02-26 Thread Bruno Cardoso Lopes via cfe-commits
@@ -0,0 +1,82 @@ +//===--===// +// +// 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] Alias cc modifier to c (PR #127719)

2025-02-26 Thread via cfe-commits
https://github.com/PiJoules updated https://github.com/llvm/llvm-project/pull/127719 >From 886754d42cf8619771b0877bc7edde940642c799 Mon Sep 17 00:00:00 2001 From: Leonard Chan Date: Tue, 18 Feb 2025 15:33:05 -0800 Subject: [PATCH] [clang] Alias cc modifier to c https://gcc.gnu.org/onlinedocs/g

[clang] [CIR] Function type return type improvements (PR #128787)

2025-02-26 Thread Bruno Cardoso Lopes via cfe-commits
https://github.com/bcardosolopes approved this pull request. LGTM after applying @erichkeane reviews and @xlauko tablegen suggestion https://github.com/llvm/llvm-project/pull/128787 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.

[clang] [CIR] Upstream basic alloca and load support (PR #128792)

2025-02-26 Thread Bruno Cardoso Lopes via cfe-commits
@@ -115,6 +115,149 @@ def ConstantOp : CIR_Op<"const", let hasFolder = 1; } +//===--===// +// AllocaOp +//===--===// + +class AllocaTypesMa

[clang] [CIR] Upstream basic alloca and load support (PR #128792)

2025-02-26 Thread Andy Kaylor via cfe-commits
@@ -0,0 +1,82 @@ +//===--===// +// +// 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] [HLSL] Fix resource wrapper declaration (PR #125718)

2025-02-26 Thread Steven Perron via cfe-commits
https://github.com/s-perron closed https://github.com/llvm/llvm-project/pull/125718 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Fix resource wrapper declaration (PR #125718)

2025-02-26 Thread Steven Perron via cfe-commits
s-perron wrote: We discussed, and we will be make the wrapper static, but it should be done in sema. https://github.com/llvm/llvm-project/pull/125718 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listin

[clang] [llvm] [HLSL][RootSignature] Implement Parsing of Descriptor Tables (PR #122982)

2025-02-26 Thread Joshua Batista via cfe-commits
@@ -0,0 +1,375 @@ +//=== ParseHLSLRootSignatureTest.cpp - Parse Root Signature tests -===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. bob80905 wrote

[clang] [clang] more useful error message for decomposition declaration missing initializer (PR #127924)

2025-02-26 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik commented: Thank you for improving the summary. @erichkeane mentioned that templates are a special case for the diagnostics with your original approach. Can we add a test that deal w/ templates to verify that the diagnostic works in those case properly? It still looks

[clang] [HLSL] Disallow virtual inheritance and functions (PR #127346)

2025-02-26 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 approved this pull request. https://github.com/llvm/llvm-project/pull/127346 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Fix invalid fixit from modernize-use-ranges for nullptr used with std::unique_ptr (PR #127162)

2025-02-26 Thread via cfe-commits
Andrewyuan34 wrote: > ping me if you want to merge it. Thanks! I'd like to merge it. https://github.com/llvm/llvm-project/pull/127162 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [memprof] Export __memprof_default_options_str on Darwin (PR #128920)

2025-02-26 Thread Ellis Hoag via cfe-commits
@@ -1617,6 +1617,10 @@ void DarwinClang::AddLinkRuntimeLibArgs(const ArgList &Args, } } + if (Sanitize.needsMemProfRt()) +if (hasExportSymbolDirective(Args)) + addExportedSymbol(CmdArgs, "___memprof_default_options_str"); ellishg wrote: Yes,

[clang] [llvm] [RISCV] Xqccmp Code Generation (PR #128815)

2025-02-26 Thread Craig Topper via cfe-commits
https://github.com/topperc approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/128815 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 0f6240c - [HLSL] Allow EmptyDecl in cbuffer/tbuffer (#128250)

2025-02-26 Thread via cfe-commits
Author: Chris B Date: 2025-02-26T08:29:24-06:00 New Revision: 0f6240c4ddc815283f7bd42fe80847295de4a92c URL: https://github.com/llvm/llvm-project/commit/0f6240c4ddc815283f7bd42fe80847295de4a92c DIFF: https://github.com/llvm/llvm-project/commit/0f6240c4ddc815283f7bd42fe80847295de4a92c.diff LOG:

[clang] [HLSL] Allow EmptyDecl in cbuffer/tbuffer (PR #128250)

2025-02-26 Thread Chris B via cfe-commits
https://github.com/llvm-beanz closed https://github.com/llvm/llvm-project/pull/128250 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-repl] Fix error recovery while PTU cleanup (PR #127467)

2025-02-26 Thread Vassil Vassilev via cfe-commits
@@ -114,6 +114,13 @@ TEST_F(InterpreterTest, Errors) { RecoverErr = Interp->Parse("var1 = 424;"); EXPECT_TRUE(!!RecoverErr); + + Err = Interp->Parse("int x = 5; auto capture = [&]() { return x * 2; };").takeError(); vgvassilev wrote: There is no such a

[clang] [llvm] Reapply [CaptureTracking][FunctionAttrs] Add support for CaptureInfo (#125880) (PR #128020)

2025-02-26 Thread Nikita Popov via cfe-commits
https://github.com/nikic updated https://github.com/llvm/llvm-project/pull/128020 >From 8fe91eb24d10e7f641928930dbcf7258f99fd8b8 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Wed, 26 Feb 2025 15:45:38 +0100 Subject: [PATCH 1/4] [MemCpyOpt] Add stack move test with ret-only capture (NFC) F

[clang] [NFC][analyzer] Simplify ownership of checker objects (PR #128887)

2025-02-26 Thread Donát Nagy via cfe-commits
@@ -185,13 +185,11 @@ class CheckerManager { StringRef OptionName, StringRef ExpectedValueDesc) const; - using CheckerRef = CheckerBase *; using CheckerTag = const void *; - using CheckerDtor =

[clang] 8dd8e5f - [Clang] Add BuiltinTemplates.td to generate code for builtin templates (#123736)

2025-02-26 Thread via cfe-commits
Author: Nikolas Klauser Date: 2025-02-26T16:01:14+01:00 New Revision: 8dd8e5f7d692cc43f4322f04034f5c472381aa43 URL: https://github.com/llvm/llvm-project/commit/8dd8e5f7d692cc43f4322f04034f5c472381aa43 DIFF: https://github.com/llvm/llvm-project/commit/8dd8e5f7d692cc43f4322f04034f5c472381aa43.dif

[clang] [Clang] Add BuiltinTemplates.td to generate code for builtin templates (PR #123736)

2025-02-26 Thread Nikolas Klauser via cfe-commits
https://github.com/philnik777 closed https://github.com/llvm/llvm-project/pull/123736 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-repl] Fix error recovery while PTU cleanup (PR #127467)

2025-02-26 Thread Anutosh Bhat via cfe-commits
@@ -114,6 +114,13 @@ TEST_F(InterpreterTest, Errors) { RecoverErr = Interp->Parse("var1 = 424;"); EXPECT_TRUE(!!RecoverErr); + + Err = Interp->Parse("int x = 5; auto capture = [&]() { return x * 2; };").takeError(); anutosh491 wrote: Shall shift it ther

[clang] [clang] Fix issues with #embed and intializer lists/template arguments (PR #128890)

2025-02-26 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon created https://github.com/llvm/llvm-project/pull/128890 Sometimes number of expressions in InitListExpr is used for template argument deduction. So, in these cases we need to pay attention to real number of expressions including expanded #embed data. Fixes https:

[clang] [clang] Fix issues with #embed and intializer lists/template arguments (PR #128890)

2025-02-26 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Mariya Podchishchaeva (Fznamznon) Changes Sometimes number of expressions in InitListExpr is used for template argument deduction. So, in these cases we need to pay attention to real number of expressions including expanded #embed data.

[clang] Thread Safety Analysis: Improved pointer handling (PR #127396)

2025-02-26 Thread Aaron Puchert via cfe-commits
https://github.com/aaronpuchert approved this pull request. Looks good to me, and thanks for the contribution! > Note, I think for now it might be safer to not enable by default yet, but > I've made a note (and hinted at in changelog) that we're planning to default > enable in future, so that

[clang-tools-extra] [clang-tidy] Add bugprone-smartptr-reset-ambiguous-call check (PR #121291)

2025-02-26 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,68 @@ +// RUN: %check_clang_tidy %s readability-ambiguous-smartptr-reset-call %t \ vbvictor wrote: I'd prefer to leave two separate files, they are easier to read and maintain imho. https://github.com/llvm/llvm-project/pull/121291 ___

[clang] [llvm] Reapply [CaptureTracking][FunctionAttrs] Add support for CaptureInfo (#125880) (PR #128020)

2025-02-26 Thread Nikita Popov via cfe-commits
https://github.com/nikic updated https://github.com/llvm/llvm-project/pull/128020 >From 38dcd5fe7ce04b5d27a4fcf8ac051bf24d5aca31 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Thu, 13 Feb 2025 09:36:35 +0100 Subject: [PATCH 1/3] Reapply [CaptureTracking][FunctionAttrs] Add support for Captu

[clang] [ARM] Introduce -mtp=auto and make it the default (PR #128728)

2025-02-26 Thread via cfe-commits
https://github.com/Zhenhang1213 updated https://github.com/llvm/llvm-project/pull/128728 >From 7a1c99ad03f07a2aa82374597b9c5bac4e5d7d33 Mon Sep 17 00:00:00 2001 From: Austin Date: Tue, 25 Feb 2025 01:24:24 +0800 Subject: [PATCH] [ARM] Aligned mtp behavior and gcc Fix #123864, resolved of the d

[clang] [CIR] Function type return type improvements (PR #128787)

2025-02-26 Thread Henrich Lauko via cfe-commits
xlauko wrote: You don't need to write custom printer/parser for return type. As suggested here https://github.com/llvm/clangir/pull/1413 These can be autogenerated from assembly format: ``` let assemblyFormat = [{ `<` custom($inputs, $varArg) (`->` $optionalReturnType^)? `>` }]; ``` ht

[clang-tools-extra] [clang-tidy] Add bugprone-smartptr-reset-ambiguous-call check (PR #121291)

2025-02-26 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,129 @@ +//===--- AmbiguousSmartptrResetCallCheck.cpp - clang-tidy -===// +// +// 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] [clang-tidy] Add bugprone-smartptr-reset-ambiguous-call check (PR #121291)

2025-02-26 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor edited https://github.com/llvm/llvm-project/pull/121291 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [ARM] Introduce -mtp=auto and make it the default (PR #128728)

2025-02-26 Thread via cfe-commits
https://github.com/Zhenhang1213 edited https://github.com/llvm/llvm-project/pull/128728 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [ARM] Introduce -mtp=auto and make it the default (PR #128728)

2025-02-26 Thread via cfe-commits
https://github.com/Zhenhang1213 updated https://github.com/llvm/llvm-project/pull/128728 >From 019e9432080f21ceef3c5fa0465705c090ead33a Mon Sep 17 00:00:00 2001 From: Austin Date: Tue, 25 Feb 2025 01:24:24 +0800 Subject: [PATCH] [ARM] Introduce -mtp=auto and make it the default This adds a new

[clang] [ARM] Introduce -mtp=auto and make it the default (PR #128728)

2025-02-26 Thread via cfe-commits
https://github.com/Zhenhang1213 updated https://github.com/llvm/llvm-project/pull/128728 >From 019e9432080f21ceef3c5fa0465705c090ead33a Mon Sep 17 00:00:00 2001 From: Austin Date: Tue, 25 Feb 2025 01:24:24 +0800 Subject: [PATCH] [ARM] Introduce -mtp=auto and make it the default This adds a new

[libclc] [libclc] Remove clspv-specific clc conversions (PR #128500)

2025-02-26 Thread Fraser Cormack via cfe-commits
frasercrmck wrote: > This commit is causing regressions on the OpenCL-CTS with `clvk/clspv`. I > need more time to understand what the issue is exactly. Interesting, I'm sorry about that. I diffed `clc-convert.cl` and `clc-clspv-convert.cl` before this change and they were identical, so the c

[clang] [llvm] [AArch64][SVE] Lower unpredicated loads/stores as LDR/STR. (PR #127837)

2025-02-26 Thread Ricardo Jesus via cfe-commits
https://github.com/rj-jesus closed https://github.com/llvm/llvm-project/pull/127837 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Improve diagnostics for vector builtins (PR #125673)

2025-02-26 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl approved this pull request. As far as the HLSL changes go. This looks fine to me. Approved! Please wait for other stakholders before merging. https://github.com/llvm/llvm-project/pull/125673 ___ cfe-commits mailing list cfe-

[libclc] [libclc] Remove clspv-specific clc conversions (PR #128500)

2025-02-26 Thread Romaric Jodin via cfe-commits
rjodinchr wrote: This commit is causing regressions on the OpenCL-CTS with `clvk/clspv`. I need more time to understand what the issue is exactly. https://github.com/llvm/llvm-project/pull/128500 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [verify] Improve the error messages with multiple active prefixes (PR #126068)

2025-02-26 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. I think this is a distinct improvement, and don't see anything to be concerned about in the code. Aaron is away at the WG14 meeting this week so don't expect a review from him anytime soon. That said, please give others ~24 hrs before

[clang] [llvm] [memprof] Add memprof options as a clang frontend flag (PR #128615)

2025-02-26 Thread Teresa Johnson via cfe-commits
@@ -1,11 +1,12 @@ -; RUN: opt < %s -mtriple=x86_64-unknown-linux -passes='function(memprof),memprof-module' -S | FileCheck %s --check-prefixes=CHECK,EMPTY -; RUN: opt < %s -mtriple=x86_64-unknown-linux -passes='function(memprof),memprof-module' -S -memprof-runtime-default-opti

[clang] [llvm] [memprof] Add memprof options as a clang frontend flag (PR #128615)

2025-02-26 Thread Teresa Johnson via cfe-commits
@@ -734,6 +755,10 @@ void darwin::Linker::ConstructJob(Compilation &C, const JobAction &JA, getMachOToolChain().addProfileRTLibs(Args, CmdArgs); + if (Args.hasArg(options::OPT_fmemory_profile_runtime_default_options_EQ)) +if (hasExportSymbolDirective(Args)) + add

[clang] [llvm] [memprof] Add memprof options as a clang frontend flag (PR #128615)

2025-02-26 Thread Teresa Johnson via cfe-commits
https://github.com/teresajohnson commented: Not opposed to adding this as a clang driver flag especially if it is needed for something other than testing/debugging, however, you could presumably always add the exported symbol when -fmemory-profiler is specified (or does the linker give an erro

[clang] [llvm] [memprof] Add memprof options as a clang frontend flag (PR #128615)

2025-02-26 Thread Teresa Johnson via cfe-commits
@@ -17,3 +17,10 @@ // RUN: not %clangxx --target=x86_64-linux-gnu -fprofile-generate -fmemory-profile-use=foo %s -### 2>&1 | FileCheck %s --check-prefix=CONFLICTWITHPGOINSTR // CONFLICTWITHPGOINSTR: error: invalid argument '-fmemory-profile-use=foo' not allowed with '-fprof

[clang] [llvm] [memprof] Add memprof options as a clang frontend flag (PR #128615)

2025-02-26 Thread Teresa Johnson via cfe-commits
https://github.com/teresajohnson edited https://github.com/llvm/llvm-project/pull/128615 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Thread Safety Analysis: Improved pointer handling (PR #127396)

2025-02-26 Thread Marco Elver via cfe-commits
https://github.com/melver closed https://github.com/llvm/llvm-project/pull/127396 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] de10e44 - Thread Safety Analysis: Support warning on passing/returning pointers to guarded variables

2025-02-26 Thread Marco Elver via cfe-commits
Author: Marco Elver Date: 2025-02-26T16:34:33+01:00 New Revision: de10e44b6fe7f3d3cfde3afd8e1222d251172ade URL: https://github.com/llvm/llvm-project/commit/de10e44b6fe7f3d3cfde3afd8e1222d251172ade DIFF: https://github.com/llvm/llvm-project/commit/de10e44b6fe7f3d3cfde3afd8e1222d251172ade.diff L

[clang] [clang] Update SVE load and store intrinsics to have FP8 variants (PR #126726)

2025-02-26 Thread via cfe-commits
@@ -107,6 +107,9 @@ llvm::Type *CodeGenTypes::ConvertTypeForMem(QualType T) { MT->getNumRows() * MT->getNumColumns()); } + if (T->isMFloat8Type()) +return llvm::Type::getIntNTy(getLLVMContext(), 8); Lukacma wrote: ```sug

[clang] 3c8c0d4 - Thread Safety Analysis: Handle address-of followed by dereference

2025-02-26 Thread Marco Elver via cfe-commits
Author: Marco Elver Date: 2025-02-26T16:34:33+01:00 New Revision: 3c8c0d4d8d9bbc160d160e683f7a74fd28574dc6 URL: https://github.com/llvm/llvm-project/commit/3c8c0d4d8d9bbc160d160e683f7a74fd28574dc6 DIFF: https://github.com/llvm/llvm-project/commit/3c8c0d4d8d9bbc160d160e683f7a74fd28574dc6.diff L

[clang] Thread Safety Analysis: Improved pointer handling (PR #127396)

2025-02-26 Thread Marco Elver via cfe-commits
melver wrote: Committed! > Looks good to me, and thanks for the contribution! Thanks for your review! Fingers crossed the Linux kernel changes will also land soon. > > Note, I think for now it might be safer to not enable by default yet, but > > I've made a note (and hinted at in changelog)

[clang] Thread Safety Analysis: Support warning on taking address of guarded variables (PR #123063)

2025-02-26 Thread Marco Elver via cfe-commits
https://github.com/melver closed https://github.com/llvm/llvm-project/pull/123063 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] aace6a2 - [RISCV] Xqcia 0.4 The spec was recently updated, this changes the name in the TD files associated and increments the Extension number in the clang driver. This is mostly a MC change

2025-02-26 Thread via cfe-commits
Author: Luke Quinn Date: 2025-02-26T08:09:20-05:00 New Revision: aace6a2f9d8bffd84a225ef76633421ff541a5d0 URL: https://github.com/llvm/llvm-project/commit/aace6a2f9d8bffd84a225ef76633421ff541a5d0 DIFF: https://github.com/llvm/llvm-project/commit/aace6a2f9d8bffd84a225ef76633421ff541a5d0.diff LO

[clang] [analyzer] Update the undefined assignment checker diagnostics to not use the term 'garbage' (PR #126596)

2025-02-26 Thread via cfe-commits
github-actions[bot] wrote: @dtarditi 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

[clang] [clang] more useful error message for decomposition declaration missing initializer (PR #127924)

2025-02-26 Thread via cfe-commits
https://github.com/kbrav updated https://github.com/llvm/llvm-project/pull/127924 >From 7f7b9b3f2e7324bd290decb7151c9432875b1dd6 Mon Sep 17 00:00:00 2001 From: kbrav Date: Wed, 19 Feb 2025 19:05:05 -0500 Subject: [PATCH 1/3] [clang] more useful error message for decomposition declaration missi

[clang] [clang-repl] Fix error recovery while PTU cleanup (PR #127467)

2025-02-26 Thread Anutosh Bhat via cfe-commits
@@ -114,6 +114,13 @@ TEST_F(InterpreterTest, Errors) { RecoverErr = Interp->Parse("var1 = 424;"); EXPECT_TRUE(!!RecoverErr); + + Err = Interp->Parse("int x = 5; auto capture = [&]() { return x * 2; };").takeError(); anutosh491 wrote: Hmmm @vgvassilev

[clang] [clang-repl] Fix error recovery while PTU cleanup (PR #127467)

2025-02-26 Thread Anutosh Bhat via cfe-commits
@@ -114,6 +114,13 @@ TEST_F(InterpreterTest, Errors) { RecoverErr = Interp->Parse("var1 = 424;"); EXPECT_TRUE(!!RecoverErr); + + Err = Interp->Parse("int x = 5; auto capture = [&]() { return x * 2; };").takeError(); anutosh491 wrote: I meant I see quite

[clang] [CLANG]Update svget, svset, svcreate, svundef to have FP8 variants (PR #126754)

2025-02-26 Thread via cfe-commits
https://github.com/Lukacma approved this pull request. LGTM. At some point we need to switch to using poison, but that is for another patch. https://github.com/llvm/llvm-project/pull/126754 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https

[clang] [llvm] [CaptureTracking][FunctionAttrs] Add support for CaptureInfo (PR #125880)

2025-02-26 Thread Nikita Popov via cfe-commits
nikic wrote: After much suffering, I managed to do a stage2+thinlto build in a Windows VM. I believe this is the root cause: ```llvm ; RUN: opt -S -passes=memcpyopt < %s declare void @init(ptr) declare void @update(ptr) define i32 @test() { %a = alloca i32 %b = alloca i32 call void @init

[clang] defe43b - Add unsigned integer overloads for abs (#128257)

2025-02-26 Thread via cfe-commits
Author: Chris B Date: 2025-02-26T08:38:18-06:00 New Revision: defe43bbffb0d25ec468f0e54b20548ec192ff90 URL: https://github.com/llvm/llvm-project/commit/defe43bbffb0d25ec468f0e54b20548ec192ff90 DIFF: https://github.com/llvm/llvm-project/commit/defe43bbffb0d25ec468f0e54b20548ec192ff90.diff LOG:

[clang] Add unsigned integer overloads for abs (PR #128257)

2025-02-26 Thread Chris B via cfe-commits
@@ -94,3 +122,60 @@ double3 test_abs_double3(double3 p0) { return abs(p0); } // CHECK-LABEL: define noundef nofpclass(nan inf) <4 x double> @_Z16test_abs_double4 // CHECK: call reassoc nnan ninf nsz arcp afn <4 x double> @llvm.fabs.v4f64( double4 test_abs_double4(double4 p0) {

[clang] Add unsigned integer overloads for abs (PR #128257)

2025-02-26 Thread Chris B via cfe-commits
https://github.com/llvm-beanz closed https://github.com/llvm/llvm-project/pull/128257 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][analyzer] Simplify ownership of checker objects (PR #128887)

2025-02-26 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 Author: Donát Nagy (NagyDonat) Changes Previously checker objects were created by raw `new` calls, which necessitated managing and calling their destructors explicitly. This commit refactors this convoluted logic by introducing

[clang] [NFC][analyzer] Simplify ownership of checker objects (PR #128887)

2025-02-26 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat created https://github.com/llvm/llvm-project/pull/128887 Previously checker objects were created by raw `new` calls, which necessitated managing and calling their destructors explicitly. This commit refactors this convoluted logic by introducing `unique_ptr`s that

[clang] [clang][bytecode] Handle UsingDirectiveDecls (PR #128888)

2025-02-26 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/12 By ignoring them. >From 77ec128a7f6bfc92824d0b30e93916dd6a23949a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Wed, 26 Feb 2025 16:03:32 +0100 Subject: [PATCH] [clang][bytecode] Handle Usi

[clang] [clang][bytecode] Handle UsingDirectiveDecls (PR #128888)

2025-02-26 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes By ignoring them. --- Full diff: https://github.com/llvm/llvm-project/pull/12.diff 2 Files Affected: - (modified) clang/lib/AST/ByteCode/Compiler.cpp (+1-1) - (modified) clang/test/AST/ByteCode/litera

[clang] Match .exe on Windows (PR #128894)

2025-02-26 Thread Justin Bogner via cfe-commits
https://github.com/bogner approved this pull request. https://github.com/llvm/llvm-project/pull/128894 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Treat constexpr-unknown value as invalid in `evaluateValue` (PR #128409)

2025-02-26 Thread Yingwei Zheng via cfe-commits
https://github.com/dtcxzyw updated https://github.com/llvm/llvm-project/pull/128409 >From 83248eb164ff53442ad6d0c9d1be20027519bac1 Mon Sep 17 00:00:00 2001 From: Yingwei Zheng Date: Tue, 18 Feb 2025 01:26:26 +0800 Subject: [PATCH 1/5] [Clang][CodeGen] Bail out on constexpr unknown values in Co

[clang] [clang] Fix issues with #embed and intializer lists/template arguments (PR #128890)

2025-02-26 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. Thanks for the fix! LGTM but this is missing a changelog entry https://github.com/llvm/llvm-project/pull/128890 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-

[clang] [llvm] [RISCV][MC] Add assembler support for XRivosVisni (PR #128773)

2025-02-26 Thread Philip Reames via cfe-commits
https://github.com/preames updated https://github.com/llvm/llvm-project/pull/128773 >From 7eab3c685c23c477cbeb3df13fb9e01eacf2378c Mon Sep 17 00:00:00 2001 From: Philip Reames Date: Tue, 25 Feb 2025 11:16:41 -0800 Subject: [PATCH 1/4] [RISCV][MC] Add assembler support for XRivosVisni This impl

[clang] [llvm] [RISCV][MC] Add assembler support for XRivosVisni (PR #128773)

2025-02-26 Thread Philip Reames via cfe-commits
@@ -10,6 +10,46 @@ // //===--===// +class RVInstVXI funct6, RISCVVFormat opv, dag outs, dag ins, +string opcodestr, string argstr> +: RVInst { + bits<5> imm; + bits<5> rs1; + bits<5> vd

[clang] [Clang] Treat constexpr-unknown value as invalid in `EvaluateAsInitializer` (PR #128409)

2025-02-26 Thread Yingwei Zheng via cfe-commits
https://github.com/dtcxzyw ready_for_review https://github.com/llvm/llvm-project/pull/128409 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][analyzer] Simplify ownership of checker objects (PR #128887)

2025-02-26 Thread Balazs Benics via cfe-commits
@@ -185,13 +185,11 @@ class CheckerManager { StringRef OptionName, StringRef ExpectedValueDesc) const; - using CheckerRef = CheckerBase *; using CheckerTag = const void *; - using CheckerDtor =

[clang] [NFC][analyzer] Simplify ownership of checker objects (PR #128887)

2025-02-26 Thread Balazs Benics via cfe-commits
https://github.com/steakhal approved this pull request. https://github.com/llvm/llvm-project/pull/128887 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] Extend support for specifying languages and version in add_new_check.py (PR #100129)

2025-02-26 Thread Marco C. via cfe-commits
Marcondiro wrote: Hello @njames93, After this PR, the class derived from `ClangTidyCheck` created by the script `add_new_check.py` overrides `isLanguageVersionSupported` by default, restricting the check's scope to `LangOpts.CPlusPlus` code. Running `clang-tidy/add_new_check.py readability awe

[clang] [ARM] Introduce -mtp=auto and make it the default (PR #128901)

2025-02-26 Thread via cfe-commits
https://github.com/Zhenhang1213 created https://github.com/llvm/llvm-project/pull/128901 This adds a new value auto to the possible values of the existing -mtp= clang option which controls how the thread pointer is found. auto means the same as soft if the target architecture doesn't support a

[clang] [Clang] Treat constexpr-unknown value as invalid in `EvaluateAsInitializer` (PR #128409)

2025-02-26 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Yingwei Zheng (dtcxzyw) Changes It is an alternative to https://github.com/llvm/llvm-project/pull/127525. Close https://github.com/llvm/llvm-project/issues/127475. --- Full diff: https://github.com/llvm/llvm-project/pull/128409.diff 3 F

[clang] [ARM] Introduce -mtp=auto and make it the default (PR #128901)

2025-02-26 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver Author: Austin (Zhenhang1213) Changes This adds a new value auto to the possible values of the existing -mtp= clang option which controls how the thread pointer is found. auto means the same as soft if the target architecture doesn't suppo

[clang] [clang] Implement instantiation context note for checking template parameters (PR #126088)

2025-02-26 Thread Matheus Izvekov via cfe-commits
@@ -5294,10 +5294,14 @@ def err_template_missing_args : Error< "%select{class template|function template|variable template|alias template|" "template template parameter|concept|template}0 %1 requires template " "arguments">; -def err_template_arg_list_different_arity : Er

[clang] [Clang] Treat constexpr-unknown value as invalid in `evaluateValue` (PR #128409)

2025-02-26 Thread Yingwei Zheng via cfe-commits
@@ -17000,6 +16998,18 @@ bool Expr::EvaluateAsInitializer(APValue &Value, const ASTContext &Ctx, if (!Info.discardCleanups()) llvm_unreachable("Unhandled cleanup; missing full expression marker?"); + +if (Value.allowConstexprUnknown()) { + assert(Value.isLV

[clang] [Clang] Treat constexpr-unknown value as invalid in `EvaluateAsInitializer` (PR #128409)

2025-02-26 Thread Yingwei Zheng via cfe-commits
https://github.com/dtcxzyw edited https://github.com/llvm/llvm-project/pull/128409 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [ARM] Introduce -mtp=auto and make it the default (PR #128901)

2025-02-26 Thread via cfe-commits
https://github.com/Zhenhang1213 edited https://github.com/llvm/llvm-project/pull/128901 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [DebugInfo] Place local ODR-uniqued types in decl DISubprograms (PR #119001)

2025-02-26 Thread Vladislav Dzhidzhoev via cfe-commits
dzhidzhoev wrote: Apologies for the delay in reviewing that. I was stuck on the original issue, so I appreciate this contribution. Now it's clear what was the root cause of the problem. > There's also a risk that I misapplied D144008, which I had to copy-and-paste > out of Phab, @dzhidzhoev w

[clang] [CodeGen] Ensure relative vtables use llvm.type.checked.load.relative (PR #126785)

2025-02-26 Thread via cfe-commits
https://github.com/PiJoules edited https://github.com/llvm/llvm-project/pull/126785 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CodeGen] Ensure relative vtables use llvm.type.checked.load.relative (PR #126785)

2025-02-26 Thread via cfe-commits
PiJoules wrote: > Can you update the PR description and explain why this is desirable? Done. I'll give it a few days for others to chime in before landing. https://github.com/llvm/llvm-project/pull/126785 ___ cfe-commits mailing list cfe-commits@lists

[clang] [CIR] Upstream basic alloca and load support (PR #128792)

2025-02-26 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor updated https://github.com/llvm/llvm-project/pull/128792 >From 235ef9e23a314f8946b48143294da367b80f7d14 Mon Sep 17 00:00:00 2001 From: Andy Kaylor Date: Tue, 25 Feb 2025 12:31:08 -0800 Subject: [PATCH 1/3] [CIR] Upstream basic alloca and load support This change i

[clang] [CIR] Function type return type improvements (PR #128787)

2025-02-26 Thread David Olsen via cfe-commits
@@ -424,6 +424,10 @@ LogicalResult cir::FuncOp::verifyType() { if (!isa(type)) return emitOpError("requires '" + getFunctionTypeAttrName().str() + "' attribute of function type"); + if (auto rt = type.getReturnTypes(); dkolsen-pgi

[clang] [CIR] Initial implementation of lowering CIR to MLIR (PR #127835)

2025-02-26 Thread Andy Kaylor via cfe-commits
andykaylor wrote: @AaronBallman , @erichkeane I think I've addressed the review comments. Is there anything else you'd like changed? https://github.com/llvm/llvm-project/pull/127835 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists

[clang] [clang][CodeGen] Additional fixes for #114062 (PR #128166)

2025-02-26 Thread via cfe-commits
asmok-g wrote: Hello, Some of our targets in Google are broken by tho original patch and we need this fix patch to unblock our internal releases. Can we land the fix soonish ? Thanks https://github.com/llvm/llvm-project/pull/128166 ___ cfe-commits ma

[clang] [MS][clang] Add support for vector deleting destructors (PR #126240)

2025-02-26 Thread Reid Kleckner via cfe-commits
https://github.com/rnk edited https://github.com/llvm/llvm-project/pull/126240 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [MS][clang] Add support for vector deleting destructors (PR #126240)

2025-02-26 Thread Reid Kleckner via cfe-commits
@@ -2657,7 +2657,10 @@ class VFTableBuilder { MethodVFTableLocation Loc(MI.VBTableIndex, WhichVFPtr.getVBaseWithVPtr(), WhichVFPtr.NonVirtualOffset, MI.VFTableIndex); if (const CXXDestructorDecl *DD = dyn_cast(MD)) { -MethodVF

[clang] [MS][clang] Add support for vector deleting destructors (PR #126240)

2025-02-26 Thread Reid Kleckner via cfe-commits
@@ -575,6 +576,12 @@ class CGCXXABI { QualType ElementType, llvm::Value *&NumElements, llvm::Value *&AllocPtr, CharUnits &CookieSize); + /// Reads the array cookie associated with the given pointer, + /// that sho

[clang] [MS][clang] Add support for vector deleting destructors (PR #126240)

2025-02-26 Thread Reid Kleckner via cfe-commits
@@ -7919,3 +7919,38 @@ void CodeGenModule::moveLazyEmissionStates(CodeGenModule *NewBuilder) { NewBuilder->ABI->MangleCtx = std::move(ABI->MangleCtx); } + +bool CodeGenModule::classNeedsVectorDestructor(const CXXRecordDecl *RD) { + CXXDestructorDecl *Dtor = RD->getDestruct

[clang] [MS][clang] Add support for vector deleting destructors (PR #126240)

2025-02-26 Thread Reid Kleckner via cfe-commits
@@ -7919,3 +7919,38 @@ void CodeGenModule::moveLazyEmissionStates(CodeGenModule *NewBuilder) { NewBuilder->ABI->MangleCtx = std::move(ABI->MangleCtx); } + +bool CodeGenModule::classNeedsVectorDestructor(const CXXRecordDecl *RD) { + CXXDestructorDecl *Dtor = RD->getDestruct

[clang] [MS][clang] Add support for vector deleting destructors (PR #126240)

2025-02-26 Thread Reid Kleckner via cfe-commits
https://github.com/rnk commented: Hm, these comments didn't post. They may be stale. I will post them and revisit them. https://github.com/llvm/llvm-project/pull/126240 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[clang] [MS][clang] Add support for vector deleting destructors (PR #126240)

2025-02-26 Thread Reid Kleckner via cfe-commits
https://github.com/rnk commented: I resolved two conversations, but there are two actionable comments. https://github.com/llvm/llvm-project/pull/126240 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listi

[clang] [CIR] Upstream basic alloca and load support (PR #128792)

2025-02-26 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 1b39328d7440aa7a94af4083257ef1c2f9394887 1ffe43b0ca298df1e35f692d98401579f32d528d --e

[clang] [clang][deps] Propagate the entire service (PR #128959)

2025-02-26 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 created https://github.com/llvm/llvm-project/pull/128959 Shared state between dependency scanning workers is managed by the dependency scanning service. Right now, the members are individually threaded through the worker, action, and collector. This makes any c

[clang] [CIR] Upstream basic alloca and load support (PR #128792)

2025-02-26 Thread Andy Kaylor via cfe-commits
@@ -0,0 +1,128 @@ +//===--===// +// +// 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: Apa

[clang] [clang][deps] Propagate the entire service (PR #128959)

2025-02-26 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Jan Svoboda (jansvoboda11) Changes Shared state between dependency scanning workers is managed by the dependency scanning service. Right now, the members are individually threaded through the worker, action, and collector. This makes any

[clang] [clang-tidy] [dataflow] Cache reference accessors for `bugprone-unchecked-optional-access` (PR #128437)

2025-02-26 Thread Valentyn Yukhymenko via cfe-commits
https://github.com/BaLiKfromUA updated https://github.com/llvm/llvm-project/pull/128437 >From 319ad0b803b8c6c6c5405178335bd1f2258be4b8 Mon Sep 17 00:00:00 2001 From: Valentyn Yukhymenko Date: Sun, 23 Feb 2025 12:08:02 + Subject: [PATCH 1/6] first implementation and basic tests --- .../Mod

[clang] [CIR] Function type return type improvements (PR #128787)

2025-02-26 Thread David Olsen via cfe-commits
https://github.com/dkolsen-pgi updated https://github.com/llvm/llvm-project/pull/128787 >From 3e396ab2f69d0dcf98605179f69411f04da68f49 Mon Sep 17 00:00:00 2001 From: David Olsen Date: Tue, 25 Feb 2025 15:21:30 -0800 Subject: [PATCH 1/2] [CIR] Function type return type improvements When a C or

<    1   2   3   4   5   >