[clang] [llvm] [LLVM][SROA] Teach SROA how to "bitcast" between fixed and scalable vectors. (PR #130973)

2025-03-12 Thread Craig Topper via cfe-commits
@@ -26,11 +26,15 @@ typedef vbool64_t fixed_bool64_t __attribute__((riscv_rvv_vector_bits(__riscv_v_ // // CHECK-128-LABEL: @call_bool32_ff( // CHECK-128-NEXT: entry: +// CHECK-128-NEXT:[[SAVED_VALUE:%.*]] = alloca <1 x i8>, align 1 topperc wrote: Err ne

[clang] [Driver] Avoid repeated hash lookups (NFC) (PR #130888)

2025-03-12 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/130888 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Buffer handle globals should not be constants (PR #130231)

2025-03-12 Thread Helena Kotas via cfe-commits
https://github.com/hekota approved this pull request. LGTM! Consider updating "Buffer" in the title to "Constant buffer" since this does not apply to other buffer resources. https://github.com/llvm/llvm-project/pull/130231 ___ cfe-commits mailing list

[clang] [NFC][analyzer] Rename `CheckerBase::getCheckerName` to `getName` (PR #130953)

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

[clang] [CIR] Upstream support for emitting ignored statements (PR #130869)

2025-03-12 Thread Andy Kaylor via cfe-commits
@@ -1,7 +1,9 @@ // RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -Wno-unused-value -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 -Wno-unused-value -fclangir -emit-llvm %s -o %

[clang] [llvm] [VectorCombine] Shrink loads used in shufflevector rebroadcasts (PR #128938)

2025-03-12 Thread Nikita Popov via cfe-commits
@@ -3398,6 +3399,101 @@ bool VectorCombine::foldInterleaveIntrinsics(Instruction &I) { return true; } +// If `I` is a load instruction, used only by shufflevector instructions with +// poison values, attempt to shrink the load to only the lanes being used. +bool VectorCombi

[clang] [Clang][CodeGen][UBSan] Add more precise attributes to recoverable ubsan handlers (PR #130990)

2025-03-12 Thread Yingwei Zheng via cfe-commits
https://github.com/dtcxzyw created https://github.com/llvm/llvm-project/pull/130990 Closes https://github.com/llvm/llvm-project/issues/130093. >From ea0d82d48d7a28467dc4e945314b57bc2b63085c Mon Sep 17 00:00:00 2001 From: Yingwei Zheng Date: Thu, 13 Mar 2025 00:39:09 +0800 Subject: [PATCH 1/2]

[clang] [CIR] Add transform test for cir-flatten-cfg (PR #130861)

2025-03-12 Thread Andy Kaylor via cfe-commits
@@ -0,0 +1,58 @@ +// RUN: cir-opt %s -cir-flatten-cfg -o - | FileCheck %s + +module { + cir.func @foo() { +cir.scope { + %0 = cir.alloca !cir.int, !cir.ptr>, ["a", init] {alignment = 4 : i64} + %1 = cir.const #cir.int<4> : !cir.int + cir.store %1, %0 : !cir.in

[clang] Honor pragmas with -ffp-contract=fast, depecate fast-honor-pragmas (PR #105746)

2025-03-12 Thread Yaxun Liu via cfe-commits
yxsamliu wrote: LGTM for HIP https://github.com/llvm/llvm-project/pull/105746 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL] Implement explicit layout for default constant buffer ($Globals) (PR #128991)

2025-03-12 Thread Ashley Coleman via cfe-commits
https://github.com/V-FEXrt approved this pull request. https://github.com/llvm/llvm-project/pull/128991 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL] Implement explicit layout for default constant buffer ($Globals) (PR #128991)

2025-03-12 Thread Ashley Coleman via cfe-commits
@@ -174,21 +176,51 @@ createBufferHandleType(const HLSLBufferDecl *BufDecl) { return cast(QT.getTypePtr()); } +// Iterates over all declarations in the HLSL buffer and based on the +// packoffset or register(c#) annotations it fills outs the Layout +// vector with the user-s

[clang-tools-extra] [clang-tidy] Add new check bugprone-capture-this-by-field (PR #130297)

2025-03-12 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 updated https://github.com/llvm/llvm-project/pull/130297 >From 8ef214f6c78d710dbd9c74b06c7c637baf93e527 Mon Sep 17 00:00:00 2001 From: Congcong Cai Date: Sat, 8 Mar 2025 00:03:39 +0800 Subject: [PATCH 1/8] [clang-tidy] Add new check bugprone-capture-this-by-field

[clang] [llvm] [HLSL] Implement explicit layout for default constant buffer ($Globals) (PR #128991)

2025-03-12 Thread Alex Sepkowski via cfe-commits
@@ -89,14 +99,57 @@ llvm::TargetExtType *HLSLBufferLayoutBuilder::createLayoutType( RecordTypes.pop_back(); for (const auto *FD : RT->getDecl()->fields()) { - assert((!Packoffsets || Index < Packoffsets->size()) && - "number of elements in layout stru

[clang] [llvm] [HLSL] Implement explicit layout for default constant buffer ($Globals) (PR #128991)

2025-03-12 Thread Alex Sepkowski via cfe-commits
@@ -174,21 +176,45 @@ createBufferHandleType(const HLSLBufferDecl *BufDecl) { return cast(QT.getTypePtr()); } +// Iterates over all declarations in the HLSL buffer and based on the +// packoffset or register(c#) annotations it fills outs the Layout +// vector with the user-s

[clang] [llvm] [HLSL] Implement explicit layout for default constant buffer ($Globals) (PR #128991)

2025-03-12 Thread Alex Sepkowski via cfe-commits
@@ -174,21 +176,45 @@ createBufferHandleType(const HLSLBufferDecl *BufDecl) { return cast(QT.getTypePtr()); } +// Iterates over all declarations in the HLSL buffer and based on the +// packoffset or register(c#) annotations it fills outs the Layout alsepkow

[clang] [llvm] [HLSL] Implement explicit layout for default constant buffer ($Globals) (PR #128991)

2025-03-12 Thread Alex Sepkowski via cfe-commits
@@ -174,21 +176,45 @@ createBufferHandleType(const HLSLBufferDecl *BufDecl) { return cast(QT.getTypePtr()); } +// Iterates over all declarations in the HLSL buffer and based on the +// packoffset or register(c#) annotations it fills outs the Layout +// vector with the user-s

[clang] [llvm] [HLSL] Implement explicit layout for default constant buffer ($Globals) (PR #128991)

2025-03-12 Thread Alex Sepkowski via cfe-commits
@@ -89,14 +99,57 @@ llvm::TargetExtType *HLSLBufferLayoutBuilder::createLayoutType( RecordTypes.pop_back(); for (const auto *FD : RT->getDecl()->fields()) { - assert((!Packoffsets || Index < Packoffsets->size()) && - "number of elements in layout stru

[clang] [llvm] [HLSL] Implement explicit layout for default constant buffer ($Globals) (PR #128991)

2025-03-12 Thread Alex Sepkowski via cfe-commits
@@ -89,14 +99,57 @@ llvm::TargetExtType *HLSLBufferLayoutBuilder::createLayoutType( RecordTypes.pop_back(); for (const auto *FD : RT->getDecl()->fields()) { - assert((!Packoffsets || Index < Packoffsets->size()) && - "number of elements in layout stru

[clang] [llvm] [HLSL] Implement explicit layout for default constant buffer ($Globals) (PR #128991)

2025-03-12 Thread Alex Sepkowski via cfe-commits
@@ -89,14 +99,57 @@ llvm::TargetExtType *HLSLBufferLayoutBuilder::createLayoutType( RecordTypes.pop_back(); for (const auto *FD : RT->getDecl()->fields()) { - assert((!Packoffsets || Index < Packoffsets->size()) && - "number of elements in layout stru

[clang] [llvm] [HLSL] Implement explicit layout for default constant buffer ($Globals) (PR #128991)

2025-03-12 Thread Alex Sepkowski via cfe-commits
@@ -58,9 +60,15 @@ namespace CodeGen { // classes) and calls layoutField to converts each field to its corresponding // LLVM type and to calculate its HLSL constant buffer layout. Any embedded // structs (or arrays of structs) are converted to target layout types as well. +// +

[clang] [llvm] [HLSL] Implement explicit layout for default constant buffer ($Globals) (PR #128991)

2025-03-12 Thread Alex Sepkowski via cfe-commits
@@ -174,21 +176,45 @@ createBufferHandleType(const HLSLBufferDecl *BufDecl) { return cast(QT.getTypePtr()); } +// Iterates over all declarations in the HLSL buffer and based on the +// packoffset or register(c#) annotations it fills outs the Layout alsepkow

[clang] [Clang][CodeGen][UBSan] Add more precise attributes to recoverable ubsan handlers (PR #130990)

2025-03-12 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 57a90883ca541a90a7a4a22d715832ec0ceb0599 f5297c7e45452b39e1ceec6ff3ab50fd6792f393 --e

[clang] [CIR] Add transform test for cir-flatten-cfg (PR #130861)

2025-03-12 Thread Erich Keane via cfe-commits
@@ -0,0 +1,58 @@ +// RUN: cir-opt %s -cir-flatten-cfg -o - | FileCheck %s + +module { + cir.func @foo() { +cir.scope { + %0 = cir.alloca !cir.int, !cir.ptr>, ["a", init] {alignment = 4 : i64} + %1 = cir.const #cir.int<4> : !cir.int + cir.store %1, %0 : !cir.in

[clang] [clang] Predefine `_CRT_USE_BUILTIN_OFFSETOF` in MS-compatible modes (PR #127568)

2025-03-12 Thread A. Jiang via cfe-commits
https://github.com/frederick-vs-ja updated https://github.com/llvm/llvm-project/pull/127568 >From 2c9e6e45944891af54cba9648297a996bb4d8cca Mon Sep 17 00:00:00 2001 From: "A. Jiang" Date: Tue, 18 Feb 2025 14:03:35 +0800 Subject: [PATCH 1/3] [clang] Predefine `_CRT_USE_BUILTIN_OFFSETOF` in MS-co

[clang] [flang] [llvm] [mlir] [TargetRegistry] Accept Triple in createTargetMachine() (NFC) (PR #130940)

2025-03-12 Thread Yingwei Zheng via cfe-commits
https://github.com/dtcxzyw approved this pull request. https://github.com/llvm/llvm-project/pull/130940 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [VectorCombine] Shrink loads used in shufflevector rebroadcasts (PR #128938)

2025-03-12 Thread Nikita Popov via cfe-commits
@@ -3398,6 +3399,101 @@ bool VectorCombine::foldInterleaveIntrinsics(Instruction &I) { return true; } +// If `I` is a load instruction, used only by shufflevector instructions with +// poison values, attempt to shrink the load to only the lanes being used. +bool VectorCombi

[clang] [llvm] [ARM][Clang] Make `+nosimd` functional for AArch32 Targets (PR #130623)

2025-03-12 Thread Jack Styles via cfe-commits
https://github.com/Stylie777 updated https://github.com/llvm/llvm-project/pull/130623 >From 7c0b94752285f2734d79e9e8d38aa20b3f7e8e61 Mon Sep 17 00:00:00 2001 From: Jack Styles Date: Fri, 7 Mar 2025 15:51:34 + Subject: [PATCH 1/4] [NFC][ARM] Split SIMD identifier away from MVE Previously, t

[clang] [llvm] [VectorCombine] Shrink loads used in shufflevector rebroadcasts (PR #128938)

2025-03-12 Thread Nikita Popov via cfe-commits
@@ -336,7 +336,7 @@ define <8 x float> @load_v2f32_v8f32(ptr dereferenceable(32) %p) { define <4 x i32> @load_v2i32_v4i32(ptr dereferenceable(16) %p) { ; CHECK-LABEL: @load_v2i32_v4i32( -; CHECK-NEXT:[[S:%.*]] = load <4 x i32>, ptr [[P:%.*]], align 1 +; CHECK-NEXT:[[S

[clang] [clang][WebAssembly] Support the `-m(no-)red-zone` flag. (PR #119997)

2025-03-12 Thread Dan Gohman via cfe-commits
sunfishcode wrote: Makes sense. My instinct here is to wait until we have a concrete use case. https://github.com/llvm/llvm-project/pull/119997 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-

[clang] [llvm] [Support] Introduce new `AdvisoryLock` interface (PR #130989)

2025-03-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Jan Svoboda (jansvoboda11) Changes This PR abstracts the `LockFileManager` API into new `AdvisoryLock` interface. This is so that we can create an alternative implementation for Clang implicitly-built modules that is optimized for single-

[clang] [flang] [llvm] [mlir] [TargetRegistry] Accept Triple in createTargetMachine() (NFC) (PR #130940)

2025-03-12 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `flang-aarch64-libcxx` running on `linaro-flang-aarch64-libcxx` while building `bolt,clang,flang,llvm,mlir,offload` at step 5 "build-unified-tree". Full details are available at: https://lab.llvm.org/buildbot/#/builders/89/bui

[clang] [llvm] [HLSL] Implement explicit layout for default constant buffer ($Globals) (PR #128991)

2025-03-12 Thread Helena Kotas via cfe-commits
@@ -89,14 +99,57 @@ llvm::TargetExtType *HLSLBufferLayoutBuilder::createLayoutType( RecordTypes.pop_back(); for (const auto *FD : RT->getDecl()->fields()) { - assert((!Packoffsets || Index < Packoffsets->size()) && - "number of elements in layout stru

[clang] [NFC][analyzer] Framework for multipart checkers (PR #130985)

2025-03-12 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat created https://github.com/llvm/llvm-project/pull/130985 In the static analyzer codebase we have a traditional pattern where a single checker class (and its singleton instance) acts as the implementation of several (user-facing or modeling) checkers that have share

[clang] [llvm] [HLSL] Implement explicit layout for default constant buffer ($Globals) (PR #128991)

2025-03-12 Thread Helena Kotas via cfe-commits
https://github.com/hekota edited https://github.com/llvm/llvm-project/pull/128991 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [llvm] [mlir] [TargetRegistry] Accept Triple in createTargetMachine() (NFC) (PR #130940)

2025-03-12 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `ppc64le-flang-rhel-clang` running on `ppc64le-flang-rhel-test` while building `bolt,clang,flang,llvm,mlir,offload` at step 5 "build-unified-tree". Full details are available at: https://lab.llvm.org/buildbot/#/builders/157/bu

[clang] Add unretained call args checker (PR #130901)

2025-03-12 Thread Ryosuke Niwa via cfe-commits
https://github.com/rniwa closed https://github.com/llvm/llvm-project/pull/130901 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][OpenCL] Fix Missing `-fdeclare-opencl-builtins` When Using `--save-temps` (PR #131017)

2025-03-12 Thread Shilei Tian via cfe-commits
shiltian wrote: * **#131017** https://app.graphite.dev/github/pr/llvm/llvm-project/131017?utm_source=stack-comment-icon"; target="_blank">https://static.graphite.dev/graphite-32x32-black.png"; alt="Graphite" width="10px" height="10px"/> 👈 https://app.graphite.dev/github/pr/llvm/llvm-project/131

[clang] [Clang][OpenCL] Fix Missing `-fdeclare-opencl-builtins` When Using `--save-temps` (PR #131017)

2025-03-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Shilei Tian (shiltian) Changes When compiling an OpenCL program directly with `clang` using `--save-temps`, an error may occur if the program contains OpenCL builtins: ``` test.cl:3:21: error: use of undeclared identifier 'get_global_id'

[clang] [Clang][OpenCL] Fix Missing `-fdeclare-opencl-builtins` When Using `--save-temps` (PR #131017)

2025-03-12 Thread Shilei Tian via cfe-commits
https://github.com/shiltian created https://github.com/llvm/llvm-project/pull/131017 When compiling an OpenCL program directly with `clang` using `--save-temps`, an error may occur if the program contains OpenCL builtins: ``` test.cl:3:21: error: use of undeclared identifier 'get_global_id'

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #125492)

2025-03-12 Thread Ziqing Luo via cfe-commits
@@ -68,32 +70,57 @@ static std::string getDREAncestorString(const DeclRefExpr *DRE, if (StParents.size() > 1) return "unavailable due to multiple parents"; -if (StParents.size() == 0) +if (StParents.empty()) break; St = StParents.begin()->get();

[clang] [CIR] Upstream support for emitting ignored statements (PR #130869)

2025-03-12 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor updated https://github.com/llvm/llvm-project/pull/130869 >From a4e8aa13f97a6c73389822f6fdcf6f5970792462 Mon Sep 17 00:00:00 2001 From: Andy Kaylor Date: Tue, 11 Mar 2025 17:01:44 -0700 Subject: [PATCH 1/3] [CIR] Upstream support for emitting ignored statements Thi

[clang] [Clang][OpenCL] Fix Missing `-fdeclare-opencl-builtins` When Using `--save-temps` (PR #131017)

2025-03-12 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 approved this pull request. Makes sense, though I don't know why we have a special flag for what is essentially a header. https://github.com/llvm/llvm-project/pull/131017 ___ cfe-commits mailing list cfe-commits@lists.llvm.o

[clang] [NFC][analyzer] Framework for multipart checkers (PR #130985)

2025-03-12 Thread via cfe-commits
=?utf-8?q?Donát?= Nagy Message-ID: In-Reply-To: llvmbot wrote: @llvm/pr-subscribers-clang Author: Donát Nagy (NagyDonat) Changes In the static analyzer codebase we have a traditional pattern where a single checker class (and its singleton instance) acts as the implementation of severa

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

2025-03-12 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: @zmodem , are you able to reproduce the link issue with just the `filteredbrk.obj` ? I can't spot a problem in LLVM IR or ASM emitted from it and lld just gives a bunch of "undefined symbol" link errors. Is that possible that more files are needed to reproduce? https://githu

[clang] [CIR] Upstream support for emitting ignored statements (PR #130869)

2025-03-12 Thread Andy Kaylor via cfe-commits
@@ -1,7 +1,9 @@ // RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -Wno-unused-value -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 -Wno-unused-value -fclangir -emit-llvm %s -o %

[clang] [llvm] [LLVM][SROA] Teach SROA how to "bitcast" between fixed and scalable vectors. (PR #130973)

2025-03-12 Thread Craig Topper via cfe-commits
@@ -26,11 +26,15 @@ typedef vbool64_t fixed_bool64_t __attribute__((riscv_rvv_vector_bits(__riscv_v_ // // CHECK-128-LABEL: @call_bool32_ff( // CHECK-128-NEXT: entry: +// CHECK-128-NEXT:[[SAVED_VALUE:%.*]] = alloca <1 x i8>, align 1 topperc wrote: vbool3

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #125492)

2025-03-12 Thread Ziqing Luo via cfe-commits
@@ -1670,30 +1936,41 @@ class ULCArraySubscriptGadget : public FixableGadget { }; // Fixable gadget to handle stand alone pointers of the form `UPC(DRE)` in the -// unspecified pointer context (isInUnspecifiedPointerContext). The gadget emits -// fixit of the form `UPC(DRE.da

[clang] [Docs] Explain how to propose an extension in Clang (PR #130803)

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

[clang] [flang] [llvm] [mlir] [TargetRegistry] Accept Triple in createTargetMachine() (NFC) (PR #130940)

2025-03-12 Thread Nikita Popov via cfe-commits
@@ -453,14 +453,14 @@ class Target { /// either the target triple from the module, or the target triple of the /// host if that does not exist. TargetMachine *createTargetMachine( - StringRef TT, StringRef CPU, StringRef Features, nikic wrote: Resto

[clang] [llvm] [CVP] Infer `nuw`/`nsw` flags for TruncInst (PR #130504)

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

[clang-tools-extra] [clang-tidy] Add new check bugprone-capture-this-by-field (PR #130297)

2025-03-12 Thread Denis Mikhailov via cfe-commits
https://github.com/denzor200 edited https://github.com/llvm/llvm-project/pull/130297 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 1d89d7d - [Docs] Explain how to propose an extension in Clang (#130803)

2025-03-12 Thread via cfe-commits
Author: Aaron Ballman Date: 2025-03-12T08:02:44-04:00 New Revision: 1d89d7d5d76e391b035f50343e2a4890506c6f2b URL: https://github.com/llvm/llvm-project/commit/1d89d7d5d76e391b035f50343e2a4890506c6f2b DIFF: https://github.com/llvm/llvm-project/commit/1d89d7d5d76e391b035f50343e2a4890506c6f2b.diff

[clang] [NFC][analyzer] Rename `CheckerBase::getCheckerName` to `getName` (PR #130953)

2025-03-12 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat created https://github.com/llvm/llvm-project/pull/130953 The method name `getCheckerName` would imply "get the name of the checker associated with `this`", so it's suitable for e.g. `BugType::getCheckerName` -- but the proper name for a method that "gets the name o

[clang] [NFC][analyzer] Rename `CheckerBase::getCheckerName` to `getName` (PR #130953)

2025-03-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 Author: Donát Nagy (NagyDonat) Changes The method name `getCheckerName` would imply "get the name of the checker associated with `this`", so it's suitable for e.g. `BugType::getCheckerName` -- but the proper name for a method th

[clang] [NFC][analyzer] Rename `CheckerBase::getCheckerName` to `getName` (PR #130953)

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

[clang] [flang] [flang] Align `-x` language modes with `gfortran` (PR #130268)

2025-03-12 Thread Iñaki Amatria Barral via cfe-commits
https://github.com/inaki-amatria updated https://github.com/llvm/llvm-project/pull/130268 From def8ab8b16eab97ffc2669631fb84406842d41e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?I=C3=B1aki=20Amatria=20Barral?= Date: Fri, 7 Mar 2025 08:45:05 +0100 Subject: [PATCH 1/2] [flang] Remove implicit assu

[clang] 7decd04 - [Clang] Add __builtin_elementwise_exp10 in the same fashion as exp/exp2 (#130746)

2025-03-12 Thread via cfe-commits
Author: Juan Manuel Martinez Caamaño Date: 2025-03-12T09:20:29+01:00 New Revision: 7decd046260d855c41a25990aee5398929ea29f8 URL: https://github.com/llvm/llvm-project/commit/7decd046260d855c41a25990aee5398929ea29f8 DIFF: https://github.com/llvm/llvm-project/commit/7decd046260d855c41a25990aee5398

[clang] [libc][nfc] Include instantiations of gpuintrin.h in IR test case (PR #130956)

2025-03-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-libc Author: Jon Chesterfield (JonChesterfield) Changes Regenerated existing test case with include-generated-funcs to show the lowered IR for each instantiation. --- Patch is 46.11 KiB, truncated to 20.00 KiB below, full version: https://github.com/

[clang] [clang] Introduce "binary" StringLiteral for #embed data (PR #127629)

2025-03-12 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman commented: Thanks for this! It also needs a release note for the fix. :-) In general, I think this seems reasonable, but I'd like confirmation from @cor3ntin given his somewhat recent thinking about unevaluated string literals and where those end up touching the

[clang] [NFC][analyzer] Rename `CheckerBase::getCheckerName` to `getName` (PR #130953)

2025-03-12 Thread Gábor Horváth via cfe-commits
https://github.com/Xazax-hun approved this pull request. https://github.com/llvm/llvm-project/pull/130953 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libc][nfc] Include instantiations of gpuintrin.h in IR test case (PR #130956)

2025-03-12 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 approved this pull request. Fine way to show the intrinsics that this generates. I originally kept it brief since I just assumed those were tested elsewhere. https://github.com/llvm/llvm-project/pull/130956 ___ cfe-commits m

[clang] [libc] [llvm] Reapply "[AMDGPU] Use COV6 by default (#118515)" (PR #130963)

2025-03-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-amdgpu Author: Shilei Tian (shiltian) Changes This reverts commit 68bcba6d7a1cc18996c0bcb7c62267c62d2040d0. --- Full diff: https://github.com/llvm/llvm-project/pull/130963.diff 17 Files Affected: - (modified) clang/docs/ReleaseNotes.rst (+3-1

[clang] [libc] [llvm] Reapply "[AMDGPU] Use COV6 by default (#118515)" (PR #130963)

2025-03-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver Author: Shilei Tian (shiltian) Changes This reverts commit 68bcba6d7a1cc18996c0bcb7c62267c62d2040d0. --- Full diff: https://github.com/llvm/llvm-project/pull/130963.diff 17 Files Affected: - (modified) clang/docs/ReleaseNotes.rst (+3-1)

[clang] [libc] [llvm] Reapply "[AMDGPU] Use COV6 by default (#118515)" (PR #130963)

2025-03-12 Thread Shilei Tian via cfe-commits
shiltian wrote: * **#130963** https://app.graphite.dev/github/pr/llvm/llvm-project/130963?utm_source=stack-comment-icon"; target="_blank">https://static.graphite.dev/graphite-32x32-black.png"; alt="Graphite" width="10px" height="10px"/> 👈 https://app.graphite.dev/github/pr/llvm/llvm-project/130

[clang] [libc] [llvm] Reapply "[AMDGPU] Use COV6 by default (#118515)" (PR #130963)

2025-03-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Shilei Tian (shiltian) Changes This reverts commit 68bcba6d7a1cc18996c0bcb7c62267c62d2040d0. --- Full diff: https://github.com/llvm/llvm-project/pull/130963.diff 17 Files Affected: - (modified) clang/docs/ReleaseNotes.rst (+3-1) - (mod

[clang] [clang] Introduce "binary" StringLiteral for #embed data (PR #127629)

2025-03-12 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon edited https://github.com/llvm/llvm-project/pull/127629 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][analyzer] Rename `CheckerBase::getCheckerName` to `getName` (PR #130953)

2025-03-12 Thread Donát Nagy via cfe-commits
@@ -41,19 +41,19 @@ class BugType { Checker(nullptr), SuppressOnSink(SuppressOnSink) {} BugType(const CheckerBase *Checker, StringRef Desc, StringRef Cat = categories::LogicError, bool SuppressOnSink = false) - : CheckerName(Checker->getCheckerName()),

[clang] [libc] [llvm] Reapply "[AMDGPU] Use COV6 by default (#118515)" (PR #130963)

2025-03-12 Thread Shilei Tian via cfe-commits
https://github.com/shiltian created https://github.com/llvm/llvm-project/pull/130963 This reverts commit 68bcba6d7a1cc18996c0bcb7c62267c62d2040d0. >From 0f831a4a78fefcdf0ac973173397325a1f53d393 Mon Sep 17 00:00:00 2001 From: Shilei Tian Date: Wed, 12 Mar 2025 09:39:45 -0400 Subject: [PATCH] Re

[clang] [NFC][analyzer] Rename `CheckerBase::getCheckerName` to `getName` (PR #130953)

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

[clang] [clang] Introduce "binary" StringLiteral for #embed data (PR #127629)

2025-03-12 Thread Mariya Podchishchaeva via cfe-commits
@@ -1332,6 +1334,11 @@ StringLiteral::getLocationOfByte(unsigned ByteNo, const SourceManager &SM, const LangOptions &Features, const TargetInfo &Target, unsigned *StartToken, un

[clang] [libc] [llvm] Reapply "[AMDGPU] Use COV6 by default (#118515)" (PR #130963)

2025-03-12 Thread Shilei Tian via cfe-commits
shiltian wrote: We will need to wait for the AMD bots to be ready. https://github.com/llvm/llvm-project/pull/130963 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][analyzer] Rename `CheckerBase::getCheckerName` to `getName` (PR #130953)

2025-03-12 Thread Gábor Horváth via cfe-commits
@@ -41,19 +41,19 @@ class BugType { Checker(nullptr), SuppressOnSink(SuppressOnSink) {} BugType(const CheckerBase *Checker, StringRef Desc, StringRef Cat = categories::LogicError, bool SuppressOnSink = false) - : CheckerName(Checker->getCheckerName()),

[clang] [NFC][analyzer] Rename `CheckerBase::getCheckerName` to `getName` (PR #130953)

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

[clang] [libc] [llvm] Reapply "[AMDGPU] Use COV6 by default (#118515)" (PR #130963)

2025-03-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-libc Author: Shilei Tian (shiltian) Changes This reverts commit 68bcba6d7a1cc18996c0bcb7c62267c62d2040d0. --- Full diff: https://github.com/llvm/llvm-project/pull/130963.diff 17 Files Affected: - (modified) clang/docs/ReleaseNotes.rst (+3-1) - (modi

[clang] [NFC][analyzer] Rename `CheckerBase::getCheckerName` to `getName` (PR #130953)

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

[clang] [libc] [llvm] Reapply "[AMDGPU] Use COV6 by default (#118515)" (PR #130963)

2025-03-12 Thread Shilei Tian via cfe-commits
shiltian wrote: CC @jdoerfert @ye-luo Once this is merged, ROCm 6.3 will be needed to run any program compiled for AMDGPU. https://github.com/llvm/llvm-project/pull/130963 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/

[clang] ab557af - [libc][nfc] Include instantiations of gpuintrin.h in IR test case (#130956)

2025-03-12 Thread via cfe-commits
Author: Jon Chesterfield Date: 2025-03-12T13:33:27Z New Revision: ab557afa40af11ab2a1276dd9ccb8e072f1c7492 URL: https://github.com/llvm/llvm-project/commit/ab557afa40af11ab2a1276dd9ccb8e072f1c7492 DIFF: https://github.com/llvm/llvm-project/commit/ab557afa40af11ab2a1276dd9ccb8e072f1c7492.diff L

[clang] [llvm] [RISCV] Add Qualcomn uC Xqcili (load large immediates) extension (PR #130012)

2025-03-12 Thread via cfe-commits
https://github.com/u4f3 updated https://github.com/llvm/llvm-project/pull/130012 >From 52cfa2c358ba20ec20f023828ba2d8bcccb38e83 Mon Sep 17 00:00:00 2001 From: u4f3 Date: Fri, 7 Mar 2025 15:01:57 +0800 Subject: [PATCH] [RISCV] Add Qualcomn uC Xqcili (load large immediates) extension The Xqcili

[clang] [Clang] add additional tests for -Wshift-bool (PR #130339)

2025-03-12 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/130339 >From bed2cb009ae2e560aa00f86b90c57d82f97bb435 Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Fri, 7 Mar 2025 22:10:24 +0200 Subject: [PATCH 1/4] [Clang] add additional tests for -Wshift-bool --- clang/te

[clang-tools-extra] [clang-tidy] Add new check bugprone-capture-this-by-field (PR #130297)

2025-03-12 Thread Denis Mikhailov via cfe-commits
@@ -0,0 +1,44 @@ +//===--- CapturingThisByFieldCheck.h - clang-tidy ---*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apa

[clang] [flang] [llvm] [mlir] [TargetRegistry] Accept Triple in createTargetMachine() (NFC) (PR #130940)

2025-03-12 Thread Nikita Popov via cfe-commits
https://github.com/nikic updated https://github.com/llvm/llvm-project/pull/130940 >From 7aa005a4e9aa14c79a527719936824bcfe9a409c Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Wed, 12 Mar 2025 10:57:58 +0100 Subject: [PATCH 1/3] [TargetRegistry] Accept Triple in createTargetMachine() (NFC)

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

2025-03-12 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] [Clang] add additional tests for -Wshift-bool (PR #130339)

2025-03-12 Thread Oleksandr T. via cfe-commits
@@ -0,0 +1,24 @@ +// RUN: %clang_cc1 -fsyntax-only -Wshift-bool -verify %s + +void t() { + int x = 10; + int y = 1; + + int a = y << x; + int b = y >> x; + + int c = 0 << x; + int d = 0 >> x; + + int e = y << 1; + int f = y >> 1; + + int g = y << -1; // expected-warning {

[clang] [llvm] [CVP] Infer `nuw`/`nsw` flags for TruncInst (PR #130504)

2025-03-12 Thread Yingwei Zheng via cfe-commits
https://github.com/dtcxzyw approved this pull request. LGTM. Thank you! https://github.com/llvm/llvm-project/pull/130504 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2025-03-12 Thread Djordje Todorovic via cfe-commits
@@ -47,14 +47,16 @@ bool MipsTargetInfo::processorSupportsGPR64() const { .Case("mips64r6", true) .Case("octeon", true) .Case("octeon+", true) + .Case("i6400", true) + .Case("i6500", true) .Default(false); } static constexpr llvm::StringLi

[clang] [ARM] Using cp15 while mtp =auto and arch is arm_arch6k and support thumb2 (PR #130027)

2025-03-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-backend-arm Author: Austin (Zhenhang1213) Changes We follow GCC mtp=auto when arch is arm_arch6k and support thumb2 reference:https://reviews.llvm.org/D114116 --- Full diff: https://github.com/llvm/llvm-project/pull/130027.di

[clang] [flang] [llvm] [mlir] [TargetRegistry] Accept Triple in createTargetMachine() (NFC) (PR #130940)

2025-03-12 Thread Matt Arsenault via cfe-commits
@@ -47,9 +47,8 @@ JITTargetMachineBuilder::createTargetMachine() { return make_error("Target has no JIT support", inconvertibleErrorCode()); - auto *TM = - TheTarget->createTargetMachine(TT.getTriple(), CPU, Features.getString(), -

[clang] [Clang][CodeGen] Do not set inbounds flag in `EmitMemberDataPointerAddress` when the base pointer is null (PR #130952)

2025-03-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: Yingwei Zheng (dtcxzyw) Changes See also https://github.com/llvm/llvm-project/pull/130734 for the original motivation. This pattern (`container_of`) is also widely used by real-world programs. Examples: https://github.com/llvm/llv

[clang] 5073b5f - [CVP] Infer `nuw`/`nsw` flags for TruncInst (#130504)

2025-03-12 Thread via cfe-commits
Author: Veera Date: 2025-03-12T08:25:24-04:00 New Revision: 5073b5fdfaf90f5d94640cf9031c73d27a91e394 URL: https://github.com/llvm/llvm-project/commit/5073b5fdfaf90f5d94640cf9031c73d27a91e394 DIFF: https://github.com/llvm/llvm-project/commit/5073b5fdfaf90f5d94640cf9031c73d27a91e394.diff LOG: [C

[clang] [llvm] [CVP] Infer `nuw`/`nsw` flags for TruncInst (PR #130504)

2025-03-12 Thread via cfe-commits
https://github.com/veera-sivarajan closed https://github.com/llvm/llvm-project/pull/130504 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [ARM][Clang] Make `+nosimd` functional for AArch32 Targets (PR #130623)

2025-03-12 Thread Jack Styles via cfe-commits
@@ -334,8 +334,8 @@ ARM_CPU_NAME("cortex-r7", ARMV7R, FK_VFPV3_D16_FP16, false, (ARM::AEK_MP | ARM::AEK_HWDIVARM)) ARM_CPU_NAME("cortex-r8", ARMV7R, FK_VFPV3_D16_FP16, false, (ARM::AEK_MP | ARM::AEK_HWDIVARM)) -ARM_CPU_NAME("cortex-r52", ARMV8R, FK_NEO

[clang] 76cf895 - Revert "[HLSL] error on out of bounds vector accesses (#128952)"

2025-03-12 Thread Hans Wennborg via cfe-commits
Author: Hans Wennborg Date: 2025-03-12T12:31:37+01:00 New Revision: 76cf895717e9eba4d2a158d5bc3e48f2f7794181 URL: https://github.com/llvm/llvm-project/commit/76cf895717e9eba4d2a158d5bc3e48f2f7794181 DIFF: https://github.com/llvm/llvm-project/commit/76cf895717e9eba4d2a158d5bc3e48f2f7794181.diff

[clang] [clang] Introduce "binary" StringLiteral for #embed data (PR #127629)

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

[clang] [Clang][NFC] Remove CallExpr::CreateTemporary (PR #130919)

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

[clang-tools-extra] [clang-tidy] Add new check bugprone-capture-this-by-field (PR #130297)

2025-03-12 Thread Denis Mikhailov via cfe-commits
@@ -0,0 +1,144 @@ +// RUN: %check_clang_tidy -std=c++11-or-later %s bugprone-capturing-this-by-field %t -- -config="{CheckOptions: {bugprone-capturing-this-by-field.FunctionWrapperTypes: '::std::function;::Fn'}}" -- denzor200 wrote: Oke, don't worry about bind

[clang] [clang][analyzer] Add support for C++23 container methods releated to iterator in ContainerModeling (PR #129719)

2025-03-12 Thread via cfe-commits
flovent wrote: thank you! I will wait for other reviewer's approval. https://github.com/llvm/llvm-project/pull/129719 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2025-03-12 Thread Anutosh Bhat via cfe-commits
https://github.com/anutosh491 updated https://github.com/llvm/llvm-project/pull/127467 >From bd1b0b2a14afeb73755db3a7deb6bffd4f50778c Mon Sep 17 00:00:00 2001 From: anutosh491 Date: Mon, 17 Feb 2025 15:33:20 +0530 Subject: [PATCH 1/3] Fix error recovery while PTU cleanup --- clang/lib/Interpr

[clang] fix(clang/**.py): fix invalid escape sequences (PR #94029)

2025-03-12 Thread Donát Nagy via cfe-commits
@@ -55,7 +55,7 @@ def run_test_once(args, extra_args): # themselves. We need to keep the comments to preserve line numbers while # avoiding empty lines which could potentially trigger formatting-related # checks. -cleaned_test = re.sub("// *CHECK-[A-Z0-9\-]*:[^

[clang] [Clang] Add __builtin_elementwise_exp10 in the same fashion as exp/exp2 (PR #130746)

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

[clang] [llvm] [ARM][Clang] Make `+nosimd` functional for AArch32 Targets (PR #130623)

2025-03-12 Thread Jack Styles via cfe-commits
@@ -334,8 +334,8 @@ ARM_CPU_NAME("cortex-r7", ARMV7R, FK_VFPV3_D16_FP16, false, (ARM::AEK_MP | ARM::AEK_HWDIVARM)) ARM_CPU_NAME("cortex-r8", ARMV7R, FK_VFPV3_D16_FP16, false, (ARM::AEK_MP | ARM::AEK_HWDIVARM)) -ARM_CPU_NAME("cortex-r52", ARMV8R, FK_NEO

<    1   2   3   4   5   6   >