[clang] [InstallAPI] Set InstallAPI as a standalone tool instead of CC1 action (PR #82293)

2024-02-19 Thread Cyndy Ishida via cfe-commits
https://github.com/cyndyishida created https://github.com/llvm/llvm-project/pull/82293 Installapi has important distinctions when compared to the clang driver, so much that, it doesn't make much sense to try to integrate into it. This patch partially reverts the CC1 action & driver support to

[clang] Turn 'counted_by' into a type attribute and parse it into 'CountAttributedType' (PR #78000)

2024-02-19 Thread Yeoul Na via cfe-commits
https://github.com/rapidsna updated https://github.com/llvm/llvm-project/pull/78000 >From c39871ed2ec642ab00360f2c3a18fba7c915f82d Mon Sep 17 00:00:00 2001 From: Yeoul Na Date: Mon, 18 Dec 2023 10:58:16 +0900 Subject: [PATCH 1/4] [BoundsSafety] Introduce CountAttributedType

[clang] Turn 'counted_by' into a type attribute and parse it into 'CountAttributedType' (PR #78000)

2024-02-19 Thread Yeoul Na via cfe-commits
https://github.com/rapidsna updated https://github.com/llvm/llvm-project/pull/78000 >From c39871ed2ec642ab00360f2c3a18fba7c915f82d Mon Sep 17 00:00:00 2001 From: Yeoul Na Date: Mon, 18 Dec 2023 10:58:16 +0900 Subject: [PATCH 1/3] [BoundsSafety] Introduce CountAttributedType

[clang] [alpha.webkit.UncountedCallArgsChecker] Ignore calls to WTF's container methods (PR #82156)

2024-02-19 Thread Ryosuke Niwa via cfe-commits
@@ -25,6 +25,11 @@ using namespace ento; namespace { +bool stringEndsWith(const std::string , const std::string ) { + auto index = str.rfind(suffix); + return index != std::string::npos && str.size() - suffix.size() == index; +} rniwa wrote: Oh, didn't

[clang] [alpha.webkit.UncountedCallArgsChecker] Allow a variable declaration in a trivial function. (PR #82291)

2024-02-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 Author: Ryosuke Niwa (rniwa) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/82291.diff 2 Files Affected: - (modified) clang/lib/StaticAnalyzer/Checkers/WebKit/PtrTypesSemantics.cpp (+5-2) - (modified)

[clang] [alpha.webkit.UncountedCallArgsChecker] Allow a variable declaration in a trivial function. (PR #82291)

2024-02-19 Thread Ryosuke Niwa via cfe-commits
https://github.com/rniwa created https://github.com/llvm/llvm-project/pull/82291 None >From b0519e342b2e145827d6d9de490f32d1dd9c5fe6 Mon Sep 17 00:00:00 2001 From: Ryosuke Niwa Date: Sat, 17 Feb 2024 18:12:16 -0800 Subject: [PATCH] [alpha.webkit.UncountedCallArgsChecker] Allow a variable

[clang] c3b87a8 - [alpha.webkit.UncountedCallArgsChecker] Allow ASSERT and atomic operations in a trivial function (#82063)

2024-02-19 Thread via cfe-commits
Author: Ryosuke Niwa Date: 2024-02-19T16:11:49-08:00 New Revision: c3b87a8810535b95ed1abd7c1ebd330131f68890 URL: https://github.com/llvm/llvm-project/commit/c3b87a8810535b95ed1abd7c1ebd330131f68890 DIFF: https://github.com/llvm/llvm-project/commit/c3b87a8810535b95ed1abd7c1ebd330131f68890.diff

[clang] [alpha.webkit.UncountedCallArgsChecker] Allow ASSERT and atomic operations in a trivial function (PR #82063)

2024-02-19 Thread Ryosuke Niwa via cfe-commits
https://github.com/rniwa closed https://github.com/llvm/llvm-project/pull/82063 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RISCV] Disable generation of asynchronous unwind tables for RISCV baremetal (PR #81727)

2024-02-19 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay approved this pull request. https://github.com/llvm/llvm-project/pull/81727 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RISCV] Disable generation of asynchronous unwind tables for RISCV baremetal (PR #81727)

2024-02-19 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay edited https://github.com/llvm/llvm-project/pull/81727 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RISCV] Disable generation of asynchronous unwind tables for RISCV baremetal (PR #81727)

2024-02-19 Thread Fangrui Song via cfe-commits
@@ -421,3 +421,11 @@ // MIPSN32R6EL: "-target-cpu" "mips64r6" // MIPSN32R6EL: "-target-abi" "n32" // MIPSN32R6EL: "-mfloat-abi" "hard" + +// RUN: %clang --target=riscv32-unknown-elf --gcc-toolchain="" -### %s 2>&1 | FileCheck %s -check-prefix=NOUWTABLE

[clang] [libc] [llvm] [openmp] [libc] Rework the GPU build to be a regular target (PR #81921)

2024-02-19 Thread Jon Chesterfield via cfe-commits
JonChesterfield wrote: One large patch may be necessary - is it also necessary to interleave reordering files with changing the contents? It makes the GUI diff tool we're using here essentially useless. If the moving code between files and factoring into functions was a separate commit we'd

[clang] [libc] [llvm] [openmp] [libc] Rework the GPU build to be a regular target (PR #81921)

2024-02-19 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 edited https://github.com/llvm/llvm-project/pull/81921 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer] Improve handling of unsigned values in ArrayBoundCheckerV2 (PR #81034)

2024-02-19 Thread via cfe-commits
NagyDonat wrote: The main effect of this commit is that it eliminates ~300-400 ArrayBoundV2 reports. I didn't review each of them, but I checked dozens of them and those were all "Out of bound access to memory after the end of the region" false positives that tried to access something at

[clang] [libc] [llvm] [openmp] [libc] Rework the GPU build to be a regular target (PR #81921)

2024-02-19 Thread Joseph Huber via cfe-commits
@@ -50,31 +50,9 @@ function(collect_object_file_deps target result) endif() endfunction(collect_object_file_deps) -# A rule to build a library from a collection of entrypoint objects. -# Usage: -# add_entrypoint_library( -# DEPENDS -# ) -# -# NOTE: If one

[clang] [libc] [llvm] [openmp] [libc] Rework the GPU build to be a regular target (PR #81921)

2024-02-19 Thread Jon Chesterfield via cfe-commits
@@ -50,31 +50,9 @@ function(collect_object_file_deps target result) endif() endfunction(collect_object_file_deps) -# A rule to build a library from a collection of entrypoint objects. -# Usage: -# add_entrypoint_library( -# DEPENDS -# ) -# -# NOTE: If one

[clang] [ObjC] Check entire chain of superclasses to see if class layout can be statically known (PR #81335)

2024-02-19 Thread John McCall via cfe-commits
https://github.com/rjmccall commented: Thanks, the breadth of tests looks good. Please improve the actual testing, though — CHECK lines are testing the IR output file at a whole, so now that there are multiple tests in this file, we really need to make these tests more specific. - First,

[clang] [clang] [SemaCXX] Disallow deducing "this" on operator `new` and `delete` (PR #82251)

2024-02-19 Thread via cfe-commits
@@ -254,6 +254,8 @@ Bug Fixes to C++ Support Fixes (`#68490 `_) - Fix a crash when trying to call a varargs function that also has an explicit object parameter. Fixes (`#80971 ICE when explicit object parameter be a

[clang] [clang] [SemaCXX] Disallow deducing "this" on operator `new` and `delete` (PR #82251)

2024-02-19 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. LGTM modulo nit https://github.com/llvm/llvm-project/pull/82251 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] [SemaCXX] Disallow deducing "this" on operator `new` and `delete` (PR #82251)

2024-02-19 Thread via cfe-commits
https://github.com/cor3ntin edited https://github.com/llvm/llvm-project/pull/82251 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Analyzer] Support RefAllowingPartiallyDestroyed and RefPtrAllowingPartiallyDestroyed (PR #82209)

2024-02-19 Thread Ryosuke Niwa via cfe-commits
https://github.com/rniwa updated https://github.com/llvm/llvm-project/pull/82209 >From 5e365d2a873aafc17d4b03eb7fee10029ff2bea1 Mon Sep 17 00:00:00 2001 From: Ryosuke Niwa Date: Sun, 18 Feb 2024 21:47:48 -0800 Subject: [PATCH] [Analyzer] Support RefAllowingPartiallyDestroyed and

[clang] [alpha.webkit.UncountedCallArgsChecker] Allow ASSERT and atomic operations in a trivial function (PR #82063)

2024-02-19 Thread Ryosuke Niwa via cfe-commits
@@ -356,6 +364,14 @@ class TrivialFunctionAnalysisVisitor return TrivialFunctionAnalysis::isTrivialImpl(Callee, Cache); } + bool VisitCXXDefaultArgExpr(const CXXDefaultArgExpr *E) { rniwa wrote: Yeah, I'm adding more general caching mechanism for

[clang] [docs] [C++20] [Modules] Ideas for transitioning to modules (PR #80687)

2024-02-19 Thread David Blaikie via cfe-commits
https://github.com/dwblaikie approved this pull request. Seems ok https://github.com/llvm/llvm-project/pull/80687 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 22fc2cb - [clang-format] Fix AllowShortLambdasOnASingleLine interfering with lambda brace wrapping. (#81848)

2024-02-19 Thread via cfe-commits
Author: rmarker Date: 2024-02-19T14:32:06-08:00 New Revision: 22fc2cb15d9e9bfb84145c6891fb748e8e52757e URL: https://github.com/llvm/llvm-project/commit/22fc2cb15d9e9bfb84145c6891fb748e8e52757e DIFF: https://github.com/llvm/llvm-project/commit/22fc2cb15d9e9bfb84145c6891fb748e8e52757e.diff LOG:

[clang] [clang-format] Fix AllowShortLambdasOnASingleLine interfering with lambda brace wrapping. (PR #81848)

2024-02-19 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/81848 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Emit a waitcnt instruction after each memory instruction (PR #79236)

2024-02-19 Thread Jun Wang via cfe-commits
@@ -167,6 +167,10 @@ def FeatureCuMode : SubtargetFeature<"cumode", "Enable CU wavefront execution mode" >; +def FeaturePreciseMemory jwanggit86 wrote: The function `hasFlag()` actually appears to be pretty expensive, and it's going to be called every

[clang] Turn 'counted_by' into a type attribute and parse it into 'CountAttributedType' (PR #78000)

2024-02-19 Thread Yeoul Na via cfe-commits
rapidsna wrote: @AaronBallman @erichkeane gentle reminder. Does my reasoning [above](https://github.com/llvm/llvm-project/pull/78000#issuecomment-1932496432) to make a new sugar type make sense? https://github.com/llvm/llvm-project/pull/78000 ___

[clang] [llvm] [AMDGPU] Emit a waitcnt instruction after each memory instruction (PR #79236)

2024-02-19 Thread Jun Wang via cfe-commits
@@ -355,6 +356,18 @@ class SICacheControl { MachineBasicBlock::iterator ) const { return false; } + +public: + // The following is for supporting precise memory mode. When the option + // amdgpu-precise-memory is enabled, an s_waitcnt

[clang] [clang] Define SwiftInfo for RISCVTargetCodeGenInfo (PR #82152)

2024-02-19 Thread Alex Bradbury via cfe-commits
asb wrote: Yes, please add a trivial test if at all possible. https://github.com/llvm/llvm-project/pull/82152 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Define SwiftInfo for RISCVTargetCodeGenInfo (PR #82152)

2024-02-19 Thread Jon Roelofs via cfe-commits
jroelofs wrote: > Can this be tested? I don't know what the affects are. Might be as simple as adding another `RUN:` line to `clang/test/CodeGenCXX/arm-swiftcall.{c,cpp}` with a riscv triple. https://github.com/llvm/llvm-project/pull/82152 ___

[clang] [Clang] Fixes to immediate-escalating functions (PR #82281)

2024-02-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: cor3ntin (cor3ntin) Changes * Consider that immediate escalating function can appear at global scope, fixing a crash * Lambda conversion to function pointer was sometimes not performed in an immediate function context when it should be.

[clang] [Clang] Fixes to immediate-escalating functions (PR #82281)

2024-02-19 Thread via cfe-commits
https://github.com/cor3ntin created https://github.com/llvm/llvm-project/pull/82281 * Consider that immediate escalating function can appear at global scope, fixing a crash * Lambda conversion to function pointer was sometimes not performed in an immediate function context when it should be.

[clang] [clang-format] Fix RemoveSemicolon for empty functions (PR #82278)

2024-02-19 Thread Owen Pan via cfe-commits
https://github.com/owenca edited https://github.com/llvm/llvm-project/pull/82278 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Fix RemoveSemicolon for empty ctors/dtors (PR #82278)

2024-02-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Owen Pan (owenca) Changes Fixes #79833. --- Full diff: https://github.com/llvm/llvm-project/pull/82278.diff 2 Files Affected: - (modified) clang/lib/Format/Format.cpp (+16-7) - (modified) clang/unittests/Format/FormatTest.cpp

[clang] [clang-format] Fix RemoveSemicolon for empty ctors/dtors (PR #82278)

2024-02-19 Thread Owen Pan via cfe-commits
https://github.com/owenca created https://github.com/llvm/llvm-project/pull/82278 Fixes #79833. >From 4bcf6dba8b97096801be550c4a8d1626ed57e475 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Mon, 19 Feb 2024 13:11:29 -0800 Subject: [PATCH] [clang-format] Fix RemoveSemicolon for empty

[clang] [clang-tools-extra] [codegen] Emit missing cleanups when an expression contains a branch (PR #80698)

2024-02-19 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/80698 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [codegen] Emit missing cleanups when an expression contains a branch (PR #80698)

2024-02-19 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/80698 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [codegen] Emit missing cleanups when an expression contains a branch (PR #80698)

2024-02-19 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/80698 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [codegen] Emit missing cleanups when an expression contains a branch (PR #80698)

2024-02-19 Thread Utkarsh Saxena via cfe-commits
@@ -592,10 +590,14 @@ void AggExprEmitter::EmitArrayInit(Address DestPtr, llvm::ArrayType *AType, // observed to be unnecessary. if (endOfInit.isValid()) Builder.CreateStore(element, endOfInit); } - -LValue elementLV = CGF.MakeAddrLValue( -

[clang] [Clang][Sema] Convert warning for extraneous template parameter lists to an extension warning (PR #82277)

2024-02-19 Thread Krystian Stasiowski via cfe-commits
https://github.com/sdkrystian edited https://github.com/llvm/llvm-project/pull/82277 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][Sema] Convert warning for extraneous template parameter lists to an extension warning (PR #82277)

2024-02-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Krystian Stasiowski (sdkrystian) Changes We currently accept the following explicit specialization with a warning for the extraneous template parameter list: ```cpp templatetypename T void f(); template template void fint(); // warning:

[clang] [Clang][Sema] Convert warning for extraneous template parameter lists to an extension warning (PR #82277)

2024-02-19 Thread Krystian Stasiowski via cfe-commits
https://github.com/sdkrystian created https://github.com/llvm/llvm-project/pull/82277 We currently accept the following explicit specialization with a warning for the extraneous template parameter list: ```cpp template void f(); template<> template<> void f(); // warning: extraneous template

[clang] [alpha.webkit.UncountedCallArgsChecker] Ignore calls to WTF's container methods (PR #82156)

2024-02-19 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ edited https://github.com/llvm/llvm-project/pull/82156 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Emit a waitcnt instruction after each memory instruction (PR #79236)

2024-02-19 Thread Jun Wang via cfe-commits
jwanggit86 wrote: > Did you try to move this to SIInsertWaitCnt, as suggested? > Did you try to move this to SIInsertWaitCnt, as suggested? Pls see my reply on Feb 15, which is copy-pasted below. Regarding the question about SIInsertWaitcnt, initially the code was indeed put there (see PR

[clang] [polly] [clang-format] Correctly annotate block braces of empty ctors/dtors (PR #82097)

2024-02-19 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/82097 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 8de2300 - [clang-format] Correctly annotate braces of empty ctors/dtors (#82097)

2024-02-19 Thread via cfe-commits
Author: Owen Pan Date: 2024-02-19T12:41:22-08:00 New Revision: 8de230093f585b64fcd642b46e6560131e95b394 URL: https://github.com/llvm/llvm-project/commit/8de230093f585b64fcd642b46e6560131e95b394 DIFF: https://github.com/llvm/llvm-project/commit/8de230093f585b64fcd642b46e6560131e95b394.diff

[clang] [alpha.webkit.UncountedCallArgsChecker] Ignore calls to WTF's container methods (PR #82156)

2024-02-19 Thread Artem Dergachev via cfe-commits
@@ -25,6 +25,11 @@ using namespace ento; namespace { +bool stringEndsWith(const std::string , const std::string ) { + auto index = str.rfind(suffix); + return index != std::string::npos && str.size() - suffix.size() == index; +} haoNoQ wrote: Consider

[clang] [alpha.webkit.UncountedCallArgsChecker] Allow ASSERT and atomic operations in a trivial function (PR #82063)

2024-02-19 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ approved this pull request. LGTM thanks! https://github.com/llvm/llvm-project/pull/82063 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [alpha.webkit.UncountedCallArgsChecker] Allow ASSERT and atomic operations in a trivial function (PR #82063)

2024-02-19 Thread Artem Dergachev via cfe-commits
@@ -356,6 +364,14 @@ class TrivialFunctionAnalysisVisitor return TrivialFunctionAnalysis::isTrivialImpl(Callee, Cache); } + bool VisitCXXDefaultArgExpr(const CXXDefaultArgExpr *E) { haoNoQ wrote: In theory this may need to be cached because it may

[clang] [alpha.webkit.UncountedCallArgsChecker] Allow ASSERT and atomic operations in a trivial function (PR #82063)

2024-02-19 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ edited https://github.com/llvm/llvm-project/pull/82063 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [polly] [clang-format] Correctly annotate block braces of empty ctors/dtors (PR #82097)

2024-02-19 Thread via cfe-commits
https://github.com/mydeveloperday approved this pull request. https://github.com/llvm/llvm-project/pull/82097 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [ObjC] Check entire chain of superclasses to see if class layout can be statically known (PR #81335)

2024-02-19 Thread via cfe-commits
AtariDreams wrote: Ping https://github.com/llvm/llvm-project/pull/81335 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][NVPTX] Allow passing arguments to the linker while standalone (PR #73030)

2024-02-19 Thread Joseph Huber via cfe-commits
jhuber6 wrote: Ping, once https://github.com/llvm/llvm-project/pull/81921 lands this patch won't cause any issues with the `libc` build like it does currently so I'd like to land this afterwards. https://github.com/llvm/llvm-project/pull/73030 ___

[clang] [Clang][NVPTX] Allow passing arguments to the linker while standalone (PR #73030)

2024-02-19 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/73030 >From ee43e8f9ae90bcd70d46b17cfecb854711a4b1ce Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Tue, 21 Nov 2023 13:45:10 -0600 Subject: [PATCH] [Clang][NVPTX] Allow passing arguments to the linker while

[clang] [RISCV] Disable generation of asynchronous unwind tables for RISCV baremetal (PR #81727)

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

[clang] [libc] [llvm] [openmp] [libc] Rework the GPU build to be a regular target (PR #81921)

2024-02-19 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/81921 >From f3013086f60f2a78c12887cf1736455e8fb1911b Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Tue, 13 Feb 2024 21:08:02 -0600 Subject: [PATCH] [libc] Rework the GPU build to be a regular target Summary: This

[clang] [clang-tools-extra] [clangd] Use `SymbolName` to represent Objective-C selectors (PR #82061)

2024-02-19 Thread Alex Hoppen via cfe-commits
https://github.com/ahoppen updated https://github.com/llvm/llvm-project/pull/82061 >From be2388c8552ea7a4466046c4d2c9b041a5bf78f2 Mon Sep 17 00:00:00 2001 From: Alex Hoppen Date: Fri, 16 Feb 2024 14:50:25 -0800 Subject: [PATCH] [clangd] Use `SymbolName` to represent Objective-C selectors

[clang] [clang][dataflow][NFC] Add a FIXME to handling of union initialization. (PR #82239)

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

[clang] [llvm] [AMDGPU] Adding the amdgpu-num-work-groups function attribute (PR #79035)

2024-02-19 Thread Jun Wang via cfe-commits
https://github.com/jwanggit86 updated https://github.com/llvm/llvm-project/pull/79035 >From 5c088a59bd36df40bae9a3a712f3994feded359d Mon Sep 17 00:00:00 2001 From: Jun Wang Date: Mon, 22 Jan 2024 12:43:27 -0600 Subject: [PATCH 1/7] [AMDGPU] Adding the amdgpu-num-work-groups function attribute

[clang-tools-extra] c9974ae - [clangd] Do not offer extraction to variable for decl init expression (#69477)

2024-02-19 Thread via cfe-commits
Author: Christian Kandeler Date: 2024-02-19T20:00:24+01:00 New Revision: c9974ae4a0601a9e9f5842114ecd899ab9142786 URL: https://github.com/llvm/llvm-project/commit/c9974ae4a0601a9e9f5842114ecd899ab9142786 DIFF:

[clang-tools-extra] [clangd] Do not offer extraction to variable for decl init expression (PR #69477)

2024-02-19 Thread Christian Kandeler via cfe-commits
https://github.com/ckandeler closed https://github.com/llvm/llvm-project/pull/69477 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] [SemaCXX] Disallow deducing "this" on operator `new` and `delete` (PR #82251)

2024-02-19 Thread Rajveer Singh Bharadwaj via cfe-commits
https://github.com/Rajveer100 updated https://github.com/llvm/llvm-project/pull/82251 >From 8fd5e1bb55a778c778bc8829199318661e4d4573 Mon Sep 17 00:00:00 2001 From: Rajveer Date: Mon, 19 Feb 2024 19:29:48 +0530 Subject: [PATCH] [clang] [SemaCXX] Disallow deducing "this" on operator `new` and

[clang] [compiler-rt] [llvm] [clang-repl] [ORC] Add support for out-of-process execution on ELF (PR #79936)

2024-02-19 Thread via cfe-commits
jameshu15869 wrote: Hi @weliveindetail, thank you for the comments sorry about the extremely delayed response - school has been busy and I just started a new job recently, so I haven't had much time to focus on other things. I was originally thinking that a lot of the ORC runtime changes

[clang] [Clang] Unify interface for accessing template arguments as written for class/variable template specializations (PR #81642)

2024-02-19 Thread Krystian Stasiowski via cfe-commits
@@ -1792,23 +1807,11 @@ class ClassTemplateSpecializationDecl llvm::PointerUnion SpecializedTemplate; - /// Further info for explicit template specialization/instantiation. - struct ExplicitSpecializationInfo { -/// The type-as-written. -TypeSourceInfo

[clang-tools-extra] [clang-tidy] Add fix-its to `avoid-return-with-void-value` check (PR #81420)

2024-02-19 Thread Danny Mösch via cfe-commits
@@ -42,10 +43,28 @@ void AvoidReturnWithVoidValueCheck::check( const auto *VoidReturn = Result.Nodes.getNodeAs("void_return"); if (IgnoreMacros && VoidReturn->getBeginLoc().isMacroID()) return; - if (!StrictMode && !Result.Nodes.getNodeAs("compound_parent")) + const

[clang-tools-extra] [clang-tidy] Add fix-its to `avoid-return-with-void-value` check (PR #81420)

2024-02-19 Thread Danny Mösch via cfe-commits
https://github.com/SimplyDanny updated https://github.com/llvm/llvm-project/pull/81420 From 71a7da3cd7035452685ce926b49d8329fbd183fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Danny=20M=C3=B6sch?= Date: Sun, 11 Feb 2024 17:04:12 +0100 Subject: [PATCH] [clang-tidy] Add fix-its to

[clang] [Driver] Remove dead -freroll-loops flag (PR #82254)

2024-02-19 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay approved this pull request. https://github.com/llvm/llvm-project/pull/82254 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libc] [llvm] [openmp] [libc] Rework the GPU build to be a regular target (PR #81921)

2024-02-19 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/81921 >From 8727a9631480deac9d9df386ed26dfcd35914a13 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Tue, 13 Feb 2024 21:08:02 -0600 Subject: [PATCH] [libc] Rework the GPU build to be a regular target Summary: This

[clang-tools-extra] [clangd] Do not offer extraction to variable for decl init expression (PR #69477)

2024-02-19 Thread kadir çetinkaya via cfe-commits
https://github.com/kadircet approved this pull request. thanks, lgtm! https://github.com/llvm/llvm-project/pull/69477 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Do not offer extraction to variable for decl init expression (PR #69477)

2024-02-19 Thread kadir çetinkaya via cfe-commits
@@ -490,6 +491,13 @@ bool eligibleForExtraction(const SelectionTree::Node *N) { BO->getRHS() == OuterImplicit.ASTNode.get()) return false; } + if (const auto *Decl = Parent->ASTNode.get()) { +if (!Decl->isInitCapture() && kadircet wrote:

[clang] [llvm] [AMDGPU] Add an option to disable unsafe uses of atomic xor (PR #69229)

2024-02-19 Thread Pierre-Andre Saulais via cfe-commits
pasaulais wrote: Thanks for the comments @arsenm @yxsamliu @b-sumner. By approaching a similar solution, do you mean MMRAs (https://github.com/llvm/llvm-project/pull/78569) ? If so, should I rebase/adapt my patch to the MMRA PR? Or will this PR be redundant and needs closing? @yxsamliu

[clang] [clang] Preserve found-decl when constructing VarTemplateIds (PR #82265)

2024-02-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: kadir çetinkaya (kadircet) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/82265.diff 3 Files Affected: - (modified) clang/include/clang/Sema/Sema.h (+1-1) - (modified) clang/lib/Sema/SemaTemplate.cpp (+8-10) -

[clang] [clang] Preserve found-decl when constructing VarTemplateIds (PR #82265)

2024-02-19 Thread kadir çetinkaya via cfe-commits
https://github.com/kadircet created https://github.com/llvm/llvm-project/pull/82265 None From 05e1d91361b4ce4226d21b00a312eb7642057c8f Mon Sep 17 00:00:00 2001 From: Kadir Cetinkaya Date: Mon, 19 Feb 2024 17:42:34 +0100 Subject: [PATCH] [clang] Preserve found-decl when constructing

[clang-tools-extra] [clangd] Do not offer extraction to variable for decl init expression (PR #69477)

2024-02-19 Thread Christian Kandeler via cfe-commits
@@ -490,6 +491,13 @@ bool eligibleForExtraction(const SelectionTree::Node *N) { BO->getRHS() == OuterImplicit.ASTNode.get()) return false; } + if (const auto *Decl = Parent->ASTNode.get()) { +if (!Decl->isInitCapture() && ckandeler wrote:

[clang] [clang][AArch64] multilib: fix deduction of "-march=" option (PR #81474)

2024-02-19 Thread Dominik Wójt via cfe-commits
domin144 wrote: @mplatings Can you merge for me? I don't have needed rights. I rebased hoping the check will pass now, but there are still some unrelated failures on windows. https://github.com/llvm/llvm-project/pull/81474 ___ cfe-commits mailing

[clang] [clang][Interp] Handle complex values in visitBool() (PR #79452)

2024-02-19 Thread Timm Baeder via cfe-commits
@@ -2120,8 +2074,15 @@ bool ByteCodeExprGen::visitInitializer(const Expr *E) { template bool ByteCodeExprGen::visitBool(const Expr *E) { std::optional T = classify(E->getType()); - if (!T) + if (!T) { +// Convert complex values to bool. +if

[clang] [clang][Interp] Handle complex values in visitBool() (PR #79452)

2024-02-19 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr updated https://github.com/llvm/llvm-project/pull/79452 >From 720f2f869a11dd7c905f8d91180f3eb517ab9279 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Thu, 25 Jan 2024 15:20:52 +0100 Subject: [PATCH] [clang][Interp] Handle complex values in

[clang] [clang][Interp] Handle complex values in visitBool() (PR #79452)

2024-02-19 Thread Timm Baeder via cfe-commits
@@ -125,3 +125,7 @@ struct XY { int before; struct XX xx, *xp; float* after; } xy[] = { 0, // all-warning {{initializer overrides prior initialization of this subobject}} [2].xx.a, [2].xx, _float }; + +const int A = ((_Complex double)1.0 ? 21 : 1);

[clang] [clang][Interp] Handle complex values in visitBool() (PR #79452)

2024-02-19 Thread via cfe-commits
@@ -125,3 +125,7 @@ struct XY { int before; struct XX xx, *xp; float* after; } xy[] = { 0, // all-warning {{initializer overrides prior initialization of this subobject}} [2].xx.a, [2].xx, _float }; + +const int A = ((_Complex double)1.0 ? 21 : 1);

[clang] [clang][Interp] Handle complex values in visitBool() (PR #79452)

2024-02-19 Thread via cfe-commits
@@ -2120,8 +2074,15 @@ bool ByteCodeExprGen::visitInitializer(const Expr *E) { template bool ByteCodeExprGen::visitBool(const Expr *E) { std::optional T = classify(E->getType()); - if (!T) + if (!T) { +// Convert complex values to bool. +if

[clang] [clang][Interp] Handle complex values in visitBool() (PR #79452)

2024-02-19 Thread via cfe-commits
https://github.com/sethp approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/79452 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][Interp] Handle complex values in visitBool() (PR #79452)

2024-02-19 Thread via cfe-commits
https://github.com/sethp edited https://github.com/llvm/llvm-project/pull/79452 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer] UnixAPIMisuseChecker Get O_CREAT from preprocessor (PR #81855)

2024-02-19 Thread Alejandro Álvarez Ayllón via cfe-commits
alejandro-alvarez-sonarsource wrote: Thanks! I have added a new test file where the values are those of [FreeRTOS](https://www.freertos.org/Documentation/api-ref/POSIX/fcntl_8h.html) https://github.com/llvm/llvm-project/pull/81855 ___ cfe-commits

[clang] [analyzer] UnixAPIMisuseChecker Get O_CREAT from preprocessor (PR #81855)

2024-02-19 Thread Alejandro Álvarez Ayllón via cfe-commits
https://github.com/alejandro-alvarez-sonarsource updated https://github.com/llvm/llvm-project/pull/81855 From 702ab6679c3b030c42e8d18acd10f438b4880eeb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alejandro=20=C3=81lvarez=20Ayll=C3=B3n?= Date: Thu, 15 Feb 2024 13:22:40 +0100 Subject: [PATCH 1/2]

[clang] 17a1b8f - [clang][Interp] Fix `nullptr - nullptr` expressions

2024-02-19 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2024-02-19T16:30:57+01:00 New Revision: 17a1b8f8481783ca9c318db6b6133631015726e9 URL: https://github.com/llvm/llvm-project/commit/17a1b8f8481783ca9c318db6b6133631015726e9 DIFF: https://github.com/llvm/llvm-project/commit/17a1b8f8481783ca9c318db6b6133631015726e9.diff

[clang] [clang][StaticAnalyzer] Crash on loop unrolling mode (PR #82089)

2024-02-19 Thread via cfe-commits
NagyDonat wrote: That sounds reasonable. Unfortunately I don't know much about the context of this change, so let's wait for a review from @danix800 (or somebody else who's knows enough) before merging this change. Also, perhaps it would be a good idea to add a testcase (or a few of them) in

[clang] [analyzer] UnixAPIMisuseChecker Get O_CREAT from preprocessor (PR #81855)

2024-02-19 Thread Balázs Kéri via cfe-commits
https://github.com/balazske commented: Code change looks good, but I could not verify the new test. Probably it is not tested if it works with a non-usual O_CREAT value (that is parsed by the checker). https://github.com/llvm/llvm-project/pull/81855

[clang] [clang][AArch64] multilib: fix deduction of "-march=" option (PR #81474)

2024-02-19 Thread Dominik Wójt via cfe-commits
https://github.com/domin144 updated https://github.com/llvm/llvm-project/pull/81474 From 4eda12594dbc07e3d3509a309d6691dcc983e5cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dominik=20W=C3=B3jt?= Date: Mon, 12 Feb 2024 13:38:14 +0100 Subject: [PATCH 1/3] [clang][AArch64] multilib: fix deduction

[clang] [Driver] Remove dead -freroll-loops flag (PR #82254)

2024-02-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver Author: Nikita Popov (nikic) Changes Remove the `-freroll-loops` flag, which has not had any effect since the migration to the new pass manager. The underlying pass has been removed entirely in #80972 due to lack of maintenance and known

[clang] [Driver] Remove dead -freroll-loops flag (PR #82254)

2024-02-19 Thread Nikita Popov via cfe-commits
https://github.com/nikic created https://github.com/llvm/llvm-project/pull/82254 Remove the `-freroll-loops` flag, which has not had any effect since the migration to the new pass manager. The underlying pass has been removed entirely in #80972 due to lack of maintenance and known bugs. >From

[clang-tools-extra] [clangd] Do not offer extraction to variable for decl init expression (PR #69477)

2024-02-19 Thread Christian Kandeler via cfe-commits
@@ -490,6 +491,13 @@ bool eligibleForExtraction(const SelectionTree::Node *N) { BO->getRHS() == OuterImplicit.ASTNode.get()) return false; } + if (const auto *Decl = Parent->ASTNode.get()) { +if (!Decl->isInitCapture() && ckandeler wrote:

[clang] [libc] [llvm] [openmp] [libc] Rework the GPU build to be a regular target (PR #81921)

2024-02-19 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/81921 >From 85f7218baa72307699b48bffa3da4005597ec719 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Tue, 13 Feb 2024 21:08:02 -0600 Subject: [PATCH] [libc] Rework the GPU build to be a regular target Summary: This

[clang] [analyzer] Improve handling of unsigned values in ArrayBoundCheckerV2 (PR #81034)

2024-02-19 Thread via cfe-commits
NagyDonat wrote: I did an open source evaluation of this commit and there are surprisingly many changes: | Project | With this commit | Without this commit | |-|-|--| | memcached |

[clang] [clang] [SemaCXX] Disallow deducing "this" on operator `new` and `delete` (PR #82251)

2024-02-19 Thread via cfe-commits
cor3ntin wrote: This change needs a release note. Please add an entry to `clang/docs/ReleaseNotes.rst` in the section the most adapted to the change, and referencing any Github issue this change fixes. Thanks! Besides that, I think the change makes sense, thanks!

[clang] [clang] [SemaCXX] Disallow deducing "this" on operator `new` and `delete` (PR #82251)

2024-02-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Rajveer Singh Bharadwaj (Rajveer100) Changes Resolves Issue #82249 As described in the issue, any deallocation function for a `class X` is a static member (even if not explicitly declared static). --- Full diff:

[clang] [clang] [SemaCXX] Disallow deducing "this" on operator `new` and `delete` (PR #82251)

2024-02-19 Thread Rajveer Singh Bharadwaj via cfe-commits
https://github.com/Rajveer100 created https://github.com/llvm/llvm-project/pull/82251 Resolves Issue #82249 As described in the issue, any deallocation function for a `class X` is a static member (even if not explicitly declared static). >From 3ad4e85144739e16be13a4d5641b24d1a7e5b00b Mon Sep

[clang] [clang][StaticAnalyzer] Crash on loop unrolling mode (PR #82089)

2024-02-19 Thread via cfe-commits
huang-me wrote: > If I understand it correctly, your change doesn't handle declarations that > are in inner statements, e.g. the variable "x" in the following code: > > ```c++ > switch (get_value()) { > case 42: > do { > int x; > // ... > } while (running); > //... > } > ``` > >

[clang-tools-extra] [clangd] Do not offer extraction to variable for decl init expression (PR #69477)

2024-02-19 Thread kadir çetinkaya via cfe-commits
https://github.com/kadircet edited https://github.com/llvm/llvm-project/pull/69477 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Do not offer extraction to variable for decl init expression (PR #69477)

2024-02-19 Thread kadir çetinkaya via cfe-commits
@@ -490,6 +491,13 @@ bool eligibleForExtraction(const SelectionTree::Node *N) { BO->getRHS() == OuterImplicit.ASTNode.get()) return false; } + if (const auto *Decl = Parent->ASTNode.get()) { +if (!Decl->isInitCapture() && kadircet wrote:

[clang-tools-extra] [clangd] Do not offer extraction to variable for decl init expression (PR #69477)

2024-02-19 Thread Christian Kandeler via cfe-commits
@@ -490,6 +491,13 @@ bool eligibleForExtraction(const SelectionTree::Node *N) { BO->getRHS() == OuterImplicit.ASTNode.get()) return false; } + if (const auto *Decl = Parent->ASTNode.get()) { +if (!Decl->isInitCapture() && ckandeler wrote:

<    1   2   3   >