[clang] [llvm] [RISCV][MC] Implement MC for Base P extension (PR #123271)

2025-03-19 Thread Craig Topper via cfe-commits
@@ -0,0 +1,1079 @@ +//===-- RISCVInstrInfoP.td - RISC-V 'P' instructions ---*- tablegen -*-===// +// +// 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: A

[clang] [llvm] Hlsl asint16 intrinsic (PR #131900)

2025-03-19 Thread Farzon Lotfi via cfe-commits
@@ -80,6 +80,25 @@ void asuint(double3, out uint3, out uint3); _HLSL_BUILTIN_ALIAS(__builtin_hlsl_elementwise_splitdouble) void asuint(double4, out uint4, out uint4); +//===--===// +// asint16 builtins +//===-

[clang] [clang][diagnostics] Update note_constexpr_invalid_cast to use enum_select and adjust its uses (PR #130868)

2025-03-19 Thread Erich Keane via cfe-commits
https://github.com/erichkeane closed https://github.com/llvm/llvm-project/pull/130868 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][analyzer] Multipart checker refactor 1: VirtualCallChecker (PR #132072)

2025-03-19 Thread Donát Nagy via cfe-commits
@@ -694,15 +694,11 @@ def MoveChecker: Checker<"Move">, ]>, Documentation; -def VirtualCallModeling : Checker<"VirtualCallModeling">, - HelpText<"Auxiliary modeling for the virtual method call checkers">, - Documentation, - Hidden; - -def PureVirtualCallChecker : Checke

[compiler-rt] [libcxx] [libcxxabi] [libunwind] [lldb] [llvm] [compiler-rt] Disable LLVM_ENABLE_PER_TARGET_RUNTIME_DIR=ON on AIX. (PR #131200)

2025-03-19 Thread Daniel Chen via cfe-commits
https://github.com/DanielCChen edited https://github.com/llvm/llvm-project/pull/131200 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [TableGen] Avoid repeated hash lookups (NFC) (PR #132142)

2025-03-19 Thread Krzysztof Drewniak via cfe-commits
https://github.com/krzysz00 approved this pull request. https://github.com/llvm/llvm-project/pull/132142 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy][C++20] Add support for aggregate types within modernize-use-emplace (PR #131969)

2025-03-19 Thread David Rivera via cfe-commits
https://github.com/RiverDave edited https://github.com/llvm/llvm-project/pull/131969 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libclang/python] Add equality comparison operators for File (PR #130383)

2025-03-19 Thread Jannick Kremer via cfe-commits
https://github.com/DeinAlptraum updated https://github.com/llvm/llvm-project/pull/130383 >From 8a206611120c15010381e1570c2b4d7548142dbd Mon Sep 17 00:00:00 2001 From: Mathias Stearn Date: Thu, 19 Dec 2024 16:22:04 +0100 Subject: [PATCH 1/2] [libclang/python] Add equality comparison operators fo

[clang] [OpenMP 6.0] Parse/Sema support for reduction over private variable with reduction clause. (PR #129938)

2025-03-19 Thread Alexey Bataev via cfe-commits
@@ -3757,6 +3768,31 @@ class OMPReductionClause final /// reduction copies. void setRHSExprs(ArrayRef RHSExprs); + /// Set the list private reduction flags + void setPrivateVariableReductionFlags(ArrayRef Flags) { +assert(Flags.size() == varlist_size() && +

[clang] [X86][AVX10.2] Use 's_' for saturate-convert intrinsics (PR #131592)

2025-03-19 Thread Phoebe Wang via cfe-commits
phoebewang wrote: > Went through the patch with my eyes, I'm not sure how useful it was but > wasn't able to spot anything. > > > Here is GCC patch: > > https://gcc.gnu.org/pipermail/gcc-patches/2025-March/678227.html > > I haven't found any changes regarding `vcvt2ph2` and no other similar

[clang] [CIR] Upstream a basic version of class LexicalScope (PR #131945)

2025-03-19 Thread Andy Kaylor via cfe-commits
andykaylor wrote: The `CIR/Lowering/func-simple.cpp` test is failing after this merge because of my change to introduce the canonicalize pass. I'll update the test as part of my type alias patch. https://github.com/llvm/llvm-project/pull/131945 ___ c

[clang] bdca412 - [clang] Auto-detect which newline style to use for `cxx_dr_status.html` (#132045)

2025-03-19 Thread via cfe-commits
Author: Vlad Serebrennikov Date: 2025-03-20T00:11:38+04:00 New Revision: bdca412681d668231aed0cb58b450713e8f9b01a URL: https://github.com/llvm/llvm-project/commit/bdca412681d668231aed0cb58b450713e8f9b01a DIFF: https://github.com/llvm/llvm-project/commit/bdca412681d668231aed0cb58b450713e8f9b01a.

[clang] [C23] Fix compound literals within function prototype (PR #132097)

2025-03-19 Thread Timm Baeder via cfe-commits
@@ -7141,7 +7141,13 @@ Sema::BuildCompoundLiteralExpr(SourceLocation LParenLoc, TypeSourceInfo *TInfo, return ExprError(); LiteralExpr = Result.get(); - bool isFileScope = !CurContext->isFunctionOrMethod(); + // We treat the compound literal as being at file scope if

[clang] [llvm] [RISCV] Add Qualcomm uC Xqcilb (Long Branch) extension (PR #131996)

2025-03-19 Thread via cfe-commits
https://github.com/hchandel closed https://github.com/llvm/llvm-project/pull/131996 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix UEFI Target info (PR #127290)

2025-03-19 Thread via cfe-commits
https://github.com/Prabhuk updated https://github.com/llvm/llvm-project/pull/127290 >From 3e6122744f355954edb6a5450ae4220ba39bc9c1 Mon Sep 17 00:00:00 2001 From: prabhukr Date: Fri, 14 Feb 2025 16:53:33 -0800 Subject: [PATCH 01/12] [clang] Fix UEFI Target info For X64 UEFI targets, making the

[clang] [clang][CodeGen][AVR] Fix a crash in AVRABIInfo (PR #131976)

2025-03-19 Thread Ben Shi via cfe-commits
https://github.com/benshi001 updated https://github.com/llvm/llvm-project/pull/131976 >From 163c73d21af736c94f1bb8f8c63caf96e127aba5 Mon Sep 17 00:00:00 2001 From: Ben Shi Date: Wed, 19 Mar 2025 13:21:48 +0800 Subject: [PATCH 1/2] [clang][CodeGen][AVR] Fix a crash in AVRABIInfo fixes https://g

[clang] [clang] Fix UEFI Target info (PR #127290)

2025-03-19 Thread via cfe-commits
https://github.com/Prabhuk updated https://github.com/llvm/llvm-project/pull/127290 >From 3e6122744f355954edb6a5450ae4220ba39bc9c1 Mon Sep 17 00:00:00 2001 From: prabhukr Date: Fri, 14 Feb 2025 16:53:33 -0800 Subject: [PATCH 01/11] [clang] Fix UEFI Target info For X64 UEFI targets, making the

[clang] [llvm] Hlsl asint16 intrinsic (PR #131900)

2025-03-19 Thread via cfe-commits
https://github.com/metkarpoonam updated https://github.com/llvm/llvm-project/pull/131900 >From 7ef40ee7d88872dbee1345cbd822e4aed8a22626 Mon Sep 17 00:00:00 2001 From: Poonam Vilas Metkar Date: Tue, 18 Mar 2025 11:30:15 -0700 Subject: [PATCH 01/10] Add codegen tests, Sema tests, SPIR-V backend t

[clang-tools-extra] [clang-tidy] support query based custom check (PR #131804)

2025-03-19 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 edited https://github.com/llvm/llvm-project/pull/131804 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][Diagnostics] Update select uses in DiagnosticXKinds.td to use enum_select (PR #130868)

2025-03-19 Thread Erich Keane via cfe-commits
erichkeane wrote: Latest patch looks right! Just change the Github subject and Commit message to better reflect what this patch is doing, and I can approve. IF that happens, either merge yourself (if you have permissions), or ping me after CI is happy, and I'll merge this for you. https://

[clang-tools-extra] [clangd] Add `HeaderInsertion` yaml config option (PR #128503)

2025-03-19 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/128503 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [X86][CodeGen] - Use shift operators for const value shifts, instead of built-ins for SSE emulation of MMX intrinsics. (PR #129197)

2025-03-19 Thread Pawan Nirpal via cfe-commits
pawan-nirpal-031 wrote: ping @arsenm https://github.com/llvm/llvm-project/pull/129197 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Add Zilsd and Zclsd Extensions (PR #131094)

2025-03-19 Thread Sam Elliott via cfe-commits
https://github.com/lenary closed https://github.com/llvm/llvm-project/pull/131094 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy][C++20] Add support for aggregate types within modernize-use-emplace (PR #131969)

2025-03-19 Thread David Rivera via cfe-commits
https://github.com/RiverDave edited https://github.com/llvm/llvm-project/pull/131969 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy][C++20] Add support for aggregate types within modernize-use-emplace (PR #131969)

2025-03-19 Thread David Rivera via cfe-commits
https://github.com/RiverDave edited https://github.com/llvm/llvm-project/pull/131969 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [ByteCode] Avoid repeated hash lookups (NFC) (PR #132141)

2025-03-19 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr approved this pull request. https://github.com/llvm/llvm-project/pull/132141 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 6003c30 - [clang] NFC: Unify implementations of CheckMemberPointerConversion (#131966)

2025-03-19 Thread via cfe-commits
Author: Matheus Izvekov Date: 2025-03-19T22:48:49-03:00 New Revision: 6003c3055a4630be31cc3d459cdbb88248a007b9 URL: https://github.com/llvm/llvm-project/commit/6003c3055a4630be31cc3d459cdbb88248a007b9 DIFF: https://github.com/llvm/llvm-project/commit/6003c3055a4630be31cc3d459cdbb88248a007b9.dif

[clang] [llvm] [RISCV] Add Qualcomm uC Xqcilb (Long Branch) extension (PR #131996)

2025-03-19 Thread via cfe-commits
hchandel wrote: Windows build has passed but linux build failed. The failed linux build seems unrelated. I am going ahead and merging the PR. https://github.com/llvm/llvm-project/pull/131996 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http

[clang] 0744d49 - [RISCV] Add Qualcomm uC Xqcilb (Long Branch) extension (#131996)

2025-03-19 Thread via cfe-commits
Author: quic_hchandel Date: 2025-03-20T11:14:53+05:30 New Revision: 0744d4926a0c567b0f10d19f0478b7a4bf960a19 URL: https://github.com/llvm/llvm-project/commit/0744d4926a0c567b0f10d19f0478b7a4bf960a19 DIFF: https://github.com/llvm/llvm-project/commit/0744d4926a0c567b0f10d19f0478b7a4bf960a19.diff

[clang-tools-extra] [clang-doc] Avoid deref of invalid std::optional (PR #131939)

2025-03-19 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/131939 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Add Qualcomm uC Xqcilb (Long Branch) extension (PR #131996)

2025-03-19 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `openmp-offload-amdgpu-runtime` running on `omp-vega20-0` while building `clang,llvm` at step 7 "Add check check-offload". Full details are available at: https://lab.llvm.org/buildbot/#/builders/30/builds/18020 Here is the r

[clang] [clang][scan-build] Treat --use-cc and --use-c++ as shell commands (PR #131932)

2025-03-19 Thread Balázs Benics via cfe-commits
https://github.com/balazs-benics-sonarsource approved this pull request. Thanks for the context. It looks good to me now. @haoNoQ, maybe you know some Perl, could you have a second opinion? Otherwise, let's merge this in a week. https://github.com/llvm/llvm-project/pull/131932 _

[clang] [Clang] emit -Wunused-variable warning for unused structured bindings without the [[maybe_unused]] attribute (PR #127061)

2025-03-19 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/127061 >From a76ee008bdb87655da465e21d09c840edecc2b1b Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Thu, 13 Feb 2025 15:24:09 +0200 Subject: [PATCH 1/2] [Clang] emit -Wunused-variable warning for unused structur

[clang] [NFC][analyzer] Correct example code in VirtualCall docs (PR #131992)

2025-03-19 Thread Donát Nagy via cfe-commits
NagyDonat wrote: (This is a really trivial fixup commit, so I decided to merge it without review. Feel free to suggest additional changes in the example code or elsewhere if you feel that something is still missing.) https://github.com/llvm/llvm-project/pull/131992

[clang] [clang] Add a missing space to the -Weager-load-cxx-named-modules diagnostic message. (PR #131987)

2025-03-19 Thread Haojian Wu via cfe-commits
https://github.com/hokein closed https://github.com/llvm/llvm-project/pull/131987 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 541ab52 - [clang] Add a missing space to the -Weager-load-cxx-named-modules diagnostic message. (#131987)

2025-03-19 Thread via cfe-commits
Author: Haojian Wu Date: 2025-03-19T11:43:40+01:00 New Revision: 541ab52ca9b0a3163b42665bf469a4499a7aea44 URL: https://github.com/llvm/llvm-project/commit/541ab52ca9b0a3163b42665bf469a4499a7aea44 DIFF: https://github.com/llvm/llvm-project/commit/541ab52ca9b0a3163b42665bf469a4499a7aea44.diff LO

[clang] [clang][deps] Implement efficient in-process `ModuleCache` (PR #129751)

2025-03-19 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 3 "clean-build-dir". Full details are available at: https://lab.llvm.org/buildbot/#/builders/64/builds/2529 Here is the relevant piece of the build log f

[clang] [clang] Do not infer lifetimebound for functions with void return type (PR #131997)

2025-03-19 Thread Haojian Wu via cfe-commits
https://github.com/hokein approved this pull request. It would be nice to have have a test for it. I think it should not be too hard to add one. https://github.com/llvm/llvm-project/pull/131997 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [llvm] [MIPS] Add MIPS i6400 and i6500 processors (PR #130587)

2025-03-19 Thread Mallikarjuna Gouda via cfe-commits
https://github.com/mgoudar updated https://github.com/llvm/llvm-project/pull/130587 >From 4f9c5b5b844a61b760a3462994c7736542c14ca4 Mon Sep 17 00:00:00 2001 From: Mallikarjuna Gouda Date: Mon, 10 Mar 2025 15:42:39 +0530 Subject: [PATCH 1/5] [MIPS] Add MIPS i6400 and i6500 processors The i6400 a

[clang] [llvm] [MIPS] Add MIPS i6400 and i6500 processors (PR #130587)

2025-03-19 Thread Mallikarjuna Gouda via cfe-commits
@@ -121,6 +121,30 @@ // MIPS-ARCH-P5600-N64: error: ABI 'n64' is not supported on CPU 'p5600' // // RUN: %clang --target=mips-linux-gnu -### -c %s \ +// RUN:-march=i6400 2>&1 \ +// RUN: | FileCheck -check-prefix=MIPS-ARCH-I6400 %s +// MIPS-ARCH-I6400: "-target-cpu" "i

[clang] [clang] Do not infer lifetimebound for functions with void return type (PR #131997)

2025-03-19 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov requested changes to this pull request. There seem to be some errors missing the attribute tests now (see buildkythe failures) https://github.com/llvm/llvm-project/pull/131997 ___ cfe-commits mailing list cfe-commits@l

[clang] [clang] Introduce elementwise clz/ctz builtins (PR #131995)

2025-03-19 Thread Timm Baeder via cfe-commits
@@ -1484,6 +1484,18 @@ def ElementwiseSubSat : Builtin { let Prototype = "void(...)"; } +def ElementwiseClz : Builtin { + let Spellings = ["__builtin_elementwise_clz"]; + let Attributes = [NoThrow, Const, CustomTypeChecking, Constexpr]; + let Prototype = "void(...)"; +} +

[clang] [clang] Introduce elementwise clz/ctz builtins (PR #131995)

2025-03-19 Thread Fraser Cormack via cfe-commits
@@ -1484,6 +1484,18 @@ def ElementwiseSubSat : Builtin { let Prototype = "void(...)"; } +def ElementwiseClz : Builtin { + let Spellings = ["__builtin_elementwise_clz"]; + let Attributes = [NoThrow, Const, CustomTypeChecking, Constexpr]; + let Prototype = "void(...)"; +} +

[clang] e0db416 - [clang][bytecode] Fix initializing array struct fields from an APValue (#131983)

2025-03-19 Thread via cfe-commits
Author: Timm Baeder Date: 2025-03-19T12:43:37+01:00 New Revision: e0db41615bd43c874d3b27ea5fe40a5940161f74 URL: https://github.com/llvm/llvm-project/commit/e0db41615bd43c874d3b27ea5fe40a5940161f74 DIFF: https://github.com/llvm/llvm-project/commit/e0db41615bd43c874d3b27ea5fe40a5940161f74.diff L

[clang-tools-extra] [clang-tidy][C++20] Add support for aggregate types within modernize-use-emplace (PR #131969)

2025-03-19 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,86 @@ +// RUN: %check_clang_tidy %s -std=c++20 modernize-use-emplace %t -- \ vbvictor wrote: Consider mergin this file `use-emplace.cpp` using 2 RUN commands with specified custom suffix. This will remove unnecessary deplication of `vector` and `init

[clang] [clang-tools-extra] Suppress pedantic diagnostic for a file not ending in EOL (PR #131794)

2025-03-19 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > Both #131812 and #131816 have been merged, so you can update your branch and > run the script now. Thank you! I re-ran the script and it seems to have an issue with line endings because the diff shows changes on every line in the file. I'm going to land these changes as-

[clang] [clang-tools-extra] Suppress pedantic diagnostic for a file not ending in EOL (PR #131794)

2025-03-19 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman closed https://github.com/llvm/llvm-project/pull/131794 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libclc] [libclc] Skip opt command if opt_flags is empty (PR #130882)

2025-03-19 Thread Wenju He via cfe-commits
wenju-he wrote: > Another option would be to unconditionally have builtin.opt targets but if no > flags are passed, just make them empty targets that rely only on builtin.link > targets. Thanks for the suggestion. Done. Please review again. https://github.com/llvm/llvm-project/pull/130882 __

[clang-tools-extra] [clang-doc][fix] crashes when generating HTML without `--repository` (PR #131698)

2025-03-19 Thread Mohamed Emad via cfe-commits
@@ -494,7 +494,7 @@ genReferencesBlock(const std::vector &References, static std::unique_ptr writeFileDefinition(const Location &L, std::optional RepositoryUrl = std::nullopt) { - if (!L.IsFileInRootDir && !RepositoryUrl) + if (!L.IsFileInRootDir || !Repos

[clang] [llvm] [flang-rt] Pass the whole path of libflang_rt.runtime.a to linker on AIX (PR #131041)

2025-03-19 Thread Daniel Chen via cfe-commits
https://github.com/DanielCChen edited https://github.com/llvm/llvm-project/pull/131041 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Reapply "[analyzer] Delay the checker constructions after parsing" (PR #128369)

2025-03-19 Thread Balazs Benics via cfe-commits
steakhal wrote: Thank you for the review! https://github.com/llvm/llvm-project/pull/128369 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][RFC] Introduce a trait to determine the structure binding size (PR #131515)

2025-03-19 Thread Aaron Ballman via cfe-commits
@@ -5066,6 +5066,10 @@ static bool CheckUnaryTypeTraitTypeCompleteness(Sema &S, TypeTrait UTT, case UTT_IsInterfaceClass: return true; + // We diagnose incomplete class types later AaronBallman wrote: ```suggestion // We diagnose incomplete class ty

[clang] [CodeGen][NFC] Run mem2reg and sroa on complex range tests (PR #131925)

2025-03-19 Thread Mészáros Gergely via cfe-commits
https://github.com/Maetveis edited https://github.com/llvm/llvm-project/pull/131925 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Add Zilsd and Zclsd Extensions (PR #131094)

2025-03-19 Thread via cfe-commits
https://github.com/dong-miao updated https://github.com/llvm/llvm-project/pull/131094 >From bcdf9641037507b855a20a8ba5d26b127dd248e8 Mon Sep 17 00:00:00 2001 From: dong-miao Date: Sat, 4 Jan 2025 17:53:58 +0800 Subject: [PATCH 01/36] Update RISCVSystemOperands.td --- llvm/lib/Target/RISCV/RIS

[clang] [NFC][analyzer] Document the VirtualCall checkers (PR #131861)

2025-03-19 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat closed https://github.com/llvm/llvm-project/pull/131861 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 9762b8e - [NFC][analyzer] Document the VirtualCall checkers (#131861)

2025-03-19 Thread via cfe-commits
Author: Donát Nagy Date: 2025-03-19T10:54:06+01:00 New Revision: 9762b8e1757601a719d926f7df77c207617adfdd URL: https://github.com/llvm/llvm-project/commit/9762b8e1757601a719d926f7df77c207617adfdd DIFF: https://github.com/llvm/llvm-project/commit/9762b8e1757601a719d926f7df77c207617adfdd.diff LO

[clang] Improve the -Wundefined-func-template diagnostic note for invisible template functions (PR #129031)

2025-03-19 Thread Haojian Wu via cfe-commits
https://github.com/hokein closed https://github.com/llvm/llvm-project/pull/129031 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][analyzer] Correct example code in VirtualCall docs (PR #131992)

2025-03-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 @llvm/pr-subscribers-clang Author: Donát Nagy (NagyDonat) Changes Oops, I noticed these just after merging my commit 9762b8e1757601a719d926f7df77c207617adfdd. --- Full diff: https://github.com/llvm/llvm-project/pull/131992.diff

[clang] [Clang] emit -Wunused-variable warning for unused structured bindings without the [[maybe_unused]] attribute (PR #127061)

2025-03-19 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/127061 >From a76ee008bdb87655da465e21d09c840edecc2b1b Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Thu, 13 Feb 2025 15:24:09 +0200 Subject: [PATCH 1/2] [Clang] emit -Wunused-variable warning for unused structur

[clang] [NFC][analyzer] Correct example code in VirtualCall docs (PR #131992)

2025-03-19 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat created https://github.com/llvm/llvm-project/pull/131992 Oops, I noticed these just after merging my commit 9762b8e1757601a719d926f7df77c207617adfdd. From 390cadac0d98d90a802cf3520a4891e39953eead Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Don=C3=A1t=20Nagy?= Date: W

[clang] [clang-format] add option to control bin-packing keyworded parameters (PR #131605)

2025-03-19 Thread Eugene Shalygin via cfe-commits
https://github.com/zeule updated https://github.com/llvm/llvm-project/pull/131605 >From 3f9cd2caa38d1b004b723049c22f4a19283d4d05 Mon Sep 17 00:00:00 2001 From: Eugene Shalygin Date: Mon, 17 Mar 2025 11:23:35 +0100 Subject: [PATCH] [clang-format] option to control bin-packing keyworded paramete

[clang] [clang-format] add option to control bin-packing keyworded parameters (PR #131605)

2025-03-19 Thread Eugene Shalygin via cfe-commits
@@ -148,6 +160,24 @@ class AnnotatingParser { } } + const FormatStyle::FunctionDeclarationWithKeywords * + isInsideFunctionWithKeywordedParameters(const FormatToken &Token) const { +const FormatToken *Previous = &Token; +while (auto Prev = Previous->getPrevious

[clang] [clang] Add a missing space to the -Weager-load-cxx-named-modules diagnostic message. (PR #131987)

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

[clang] [clang] Add a missing space to the -Weager-load-cxx-named-modules diagnostic message. (PR #131987)

2025-03-19 Thread Haojian Wu via cfe-commits
https://github.com/hokein created https://github.com/llvm/llvm-project/pull/131987 None >From f15c7880c04597b2227e5189b8c3af2078338cf8 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Wed, 19 Mar 2025 10:26:51 +0100 Subject: [PATCH] [clang] Add a missing space to the -Weager-load-cxx-named-mod

[clang] [Clang][OpenCL][AMDGPU] Allow a kernel to call another kernel (PR #115821)

2025-03-19 Thread Aniket Lal via cfe-commits
@@ -6138,6 +6150,17 @@ void CodeGenModule::EmitGlobalFunctionDefinition(GlobalDecl GD, CodeGenFunction(*this).GenerateCode(GD, Fn, FI); setNonAliasAttributes(GD, Fn); + + if (D->hasAttr()) { +if (GD.getKernelReferenceKind() == KernelReferenceKind::Stub) { + if (

[clang] [Clang][OpenCL][AMDGPU] Allow a kernel to call another kernel (PR #115821)

2025-03-19 Thread Aniket Lal via cfe-commits
@@ -6127,6 +6133,12 @@ RValue CodeGenFunction::EmitCall(QualType CalleeType, const auto *FnType = cast(PointeeType); + if (auto FD = dyn_cast_or_null(TargetDecl)) { +if (FD->hasAttr()) { + CGM.getTargetCodeGenInfo().setOCLKernelStubCallingConvention(FnType); +

[clang] 74f5a02 - Reapply "[AArch64][SVE] Improve fixed-length addressing modes. (#129732)" (#130625)

2025-03-19 Thread via cfe-commits
Author: Ricardo Jesus Date: 2025-03-19T08:25:37Z New Revision: 74f5a028cb612e7e9bcf75d8ceb1a0a9d20fdb80 URL: https://github.com/llvm/llvm-project/commit/74f5a028cb612e7e9bcf75d8ceb1a0a9d20fdb80 DIFF: https://github.com/llvm/llvm-project/commit/74f5a028cb612e7e9bcf75d8ceb1a0a9d20fdb80.diff LOG:

[clang] [llvm] Reapply "[AArch64][SVE] Improve fixed-length addressing modes. (#130263)" (PR #130625)

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

[clang] [Clang][OpenCL][AMDGPU] Allow a kernel to call another kernel (PR #115821)

2025-03-19 Thread Aniket Lal via cfe-commits
@@ -1162,9 +1162,15 @@ void MicrosoftCXXNameMangler::mangleUnqualifiedName(GlobalDecl GD, ->getTemplatedDecl() ->hasAttr())) && GD.getKernelReferenceKind() == KernelReferenceKind::Stub; +bool IsOCLDeviceStub = +

[clang] Clang: Add elementwise minnum/maxnum builtin functions (PR #129207)

2025-03-19 Thread YunQiang Su via cfe-commits
https://github.com/wzssyqa updated https://github.com/llvm/llvm-project/pull/129207 >From 5c3b36b06294b43088d277c689c3367825708779 Mon Sep 17 00:00:00 2001 From: YunQiang Su Date: Fri, 28 Feb 2025 16:09:04 +0800 Subject: [PATCH 1/6] Clang: Add minnum/maxnum builtin functions support With https

[clang] [llvm] Vectorize: Support fminimumnum and fmaximumnum (PR #131781)

2025-03-19 Thread YunQiang Su via cfe-commits
@@ -0,0 +1,407 @@ +// NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --version 5 wzssyqa wrote: We have the backend test already. This PR fixes the front to generate vectorized IR from C code. https://github.com/llvm/llvm-p

[clang] [clang][Sema] Propagate qualifiers during derived-to-base conversion (PR #127824)

2025-03-19 Thread Antonio Frighetto via cfe-commits
https://github.com/antoniofrighetto closed https://github.com/llvm/llvm-project/pull/127824 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][OpenCL][AMDGPU] Allow a kernel to call another kernel (PR #115821)

2025-03-19 Thread Aniket Lal via cfe-commits
@@ -0,0 +1,43 @@ +// RUN: %clang_cc1 -triple amdgcn-unknown-unknown -emit-llvm -o - %s | FileCheck %s lalaniket8 wrote: Changed test file to auto generate using update_cc_test_checks.py with --include-generated-funcs argument. This can detect and include stub v

[clang] [llvm] [MIPS] Add MIPS i6400 and i6500 processors (PR #130587)

2025-03-19 Thread via cfe-commits
@@ -121,6 +121,30 @@ // MIPS-ARCH-P5600-N64: error: ABI 'n64' is not supported on CPU 'p5600' // // RUN: %clang --target=mips-linux-gnu -### -c %s \ +// RUN:-march=i6400 2>&1 \ +// RUN: | FileCheck -check-prefix=MIPS-ARCH-I6400 %s +// MIPS-ARCH-I6400: "-target-cpu" "i

[clang] [Format] Do not crash on non-null terminated strings (PR #131299)

2025-03-19 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov edited https://github.com/llvm/llvm-project/pull/131299 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [X86][AVX10.2] Use 's_' for saturate-convert intrinsics (PR #131592)

2025-03-19 Thread Phoebe Wang via cfe-commits
phoebewang wrote: Here is GCC patch: https://gcc.gnu.org/pipermail/gcc-patches/2025-March/678227.html https://github.com/llvm/llvm-project/pull/131592 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listi

[clang-tools-extra] [clang-doc][fix] crashes when generating HTML without `--repository` (PR #131698)

2025-03-19 Thread Mohamed Emad via cfe-commits
hulxv wrote: @ilovepi I see you opened a PR to solve the same issue [here](https://github.com/llvm/llvm-project/pull/131939). Wouldn't be better if I continue working on it with your suggestions? 😅 https://github.com/llvm/llvm-project/pull/131698 ___

[clang] Clang: Add elementwise minnum/maxnum builtin functions (PR #129207)

2025-03-19 Thread YunQiang Su via cfe-commits
https://github.com/wzssyqa updated https://github.com/llvm/llvm-project/pull/129207 >From 5c3b36b06294b43088d277c689c3367825708779 Mon Sep 17 00:00:00 2001 From: YunQiang Su Date: Fri, 28 Feb 2025 16:09:04 +0800 Subject: [PATCH 1/6] Clang: Add minnum/maxnum builtin functions support With https

[clang] [clang][bytecode] Fix initialing array struct fields from an APValue (PR #131983)

2025-03-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes We need to recurse once more here and move the array case into the bigger if chain. --- Full diff: https://github.com/llvm/llvm-project/pull/131983.diff 3 Files Affected: - (modified) clang/lib/AST/ByteCo

[clang] [clang][bytecode] Fix initialing array struct fields from an APValue (PR #131983)

2025-03-19 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/131983 We need to recurse once more here and move the array case into the bigger if chain. >From 7fa354a81378172ce3cd5488b457f129da883698 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Wed, 19 Ma

[clang] Clang: Add elementwise minnum/maxnum builtin functions (PR #129207)

2025-03-19 Thread YunQiang Su via cfe-commits
wzssyqa wrote: > > > Needs the documentation updates in clang language extensions with the > > > other elementwise builtins, and a release note > > > > > > Documentation updated. And ReleaseNotes is submitted as a new PR: #131977 > > Best to keep the note about the new builtins here. The PR m

[clang] [llvm] Vectorize: Support fminimumnum and fmaximumnum (PR #131781)

2025-03-19 Thread Matt Arsenault via cfe-commits
@@ -0,0 +1,407 @@ +// NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --version 5 arsenm wrote: Should not be testing the vectorizer in clang. This needs a pure IR test in the backend https://github.com/llvm/llvm-project/p

[clang] [OffloadBundler] Expose function to parse compressed bundle headers (PR #130284)

2025-03-19 Thread Juan Manuel Martinez Caamaño via cfe-commits
https://github.com/jmmartinez closed https://github.com/llvm/llvm-project/pull/130284 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][Sema] Propagate qualifiers during derived-to-base conversion (PR #127824)

2025-03-19 Thread Antonio Frighetto via cfe-commits
https://github.com/antoniofrighetto updated https://github.com/llvm/llvm-project/pull/127824 >From e9988c36ed788b2d1ce00b028bed51169bd8b02c Mon Sep 17 00:00:00 2001 From: Antonio Frighetto Date: Wed, 19 Mar 2025 09:04:29 +0100 Subject: [PATCH] [clang][Sema] Propagate qualifiers during derived-t

[clang] [OffloadBundler] Expose function to parse compressed bundle headers (PR #130284)

2025-03-19 Thread Juan Manuel Martinez Caamaño via cfe-commits
jmmartinez wrote: Thanks for the review ! https://github.com/llvm/llvm-project/pull/130284 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][bytecode] Fix initializing array struct fields from an APValue (PR #131983)

2025-03-19 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr closed https://github.com/llvm/llvm-project/pull/131983 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy][C++20] Add support for aggregate types within modernize-use-emplace (PR #131969)

2025-03-19 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,86 @@ +// RUN: %check_clang_tidy %s -std=c++20 modernize-use-emplace %t -- \ +// RUN: -config="{CheckOptions: \ +// RUN: {modernize-use-emplace.ContainersWithPushBack: \ +// RUN:'::std::vector; ::std::list; ::std::deque; llvm::LikeASmallVe

[clang-tools-extra] [clang-tidy] Skip system macros in readability-identifier-naming check (PR #132016)

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

[clang-tools-extra] [clang-tidy] Skip system macros in readability-identifier-naming check (PR #132016)

2025-03-19 Thread Carlos Galvez via cfe-commits
carlosgalvezp wrote: > We could, but also RenamerClangTidyVisitor could be improved to skip system > code if not enabled. I checked briefly and it does not seem to process system declarations already now, it was just the macros that were missing. https://github.com/llvm/llvm-project/pull/1320

[clang] [CIR] Upstream a basic version of class LexicalScope (PR #131945)

2025-03-19 Thread Erich Keane via cfe-commits
@@ -149,14 +156,125 @@ void CIRGenFunction::declare(mlir::Value addrVal, const Decl *var, QualType ty, allocaOp.setConstantAttr(mlir::UnitAttr::get(&getMLIRContext())); } +void CIRGenFunction::LexicalScope::cleanup() { + CIRGenBuilderTy &builder = cgf.builder; + Lexical

[clang] [CIR] Upstream a basic version of class LexicalScope (PR #131945)

2025-03-19 Thread Erich Keane via cfe-commits
https://github.com/erichkeane commented: 2 nits, else LGTM. https://github.com/llvm/llvm-project/pull/131945 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream a basic version of class LexicalScope (PR #131945)

2025-03-19 Thread Erich Keane via cfe-commits
@@ -149,14 +156,125 @@ void CIRGenFunction::declare(mlir::Value addrVal, const Decl *var, QualType ty, allocaOp.setConstantAttr(mlir::UnitAttr::get(&getMLIRContext())); } +void CIRGenFunction::LexicalScope::cleanup() { + CIRGenBuilderTy &builder = cgf.builder; + Lexical

[clang-tools-extra] [clang-tidy] support query based custom check (PR #131804)

2025-03-19 Thread Carlos Galvez via cfe-commits
@@ -0,0 +1,20 @@ +set(LLVM_LINK_COMPONENTS + support + ) + +add_clang_library(clangTidyCustomModule STATIC + CustomTidyModule.cpp + QueryCheck.cpp + + LINK_LIBS + clangTidy + clangTidyUtils + + DEPENDS + ClangDriverOptions + ) + +clang_target_link_libraries(clangTidyCust

[clang] [Clang][NFC] Add test for CWG2289 "Uniqueness of structured binding names" (PR #131054)

2025-03-19 Thread Yanzuo Liu via cfe-commits
zwuis wrote: > "Declarative region" is clearly pre-P1787R6 wording. Can you find the wording > in the current draft that covers this? Yes. I have updated the description of this PR. https://github.com/llvm/llvm-project/pull/131054 ___ cfe-commits mai

[clang] [Clang][CodeGen] Do not set inbounds flag for struct GEP with null base pointers (PR #130734)

2025-03-19 Thread Yingwei Zheng via cfe-commits
dtcxzyw wrote: @efriedma-quic Any more comments? https://github.com/llvm/llvm-project/pull/130734 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Skip system macros in readability-identifier-naming check (PR #132016)

2025-03-19 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 861efd4b3f93d30d353f0a6eea249fbdac1778a0 0d4f53cefc223a116b25f9106d37dc707c58ec0f --e

[clang] [Clang] Introduce a trait to determine the structure binding size (PR #131515)

2025-03-19 Thread Yanzuo Liu via cfe-commits
@@ -1642,6 +1661,56 @@ void Sema::CheckCompleteDecompositionDeclaration(DecompositionDecl *DD) { DD->setInvalidDecl(); } +std::optional Sema::GetDecompositionElementCount(QualType T, + SourceLocation Loc) { + con

[clang] [clang] Do not infer lifetimebound for functions with void return type (PR #131997)

2025-03-19 Thread Ilya Biryukov via cfe-commits
ilya-biryukov wrote: LGTM! I second the suggestion to add a test. Also see the suggestion to turn this into a warning in the first place: https://github.com/llvm/llvm-project/issues/126231#issuecomment-2735876367 I am not sure why lifetimebound needs to be an error while other attributes like

[clang] [Clang] Force expressions with UO_Not to not be non-negative (PR #126846)

2025-03-19 Thread Yutong Zhu via cfe-commits
YutongZhuu wrote: > I think this change might went too far. We are seeing this check flagging > code like this: > > ``` > error: implicit conversion loses integer precision: 'int' to 'int8_t' (aka > 'signed char') [-Werror,-Wimplicit-int-conversion]: > int8_t shift = ... > ... > shift = -shift

[clang] [Clang][Diagnostics] Update select uses in DiagnosticXKinds.td to use enum_select (PR #130868)

2025-03-19 Thread Erich Keane via cfe-commits
erichkeane wrote: > I was wondering if it was okay for a replacement since the names of the > CommandTraits options are the same. Also would a select with only 1 use (with > a magic number) be up for replacement? I'll check out the review. As far as this CommandTraits one, it probably is not

  1   2   3   4   >