[clang] [llvm] [mlir] [NVPTX] Unify and extend barrier{.cta} intrinsic support (PR #140615)

2025-05-20 Thread Durgadoss R via cfe-commits
@@ -462,24 +462,28 @@ def NVVM_MBarrierTestWaitSharedOp : NVVM_Op<"mbarrier.test.wait.shared">, // NVVM synchronization op definitions //===--===// -def NVVM_Barrier0Op : NVVM_IntrOp<"barrier0"> { +def NVVM_

[clang] [Clang][Sema] Reject array prvalue operands (PR #140702)

2025-05-20 Thread via cfe-commits
languagelawyer wrote: @pinskia the thing is, GCC started accepting ill-formed code right when it was reaffirmed it is ill-formed https://github.com/llvm/llvm-project/pull/140702 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llv

[clang] [flang] [flang] add -floop-interchange and enable it with opt levels (PR #140182)

2025-05-20 Thread Sebastian Pop via cfe-commits
https://github.com/sebpop updated https://github.com/llvm/llvm-project/pull/140182 >From 46efee7d48a11794fc103cf67b21796d8e5f3408 Mon Sep 17 00:00:00 2001 From: Sebastian Pop Date: Mon, 12 May 2025 21:56:03 + Subject: [PATCH 1/3] [flang] add -floop-interchange to flang driver This patch al

[clang] [Sema] Warn about omitting deprecated enumerator in switch (PR #138562)

2025-05-20 Thread Reid Kleckner via cfe-commits
rnk wrote: > I think silencing the warning is better than suggesting a default case, which > may not be considered good practice. I'm not sure, I think our perspectives as compiler people might be a bit off base. We're always forming closed algebraic sum types, like variants, AST nodes, that

[clang] [CIR] Upstream comparison ops for VectorType (PR #140597)

2025-05-20 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/140597 >From e43d04b1eb1660dcf1a99d405858efd3a9647657 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sun, 18 May 2025 21:14:03 +0200 Subject: [PATCH 1/2] [CIR] Upstream comparion ops for VectorType --- clang/

[clang] [llvm] [UBSan] Implement src:*=sanitize for UBSan (PR #140529)

2025-05-20 Thread Qinkun Bao via cfe-commits
https://github.com/qinkunbao edited https://github.com/llvm/llvm-project/pull/140529 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][TableGen] Fix Duplicate Entries in TableGen (PR #140828)

2025-05-20 Thread via cfe-commits
https://github.com/Mr-Anyone created https://github.com/llvm/llvm-project/pull/140828 Fixed TableGen duplicate issues that causes the wrong interrupt attribute from being selected. resolves #140701 >From 640bc8ba7a0bf9c7bffd1a2911c1ddac3b4e6fcd Mon Sep 17 00:00:00 2001 From: Vincent Date: Tu

[clang] [clang][TableGen] Fix Duplicate Entries in TableGen (PR #140828)

2025-05-20 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vincent (Mr-Anyone) Changes Fixed TableGen duplicate issues that causes the wrong interrupt attribute from being selected. resolves #140701 --- Full diff: https://github.com/llvm/llvm-project/pull/140828.diff 2 Files Affected: - (adde

[clang] [clang][TableGen] Fix Duplicate Entries in TableGen (PR #140828)

2025-05-20 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-risc-v Author: Vincent (Mr-Anyone) Changes Fixed TableGen duplicate issues that causes the wrong interrupt attribute from being selected. resolves #140701 --- Full diff: https://github.com/llvm/llvm-project/pull/140828.diff 2 Files Affected:

[clang] [clang][TableGen] Fix Duplicate Entries in TableGen (PR #140828)

2025-05-20 Thread via cfe-commits
https://github.com/Mr-Anyone updated https://github.com/llvm/llvm-project/pull/140828 >From f9b4429de43493a95dc107e383e71ffaebecf2ba Mon Sep 17 00:00:00 2001 From: Vincent Date: Tue, 20 May 2025 21:25:32 -0400 Subject: [PATCH] [clang][TableGen] Fix Duplicate Entries in TableGen Fixed TableGen

[clang] [lld] [llvm] [polly] Fix regression tests with bad FileCheck checks (PR #140373)

2025-05-20 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/140373 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Set the final date for workaround for libstdc++'s `format_kind` (PR #140831)

2025-05-20 Thread A. Jiang via cfe-commits
https://github.com/frederick-vs-ja created https://github.com/llvm/llvm-project/pull/140831 We can use 20250520 as the final date, see the following commits. - GCC releases/gcc-15 branch: - https://gcc.gnu.org/g:fedf81ef7b98e5c9ac899b8641bb670746c51205 - https://gcc.gnu.org/g

[clang] 701fe51 - [Clang] Fix an inadvertent overwrite of sub-initializers (#140714)

2025-05-20 Thread via cfe-commits
Author: Younan Zhang Date: 2025-05-21T10:02:34+08:00 New Revision: 701fe51fd667904d160fb46b6ceba09006fe8291 URL: https://github.com/llvm/llvm-project/commit/701fe51fd667904d160fb46b6ceba09006fe8291 DIFF: https://github.com/llvm/llvm-project/commit/701fe51fd667904d160fb46b6ceba09006fe8291.diff

[clang] [Clang] Fix an inadvertent overwrite of sub-initializers (PR #140714)

2025-05-20 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 closed https://github.com/llvm/llvm-project/pull/140714 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][TableGen] Fix Duplicate Entries in TableGen (PR #140828)

2025-05-20 Thread via cfe-commits
https://github.com/Mr-Anyone updated https://github.com/llvm/llvm-project/pull/140828 >From 393ccc154e2f1d68ef25d660c8063ab9674ab09b Mon Sep 17 00:00:00 2001 From: Vincent Date: Tue, 20 May 2025 21:25:32 -0400 Subject: [PATCH] [clang][TableGen] Fix Duplicate Entries in TableGen Fixed TableGen

[clang] [clang-format] Handle raw string literals containing JSON code (PR #140666)

2025-05-20 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/140666 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 0dfdf7e - [clang-format] Handle raw string literals containing JSON code (#140666)

2025-05-20 Thread via cfe-commits
Author: Owen Pan Date: 2025-05-20T19:15:57-07:00 New Revision: 0dfdf7efbfe347517eb4c7f544043a71af4e4a25 URL: https://github.com/llvm/llvm-project/commit/0dfdf7efbfe347517eb4c7f544043a71af4e4a25 DIFF: https://github.com/llvm/llvm-project/commit/0dfdf7efbfe347517eb4c7f544043a71af4e4a25.diff LOG:

[clang] [Clang] Set the final date for workaround for libstdc++'s `format_kind` (PR #140831)

2025-05-20 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: A. Jiang (frederick-vs-ja) Changes We can use 20250520 as the final date, see the following commits. - GCC releases/gcc-15 branch: - https://gcc.gnu.org/g:fedf81ef7b98e5c9ac899b8641bb670746c51205 - https://gcc.gnu.org/g

[clang] [clang][TableGen] Fix Duplicate Entries in TableGen (PR #140828)

2025-05-20 Thread via cfe-commits
https://github.com/Mr-Anyone updated https://github.com/llvm/llvm-project/pull/140828 >From 393ccc154e2f1d68ef25d660c8063ab9674ab09b Mon Sep 17 00:00:00 2001 From: Vincent Date: Tue, 20 May 2025 21:25:32 -0400 Subject: [PATCH 1/2] [clang][TableGen] Fix Duplicate Entries in TableGen Fixed Table

[clang] [analyzer][NFC] Introduce framework for checker families (PR #139256)

2025-05-20 Thread Donát Nagy via cfe-commits
@@ -115,9 +115,22 @@ class CheckerRegistry { public: /// Adds a checker to the registry. Use this non-templated overload when your /// checker requires custom initialization. - void addChecker(RegisterCheckerFn Fn, ShouldRegisterFunction sfn, + void addChecker(RegisterChe

[clang] [llvm] [RISCV] Add Andes A25/AX25 processor definition (PR #140681)

2025-05-20 Thread Min-Yih Hsu via cfe-commits
@@ -648,6 +648,38 @@ def RP2350_HAZARD3 : RISCVProcessorModel<"rp2350-hazard3", FeatureStdExtZcb, FeatureStdExtZcmp]>; +def ANDES_A25 : RISCVProcessorModel<"andes-a25", +

[clang] [llvm] [RISCV] Add Andes A25/AX25 processor definition (PR #140681)

2025-05-20 Thread Min-Yih Hsu via cfe-commits
@@ -648,6 +648,38 @@ def RP2350_HAZARD3 : RISCVProcessorModel<"rp2350-hazard3", FeatureStdExtZcb, FeatureStdExtZcmp]>; +def ANDES_A25 : RISCVProcessorModel<"andes-a25", +

[clang] [CIR] Add support for recursive record layouts (PR #140811)

2025-05-20 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor created https://github.com/llvm/llvm-project/pull/140811 While processing members of a record, we try to create new record types as we encounter them, but if this would result in recursion (either because the type points to itself or because it points to a type th

[clang] [CIR][NFC] Eliminate ArgInfo structure (PR #140612)

2025-05-20 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `openmp-offload-amdgpu-runtime-2` running on `rocm-worker-hw-02` while building `clang` at step 5 "compile-openmp". Full details are available at: https://lab.llvm.org/buildbot/#/builders/10/builds/5735 Here is the relevant

[clang] [CIR] Upstream lowering of conditional operators to TernaryOp (PR #138156)

2025-05-20 Thread Andy Kaylor via cfe-commits
@@ -1658,6 +1828,170 @@ mlir::Value ScalarExprEmitter::VisitUnaryExprOrTypeTraitExpr( cgf.cgm.UInt64Ty, e->EvaluateKnownConstInt(cgf.getContext(; } +/// Return true if the specified expression is cheap enough and side-effect-free +/// enough to evaluate un

[clang] [CIR] Upstream support for string literals (PR #140796)

2025-05-20 Thread Erich Keane via cfe-commits
@@ -26,6 +26,34 @@ class CIRGenBuilderTy : public cir::CIRBaseBuilderTy { CIRGenBuilderTy(mlir::MLIRContext &mlirContext, const CIRGenTypeCache &tc) : CIRBaseBuilderTy(mlirContext), typeCache(tc) {} + /// Get a cir::ConstArrayAttr for a string literal. + /// Note: Th

[clang] [CIR][NFC] Fix an unused variable warning (PR #140783)

2025-05-20 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor approved this pull request. Thanks for the fixes! https://github.com/llvm/llvm-project/pull/140783 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream support for string literals (PR #140796)

2025-05-20 Thread Erich Keane via cfe-commits
https://github.com/erichkeane edited https://github.com/llvm/llvm-project/pull/140796 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [mlir] [AMDGPU] Add a new amdgcn.load.to.lds intrinsic (PR #137425)

2025-05-20 Thread Krzysztof Drewniak via cfe-commits
krzysz00 wrote: > I don't think we need to worry about compatibility with an intrinsic that's > been committed for a day `global.load.lds` and `buffer[.ptr].load.lds` have been around for quite a while though, and this is just an abstraction over them https://github.com/llvm/llvm-project/pull

[clang] [CIR] Implement switch case simplify (PR #140649)

2025-05-20 Thread Andy Kaylor via cfe-commits
@@ -159,6 +159,107 @@ struct SimplifySelect : public OpRewritePattern { } }; +/// Simplify `cir.switch` operations by folding cascading cases +/// into a single `cir.case` with the `anyof` kind. +/// +/// This pattern identifies cascading cases within a `cir.switch` operati

[clang] [CIR] Implement switch case simplify (PR #140649)

2025-05-20 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor edited https://github.com/llvm/llvm-project/pull/140649 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Implement switch case simplify (PR #140649)

2025-05-20 Thread Andy Kaylor via cfe-commits
@@ -0,0 +1,196 @@ +// RUN: cir-opt -cir-canonicalize -cir-simplify -o %t.cir %s +// RUN: FileCheck --input-file=%t.cir %s + +!s32i = !cir.int + +module { +cir.func @foldCascade(%arg0: !s32i) { +%0 = cir.alloca !s32i, !cir.ptr, ["a", init] {alignment = 4 : i64} +cir.sto

[clang] [CIR] Implement switch case simplify (PR #140649)

2025-05-20 Thread Andy Kaylor via cfe-commits
@@ -159,6 +159,107 @@ struct SimplifySelect : public OpRewritePattern { } }; +/// Simplify `cir.switch` operations by folding cascading cases +/// into a single `cir.case` with the `anyof` kind. +/// +/// This pattern identifies cascading cases within a `cir.switch` operati

[clang] [CIR] Implement switch case simplify (PR #140649)

2025-05-20 Thread Andy Kaylor via cfe-commits
@@ -159,6 +159,107 @@ struct SimplifySelect : public OpRewritePattern { } }; +/// Simplify `cir.switch` operations by folding cascading cases +/// into a single `cir.case` with the `anyof` kind. +/// +/// This pattern identifies cascading cases within a `cir.switch` operati

[clang] [CIR] Upstream support for string literals (PR #140796)

2025-05-20 Thread Erich Keane via cfe-commits
https://github.com/erichkeane commented: still ok, 1 nit. https://github.com/llvm/llvm-project/pull/140796 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Implement switch case simplify (PR #140649)

2025-05-20 Thread via cfe-commits
@@ -159,6 +159,107 @@ struct SimplifySelect : public OpRewritePattern { } }; +/// Simplify `cir.switch` operations by folding cascading cases +/// into a single `cir.case` with the `anyof` kind. +/// +/// This pattern identifies cascading cases within a `cir.switch` operati

[clang] [CIR] Implement switch case simplify (PR #140649)

2025-05-20 Thread Andy Kaylor via cfe-commits
@@ -159,6 +159,107 @@ struct SimplifySelect : public OpRewritePattern { } }; +/// Simplify `cir.switch` operations by folding cascading cases +/// into a single `cir.case` with the `anyof` kind. +/// +/// This pattern identifies cascading cases within a `cir.switch` operati

[clang] [SystemZ][z/OS] Add visibility features for z/OS (eg. _Export, pragma export) (PR #111035)

2025-05-20 Thread Sean Perry via cfe-commits
@@ -7552,6 +7552,27 @@ attribute requires a string literal argument to identify the handle being releas }]; } +def zOSExportDocs : Documentation { + let Category = DocCatFunction; + let Content = [{ +Use the ``_Export`` keyword on a function or external variable to declar

[clang] [clang][TableGen] Fix Duplicate Entries in TableGen (PR #140828)

2025-05-20 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 HEAD~1 HEAD --extensions cpp -- clang/test/AST/ast-dump-riscv-attributes.cpp clang/u

[clang] [SystemZ][z/OS] Add visibility features for z/OS (eg. _Export, pragma export) (PR #111035)

2025-05-20 Thread Sean Perry via cfe-commits
@@ -4504,6 +4504,11 @@ void Parser::ParseDeclarationSpecifiers( isInvalid = DS.setFunctionSpecNoreturn(Loc, PrevSpec, DiagID); break; +case tok::kw__Export: + // We're done with the declaration-specifiers. + goto DoneWithDeclSpec; per

[clang] [SystemZ][z/OS] Add visibility features for z/OS (eg. _Export, pragma export) (PR #111035)

2025-05-20 Thread Sean Perry via cfe-commits
@@ -7552,6 +7552,27 @@ attribute requires a string literal argument to identify the handle being releas }]; } +def zOSExportDocs : Documentation { + let Category = DocCatFunction; + let Content = [{ +Use the ``_Export`` keyword on a function or external variable to declar

[clang] [SystemZ][z/OS] Add visibility features for z/OS (eg. _Export, pragma export) (PR #111035)

2025-05-20 Thread Sean Perry via cfe-commits
@@ -1400,6 +1416,171 @@ bool Parser::HandlePragmaMSAllocText(StringRef PragmaName, return true; } +NestedNameSpecifier * +Parser::zOSParseIdentifier(StringRef PragmaName, + const IdentifierInfo *IdentName) { + NestedNameSpecifier *NestedId = nullp

[clang] [clang][TableGen] Fix Duplicate Entries in TableGen (PR #140828)

2025-05-20 Thread via cfe-commits
https://github.com/Mr-Anyone updated https://github.com/llvm/llvm-project/pull/140828 >From 393ccc154e2f1d68ef25d660c8063ab9674ab09b Mon Sep 17 00:00:00 2001 From: Vincent Date: Tue, 20 May 2025 21:25:32 -0400 Subject: [PATCH 1/3] [clang][TableGen] Fix Duplicate Entries in TableGen Fixed Table

[clang] [SystemZ][z/OS] Add visibility features for z/OS (eg. _Export, pragma export) (PR #111035)

2025-05-20 Thread Sean Perry via cfe-commits
@@ -401,6 +401,12 @@ struct PragmaMaxTokensTotalHandler : public PragmaHandler { Token &FirstToken) override; }; +struct PragmaExportHandler : public PragmaHandler { perry-ca wrote: Ok. Multiple requests now. I'll move the keyword _Expor

[clang] [SystemZ][z/OS] Add visibility features for z/OS (eg. _Export, pragma export) (PR #111035)

2025-05-20 Thread Sean Perry via cfe-commits
@@ -4504,6 +4504,11 @@ void Parser::ParseDeclarationSpecifiers( isInvalid = DS.setFunctionSpecNoreturn(Loc, PrevSpec, DiagID); break; +case tok::kw__Export: + // We're done with the declaration-specifiers. + goto DoneWithDeclSpec; per

[clang-tools-extra] [clangd] Add 'apply all clangd fixes' and 'apply all '_' fixes' QuickFixes (PR #79867)

2025-05-20 Thread Tor Shepherd via cfe-commits
torshepherd wrote: It's been a while since I looked at this, but from what I remember my attempt to fix the last part didn't quite work as expected. I can try to test it again, but I ended up just abandoning it at the time since I didn't really miss the functionality as much as I thought http

[clang] [clang-format] Handle raw string literals containing JSON code (PR #140666)

2025-05-20 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `llvm-clang-x86_64-gcc-ubuntu` running on `sie-linux-worker3` while building `clang` at step 6 "test-build-unified-tree-check-all". Full details are available at: https://lab.llvm.org/buildbot/#/builders/174/builds/18088 Her

[clang] [llvm] [RISCV] Add Andes A25/AX25 processor definition (PR #140681)

2025-05-20 Thread Min-Yih Hsu via cfe-commits
mshockwave wrote: I propose writing `test/Driver/print-enabled-extensions` tests instead for testing extensions. https://github.com/llvm/llvm-project/pull/140681 ___ cfe-commits mailing list cfe-commits@lists.llvm.or

[clang] [CodeGen] Add TBAA struct path info for array members (PR #137719)

2025-05-20 Thread John McCall via cfe-commits
https://github.com/rjmccall approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/137719 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream support for lowering cir.switch to LLVM (PR #140425)

2025-05-20 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor approved this pull request. lgtm https://github.com/llvm/llvm-project/pull/140425 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream lowering of conditional operators to TernaryOp (PR #138156)

2025-05-20 Thread Andy Kaylor via cfe-commits
@@ -948,6 +950,165 @@ void CIRGenFunction::emitIgnoredExpr(const Expr *e) { emitLValue(e); } +// Handle the case where the condition is a constant evaluatable simple integer, +// which means we don't have to separately handle the true/false blocks. +static std::optional han

[clang] [CodeGen] Add TBAA struct path info for array members (PR #137719)

2025-05-20 Thread Bruno De Fraine via cfe-commits
https://github.com/brunodf-snps updated https://github.com/llvm/llvm-project/pull/137719 >From d63c8fe4fcc8e89933bf3c1cc176941b0b9094fa Mon Sep 17 00:00:00 2001 From: Bruno De Fraine Date: Mon, 28 Apr 2025 14:12:00 +0200 Subject: [PATCH 1/4] [clang][CodeGen] Make tbaa-array test more robust Av

[clang] [llvm] [RISCV] Add Andes A25/AX25 processor definition (PR #140681)

2025-05-20 Thread Min-Yih Hsu via cfe-commits
https://github.com/mshockwave edited https://github.com/llvm/llvm-project/pull/140681 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer][NFC] Introduce framework for checker families (PR #139256)

2025-05-20 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat edited https://github.com/llvm/llvm-project/pull/139256 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Add support for recursive record layouts (PR #140811)

2025-05-20 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Andy Kaylor (andykaylor) Changes While processing members of a record, we try to create new record types as we encounter them, but if this would result in recursion (either because the type points to itself or because it points to a type

[clang] [CIR] Upstream support for string literals (PR #140796)

2025-05-20 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor updated https://github.com/llvm/llvm-project/pull/140796 >From 7e1e98fd2f1686709fe16b6853dcbf00623e626c Mon Sep 17 00:00:00 2001 From: Andy Kaylor Date: Tue, 20 May 2025 09:51:41 -0700 Subject: [PATCH 1/4] [CIR] Upstream support for string literals This adds the m

[clang] Revert "[clang][Dependency Scanning] Report What a Module Exports during Scanning (#137421)" (PR #140820)

2025-05-20 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Qiongsi Wu (qiongsiwu) Changes This reverts commit ea1bfbf3f6399b7d2d840722f0e87542d00f6a35. The commit did not solve the fundamental issue we need to handle and is no longer necessary. rdar://144794793 --- Full diff: https://github.co

[clang] Revert "[clang][Dependency Scanning] Report What a Module Exports during Scanning (#137421)" (PR #140820)

2025-05-20 Thread Cyndy Ishida via cfe-commits
https://github.com/cyndyishida approved this pull request. https://github.com/llvm/llvm-project/pull/140820 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Update Sema Checking Diagnostics for builtins (PR #138429)

2025-05-20 Thread Helena Kotas via cfe-commits
https://github.com/hekota approved this pull request. https://github.com/llvm/llvm-project/pull/138429 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libclc] [libclc] Re-use shuffle_decl.inc in OpenCL shuffle2 declaration (PR #140679)

2025-05-20 Thread Wenju He via cfe-commits
https://github.com/wenju-he updated https://github.com/llvm/llvm-project/pull/140679 >From 5015512439f6ba846223b1d04e71d8cdae36d3fa Mon Sep 17 00:00:00 2001 From: Wenju He Date: Mon, 19 May 2025 22:14:55 -0700 Subject: [PATCH] [libclc] Re-use shuffle_decl.inc in OpenCL shuffle2 declaration Al

[libclc] [libclc] Re-use shuffle_decl.inc in OpenCL shuffle2 declaration (PR #140679)

2025-05-20 Thread Wenju He via cfe-commits
wenju-he wrote: > Sorry, just merged #140557 so you'll have to fix the conflicts before merging. done, thanks https://github.com/llvm/llvm-project/pull/140679 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailm

[clang] [CIR] Implement switch case simplify (PR #140649)

2025-05-20 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor commented: This looks good. I have just a few minor suggestions. https://github.com/llvm/llvm-project/pull/140649 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-

[clang] [CIR][LLVMLowering] Upstream Bitcast lowering (PR #140774)

2025-05-20 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor approved this pull request. lgtm https://github.com/llvm/llvm-project/pull/140774 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Functions called in discarded statements should not be instantiated (PR #140576)

2025-05-20 Thread Daniel Bertalan via cfe-commits
BertalanD wrote: @cor3ntin fyi, we have been seeing build failures since this commit on code like this: ```c++ void should_compile() { if constexpr (false) { auto lam = []() { return 0; }; 1 | lam(); } } ``` The error is: ```console bug.cpp:4:7: error: invalid operands to binary exp

[clang] [CIR] Add support for recursive record layouts (PR #140811)

2025-05-20 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. Want someone else to poke at it, but nothing from my end. https://github.com/llvm/llvm-project/pull/140811 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/

[clang] [CIR] Implement switch case simplify (PR #140649)

2025-05-20 Thread Andy Kaylor via cfe-commits
andykaylor wrote: > @andykaylor @erichkeane @bcardosolopes While implementing this > simplification, I noticed a difference compared to the previous behavior > where the folding happened during codegen. > ... > After applying the new CIR simplify pass, the output is: > > ```mlir > cir.case(any

[clang] [CIR] Implement switch case simplify (PR #140649)

2025-05-20 Thread Andy Kaylor via cfe-commits
@@ -159,6 +159,107 @@ struct SimplifySelect : public OpRewritePattern { } }; +/// Simplify `cir.switch` operations by folding cascading cases +/// into a single `cir.case` with the `anyof` kind. +/// +/// This pattern identifies cascading cases within a `cir.switch` operati

[clang] [CIR] Upstream support for string literals (PR #140796)

2025-05-20 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor updated https://github.com/llvm/llvm-project/pull/140796 >From 7e1e98fd2f1686709fe16b6853dcbf00623e626c Mon Sep 17 00:00:00 2001 From: Andy Kaylor Date: Tue, 20 May 2025 09:51:41 -0700 Subject: [PATCH 1/3] [CIR] Upstream support for string literals This adds the m

[clang] Revert "[clang][Dependency Scanning] Report What a Module Exports during Scanning (#137421)" (PR #140820)

2025-05-20 Thread Qiongsi Wu via cfe-commits
https://github.com/qiongsiwu created https://github.com/llvm/llvm-project/pull/140820 This reverts commit ea1bfbf3f6399b7d2d840722f0e87542d00f6a35. The commit did not solve the fundamental issue we need to handle and is no longer necessary. rdar://144794793 >From 22c4747a1232756c672691a14ae

[clang] [CIR][NFC] Eliminate ArgInfo structure (PR #140612)

2025-05-20 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor closed https://github.com/llvm/llvm-project/pull/140612 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream support for string literals (PR #140796)

2025-05-20 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor updated https://github.com/llvm/llvm-project/pull/140796 >From 7e1e98fd2f1686709fe16b6853dcbf00623e626c Mon Sep 17 00:00:00 2001 From: Andy Kaylor Date: Tue, 20 May 2025 09:51:41 -0700 Subject: [PATCH 1/2] [CIR] Upstream support for string literals This adds the m

[clang] 554e27e - [CIR][NFC] Eliminate ArgInfo structure (#140612)

2025-05-20 Thread via cfe-commits
Author: Andy Kaylor Date: 2025-05-20T15:17:10-07:00 New Revision: 554e27ef69616fda5747a9d8137c9eb987857a12 URL: https://github.com/llvm/llvm-project/commit/554e27ef69616fda5747a9d8137c9eb987857a12 DIFF: https://github.com/llvm/llvm-project/commit/554e27ef69616fda5747a9d8137c9eb987857a12.diff L

[clang] [CIR] Upstream comparison ops for VectorType (PR #140597)

2025-05-20 Thread Andy Kaylor via cfe-commits
@@ -2083,4 +2083,33 @@ def VecExtractOp : CIR_Op<"vec.extract", [Pure, let hasFolder = 1; } +//===--===// +// VecCmpOp +//===--===// + +def

[clang] [CIR] Upstream comparison ops for VectorType (PR #140597)

2025-05-20 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor approved this pull request. https://github.com/llvm/llvm-project/pull/140597 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer][NFC] Introduce framework for checker families (PR #139256)

2025-05-20 Thread Donát Nagy via cfe-commits
NagyDonat wrote: I have yet another implementation idea where: - boilerplate is either minimal or nonexistent; - there is no need to pass an additional string value (the debug name) through the checker registry code; - the debug name is guaranteed to be the same as the class name. The minimal-b

[clang-tools-extra] [clang-tidy][NFC] Refactor `modernize-use-trailing-return-type-check` check code and tests (PR #140759)

2025-05-20 Thread Baranov Victor via cfe-commits
@@ -383,6 +382,10 @@ void UseTrailingReturnTypeCheck::keepSpecifiers( } } +UseTrailingReturnTypeCheck::UseTrailingReturnTypeCheck( vbvictor wrote: Initially, I did this change in preparation for PR https://github.com/llvm/llvm-project/pull/135383, where I

[clang-tools-extra] [clang-tidy][NFC] Refactor `modernize-use-trailing-return-type-check` check code and tests (PR #140759)

2025-05-20 Thread Baranov Victor via cfe-commits
@@ -113,7 +113,7 @@ struct UnqualNameVisitor : public RecursiveASTVisitor { }; } // namespace -constexpr llvm::StringLiteral Message = +constexpr llvm::StringLiteral MessageFunction = vbvictor wrote: This came from https://github.com/llvm/llvm-project/pull/1

[clang-tools-extra] [clang-tidy][NFC] Refactor `modernize-use-trailing-return-type-check` check code and tests (PR #140759)

2025-05-20 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor updated https://github.com/llvm/llvm-project/pull/140759 >From fbae463925738d8628593d5daaabe2a299aecbbf Mon Sep 17 00:00:00 2001 From: Baranov Victor Date: Tue, 20 May 2025 19:23:35 +0300 Subject: [PATCH 1/2] [clang-tidy][nfc] refactor use-trailing-return-type-check

[clang-tools-extra] [clang-tidy][NFC] Refactor `modernize-use-trailing-return-type-check` check code and tests (PR #140759)

2025-05-20 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor updated https://github.com/llvm/llvm-project/pull/140759 >From fbae463925738d8628593d5daaabe2a299aecbbf Mon Sep 17 00:00:00 2001 From: Baranov Victor Date: Tue, 20 May 2025 19:23:35 +0300 Subject: [PATCH 1/3] [clang-tidy][nfc] refactor use-trailing-return-type-check

[clang] [clang-format][NFC] Minor efficiency cleanup (PR #140835)

2025-05-20 Thread Owen Pan via cfe-commits
https://github.com/owenca created https://github.com/llvm/llvm-project/pull/140835 None >From ca6a78c3c078fca61fe5ae60566adc4bf17503d2 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Tue, 20 May 2025 19:45:15 -0700 Subject: [PATCH] [clang-format][NFC] Minor efficiency cleanup --- clang/lib/For

[clang] [Modules] Don't fail when an unused textual header is missing. (PR #138227)

2025-05-20 Thread Volodymyr Sapsai via cfe-commits
vsapsai wrote: > I know what we do is cheesy and we might need to reconsider how to approach > it, but this is a breaking change and it would be great to find a resolution > for it before committing to the new behavior. Could we revert this while we > discuss the potential ways out of it? Wha

[clang] [llvm] [Clang][LoongArch] Support target attribute for function (PR #140700)

2025-05-20 Thread Lu Weining via cfe-commits
@@ -0,0 +1,19 @@ +// RUN: %clang_cc1 -triple loongarch64-linux-gnu -fsyntax-only -verify %s + +// expected-error@+1 {{function multiversioning is not supported on the current target}} +void __attribute__((target("default"))) bar(void){} + +// expected-error@+1 {{target(arch=..)

[clang] [llvm] [Clang][LoongArch] Support target attribute for function (PR #140700)

2025-05-20 Thread Lu Weining via cfe-commits
@@ -0,0 +1,19 @@ +// RUN: %clang_cc1 -triple loongarch64-linux-gnu -fsyntax-only -verify %s + +// expected-error@+1 {{function multiversioning is not supported on the current target}} +void __attribute__((target("default"))) bar(void){} SixWeining wrote: ```sug

[clang] [libc] [llvm] [clang] Make __builtin_expf constexpr. (PR #140841)

2025-05-20 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (lntue) Changes A draft PR to make `__builtin_expf` constexpr using LLVM libc math implementation. --- Patch is 244.33 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/140841.diff 429 Fil

[clang] [libc] [llvm] [clang] Make __builtin_expf constexpr. (PR #140841)

2025-05-20 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-libc Author: None (lntue) Changes A draft PR to make `__builtin_expf` constexpr using LLVM libc math implementation. --- Patch is 244.33 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/140841.diff 429 File

[clang] [llvm] [RISCV] Add Andes A25/AX25 processor definition (PR #140681)

2025-05-20 Thread Kito Cheng via cfe-commits
https://github.com/kito-cheng commented: I thought it should have xandesperf extension? https://github.com/llvm/llvm-project/pull/140681 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Clang][LoongArch] Support target attribute for function (PR #140700)

2025-05-20 Thread via cfe-commits
@@ -388,6 +388,51 @@ bool LoongArchTargetInfo::handleTargetFeatures( return true; } +ParsedTargetAttr +LoongArchTargetInfo::parseTargetAttr(StringRef Features) const { + ParsedTargetAttr Ret; + if (Features == "default") +return Ret; + SmallVector AttrFeatures; + Fea

[clang] [clang-format][NFC] Minor efficiency cleanup (PR #140835)

2025-05-20 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Owen Pan (owenca) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/140835.diff 2 Files Affected: - (modified) clang/lib/Format/FormatToken.h (+3-1) - (modified) clang/lib/Format/TokenAnnotator.cpp (+7-17) ```

[clang] [Clang][Sema] Reject array prvalue operands (PR #140702)

2025-05-20 Thread via cfe-commits
@@ -7639,6 +7639,8 @@ def warn_param_mismatched_alignment : Warning< def err_objc_object_assignment : Error< "cannot assign to class object (%0 invalid)">; +def err_typecheck_array_prvalue_operand : Error< + "array prvalue is not permitted">; Sirraide wrote

[clang] [Clang][Sema] Reject array prvalue operands (PR #140702)

2025-05-20 Thread via cfe-commits
@@ -16,4 +15,13 @@ int main() f0(a1); f1(a2); f2(a3); + + using IA = int[]; + void(+IA{ 1, 2, 3 }); // expected-error {{array prvalue}} Sirraide wrote: Can you add some tests here to make sure that we don’t complain about array glvalues? https://gith

[clang] [clang] Fixed Constant Evaluation don't Call Destructor (PR #140278)

2025-05-20 Thread via cfe-commits
@@ -416,3 +416,38 @@ static_assert( // expected-note@-1 {{read of dereferenced one-past-the-end pointer is not allowed in a constant expression}} ); } + +// taken from: https://github.com/llvm/llvm-project/issues/139818 +namespace GH139818{ Sirraide wrot

[clang] [clang] Fixed Constant Evaluation don't Call Destructor (PR #140278)

2025-05-20 Thread via cfe-commits
https://github.com/Sirraide edited https://github.com/llvm/llvm-project/pull/140278 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][Sema] Reject array prvalue operands (PR #140702)

2025-05-20 Thread via cfe-commits
@@ -15840,6 +15859,11 @@ ExprResult Sema::CreateBuiltinUnaryOp(SourceLocation OpLoc, InputExpr->getType()->isSpecificBuiltinType(BuiltinType::Dependent)) { resultType = Context.DependentTy; } else { +if (Opc == UO_Deref || Opc == UO_Plus) { Sir

[clang] [lld] [llvm] Adding Matching and Inference Functionality to Propeller (PR #139008)

2025-05-20 Thread via cfe-commits
wdx727 wrote: > Thanks for the patch. I think this PR should be split up a bit, so that it's > easier to review distinct sections. In particular the areas related to > yaml2obj/obj2yaml, llvm-readobj and llvm-objdump could probably be their own > PR, where we can focus on reviewing how tools r

[clang] [llvm] [Clang][LoongArch] Support target attribute for function (PR #140700)

2025-05-20 Thread Lu Weining via cfe-commits
@@ -0,0 +1,19 @@ +// RUN: %clang_cc1 -triple loongarch64-linux-gnu -fsyntax-only -verify %s + +// expected-error@+1 {{function multiversioning is not supported on the current target}} +void __attribute__((target("default"))) bar(void){} + +// expected-error@+1 {{target(arch=..)

[clang] [clang][bytecode][NFC] Remove Frame.cpp (PR #140750)

2025-05-20 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-ppc64-aix` running on `aix-ppc64` while building `clang` at step 6 "test-build-unified-tree-check-all". Full details are available at: https://lab.llvm.org/buildbot/#/builders/64/builds/3702 Here is the relevant piece

[clang-tools-extra] [clang-tidy][NFC] Refactor `modernize-use-trailing-return-type-check` check code and tests (PR #140759)

2025-05-20 Thread Nicolas van Kempen via cfe-commits
@@ -28,7 +27,7 @@ struct ClassifiedToken { class UseTrailingReturnTypeCheck : public ClangTidyCheck { public: UseTrailingReturnTypeCheck(StringRef Name, ClangTidyContext *Context) - : ClangTidyCheck(Name, Context) {} + : ClangTidyCheck(Name, Context) {}; ---

[clang-tools-extra] [clang-tidy][NFC] Refactor `modernize-use-trailing-return-type-check` check code and tests (PR #140759)

2025-05-20 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank edited https://github.com/llvm/llvm-project/pull/140759 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fixed Constant Evaluation don't Call Destructor (PR #140278)

2025-05-20 Thread Younan Zhang via cfe-commits
@@ -1321,4 +1321,39 @@ namespace GH139160{ // expected-note@-2 {{non-constexpr function 'make_struct' cannot be used in a constant expression}} }; +// taken from: https://github.com/llvm/llvm-project/issues/139818 +namespace GH

[clang] [Clang] Set the final date for workaround for libstdc++'s `format_kind` (PR #140831)

2025-05-20 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 approved this pull request. https://github.com/llvm/llvm-project/pull/140831 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

<    1   2   3   4   5   6   >