[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-06-18 Thread via cfe-commits
@@ -101,7 +101,8 @@ define void @f5() "frame-pointer"="all" { ; CHECK-NEXT:.seh_endprologue ; CHECK-NEXT:leaq -92(%rbp), %rcx ; CHECK-NEXT:callq external -; CHECK-NEXT:nop +; UEFI does not have SEH, so does not require NOP +; WIN64-NEXT:nop

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-06-18 Thread via cfe-commits
@@ -2660,6 +2644,133 @@ void X86AsmPrinter::emitCallInstruction(const llvm::MCInst &MCI) { OutStreamer->emitInstruction(MCI, getSubtargetInfo()); } +// Checks whether a NOP is required after a CALL and inserts the NOP, if +// necessary. +void X86AsmPrinter::emitNopAfterCall

[clang] [llvm] [LLVM][IRBuilder] Use NUW arithmetic for Create{ElementCount,TypeSize}. (PR #143532)

2025-06-18 Thread Florian Hahn via cfe-commits
@@ -177,16 +177,16 @@ define void @add_unique_ind32(ptr noalias nocapture %a, i64 %n) { ; CHECK-LABEL: @add_unique_ind32( ; CHECK-NEXT: entry: ; CHECK-NEXT:[[TMP0:%.*]] = call i64 @llvm.vscale.i64() -; CHECK-NEXT:[[TMP1:%.*]] = shl i64 [[TMP0]], 2 +; CHECK-NEXT:[[

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-06-18 Thread via cfe-commits
@@ -9,7 +9,6 @@ define i32 @foobar() gc "statepoint-example" personality ptr @__gxx_personality_ ; CHECK-NEXT:.seh_endprologue ; CHECK-NEXT:callq bar ; CHECK-NEXT: .Ltmp0: -; CHECK-NEXT:nop sivadeilra wrote: Since this is for the Windows GNU targ

[clang] [clang-tools-extra] [clang-tidy] Warn about misuse of sizeof operator in loops. (PR #143205)

2025-06-18 Thread via cfe-commits
@@ -146,6 +146,13 @@ Changes in existing checks ` check to detect conversion in argument of ``std::make_optional``. +- Improved :doc: `bugprone-sizeof-expression + ` check by adding + `WarnOnSizeOfInLoopTermination` option to detect misuses of ``sizeof`` + expression in

[clang] Add missing intrinsics to cuda headers (PR #143664)

2025-06-18 Thread Artem Belevich via cfe-commits
Artem-B wrote: It's a C++-11 feature. Tests still include c++98. We do not intend to keep everything working with c++98 (we already use c++11 in other headers), but we should not break it either. In this case, you can just enable the new stuff for c++11 or newer standards. https://github.com/

[clang] [llvm] [LLVM][IRBuilder] Use NUW arithmetic for Create{ElementCount,TypeSize}. (PR #143532)

2025-06-18 Thread Florian Hahn via cfe-commits
https://github.com/fhahn approved this pull request. LGTM, thanks https://github.com/llvm/llvm-project/pull/143532 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Add support for member initialization from constructors (PR #144583)

2025-06-18 Thread Bruno Cardoso Lopes via cfe-commits
@@ -53,19 +53,135 @@ bool CIRGenFunction::isConstructorDelegationValid( return true; } +static void emitLValueForAnyFieldInitialization(CIRGenFunction &cgf, +CXXCtorInitializer *memberInit, +

[clang] [CIR] Add support for member initialization from constructors (PR #144583)

2025-06-18 Thread Bruno Cardoso Lopes via cfe-commits
https://github.com/bcardosolopes approved this pull request. LGTM module few nits https://github.com/llvm/llvm-project/pull/144583 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Add support for member initialization from constructors (PR #144583)

2025-06-18 Thread Bruno Cardoso Lopes via cfe-commits
@@ -84,6 +200,34 @@ Address CIRGenFunction::loadCXXThisAddress() { return Address(loadCXXThis(), cxxThisAlignment); } +void CIRGenFunction::emitInitializerForField(FieldDecl *field, LValue lhs, + Expr *init) { + QualType fieldType

[clang] [CIR] Add support for member initialization from constructors (PR #144583)

2025-06-18 Thread Bruno Cardoso Lopes via cfe-commits
@@ -53,19 +53,135 @@ bool CIRGenFunction::isConstructorDelegationValid( return true; } +static void emitLValueForAnyFieldInitialization(CIRGenFunction &cgf, +CXXCtorInitializer *memberInit, +

[clang] [CIR] Add initial support for bitfields in structs (PR #142041)

2025-06-18 Thread via cfe-commits
@@ -14,6 +14,105 @@ namespace clang::CIRGen { +/// Record with information about how a bitfield should be accessed. This is +/// very similar to what LLVM codegen does, once CIR evolves it's possible we +/// can use a more higher level representation. +/// +/// Often we lay o

[clang] [CIR] Add support for member initialization from constructors (PR #144583)

2025-06-18 Thread Bruno Cardoso Lopes via cfe-commits
https://github.com/bcardosolopes edited https://github.com/llvm/llvm-project/pull/144583 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Add support for member initialization from constructors (PR #144583)

2025-06-18 Thread Bruno Cardoso Lopes via cfe-commits
https://github.com/bcardosolopes edited https://github.com/llvm/llvm-project/pull/144583 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Add support for member initialization from constructors (PR #144583)

2025-06-18 Thread Bruno Cardoso Lopes via cfe-commits
@@ -53,19 +53,135 @@ bool CIRGenFunction::isConstructorDelegationValid( return true; } +static void emitLValueForAnyFieldInitialization(CIRGenFunction &cgf, +CXXCtorInitializer *memberInit, +

[clang] Use the Windows SDK arguments over the environment (PR #144805)

2025-06-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Fabrice de Gans (Steelskin) Changes If any of the Windows SDK (and MSVC)-related argument is passed in the command line, they should take priority over the environment variables like `INCLUDE` or `LIB` set by vcvarsall from the Visual Stu

[clang] Use the Windows SDK arguments over the environment (PR #144805)

2025-06-18 Thread Fabrice de Gans via cfe-commits
https://github.com/Steelskin created https://github.com/llvm/llvm-project/pull/144805 If any of the Windows SDK (and MSVC)-related argument is passed in the command line, they should take priority over the environment variables like `INCLUDE` or `LIB` set by vcvarsall from the Visual Studio De

[clang] [clang] ODR hashes depth+index and not name of TemplateTypeParm (PR #144796)

2025-06-18 Thread Maksim Ivanov via cfe-commits
https://github.com/emaxx-google updated https://github.com/llvm/llvm-project/pull/144796 >From 2fd016fd5d0bbc8d9922e7dbdc3bf29fd9099450 Mon Sep 17 00:00:00 2001 From: Maksim Ivanov Date: Wed, 18 Jun 2025 23:13:55 +0200 Subject: [PATCH 1/2] [clang] ODR hashes depth+index and not name of Templat

[clang] Use the Windows SDK arguments over the environment (PR #144805)

2025-06-18 Thread Fabrice de Gans via cfe-commits
https://github.com/Steelskin updated https://github.com/llvm/llvm-project/pull/144805 >From 472cb7e13aa720a3fd53078d45e9c30503029003 Mon Sep 17 00:00:00 2001 From: Fabrice de Gans Date: Wed, 18 Jun 2025 15:04:35 -0700 Subject: [PATCH 1/2] Use the Windows SDK arguments over the environment If a

[clang] Use the Windows SDK arguments over the environment (PR #144805)

2025-06-18 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/lib/Driver/ToolChains/MSVC.cpp ``

[clang] let Neon builtin function accept a const variable (PR #144625)

2025-06-18 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic edited https://github.com/llvm/llvm-project/pull/144625 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-06-18 Thread via cfe-commits
https://github.com/sivadeilra created https://github.com/llvm/llvm-project/pull/144745 This fixes a long-standing bug in LLVM's support for generating Windows EH tables, specifically the IP2State tables. On most Windows platforms (AMD64, ARM64, ARM32, IA64, but *not* x86-32), exception handli

[compiler-rt] [libcxxabi] [libunwind] [runtimes][PAC] Harden unwinding when possible (#138571) (PR #143230)

2025-06-18 Thread Anatoly Trosinenko via cfe-commits
@@ -30,6 +30,46 @@ EXCEPTION_DISPOSITION _GCC_specific_handler(PEXCEPTION_RECORD, void *, PCONTEXT, _Unwind_Personality_Fn); #endif +#if __has_include() +#include +#endif + +#if defined(__APPLE__) && __has_feature(ptrauth_qualifier

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-06-18 Thread via cfe-commits
github-actions[bot] wrote: Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be notified. If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you, it

[clang] [flang] [llvm] [flang][AArch64] Always link compiler-rt to flang after libgcc (PR #144710)

2025-06-18 Thread Kiran Chandramohan via cfe-commits
kiranchandramohan wrote: Can you add a fixes tag for https://github.com/llvm/llvm-project/issues/141147 ? https://github.com/llvm/llvm-project/pull/144710 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/li

[clang] [flang] [llvm] [llvm] annotate remaining LLVM interfaces for DLL export (PR #144746)

2025-06-18 Thread Andrew Rogers via cfe-commits
https://github.com/andrurogerz created https://github.com/llvm/llvm-project/pull/144746 ## Purpose This patch is one in a series of code-mods that annotate LLVM’s public interface for export. This patch annotates the remaining LLVM interface that was missed in, or modified since, previous pat

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-06-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-x86 Author: None (sivadeilra) Changes This fixes a long-standing bug in LLVM's support for generating Windows EH tables, specifically the IP2State tables. On most Windows platforms (AMD64, ARM64, ARM32, IA64, but *not* x86-32), exception handl

[clang-tools-extra] Use spelling for clangd missing includes filtering (PR #143411)

2025-06-18 Thread via cfe-commits
https://github.com/Harald-R closed https://github.com/llvm/llvm-project/pull/143411 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AArch64][SelectionDAG] Add CodeGen support for scalar FEAT_CPA (PR #105669)

2025-06-18 Thread Rodolfo Wottrich via cfe-commits
https://github.com/rgwott edited https://github.com/llvm/llvm-project/pull/105669 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AArch64] Add CodeGen support for scalar FEAT_CPA (PR #105669)

2025-06-18 Thread Rodolfo Wottrich via cfe-commits
https://github.com/rgwott edited https://github.com/llvm/llvm-project/pull/105669 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [include-cleaner] Add POSIX symbol mappings (PR #144748)

2025-06-18 Thread Ildikó Cseri via cfe-commits
https://github.com/cseriildi created https://github.com/llvm/llvm-project/pull/144748 ### **Summary** This PR adds more symbol-header mappings that `clang-include-cleaner`, `clangd` and `clang-tidy` use to detect symbols that are used but not directly included ([following the include-what-you

[clang] [flang] [llvm] [flang][AArch64] Always link compiler-rt to flang after libgcc (PR #144710)

2025-06-18 Thread Paul Osmialowski via cfe-commits
https://github.com/pawosm-arm edited https://github.com/llvm/llvm-project/pull/144710 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [include-cleaner] Add POSIX symbol mappings (PR #144748)

2025-06-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Ildikó Cseri (cseriildi) Changes ### **Summary** This PR adds more symbol-header mappings that `clang-include-cleaner`, `clangd` and `clang-tidy` use to detect symbols that are used but not directly included ([following the include-what-

[clang] [include-cleaner] Add POSIX symbol mappings (PR #144748)

2025-06-18 Thread via cfe-commits
github-actions[bot] wrote: Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be notified. If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you, it

[clang] [llvm] [AArch64] Add CodeGen support for scalar FEAT_CPA (PR #105669)

2025-06-18 Thread Rodolfo Wottrich via cfe-commits
@@ -5025,6 +5025,11 @@ def msve_vector_bits_EQ : Joined<["-"], "msve-vector-bits=">, Group, HelpText<"Specify the size in bits of an SVE vector register. Defaults to the" " vector length agnostic value of \"scalable\". (AArch64 only)">; + +def mcpa_codegen : Flag<

[clang] [llvm] [AArch64] Add CodeGen support for scalar FEAT_CPA (PR #105669)

2025-06-18 Thread Rodolfo Wottrich via cfe-commits
@@ -0,0 +1,451 @@ +; RUN: llc -mtriple=aarch64 -verify-machineinstrs --mattr=+cpa -O0 -global-isel=0 -fast-isel=0 %s -o - 2>&1 | FileCheck %s --check-prefixes=CHECK-CPA-O0 +; RUN: llc -mtriple=aarch64 -verify-machineinstrs --mattr=+cpa -O3 -global-isel=0 -fast-isel=0 %s -o - 2>

[clang] Inject compilation command into __cli_ global variable (PR #144622)

2025-06-18 Thread Eli Friedman via cfe-commits
efriedma-quic wrote: Please start a thread on https://discourse.llvm.org/ describing the problem you're trying to solve, and your proposed solution. https://github.com/llvm/llvm-project/pull/144622 ___ cfe-commits mailing list cfe-commits@lists.llvm.o

[clang] [include-cleaner] Add POSIX symbol mappings (PR #144748)

2025-06-18 Thread Ildikó Cseri via cfe-commits
https://github.com/cseriildi updated https://github.com/llvm/llvm-project/pull/144748 From c4681dfa8da9ba90418525f32a3d1968366174d2 Mon Sep 17 00:00:00 2001 From: Ildiko Cseri Date: Wed, 18 Jun 2025 12:58:34 + Subject: [PATCH] [include-cleaner] Add POSIX symbol mappings Add POSIX symbol-to

[clang-tools-extra] [clang-doc] mangle specialization file names (PR #144617)

2025-06-18 Thread Erick Velez via cfe-commits
@@ -909,6 +910,13 @@ emitInfo(const RecordDecl *D, const FullComment *FC, Location Loc, RI->Template.emplace(); RI->Template->Specialization.emplace(); auto &Specialization = *RI->Template->Specialization; +auto *Mangler = ItaniumMangleContext::create( +

[compiler-rt] [libcxxabi] [libunwind] [runtimes][PAC] Harden unwinding when possible (#138571) (PR #143230)

2025-06-18 Thread Oliver Hunt via cfe-commits
@@ -30,6 +30,46 @@ EXCEPTION_DISPOSITION _GCC_specific_handler(PEXCEPTION_RECORD, void *, PCONTEXT, _Unwind_Personality_Fn); #endif +#if __has_include() +#include +#endif + +#if defined(__APPLE__) && __has_feature(ptrauth_qualifier

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-06-18 Thread via cfe-commits
https://github.com/sivadeilra updated https://github.com/llvm/llvm-project/pull/144745 >From 50c418d4259ac5039d9ab7532afd518a0cfbbc64 Mon Sep 17 00:00:00 2001 From: Arlie Davis Date: Mon, 16 Jun 2025 11:09:23 -0700 Subject: [PATCH 1/2] Fix IP2State tables --- .../CodeGenCXX/microsoft-abi-eh-a

[clang-tools-extra] [clang-tidy] Improve `bugprone-exception-escape`: add stacktrace of escaped exception (PR #134375)

2025-06-18 Thread Baranov Victor via cfe-commits
vbvictor wrote: > Could you add some separate tests for this diagnostic? I've added tests with: - with template functions - deeper nesting - multiple exceptions throw (as for now, it reports for only one, and I'd like to leave it for first iteration) If there are any more tests that I should,

[clang] [clang] Use TargetInfo to determine device kernel calling convention (PR #144728)

2025-06-18 Thread Nick Sarnie via cfe-commits
https://github.com/sarnex closed https://github.com/llvm/llvm-project/pull/144728 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [InstCombine] remove dead loads, such as memcpy from undef (PR #143958)

2025-06-18 Thread Nikita Popov via cfe-commits
@@ -3339,16 +3340,23 @@ static bool isAllocSiteRemovable(Instruction *AI, if (IntrinsicInst *II = dyn_cast(I)) { switch (II->getIntrinsicID()) { default: -return false; +return std::nullopt; case Intrinsic::memmov

[clang] [llvm] [InstCombine] remove dead loads, such as memcpy from undef (PR #143958)

2025-06-18 Thread Nikita Popov via cfe-commits
https://github.com/nikic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/143958 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-06-18 Thread Eli Friedman via cfe-commits
@@ -2660,6 +2644,133 @@ void X86AsmPrinter::emitCallInstruction(const llvm::MCInst &MCI) { OutStreamer->emitInstruction(MCI, getSubtargetInfo()); } +// Checks whether a NOP is required after a CALL and inserts the NOP, if +// necessary. +void X86AsmPrinter::emitNopAfterCall

[clang] 86d1d6b - [clang] Use TargetInfo to determine device kernel calling convention (#144728)

2025-06-18 Thread via cfe-commits
Author: Nick Sarnie Date: 2025-06-18T20:50:12Z New Revision: 86d1d6b2c0c1f03e82cb8e360f2672c6f0ea39d5 URL: https://github.com/llvm/llvm-project/commit/86d1d6b2c0c1f03e82cb8e360f2672c6f0ea39d5 DIFF: https://github.com/llvm/llvm-project/commit/86d1d6b2c0c1f03e82cb8e360f2672c6f0ea39d5.diff LOG: [

[clang] 4dca445 - [CIR] Upstream ComplexType builtin_complex (#144225)

2025-06-18 Thread via cfe-commits
Author: Amr Hesham Date: 2025-06-18T23:09:48+02:00 New Revision: 4dca4459a328b8d589d81cd1f203b798c36ebf35 URL: https://github.com/llvm/llvm-project/commit/4dca4459a328b8d589d81cd1f203b798c36ebf35 DIFF: https://github.com/llvm/llvm-project/commit/4dca4459a328b8d589d81cd1f203b798c36ebf35.diff LO

[clang] [llvm] [InstCombine] remove dead loads, such as memcpy from undef (PR #143958)

2025-06-18 Thread Nikita Popov via cfe-commits
https://github.com/nikic edited https://github.com/llvm/llvm-project/pull/143958 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream ComplexType builtin_complex (PR #144225)

2025-06-18 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/144225 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream ComplexType builtin_complex (PR #144225)

2025-06-18 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `lldb-x86_64-debian` running on `lldb-x86_64-debian` while building `clang` at step 6 "test". Full details are available at: https://lab.llvm.org/buildbot/#/builders/162/builds/24860 Here is the relevant piece of the build lo

[clang] [flang] [llvm] [llvm] annotate remaining LLVM interfaces for DLL export (PR #144746)

2025-06-18 Thread Jakub Kuderski via cfe-commits
https://github.com/kuhar commented: Could you break this down into a few smaller PRs? I'm concerned that landing a big patch like this may result in messery reverts that will force uses to recompile almost all of the project. https://github.com/llvm/llvm-project/pull/144746 ___

[clang] [Analysis] Avoid some warnings about exit from noreturn function (PR #144408)

2025-06-18 Thread Serge Pavlov via cfe-commits
@@ -0,0 +1,107 @@ +// RUN: %clang_cc1 -fsyntax-only %s -verify + +[[noreturn]] extern void noret(); +[[noreturn]] extern void noret2(); +extern void ordinary(); + +typedef void (*func_type)(void); + spavloff wrote: Added, thank you. https://github.com/llvm/llvm-

[clang] [CUDA][HIP] Add a __device__ version of std::__glibcxx_assert_fail() (PR #136133)

2025-06-18 Thread Artem Belevich via cfe-commits
Artem-B wrote: @jmmartinez It appears that CUDA tests are broken by this change: https://lab.llvm.org/buildbot/#/builders/69/builds/22562/steps/8/logs/stdio ``` FAILED: External/CUDA/CMakeFiles/algorithm-cuda-11.8-c++98-libstdc++-10.dir/algorithm.cu.o /buildbot/cuda-t4-0/work/clang-cuda-t4/c

[clang] [Analysis] Avoid some warnings about exit from noreturn function (PR #144408)

2025-06-18 Thread Serge Pavlov via cfe-commits
@@ -0,0 +1,107 @@ +// RUN: %clang_cc1 -fsyntax-only %s -verify + +[[noreturn]] extern void noret(); +[[noreturn]] extern void noret2(); +extern void ordinary(); + +typedef void (*func_type)(void); + +// Constant initialization. + +void (* const const_fptr)() = noret; +[[noreturn]]

[clang] [llvm] [HLSL][RootSignature] Plug-in serialization and add full sample testcase (PR #144769)

2025-06-18 Thread Finn Plummer via cfe-commits
https://github.com/inbelic created https://github.com/llvm/llvm-project/pull/144769 This pr extends `dumpRootElements` to invoke the print methods of all `RootElement`s now that they are all implemented. Extends the `RootSignatures-AST.hlsl` testcase to have a root element of each type being

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-06-18 Thread via cfe-commits
https://github.com/sivadeilra updated https://github.com/llvm/llvm-project/pull/144745 >From 50c418d4259ac5039d9ab7532afd518a0cfbbc64 Mon Sep 17 00:00:00 2001 From: Arlie Davis Date: Mon, 16 Jun 2025 11:09:23 -0700 Subject: [PATCH 1/3] Fix IP2State tables --- .../CodeGenCXX/microsoft-abi-eh-a

[clang] [clang-tools-extra] [clang-tidy] Warn about misuse of sizeof operator in loops. (PR #143205)

2025-06-18 Thread Malavika Samak via cfe-commits
@@ -353,6 +367,19 @@ void SizeofExpressionCheck::check(const MatchFinder::MatchResult &Result) { diag(E->getBeginLoc(), "suspicious usage of 'sizeof(char*)'; do you mean 'strlen'?") << E->getSourceRange(); + } else if (const auto *E = Result.Nodes.getNode

[clang] [llvm] [Reland] [PowerPC] frontend get target feature from backend with cpu name (PR #144594)

2025-06-18 Thread zhijian lin via cfe-commits
https://github.com/diggerlin updated https://github.com/llvm/llvm-project/pull/144594 >From 2d0f536bdc6fc24f09053569a8c84056ffc31e0d Mon Sep 17 00:00:00 2001 From: zhijian lin Date: Thu, 12 Jun 2025 13:38:13 -0400 Subject: [PATCH 1/5] [PowerPC] frontend get target feature from backend with cp

[clang] [lldb] [Clang][PowerPC] Add __dmr1024 type and DMF integer calculation builtins (PR #142480)

2025-06-18 Thread Maryam Moghadas via cfe-commits
https://github.com/maryammo edited https://github.com/llvm/llvm-project/pull/142480 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [Clang][PowerPC] Add __dmr1024 type and DMF integer calculation builtins (PR #142480)

2025-06-18 Thread Maryam Moghadas via cfe-commits
https://github.com/maryammo edited https://github.com/llvm/llvm-project/pull/142480 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 67c52aa - [CIR] Upstream support for IncompleteArrayType (#144138)

2025-06-18 Thread via cfe-commits
Author: Amr Hesham Date: 2025-06-18T21:47:50+02:00 New Revision: 67c52aacae2aa698eb1d31d81d2376bd77723d3a URL: https://github.com/llvm/llvm-project/commit/67c52aacae2aa698eb1d31d81d2376bd77723d3a DIFF: https://github.com/llvm/llvm-project/commit/67c52aacae2aa698eb1d31d81d2376bd77723d3a.diff LO

[clang] [CIR] Upstream support for IncompleteArrayType (PR #144138)

2025-06-18 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/144138 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang-tidy] Warn about misuse of sizeof operator in loops. (PR #143205)

2025-06-18 Thread Malavika Samak via cfe-commits
https://github.com/malavikasamak edited https://github.com/llvm/llvm-project/pull/143205 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream ComplexType builtin_complex (PR #144225)

2025-06-18 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/144225 >From d5c7a04815acee8b792e95fcd376fc492bcadb58 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sat, 14 Jun 2025 16:21:20 +0200 Subject: [PATCH 1/4] [CIR] Upstream ComplexType builtin_complex --- clang/l

[clang] [llvm] [NFC][HLSL][DXIL] Move D3D12.h enums and flags to DXILABI (PR #143041)

2025-06-18 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/143041 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [NFC][HLSL][DXIL] Move D3D12.h enums and flags to DXILABI (PR #143041)

2025-06-18 Thread Finn Plummer via cfe-commits
inbelic wrote: I will close this pr and create a new one to target once the StaticSampler and DescriptorTable back-end parsing is created. https://github.com/llvm/llvm-project/pull/143041 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https:/

[clang] [HIP] Remove dots in HIP runtime path (PR #143792)

2025-06-18 Thread Yaxun Liu via cfe-commits
@@ -743,9 +743,12 @@ void Linux::AddHIPRuntimeLibArgs(const ArgList &Args, Args.MakeArgString(StringRef("-L") + RocmInstallation->getLibPath())); if (Args.hasFlag(options::OPT_frtlib_add_rpath, - options::OPT_fno_rtlib_add_rpath, false)) +

[clang] [llvm] [AMDGPU][clang][CodeGen][opt] Add late-resolved feature identifying predicates (PR #134016)

2025-06-18 Thread Aaron Ballman via cfe-commits
@@ -9102,6 +9102,15 @@ bool InitializationSequence::Diagnose(Sema &S, case FK_ConversionFailed: { QualType FromType = OnlyArg->getType(); +// __amdgpu_feature_predicate_t can be explicitly cast to the logical op +// type, although this is almost always an error a

[clang] [Analysis] Avoid some warnings about exit from noreturn function (PR #144408)

2025-06-18 Thread Serge Pavlov via cfe-commits
@@ -0,0 +1,107 @@ +// RUN: %clang_cc1 -fsyntax-only %s -verify + +[[noreturn]] extern void noret(); +[[noreturn]] extern void noret2(); +extern void ordinary(); + +typedef void (*func_type)(void); + +// Constant initialization. + +void (* const const_fptr)() = noret; +[[noreturn]]

[clang] [llvm] [Reland] [PowerPC] frontend get target feature from backend with cpu name (PR #144594)

2025-06-18 Thread zhijian lin via cfe-commits
https://github.com/diggerlin updated https://github.com/llvm/llvm-project/pull/144594 >From 2d0f536bdc6fc24f09053569a8c84056ffc31e0d Mon Sep 17 00:00:00 2001 From: zhijian lin Date: Thu, 12 Jun 2025 13:38:13 -0400 Subject: [PATCH 1/4] [PowerPC] frontend get target feature from backend with cp

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

2025-06-18 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,63 @@ + +Query Based Custom Clang-Tidy Checks + + +Introduction + + +This page provides examples of how to add query based custom checks for +:program:`clang-tidy`. + +Custom checks are

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

2025-06-18 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,63 @@ + +Query Based Custom Clang-Tidy Checks + + +Introduction + + +This page provides examples of how to add query based custom checks for +:program:`clang-tidy`. + +Custom checks are

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

2025-06-18 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor 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-tools-extra] [clang-tidy] support query based custom check (PR #131804)

2025-06-18 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor commented: Mostly docs suggestions. I like this approach with config file, but don't have a strong opinion for now, so LGTM without explicit approval. https://github.com/llvm/llvm-project/pull/131804 ___ cfe-commits mailing

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

2025-06-18 Thread Baranov Victor via cfe-commits
@@ -292,6 +293,8 @@ An overview of all the command-line options: Checks - Same as '--checks'. Additionally, the list of globs can be specified as a list instead of a string. +C

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

2025-06-18 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,63 @@ + +Query Based Custom Clang-Tidy Checks + + +Introduction + + +This page provides examples of how to add query based custom checks for +:program:`clang-tidy`. + +Custom checks are

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

2025-06-18 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,146 @@ +//===--- QueryCheck.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] support query based custom check (PR #131804)

2025-06-18 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,63 @@ + +Query Based Custom Clang-Tidy Checks + + +Introduction + + +This page provides examples of how to add query based custom checks for +:program:`clang-tidy`. + +Custom checks are

[compiler-rt] [libcxxabi] [libunwind] [runtimes][PAC] Harden unwinding when possible (#138571) (PR #143230)

2025-06-18 Thread Daniil Kovalev via cfe-commits
@@ -83,7 +83,13 @@ __llvm_profile_iterate_data(const __llvm_profile_data *Data) { /* This method is only used in value profiler mock testing. */ COMPILER_RT_VISIBILITY void * __llvm_get_function_addr(const __llvm_profile_data *Data) { - return Data->FunctionPointer; + void

[clang] Add missing intrinsics to cuda headers (PR #143664)

2025-06-18 Thread via cfe-commits
vitor1001 wrote: > It appears to be breaking CUDA tests: > https://lab.llvm.org/buildbot/#/builders/69/builds/22559 Strange. Do you have any ideas why `decltype` is not working? https://github.com/llvm/llvm-project/pull/143664 ___ cfe-commits mailin

[clang] [CIR] Implement folder for VecSplatOp (PR #143771)

2025-06-18 Thread Amr Hesham via cfe-commits
@@ -142,7 +142,8 @@ void CIRCanonicalizePass::runOnOperation() { // Many operations are here to perform a manual `fold` in // applyOpPatternsGreedily. if (isa(op)) +VecExtractOp, VecShuffleOp, VecShuffleDynamicOp, VecSplatOp, +VecTernaryOp>(o

[clang] Revert "[HLSL][SPIRV] Add vk::constant_id attribute." (PR #144812)

2025-06-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Steven Perron (s-perron) Changes Reverts llvm/llvm-project#143544 --- Patch is 38.46 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/144812.diff 15 Files Affected: - (modified) clang/include/

[clang] Revert "[HLSL][SPIRV] Add vk::constant_id attribute." (PR #144812)

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

[clang] Revert "[HLSL][SPIRV] Add vk::constant_id attribute." (PR #144812)

2025-06-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: Steven Perron (s-perron) Changes Reverts llvm/llvm-project#143544 --- Patch is 38.46 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/144812.diff 15 Files Affected: - (modified) clang/

[clang] [llvm] [HLSL][RootSignature] Add `hlsl-rootsig-ver` option to specify root signature version (PR #144813)

2025-06-18 Thread Finn Plummer via cfe-commits
https://github.com/inbelic created https://github.com/llvm/llvm-project/pull/144813 This pr provides the ability to specify the root signature version as a compiler option and to retain this in the root signature decl. It also updates the methods to serialize the version when dumping the decl

[clang] [llvm] [HLSL][RootSignature] Add `hlsl-rootsig-ver` option to specify root signature version (PR #144813)

2025-06-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-llvm-support @llvm/pr-subscribers-clang-codegen Author: Finn Plummer (inbelic) Changes This pr provides the ability to specify the root signature version as a compiler option and to retain this in the root signature decl. It also updates the methods to

[clang] [llvm] [HLSL][RootSignature] Add `hlsl-rootsig-ver` option to specify root signature version (PR #144813)

2025-06-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-directx Author: Finn Plummer (inbelic) Changes This pr provides the ability to specify the root signature version as a compiler option and to retain this in the root signature decl. It also updates the methods to serialize the version when dump

[clang] Revert "[HLSL][SPIRV] Add vk::constant_id attribute." (PR #144812)

2025-06-18 Thread Steven Perron via cfe-commits
https://github.com/s-perron created https://github.com/llvm/llvm-project/pull/144812 Reverts llvm/llvm-project#143544 >From 9d775256000726929f826ec164aa514d4a6e2288 Mon Sep 17 00:00:00 2001 From: Steven Perron Date: Wed, 18 Jun 2025 19:30:17 -0400 Subject: [PATCH] Revert "[HLSL][SPIRV] Add vk:

[clang] 5f69d68 - Revert "[HLSL][SPIRV] Add vk::constant_id attribute." (#144812)

2025-06-18 Thread via cfe-commits
Author: Steven Perron Date: 2025-06-18T19:30:43-04:00 New Revision: 5f69d680e2cc94dcb30a7f29e8144725530a6da4 URL: https://github.com/llvm/llvm-project/commit/5f69d680e2cc94dcb30a7f29e8144725530a6da4 DIFF: https://github.com/llvm/llvm-project/commit/5f69d680e2cc94dcb30a7f29e8144725530a6da4.diff

[clang] [AArch64] Add option -msve-streaming-vector-bits= . (PR #144611)

2025-06-18 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic updated https://github.com/llvm/llvm-project/pull/144611 >From c28804a471a9fe6be24479ffbfd7d4aa6c774125 Mon Sep 17 00:00:00 2001 From: Eli Friedman Date: Tue, 17 Jun 2025 11:48:47 -0700 Subject: [PATCH 1/2] [AArch64] Add option -msve-streaming-vector-bits= . Th

[clang] [AArch64] Add option -msve-streaming-vector-bits= . (PR #144611)

2025-06-18 Thread Eli Friedman via cfe-commits
efriedma-quic wrote: Pushed revised patch which correctly handles streaming-compatible functions (the previous version accidentally treated them as non-streaming). https://github.com/llvm/llvm-project/pull/144611 ___ cfe-commits mailing list cfe-commi

[clang] [lld] Use the Windows SDK arguments over the environment (PR #144805)

2025-06-18 Thread Fabrice de Gans via cfe-commits
@@ -110,19 +114,15 @@ void visualstudio::Linker::ConstructJob(Compilation &C, const JobAction &JA, llvm::archToLegacyVCArch(TC.getArch())); CmdArgs.push_back(Args.MakeArgString(Twine("-libpath:") + DIAPath)); } - if (!llvm::sys::Process::GetE

[clang] [HIP] Emit the CUID value in the module with the new driver (PR #144570)

2025-06-18 Thread Matt Arsenault via cfe-commits
arsenm wrote: > `llvm.compiler.used` global uses AS(0) which makes SPIR-V unhappy, but with > this global it's AS(4) which makes it happy. Either way, this should be fixed. llvm.used and llvm.compiler.used should universally use addrspace(0) and SPIRV should be fixed to not break on this

[clang] HIPSPV: Unbundle SDL (PR #136412)

2025-06-18 Thread Paulius Velesko via cfe-commits
https://github.com/pvelesko updated https://github.com/llvm/llvm-project/pull/136412 >From fe6a426fc135c7232650b5ebac465ceaa66d7a20 Mon Sep 17 00:00:00 2001 From: Paulius Velesko Date: Sat, 19 Apr 2025 10:02:59 +0300 Subject: [PATCH 1/4] HIPSPV: Unbundle SDL This fixes the issue of rdc linking

[clang] HIPSPV: Unbundle SDL (PR #136412)

2025-06-18 Thread Paulius Velesko via cfe-commits
https://github.com/pvelesko updated https://github.com/llvm/llvm-project/pull/136412 >From fe6a426fc135c7232650b5ebac465ceaa66d7a20 Mon Sep 17 00:00:00 2001 From: Paulius Velesko Date: Sat, 19 Apr 2025 10:02:59 +0300 Subject: [PATCH 1/4] HIPSPV: Unbundle SDL This fixes the issue of rdc linking

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-06-18 Thread via cfe-commits
@@ -2660,6 +2644,133 @@ void X86AsmPrinter::emitCallInstruction(const llvm::MCInst &MCI) { OutStreamer->emitInstruction(MCI, getSubtargetInfo()); } +// Checks whether a NOP is required after a CALL and inserts the NOP, if +// necessary. +void X86AsmPrinter::emitNopAfterCall

[clang] 2bcdfa1 - [CIR] Add side effect attribute to call operations (#144201)

2025-06-18 Thread via cfe-commits
Author: Sirui Mu Date: 2025-06-19T09:58:19+08:00 New Revision: 2bcdfa198aa511479c46144c5cf95c7c685384ef URL: https://github.com/llvm/llvm-project/commit/2bcdfa198aa511479c46144c5cf95c7c685384ef DIFF: https://github.com/llvm/llvm-project/commit/2bcdfa198aa511479c46144c5cf95c7c685384ef.diff LOG:

[clang] [CIR] Add side effect attribute to call operations (PR #144201)

2025-06-18 Thread Sirui Mu via cfe-commits
https://github.com/Lancern closed https://github.com/llvm/llvm-project/pull/144201 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix crash when doing special member lookup on forward-declared classes (PR #144828)

2025-06-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Ameya Gurjar (Ameya674) Changes The compiler tends to crash when encountering a forward-declared incomplete type in Sema::LookupSpecialMember. Fixed this by adding a check to handle the incomplete types. The patch compiles and clang tri

<    1   2   3   4   >