[clang] [analyzer] `SValBuilder::evalBinOpLN`: try simplifying the RHS first (PR #161537)

2025-10-01 Thread Balazs Benics via cfe-commits
@@ -,6 +,12 @@ SVal SimpleSValBuilder::evalBinOpLN(ProgramStateRef state, assert(!BinaryOperator::isComparisonOp(op) && "arguments to comparison ops must be of the same type"); + // Constraints may have changed since the creation of a bound SVal. Check if

[clang] [alpha.webkit.RetainPtrCtorAdoptChecker] Don't treat assignment to an +1 out argument as a leak (PR #161633)

2025-10-01 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 @llvm/pr-subscribers-clang Author: Ryosuke Niwa (rniwa) Changes Make RetainPtrCtorAdoptChecker recognize an assignment to an +1 out argument so that it won't emit a memory leak warning. --- Full diff: https://github.com/llvm/llv

[clang] [clang] VectorExprEvaluator::VisitCallExpr - add constant folding for X86 pslldqi/psrldqi intrinsics (PR #157403)

2025-10-01 Thread Simon Pilgrim via cfe-commits
@@ -267,7 +267,8 @@ let Header = "emmintrin.h", Attributes = [NoThrow, RequireDeclaration] in { def _mm_pause : X86LibBuiltin<"void()">; } -let Features = "sse2", Attributes = [NoThrow, Const, RequiredVectorWidth<128>] in { +let Features = "sse2", +Attributes = [NoThro

[clang] [CIR] Make all opt tests verify roundtrip (PR #161439)

2025-10-01 Thread Henrich Lauko via cfe-commits
https://github.com/xlauko updated https://github.com/llvm/llvm-project/pull/161439 >From aa7063a9cc0007bee9d11ddc132c6b9ca2b3e750 Mon Sep 17 00:00:00 2001 From: xlauko Date: Tue, 30 Sep 2025 22:38:21 +0200 Subject: [PATCH] [CIR] Make all opt tests verify roundtrip This mirrors incubator change

[clang] [llvm] [DirectX] Updating Root Signature Metadata to contain Static Sampler flags (PR #160210)

2025-10-01 Thread Justin Bogner via cfe-commits
@@ -501,6 +502,17 @@ Error MetadataParser::parseStaticSampler(mcdxbc::RootSignatureDesc &RSD, return Error(std::move(E)); Sampler.ShaderVisibility = *Visibility; + if (RSD.Version < 3) { +RSD.StaticSamplers.push_back(Sampler); +return Error::success(); + } +

[clang-tools-extra] [clang-tidy] Add new check: `readability-redundant-typename` (PR #161574)

2025-10-01 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor edited https://github.com/llvm/llvm-project/pull/161574 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR][NFC] Update existing atomic ops to match assembly conventions (PR #161543)

2025-10-01 Thread Sirui Mu via cfe-commits
@@ -4224,12 +4226,8 @@ def CIR_AtomicCmpXchg : CIR_Op<"atomic.cmpxchg", [ Example: ```mlir -%old, %success = cir.atomic.cmpxchg(%ptr : !cir.ptr, -%expected : !u64i, -%desired : !u64i, -

[clang] [CIR][NFC] Update existing atomic ops to match assembly conventions (PR #161543)

2025-10-01 Thread Sirui Mu via cfe-commits
https://github.com/Lancern updated https://github.com/llvm/llvm-project/pull/161543 >From fbd90aba0ab0d4fe56480c07ab006d755b5e6a8c Mon Sep 17 00:00:00 2001 From: Sirui Mu Date: Thu, 2 Oct 2025 00:00:36 +0800 Subject: [PATCH] [CIR][NFC] Update existing atomic ops to match assembly conventions

[clang] [CIR][NFC] Update existing atomic ops to match assembly conventions (PR #161543)

2025-10-01 Thread Sirui Mu via cfe-commits
@@ -4224,12 +4226,8 @@ def CIR_AtomicCmpXchg : CIR_Op<"atomic.cmpxchg", [ Example: ```mlir -%old, %success = cir.atomic.cmpxchg(%ptr : !cir.ptr, -%expected : !u64i, -%desired : !u64i, -

[clang] [CIR] Atomic fetch operation (PR #161631)

2025-10-01 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-clangir Author: Sirui Mu (Lancern) Changes This patch adds CIR support for atomic fetch-and-update operations, including the intrinsic functions `__atomic_fetch_`, `__atomic__fetch`, and `__c11_atomic_fetch_

[clang] [CIR] Atomic fetch operation (PR #161631)

2025-10-01 Thread Sirui Mu via cfe-commits
https://github.com/Lancern created https://github.com/llvm/llvm-project/pull/161631 This patch adds CIR support for atomic fetch-and-update operations, including the intrinsic functions `__atomic_fetch_`, `__atomic__fetch`, and `__c11_atomic_fetch_`, where `` could be `add`, `sub`, `max`, `mi

[clang] [OpenACC][CIR] Finish 'private' recipe lowering by doing 'init' (PR #161540)

2025-10-01 Thread Andy Kaylor via cfe-commits
@@ -66,47 +66,134 @@ struct HasDtor { // CHECK-NEXT: acc.private.recipe @privatization__Bcnt1__ZTSA5_i : !cir.ptr> init { // CHECK-NEXT: ^bb0(%[[ARG:.*]]: !cir.ptr> {{.*}}, %[[BOUND1:.*]]: !acc.data_bounds_ty {{.*}}): // CHECK-NEXT: %[[ALLOCA:.*]] = cir.alloca !cir.array, !c

[clang] [llvm] [mlir] fix(security): Address CodeQL Uncontrolled Data in Path Expression vulnerability (PR #160531)

2025-10-01 Thread MUSTAPHA BARKI via cfe-commits
https://github.com/aka76bm updated https://github.com/llvm/llvm-project/pull/160531 >From e28b543df69358dddef60dca110353227bced70f Mon Sep 17 00:00:00 2001 From: MUSTAPHA BARKI Date: Tue, 23 Sep 2025 02:52:03 +0100 Subject: [PATCH 01/10] [clang][AST] Add comment clarifying GNU inline visibilit

[clang-tools-extra] [clang-tidy] Add new check: `readability-redundant-typename` (PR #161574)

2025-10-01 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,71 @@ +//===--===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apac

[clang] [HLSL] [SPIR-V] Add counter member for typed buffer (PR #161414)

2025-10-01 Thread Helena Kotas via cfe-commits
@@ -863,12 +979,17 @@ BuiltinTypeDeclBuilder &BuiltinTypeDeclBuilder::addCopyAssignmentOperator() { using PH = BuiltinTypeMethodBuilder::PlaceHolder; DeclarationName Name = AST.DeclarationNames.getCXXOperatorName(OO_Equal); - return BuiltinTypeMethodBuilder(*this, Name,

[clang] 39410df - [clang] Invert condition refactored in #160935 (#161583)

2025-10-01 Thread via cfe-commits
Author: Jan Svoboda Date: 2025-10-01T14:34:02-07:00 New Revision: 39410dff52d813ccfc7efc6fc0c6afd4583e14a6 URL: https://github.com/llvm/llvm-project/commit/39410dff52d813ccfc7efc6fc0c6afd4583e14a6 DIFF: https://github.com/llvm/llvm-project/commit/39410dff52d813ccfc7efc6fc0c6afd4583e14a6.diff L

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

2025-10-01 Thread Oliver Hunt via cfe-commits
ojhunt wrote: > @ojhunt Thanks for an update! I've resolved several threads, but some things > should still be fixed. > > Please let me know if you have any comments/questions or any help is needed > from my side. > > ### Trivial style-related issues > These require almost zero effort to appl

[clang] [AST] Give `CharUnits::operator%` a consistent type. NFC (PR #160781)

2025-10-01 Thread Justin Bogner via cfe-commits
https://github.com/bogner auto_merge_enabled https://github.com/llvm/llvm-project/pull/160781 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Add new check: `readability-redundant-typename` (PR #161574)

2025-10-01 Thread Victor Chernyakin via cfe-commits
https://github.com/localspook updated https://github.com/llvm/llvm-project/pull/161574 >From 82c842a3e8f0f2e9dcfacca0eada9f6aeacd38d8 Mon Sep 17 00:00:00 2001 From: Victor Chernyakin Date: Wed, 1 Oct 2025 18:35:35 + Subject: [PATCH 1/7] [clang-tidy] Add new check: `readability-redundant-ty

[clang] [llvm] [HLSL] Update Frontend to support version 1.2 of root signature (PR #160616)

2025-10-01 Thread via cfe-commits
https://github.com/joaosaffran updated https://github.com/llvm/llvm-project/pull/160616 >From 787c77638092b06e7648f03660a4429dc602aac6 Mon Sep 17 00:00:00 2001 From: Joao Saffran Date: Thu, 18 Sep 2025 14:16:25 -0700 Subject: [PATCH 01/23] adding yaml representation and updating write logic --

[clang] [Clang][NFC] Refactor operator delete argument handling (PR #160554)

2025-10-01 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor updated https://github.com/llvm/llvm-project/pull/160554 >From ade6f590cac752c996b3c765c84a86a9867185c6 Mon Sep 17 00:00:00 2001 From: Andy Kaylor Date: Tue, 23 Sep 2025 17:09:29 -0700 Subject: [PATCH 1/3] [Clang][NFC] Refactor operator delete argument handling Th

[clang] Thread Safety Analysis: Optimize LocalVariableMap's canonical reference computation (PR #161600)

2025-10-01 Thread Marco Elver via cfe-commits
https://github.com/melver created https://github.com/llvm/llvm-project/pull/161600 We observed slowdowns in auto-generated million+ line C++ source files due to recent fixes to LocalVariableMap. Rather than recompute the canonical underlying non-reference VarDefinition every time we need to pe

[clang] [Sema] Don't call isNonConstantStorage on incomplete variable types (PR #161590)

2025-10-01 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Akira Hatanaka (ahatanak) Changes The code that applies section attributes to global variables was crashing when it encountered a variable whose type was incomplete. This change adds a check to ensure the variable's type is complete befor

[clang] 780f69c - [Clang][CMake] Add CSSPGO support to LLVM_BUILD_INSTRUMENTED (#79942)

2025-10-01 Thread via cfe-commits
Author: Amir Ayupov Date: 2025-10-01T15:25:34-07:00 New Revision: 780f69cd922d8925648e11e771e77f0b46190e5b URL: https://github.com/llvm/llvm-project/commit/780f69cd922d8925648e11e771e77f0b46190e5b DIFF: https://github.com/llvm/llvm-project/commit/780f69cd922d8925648e11e771e77f0b46190e5b.diff L

[clang] [-Wunsafe-buffer-usage] Add unique_ptr accesses (PR #156773)

2025-10-01 Thread via cfe-commits
https://github.com/shreya-jain updated https://github.com/llvm/llvm-project/pull/156773 >From 927b2f61b8f5e0163c065ee4cbbf7ebb6956c34b Mon Sep 17 00:00:00 2001 From: shreya-jain Date: Wed, 3 Sep 2025 00:36:02 -0700 Subject: [PATCH 01/13] Update UnsafeBufferUsage.h --- clang/include/clang/Anal

[clang] [clang-format][NFC] Introduce isNoneOf (PR #161021)

2025-10-01 Thread Björn Schäpers via cfe-commits
https://github.com/HazardyKnusperkeks edited https://github.com/llvm/llvm-project/pull/161021 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream `AddressSpace` support for `PointerType` (PR #161028)

2025-10-01 Thread Andy Kaylor via cfe-commits
@@ -73,13 +74,17 @@ struct CIRGenTypeCache { /// The alignment of size_t. unsigned char SizeAlignInBytes; + LangAS ASTAllocaAddressSpace; andykaylor wrote: ```suggestion cir::TargetAddressSpaceAttr cirAllocaAddressSpace; ``` We can change the type of t

[clang-tools-extra] [clang-tidy][NFC] Do less unnecessary work in `modernize-deprecated-headers` (PR #160967)

2025-10-01 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank approved this pull request. https://github.com/llvm/llvm-project/pull/160967 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream `AddressSpace` support for `PointerType` (PR #161028)

2025-10-01 Thread Fabian Mora via cfe-commits
@@ -297,6 +317,20 @@ bool RecordType::isLayoutIdentical(const RecordType &other) { // Data Layout information for types //===--===// +llvm::TypeSize +PointerType::getTypeSizeInBits(const ::mlir::DataLayout &

[clang-tools-extra] [clang-tidy][NFC] Do less unnecessary work in `modernize-deprecated-headers` (PR #160967)

2025-10-01 Thread Nicolas van Kempen via cfe-commits
@@ -131,48 +131,38 @@ void DeprecatedHeadersCheck::check( } IncludeModernizePPCallbacks::IncludeModernizePPCallbacks( -std::vector &IncludesToBeProcessed, LangOptions LangOpts, -const SourceManager &SM, bool CheckHeaderFile) -: IncludesToBeProcessed(IncludesToBePro

[clang-tools-extra] [clang-tidy][NFC] Do less unnecessary work in `modernize-deprecated-headers` (PR #160967)

2025-10-01 Thread Nicolas van Kempen via cfe-commits
@@ -131,48 +131,38 @@ void DeprecatedHeadersCheck::check( } IncludeModernizePPCallbacks::IncludeModernizePPCallbacks( -std::vector &IncludesToBeProcessed, LangOptions LangOpts, -const SourceManager &SM, bool CheckHeaderFile) -: IncludesToBeProcessed(IncludesToBePro

[clang] [clang-tools-extra] [llvm] [llvm][support] Move `make_absolute` from `sys::fs` to `sys::path` (PR #161459)

2025-10-01 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `mlir-nvidia-gcc7` running on `mlir-nvidia` while building `bolt,clang-tools-extra,clang,llvm` at step 7 "test-build-check-mlir-build-only-check-mlir". Full details are available at: https://lab.llvm.org/buildbot/#/builders/11

[clang] [clang] Invert condition refactored in #160935 (PR #161583)

2025-10-01 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 created https://github.com/llvm/llvm-project/pull/161583 The PR #160935 incorrectly replaced `llvm::sys::fs::getUniqueID()` with `llvm::vfs::FileSystem::exists()` in a condition. That's incorrect, since the first function returns `std::error_code` that evaluates

[clang] [clang][modules-driver] Add dependency scan and dependency graph (PR #152770)

2025-10-01 Thread Michael Spencer via cfe-commits
https://github.com/Bigcheese edited https://github.com/llvm/llvm-project/pull/152770 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL][TEST] Fix root signature driver test on WSL (PR #161566)

2025-10-01 Thread Justin Bogner via cfe-commits
https://github.com/bogner requested changes to this pull request. Why is the extension different under WSL? This change might be reasonable, but I find that difference quite surprising and wonder if this is masking another bug. Can we look into the answer to that before making this change pleas

[clang-tools-extra] [clang-tidy] Add new check: `readability-redundant-typename` (PR #161574)

2025-10-01 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,71 @@ +//===--===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apac

[clang] [clang-tools-extra] [clang-tidy] Add new check: `readability-redundant-typename` (PR #161574)

2025-10-01 Thread Victor Chernyakin via cfe-commits
https://github.com/localspook updated https://github.com/llvm/llvm-project/pull/161574 >From 82c842a3e8f0f2e9dcfacca0eada9f6aeacd38d8 Mon Sep 17 00:00:00 2001 From: Victor Chernyakin Date: Wed, 1 Oct 2025 18:35:35 + Subject: [PATCH 01/10] [clang-tidy] Add new check: `readability-redundant-

[clang] [llvm] [Clang][CMake] Add CSSPGO support to LLVM_BUILD_INSTRUMENTED (PR #79942)

2025-10-01 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-aarch64-quick` running on `linaro-clang-aarch64-quick` while building `clang,llvm` at step 5 "ninja check 1". Full details are available at: https://lab.llvm.org/buildbot/#/builders/65/builds/23417 Here is the relevan

[clang] [clang] Invert condition refactored in #160935 (PR #161583)

2025-10-01 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 closed https://github.com/llvm/llvm-project/pull/161583 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR][NFC] Fix CIR build (PR #161577)

2025-10-01 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor closed https://github.com/llvm/llvm-project/pull/161577 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Don't call isNonConstantStorage on incomplete variable types (PR #161590)

2025-10-01 Thread Eli Friedman via cfe-commits
@@ -14918,52 +14918,57 @@ void Sema::CheckCompleteVariableDeclaration(VarDecl *var) { } // Apply section attributes and pragmas to global variables. - if (GlobalStorage && var->isThisDeclarationADefinition() && - !inTemplateInstantiation()) { -PragmaStack *Stack

[clang] [llvm] [DirectX] Fix Flags validation to prevent casting into enum (PR #161587)

2025-10-01 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-directx Author: None (joaosaffran) Changes This PR changes the validation logic for Root Descriptor and Descriptor Range flags to properly check if the `uint32_t` values are within range before casting into the enums. --- Full diff: https://g

[clang] [Clang][Sema] Switch diagnostics from toString to operator<< for APSInt/APInt (PR #161474)

2025-10-01 Thread Samarth Narang via cfe-commits
https://github.com/snarang181 closed https://github.com/llvm/llvm-project/pull/161474 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [DirectX] Fix Flags validation to prevent casting into enum (PR #161587)

2025-10-01 Thread via cfe-commits
https://github.com/joaosaffran created https://github.com/llvm/llvm-project/pull/161587 This PR changes the validation logic for Root Descriptor and Descriptor Range flags to properly check if the `uint32_t` values are within range before casting into the enums. >From 82832bc1604b6677f25d96a

[clang] [CIR] Upstream `AddressSpace` support for `PointerType` (PR #161028)

2025-10-01 Thread Andy Kaylor via cfe-commits
@@ -0,0 +1,30 @@ +// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -fclangir -emit-cir %s -o %t.cir +// RUN: FileCheck --input-file=%t.cir %s -check-prefix=CIR +// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -fclangir -emit-llvm %s -o %t.ll +// RUN: FileCheck --input-fil

[clang] [CIR] Upstream `AddressSpace` support for `PointerType` (PR #161028)

2025-10-01 Thread Andy Kaylor via cfe-commits
@@ -766,30 +802,47 @@ mlir::LogicalResult cir::VectorType::verify( } //===--===// -// PointerType Definitions +// TargetAddressSpace definitions //===

[clang] [CIR] Upstream `AddressSpace` support for `PointerType` (PR #161028)

2025-10-01 Thread Andy Kaylor via cfe-commits
@@ -2052,8 +2052,8 @@ mlir::Value CIRGenFunction::emitAlloca(StringRef name, mlir::Type ty, // CIR uses its own alloca address space rather than follow the target data // layout like original CodeGen. The data layout awareness should be done in // the lowering pass inste

[clang] [clang][Dependency Scanning] Refactor Scanning Compiler Instance Initialization (PR #161300)

2025-10-01 Thread Qiongsi Wu via cfe-commits
@@ -453,8 +583,18 @@ bool DependencyScanningAction::runInvocation( ScanInstance.getPreprocessorOpts().ImplicitPCHInclude, ScanInstance, ScanInstance.getHeaderSearchOpts().PrebuiltModuleFiles, PrebuiltModulesASTMap, ScanInstance.getDiagnostic

[clang] [clang-repl] Teach clang-repl how to load PCHs (reprise) (PR #157359)

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

[clang] [HLSL] Add support for elementwise and aggregate splat casting struct types with bitfields (PR #161263)

2025-10-01 Thread Sarah Spall via cfe-commits
https://github.com/spall created https://github.com/llvm/llvm-project/pull/161263 Adds support for elementwise and aggregate splat casting struct types with bitfields. Replacing existing Flattening function which used to produce a list of GEPs representing a flattened object with one that prod

[clang] [clang] VectorExprEvaluator::VisitCallExpr - add constant folding for X86 pslldqi/psrldqi intrinsics (PR #157403)

2025-10-01 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon updated https://github.com/llvm/llvm-project/pull/157403 >From 38b90ecc3dc30668860cc80a6c8f075536764b5e Mon Sep 17 00:00:00 2001 From: kimyounhoex1 Date: Thu, 4 Sep 2025 00:55:24 +0900 Subject: [PATCH 01/22] todo list --- clang/lib/AST/ExprConstant.cpp | 4 1 f

[clang] [llvm] Make sanitizer special case list slash-agnostic (PR #149886)

2025-10-01 Thread Vitaly Buka via cfe-commits
vitalybuka wrote: There is GlobPatternTest,cpp which should be extended. https://github.com/llvm/llvm-project/pull/149886 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [alpha.webkit.RetainPtrCtorAdoptChecker] Allow leakRef in copy methods (PR #160986)

2025-10-01 Thread Rashmi Mudduluru via cfe-commits
https://github.com/t-rasmud approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/160986 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 9ba1121 - [RISCV] Remove break after return in RISCVVEmitter.cpp. NFC (#161599)

2025-10-01 Thread via cfe-commits
Author: Craig Topper Date: 2025-10-01T16:07:26-07:00 New Revision: 9ba1121e3c200bd7935ced3f33d161a0f488609b URL: https://github.com/llvm/llvm-project/commit/9ba1121e3c200bd7935ced3f33d161a0f488609b DIFF: https://github.com/llvm/llvm-project/commit/9ba1121e3c200bd7935ced3f33d161a0f488609b.diff

[clang] [clang][Dependency Scanning] Refactor Scanning Compiler Instance Initialization (PR #161300)

2025-10-01 Thread Jan Svoboda via cfe-commits
@@ -72,9 +74,77 @@ class DependencyScanningAction { bool DiagConsumerFinished = false; }; -// Helper functions -void sanitizeDiagOpts(DiagnosticOptions &DiagOpts); +// Helper functions and data types. +std::unique_ptr +createDiagOptions(const std::vector &CommandLine); +st

[clang] [llvm] [mlir] Enforce Unix line endings for Clang/LLVM/MLIR projects (PR #161460)

2025-10-01 Thread Rahul Joshi via cfe-commits
jurahul wrote: Thanks for confirming that Windows side is fine. I assume clang-format run only on C/C++ source files, so other files like .bat or .py should be unaffected by this change. Additionally, in my test PR https://github.com/llvm/llvm-project/pull/161257 I had modified a .cpp file un

[clang] [X86] Mark AVX-512 intrinsics constexpr (Fixes #160556) (PR #161544)

2025-10-01 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] [clang-sycl-linker][NFC] Remove dead includes (PR #161564)

2025-10-01 Thread Alexey Bader via cfe-commits
https://github.com/bader created https://github.com/llvm/llvm-project/pull/161564 These includes are not used by ClangSYCLLinker.cpp directly. >From 1d76d92ae8b358466815479f25ffbed5d18fe385 Mon Sep 17 00:00:00 2001 From: Alexey Bader Date: Wed, 1 Oct 2025 11:15:27 -0700 Subject: [PATCH] [clang

[clang] [clang-format] Add SpaceBeforeUnderscoreParens option for GNU gettext… (PR #159925)

2025-10-01 Thread Simon Marchi via cfe-commits
simark wrote: Here's an idea for an oddly-specific setting, but less oddly-specific than the proposed one: a setting that is a list of identifiers that are exceptions to the "space before parenthesis" rule, which we'd use like: SpaceBeforeIdentifierExceptions: - "_" This has the adv

[clang] [ObjC][Preprocessor] Handle @import directive as a pp-directive (PR #157726)

2025-10-01 Thread Michael Spencer via cfe-commits
@@ -947,6 +940,10 @@ bool Scanner::lexPPLine(const char *&First, const char *const End) { auto ScEx2 = make_scope_exit( [&]() { TheLexer.setParsingPreprocessorDirective(false); }); + // FIXME: Shoule we handle @import as a preprocessing directive? Bi

[clang] [C23] Implement WG14 N3037 (PR #132939)

2025-10-01 Thread Cyndy Ishida via cfe-commits
https://github.com/cyndyishida edited https://github.com/llvm/llvm-project/pull/132939 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] [SPIR-V] Add counter member for typed buffer (PR #161414)

2025-10-01 Thread Helena Kotas via cfe-commits
https://github.com/hekota edited https://github.com/llvm/llvm-project/pull/161414 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang-tidy] Add new check: `readability-redundant-typename` (PR #161574)

2025-10-01 Thread Victor Chernyakin via cfe-commits
https://github.com/localspook edited https://github.com/llvm/llvm-project/pull/161574 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR][NFC] Cleanup MissingFeature asserts in RecordLayoutBuilder (PR #161605)

2025-10-01 Thread via cfe-commits
@@ -296,9 +296,8 @@ void CIRRecordLowering::lower(bool nonVirtualBaseType) { } llvm::stable_sort(members); - // TODO: implement clipTailPadding once bitfields are implemented - assert(!cir::MissingFeatures::bitfields()); - assert(!cir::MissingFeatures::recordZeroInit())

[clang] [CIR][NFC] Cleanup MissingFeature asserts in RecordLayoutBuilder (PR #161605)

2025-10-01 Thread via cfe-commits
https://github.com/Andres-Salamanca approved this pull request. https://github.com/llvm/llvm-project/pull/161605 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [LLVM] Add GNU make jobserver support (PR #145131)

2025-10-01 Thread Yaxun Liu via cfe-commits
@@ -119,7 +130,24 @@ class ThreadPoolExecutor : public Executor { auto Task = std::move(WorkStack.back()); WorkStack.pop_back(); Lock.unlock(); - Task(); + + if (TheJobserver) { +JobSlot Slot = TheJobserver->tryAcquire(); +if (Slot.is

[clang] a2330a3 - [Clang][Sema] Switch diagnostics from toString to operator<< for APSInt/APInt (#161474)

2025-10-01 Thread via cfe-commits
Author: Samarth Narang Date: 2025-10-02T07:59:52+05:30 New Revision: a2330a398db398e33687a6bed71092a85312e481 URL: https://github.com/llvm/llvm-project/commit/a2330a398db398e33687a6bed71092a85312e481 DIFF: https://github.com/llvm/llvm-project/commit/a2330a398db398e33687a6bed71092a85312e481.diff

[clang] [llvm] [DirectX] Updating Root Signature Metadata to contain Static Sampler flags (PR #160210)

2025-10-01 Thread via cfe-commits
@@ -501,6 +502,17 @@ Error MetadataParser::parseStaticSampler(mcdxbc::RootSignatureDesc &RSD, return Error(std::move(E)); Sampler.ShaderVisibility = *Visibility; + if (RSD.Version < 3) { +RSD.StaticSamplers.push_back(Sampler); +return Error::success(); + } +

[clang] [clang-tools-extra] [clang-tidy] Add new check: `readability-redundant-typename` (PR #161574)

2025-10-01 Thread Victor Chernyakin via cfe-commits
@@ -0,0 +1,68 @@ +//===--===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apac

[clang] [clang-sycl-linker][NFC] Remove dead includes (PR #161564)

2025-10-01 Thread Alexey Bader via cfe-commits
https://github.com/bader updated https://github.com/llvm/llvm-project/pull/161564 >From 1d76d92ae8b358466815479f25ffbed5d18fe385 Mon Sep 17 00:00:00 2001 From: Alexey Bader Date: Wed, 1 Oct 2025 11:15:27 -0700 Subject: [PATCH 1/2] [clang-sycl-linker][NFC] Remove dead includes These includes ar

[clang] [llvm] [LLVM] Add GNU make jobserver support (PR #145131)

2025-10-01 Thread Yaxun Liu via cfe-commits
yxsamliu wrote: > Sorry that I haven't commented earlier but I have only just got around to > looking at this in more detail. Although, the parallel functions for > `Parallel.cpp` already "batch", I would still be a bit concerned about the > overhead for obtaining the job slot. Perhaps like in

[clang] [CIR] Initial support for emitting coroutine body (PR #161616)

2025-10-01 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (Andres-Salamanca) Changes This PR adds new `FuncOp` attributes (`coroutine` and `builtin`) and begins the implementation of the `emitCoroutineBody` function. Feature markers were also added for guidance in future PRs. --- Full diff

[clang] [CIR] Initial support for emitting coroutine body (PR #161616)

2025-10-01 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clangir Author: None (Andres-Salamanca) Changes This PR adds new `FuncOp` attributes (`coroutine` and `builtin`) and begins the implementation of the `emitCoroutineBody` function. Feature markers were also added for guidance in future PRs. --- Full di

[clang] [CIR] Initial support for emitting coroutine body (PR #161616)

2025-10-01 Thread via cfe-commits
https://github.com/Andres-Salamanca created https://github.com/llvm/llvm-project/pull/161616 This PR adds new `FuncOp` attributes (`coroutine` and `builtin`) and begins the implementation of the `emitCoroutineBody` function. Feature markers were also added for guidance in future PRs. >From 66

[clang] [llvm] [RISCV] Support Zvfbfa codegen and C intrinsics (PR #161158)

2025-10-01 Thread Jim Lin via cfe-commits
tclin914 wrote: Could we put those intrinsics tests for Zvfbfa under seperate directory like `zvfbfmin` https://github.com/llvm/llvm-project/pull/161158 ___ cfe-commits mailing list [email protected] https:/

[clang] [clang] Convert second arg of __builtin_assume_aligned to ConstantExpr (PR #161314)

2025-10-01 Thread Alan Zhao via cfe-commits
alanzhao1 wrote: > Heads up - this PR is causing us to hit the following assertion in > https://github.com/google/highway. I'm currently running cvise to get a > minimal reproducer. The repro file is 2.5M, so cvise will take forever. This will take a while, so I apologize in advance. https:/

[clang] [Clang][Sema] Fix crash in CheckUsingDeclQualifier due to diagnostic missing an argument (PR #161277)

2025-10-01 Thread Shafik Yaghmour via cfe-commits
@@ -430,3 +434,15 @@ void ctad_test() { CTAD t = s; // expected-warning {{class template argument deduction is incompatible with C++ standards before C++17}} } #endif + +namespace GH161702 { +struct S { + enum E { A }; + using E::A; // expected-warning {{enumeration type i

[clang] [Headers][X86] Enable constexpr handling for MMX/SSE/AVX/AVX512 PMADDWD/PMADDUBSW intrinsics intrinsics (PR #161563)

2025-10-01 Thread Bhasawut Singhaphan via cfe-commits
https://github.com/markbhasawut created https://github.com/llvm/llvm-project/pull/161563 This PR updates the PMADDWD/PMADDUBSW builtins to support constant expression handling, by extending the VectorExprEvaluator::VisitCallExpr that handles interp__builtin_ia32_pmadd builtins. Closes #155392

[clang] [llvm] Make sanitizer special case list slash-agnostic (PR #149886)

2025-10-01 Thread Vitaly Buka via cfe-commits
https://github.com/vitalybuka requested changes to this pull request. I believe this patch will not handle pattern: path "clang\something" agains patter "src:clang/". Can you please extend the test? https://github.com/llvm/llvm-project/pull/149886 ___

[clang] [Clang][Headers] Fix tgmath.h incompatibility with Glibc (PR #161301)

2025-10-01 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 origin/main HEAD --extensions h -- clang/lib/Headers/tgmath.h `` :warning: T

[clang-tools-extra] [clang-tidy] Add new check: `readability-redundant-typename` (PR #161574)

2025-10-01 Thread Victor Chernyakin via cfe-commits
https://github.com/localspook updated https://github.com/llvm/llvm-project/pull/161574 >From 82c842a3e8f0f2e9dcfacca0eada9f6aeacd38d8 Mon Sep 17 00:00:00 2001 From: Victor Chernyakin Date: Wed, 1 Oct 2025 18:35:35 + Subject: [PATCH 1/8] [clang-tidy] Add new check: `readability-redundant-ty

[libunwind] [libunwind][test] Add check for objcopy to improve test compatibility (PR #161112)

2025-10-01 Thread Wu Yingcong via cfe-commits
https://github.com/yingcong-wu closed https://github.com/llvm/llvm-project/pull/161112 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libunwind] 4aaf6d1 - [libunwind][test] Add check for objcopy to improve test compatibility (#161112)

2025-10-01 Thread via cfe-commits
Author: Wu Yingcong Date: 2025-10-02T07:42:43+08:00 New Revision: 4aaf6d1b8cc655f37a1a4ab8f7a7988dbef4eeae URL: https://github.com/llvm/llvm-project/commit/4aaf6d1b8cc655f37a1a4ab8f7a7988dbef4eeae DIFF: https://github.com/llvm/llvm-project/commit/4aaf6d1b8cc655f37a1a4ab8f7a7988dbef4eeae.diff L

[clang] Thread Safety Analysis: Optimize LocalVariableMap's canonical reference computation (PR #161600)

2025-10-01 Thread Marco Elver via cfe-commits
https://github.com/melver updated https://github.com/llvm/llvm-project/pull/161600 >From bc7a52aa82c784f17bd4f1132091c9bac334766e Mon Sep 17 00:00:00 2001 From: Marco Elver Date: Thu, 2 Oct 2025 00:34:29 +0200 Subject: [PATCH] Thread Safety Analysis: Optimize LocalVariableMap's canonical refer

[clang] [Sema] Don't call isNonConstantStorage on incomplete variable types (PR #161590)

2025-10-01 Thread Akira Hatanaka via cfe-commits
@@ -14918,52 +14918,57 @@ void Sema::CheckCompleteVariableDeclaration(VarDecl *var) { } // Apply section attributes and pragmas to global variables. - if (GlobalStorage && var->isThisDeclarationADefinition() && - !inTemplateInstantiation()) { -PragmaStack *Stack

[clang] [CIR] Implement initial LoweringPrepare support for global ctors (PR #161452)

2025-10-01 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor updated https://github.com/llvm/llvm-project/pull/161452 >From bc2fc8dc65eb0eaa483ba161199c445ea16b30b5 Mon Sep 17 00:00:00 2001 From: Andy Kaylor Date: Thu, 25 Sep 2025 18:25:13 -0700 Subject: [PATCH 1/2] [CIR] Implement initial LoweringPrepare support for global

[clang] [OpenACC][CIR] Generate private recipe pointer/array 'alloca's (PR #160911)

2025-10-01 Thread Erich Keane via cfe-commits
@@ -35,6 +37,110 @@ mlir::Block *OpenACCRecipeBuilderBase::createRecipeBlock(mlir::Region ®ion, return builder.createBlock(®ion, region.end(), types, locs); } +mlir::Value OpenACCRecipeBuilderBase::makeBoundsAlloca( +mlir::Block *block, SourceRange exprRange, mlir::Loca

[clang-tools-extra] [clang-tidy] Add new check: `readability-redundant-typename` (PR #161574)

2025-10-01 Thread Victor Chernyakin via cfe-commits
https://github.com/localspook updated https://github.com/llvm/llvm-project/pull/161574 >From 82c842a3e8f0f2e9dcfacca0eada9f6aeacd38d8 Mon Sep 17 00:00:00 2001 From: Victor Chernyakin Date: Wed, 1 Oct 2025 18:35:35 + Subject: [PATCH 1/6] [clang-tidy] Add new check: `readability-redundant-ty

[clang] [clang][Dependency Scanning] Refactor Scanning Compiler Instance Initialization (PR #161300)

2025-10-01 Thread Qiongsi Wu via cfe-commits
@@ -72,9 +74,77 @@ class DependencyScanningAction { bool DiagConsumerFinished = false; }; -// Helper functions -void sanitizeDiagOpts(DiagnosticOptions &DiagOpts); +// Helper functions and data types. +std::unique_ptr +createDiagOptions(const std::vector &CommandLine); +st

[clang] [CIR][NFC] Cleanup MissingFeature asserts in RecordLayoutBuilder (PR #161605)

2025-10-01 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clangir Author: Andy Kaylor (andykaylor) Changes This change cleans up some cir::MissingFeature asserts in CIRGenRecordLayoutBuilder.cpp. In a couple of cases the asserts were stale markers that we failed to remove when the correspond support was imple

[clang] [clang][Dependency Scanning] Refactor Scanning Compiler Instance Initialization (PR #161300)

2025-10-01 Thread Qiongsi Wu via cfe-commits
@@ -72,9 +74,77 @@ class DependencyScanningAction { bool DiagConsumerFinished = false; }; -// Helper functions -void sanitizeDiagOpts(DiagnosticOptions &DiagOpts); +// Helper functions and data types. +std::unique_ptr +createDiagOptions(const std::vector &CommandLine); -

[clang] [clang][Dependency Scanning] Refactor Scanning Compiler Instance Initialization (PR #161300)

2025-10-01 Thread Qiongsi Wu via cfe-commits
@@ -434,14 +535,39 @@ bool DependencyScanningAction::runInvocation( ScanInstance.createSourceManager(*FileMgr); + // Consider different header search and diagnostic options to create + // different modules. This avoids the unsound aliasing of module PCMs. + // + // TODO

[clang] [clang] Implement __builtin_stdc_rotate_left, __builtin_stdc_rotate_right (PR #160259)

2025-10-01 Thread NagaChaitanya Vellanki via cfe-commits
https://github.com/chaitanyav updated https://github.com/llvm/llvm-project/pull/160259 >From 258cb5d1d0e189512dc62a28184a7c10e2917669 Mon Sep 17 00:00:00 2001 From: NagaChaitanya Vellanki Date: Tue, 23 Sep 2025 02:17:49 -0700 Subject: [PATCH] [clang] Implement __builtin_stdc_rotate_{left,right}

[clang] [clang][Dependency Scanning] Refactor Scanning Compiler Instance Initialization (PR #161300)

2025-10-01 Thread Qiongsi Wu via cfe-commits
https://github.com/qiongsiwu updated https://github.com/llvm/llvm-project/pull/161300 >From 554613b511baa2772e0f1871008fd124bdc48700 Mon Sep 17 00:00:00 2001 From: Qiongsi Wu Date: Mon, 29 Sep 2025 16:46:02 -0700 Subject: [PATCH 1/3] Extract dependency scanning compiler instance initialization

[clang] [llvm] [HLSL] Implement the `fwidth` intrinsic for DXIL and SPIR-V target (PR #161378)

2025-10-01 Thread Alexander Johnston via cfe-commits
https://github.com/Alexander-Johnston updated https://github.com/llvm/llvm-project/pull/161378 >From a1419718a44fa4c65324477443f218e5382ed384 Mon Sep 17 00:00:00 2001 From: Alexander Johnston Date: Mon, 29 Sep 2025 19:54:02 +0100 Subject: [PATCH] [HLSL] Implement the `fwidth` intrinsic Closes

[clang] [llvm] [HLSL] Implement the `fwidth` intrinsic for DXIL and SPIR-V target (PR #161378)

2025-10-01 Thread Alexander Johnston via cfe-commits
https://github.com/Alexander-Johnston updated https://github.com/llvm/llvm-project/pull/161378 >From 445fcb1bb4a074c3e78c019e36d7ecfbb1da0430 Mon Sep 17 00:00:00 2001 From: Alexander Johnston Date: Mon, 29 Sep 2025 19:54:02 +0100 Subject: [PATCH] [HLSL] Implement the `fwidth` intrinsic Closes

[clang] [RISCV] Remove break after return in RISCVVEmitter.cpp. NFC (PR #161599)

2025-10-01 Thread Craig Topper via cfe-commits
https://github.com/topperc closed https://github.com/llvm/llvm-project/pull/161599 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Compare canonical conversion function (PR #154158)

2025-10-01 Thread via cfe-commits
eaeltsin wrote: > > cc @alexfh and @rnk, who should be able to test this. Testing these changes > > in advance proved really important in the past as sometimes they tend to > > break in quite a few tricky and hard-to-catch places on the compiler > > releases otherwise. > > I agree. Can we imp

[clang] [ObjC][Preprocessor] Handle @import directive as a pp-directive (PR #157726)

2025-10-01 Thread Michael Spencer via cfe-commits
https://github.com/Bigcheese edited https://github.com/llvm/llvm-project/pull/157726 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RISCV] Remove break after return in RISCVVEmitter.cpp. NFC (PR #161599)

2025-10-01 Thread Min-Yih Hsu via cfe-commits
https://github.com/mshockwave approved this pull request. https://github.com/llvm/llvm-project/pull/161599 ___ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

  1   2   3   4   >