[clang-tools-extra] [clang-tidy][misleading-indentation]ignore false-positives for line started with empty macro (PR #75061)

2023-12-11 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tidy Author: Congcong Cai (HerrCai0907) Changes Fixes: #71767 --- Full diff: https://github.com/llvm/llvm-project/pull/75061.diff 4 Files Affected: - (modified) clang-tools-extra/clang-tidy/readability/MisleadingIndentationCheck.cpp (+21-3) -

[clang] [llvm] [AArch64] Correctly mark Neoverse N2 as an Armv9.0a core (PR #75055)

2023-12-11 Thread David Spickett via cfe-commits
https://github.com/DavidSpickett edited https://github.com/llvm/llvm-project/pull/75055 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[mlir] [libc] [lld] [libcxxabi] [compiler-rt] [lldb] [llvm] [clang-tools-extra] [libunwind] [libcxx] [clang] [openmp] [flang] [C23] Implement N3018: The constexpr specifier for object definitions (PR

2023-12-11 Thread Guillot Tony via cfe-commits
to268 wrote: I have found no major issues with the C23 `auto` keyword. There is a minor improvement that I've found in the test cases. Concerning N3006 (AKA: Underspecified object declarations), I haven't reviewed yet the compatibility with the `constexpr` keyword, since I haven't work much on

[llvm] [clang] [AArch64] Correctly mark Neoverse N2 as an Armv9.0a core (PR #75055)

2023-12-11 Thread Thorsten Schütt via cfe-commits
@@ -94,6 +94,11 @@ Changes to the AArch64 Backend * Added support for Cortex-A520, Cortex-A720 and Cortex-X4 CPUs. +* Neoverse-N2 was incorrectly marked as an Armv8.5a core. This has been + changed to an Armv9.0a core. However, crypto options are not enabled + by default fo

[clang] 45f3eea - Fix test rocm-detect.hip (#74872)

2023-12-11 Thread via cfe-commits
Author: Yaxun (Sam) Liu Date: 2023-12-11T10:39:48-05:00 New Revision: 45f3eea12aa6a051d12f1370fcb2e949c0d15c15 URL: https://github.com/llvm/llvm-project/commit/45f3eea12aa6a051d12f1370fcb2e949c0d15c15 DIFF: https://github.com/llvm/llvm-project/commit/45f3eea12aa6a051d12f1370fcb2e949c0d15c15.dif

[clang] Fix test rocm-detect.hip (PR #74872)

2023-12-11 Thread Yaxun Liu via cfe-commits
https://github.com/yxsamliu closed https://github.com/llvm/llvm-project/pull/74872 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AArch64] Correctly mark Neoverse N2 as an Armv9.0a core (PR #75055)

2023-12-11 Thread David Spickett via cfe-commits
@@ -94,6 +94,11 @@ Changes to the AArch64 Backend * Added support for Cortex-A520, Cortex-A720 and Cortex-X4 CPUs. +* Neoverse-N2 was incorrectly marked as an Armv8.5a core. This has been + changed to an Armv9.0a core. However, crypto options are not enabled + by default fo

[clang] 32ec462 - [clang][Interp][NFC] Handle body-less functions like implicit ones

2023-12-11 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2023-12-11T16:48:21+01:00 New Revision: 32ec462519accb92176fe87b1fc7566b02187e4b URL: https://github.com/llvm/llvm-project/commit/32ec462519accb92176fe87b1fc7566b02187e4b DIFF: https://github.com/llvm/llvm-project/commit/32ec462519accb92176fe87b1fc7566b02187e4b.diff LO

[clang] [clang-tools-extra] [clang-tidy] Improve performance of misc-const-correctness (PR #72705)

2023-12-11 Thread Congcong Cai via cfe-commits
@@ -15,6 +15,76 @@ namespace clang { using namespace ast_matchers; +static bool canResolveToExprImpl(const Expr *Node, const Expr *Target) { + + const auto IgnoreDerivedToBase = [](const Expr *E, auto Matcher) { +if (Matcher(E)) + return true; +if (const auto *Ca

[clang] [clang-tools-extra] [clang-tidy] Improve performance of misc-const-correctness (PR #72705)

2023-12-11 Thread Congcong Cai via cfe-commits
@@ -15,6 +15,76 @@ namespace clang { using namespace ast_matchers; +static bool canResolveToExprImpl(const Expr *Node, const Expr *Target) { HerrCai0907 wrote: This function is hard to understand because it used matcher style naming but logic operator style

[clang-tools-extra] [clang] [clang-tidy] Improve performance of misc-const-correctness (PR #72705)

2023-12-11 Thread Congcong Cai via cfe-commits
@@ -15,6 +15,76 @@ namespace clang { using namespace ast_matchers; +static bool canResolveToExprImpl(const Expr *Node, const Expr *Target) { + + const auto IgnoreDerivedToBase = [](const Expr *E, auto Matcher) { +if (Matcher(E)) + return true; +if (const auto *Ca

[llvm] [clang] [AArch64] Correctly mark Neoverse N2 as an Armv9.0a core (PR #75055)

2023-12-11 Thread Jonathan Thackray via cfe-commits
https://github.com/jthackray updated https://github.com/llvm/llvm-project/pull/75055 >From f04fea5a67c37a7ae33b611adb04733893563342 Mon Sep 17 00:00:00 2001 From: Jonathan Thackray Date: Mon, 11 Dec 2023 14:30:46 + Subject: [PATCH 1/2] [AArch64] Correctly mark Neoverse-N2 as an Armv9.0a cor

[clang] [Cygwin] Reduced number of inline elements of CallArgList. (PR #74977)

2023-12-11 Thread 徐持恒 Xu Chiheng via cfe-commits
xu-chiheng wrote: I have build scripts and patches at: https://github.com/xu-chiheng/Note On Mon, Dec 11, 2023 at 11:25 PM Yingchi Long ***@***.***> wrote: > When bootstrapping Clang on Cygwin, there are various weird problems. > > What are those "weired problems" > > Reducing the size of CallA

[llvm] [clang] [AArch64] Correctly mark Neoverse N2 as an Armv9.0a core (PR #75055)

2023-12-11 Thread Jonathan Thackray via cfe-commits
@@ -94,6 +94,11 @@ Changes to the AArch64 Backend * Added support for Cortex-A520, Cortex-A720 and Cortex-X4 CPUs. +* Neoverse-N2 was incorrectly marked as an Armv8.5a core. This has been + changed to an Armv9.0a core. However, crypto options are not enabled + by default fo

[llvm] [clang] [AArch64] Correctly mark Neoverse N2 as an Armv9.0a core (PR #75055)

2023-12-11 Thread David Spickett via cfe-commits
https://github.com/DavidSpickett approved this pull request. LGTM Once again clang-format rightly complaining about a lot of the surrounding code, but it would obscure the change here so you can ignore it. https://github.com/llvm/llvm-project/pull/75055

[libcxx] [libc] [clang] [mlir] [llvm] [clang-tools-extra] [libc++][span] P2821R5: span.at() (PR #74994)

2023-12-11 Thread Hristo Hristov via cfe-commits
https://github.com/H-G-Hristov updated https://github.com/llvm/llvm-project/pull/74994 >From 6e26ca239c49e1b7d9ab72217db7339e92df163f Mon Sep 17 00:00:00 2001 From: Zingam Date: Sun, 10 Dec 2023 14:16:02 +0200 Subject: [PATCH 01/11] [libc++][span] P2821R5: span.at() --- libcxx/include/span

[clang] 607f19c - [clang][Interp] Fix float->int casts overflowing (#72658)

2023-12-11 Thread via cfe-commits
Author: Timm Baeder Date: 2023-12-11T17:25:03+01:00 New Revision: 607f19cb947a25fe7ed131d983a90961f3c2541a URL: https://github.com/llvm/llvm-project/commit/607f19cb947a25fe7ed131d983a90961f3c2541a DIFF: https://github.com/llvm/llvm-project/commit/607f19cb947a25fe7ed131d983a90961f3c2541a.diff L

[clang] [clang][Interp] Fix float->int casts overflowing (PR #72658)

2023-12-11 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr closed https://github.com/llvm/llvm-project/pull/72658 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang] [clang-tools-extra] [llvm-objcopy] Add --gap-fill and --pad-to options (PR #65815)

2023-12-11 Thread via cfe-commits
https://github.com/quic-akaryaki updated https://github.com/llvm/llvm-project/pull/65815 >From 21ba98fbed6ef3b9bbbef96feb6dfeb0679f7ce8 Mon Sep 17 00:00:00 2001 From: Alexey Karyakin Date: Tue, 5 Sep 2023 15:46:34 -0700 Subject: [PATCH 1/6] [llvm-objcopy] Add --gap-fill and --pad-to options `-

[clang] [clang] Substitute alias templates from correct context (PR #75069)

2023-12-11 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon created https://github.com/llvm/llvm-project/pull/75069 Current context set to where alias was met, not where it is declared caused incorrect access check in case alias referenced private members of the parent class. This is a recommit of 6b1aa31 with a slight modi

[clang] [clang] Substitute alias templates from correct context (PR #75069)

2023-12-11 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Mariya Podchishchaeva (Fznamznon) Changes Current context set to where alias was met, not where it is declared caused incorrect access check in case alias referenced private members of the parent class. This is a recommit of 6b1aa31 with

[clang] [RISCV] Enable target attribute when invoked through clang driver (PR #74889)

2023-12-11 Thread Philip Reames via cfe-commits
preames wrote: > Related question. If there is an -mcpu on the command line and target > attribute changes the march, do we keep the original CPU in the -target-cpu > attribute or drop it. The reason for all those negative features from the > driver was to make the backend not infer any featur

[clang] 99c0a3e - [RISCV] Enable target attribute when invoked through clang driver (#74889)

2023-12-11 Thread via cfe-commits
Author: Philip Reames Date: 2023-12-11T08:55:21-08:00 New Revision: 99c0a3ea98724798361c8ef72d07d9646dcb64ee URL: https://github.com/llvm/llvm-project/commit/99c0a3ea98724798361c8ef72d07d9646dcb64ee DIFF: https://github.com/llvm/llvm-project/commit/99c0a3ea98724798361c8ef72d07d9646dcb64ee.diff

[clang] [RISCV] Enable target attribute when invoked through clang driver (PR #74889)

2023-12-11 Thread Philip Reames via cfe-commits
https://github.com/preames closed https://github.com/llvm/llvm-project/pull/74889 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 05b68d5 - [AArch64][SME2] Add PEXT, PSEL builtins for SME2 (#72827)

2023-12-11 Thread via cfe-commits
Author: Dinar Temirbulatov Date: 2023-12-11T16:58:22Z New Revision: 05b68d596047cf50f721eea1c69275f8906ba561 URL: https://github.com/llvm/llvm-project/commit/05b68d596047cf50f721eea1c69275f8906ba561 DIFF: https://github.com/llvm/llvm-project/commit/05b68d596047cf50f721eea1c69275f8906ba561.diff

[clang] [AArch64][SME2] Add PEXT, PSEL builtins for SME2 (PR #72827)

2023-12-11 Thread Dinar Temirbulatov via cfe-commits
https://github.com/dtemirbulatov closed https://github.com/llvm/llvm-project/pull/72827 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [llvm] [Clang] Generate the GEP instead of adding AST nodes (PR #73730)

2023-12-11 Thread Nick Desaulniers via cfe-commits
nickdesaulniers wrote: LGTM; but perhaps @efriedma-quic should finish off the review. https://github.com/llvm/llvm-project/pull/73730 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Cygwin] Reduced number of inline elements of CallArgList. (PR #74977)

2023-12-11 Thread Yingchi Long via cfe-commits
inclyc wrote: > I have build scripts and patches at: https://github.com/xu-chiheng/Note > […](#) > On Mon, Dec 11, 2023 at 11:25 PM Yingchi Long ***@***.***> wrote: When > bootstrapping Clang on Cygwin, there are various weird problems. What are > those "weired problems" Reducing the size of Ca

[libc] [clang-tools-extra] [llvm] [libcxx] [mlir] [clang] [libc++][span] P2821R5: span.at() (PR #74994)

2023-12-11 Thread Mark de Wever via cfe-commits
@@ -343,6 +345,15 @@ public: return __data_[__idx]; } +# if _LIBCPP_STD_VER >= 26 +_LIBCPP_HIDE_FROM_ABI constexpr reference at(size_type __index) const { + if (__index >= size()) { mordante wrote: @philnik777 requested to remove these b

[llvm] [clang] [ValueTracking] Add dominating condition support in computeKnownBits() (PR #73662)

2023-12-11 Thread via cfe-commits
yonghong-song wrote: > @yonghong-song I think it may be possible to improve CVP to handle this > better, in which case we won't need BPF workarounds. I'll look into it. @nikic and @bjope. Indeed, https://github.com/llvm/llvm-project/pull/75039 didn't resolve the issue and the generated bpf cod

[clang] [Clang][SME2] Add multi-vector unpack builtins (PR #75075)

2023-12-11 Thread Kerry McLaughlin via cfe-commits
https://github.com/kmclaughlin-arm created https://github.com/llvm/llvm-project/pull/75075 Adds the following SME2 builtins: - svunpk (x2 & x4) See https://github.com/ARM-software/acle/pull/217/files Patch by David Sherwood >From 35ea4be3c6fe26a4dd956df6717df1e6f6e4ae6d Mon Sep 17 00:00:00

[clang] [Clang][SME2] Add multi-vector unpack builtins (PR #75075)

2023-12-11 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: Kerry McLaughlin (kmclaughlin-arm) Changes Adds the following SME2 builtins: - svunpk (x2 & x4) See https://github.com/ARM-software/acle/pull/217/files Patch by David Sherwood --- Patch is 37.97 KiB, tr

[clang] [clang] Substitute alias templates from correct context (PR #75069)

2023-12-11 Thread Erich Keane via cfe-commits
erichkeane wrote: Can you point out the diff from the previous patch? https://github.com/llvm/llvm-project/pull/75069 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 Thread Gábor Spaits via cfe-commits
https://github.com/spaits created https://github.com/llvm/llvm-project/pull/75076 `PRValueHandler`'s handle function is only called from Tracker's track function. In `Tracker::track` the `ExprNode` parameter passed to `PRValueHandler::handle` is already the `ExplodedNode` for the tracked expre

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 Author: Gábor Spaits (spaits) Changes `PRValueHandler`'s handle function is only called from Tracker's track function. In `Tracker::track` the `ExprNode` parameter passed to `PRValueHandler::handle` is already the `ExplodedNode`

[clang] [llvm] [AArch64] Correctly mark Neoverse N2 as an Armv9.0a core (PR #75055)

2023-12-11 Thread Rodolfo Wottrich via cfe-commits
https://github.com/rgwott approved this pull request. Looking good. Is there a document to reference in the commit message? https://github.com/llvm/llvm-project/pull/75055 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/c

[clang] [clang][fatlto] Don't set ThinLTO module flag with FatLTO (PR #75079)

2023-12-11 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi created https://github.com/llvm/llvm-project/pull/75079 Since FatLTO now uses the UnifiedLTO pipeline, we should not set the ThinLTO module flag to true, since it may cause an assertion failure. See https://github.com/llvm/llvm-project/issues/70703 for context. >Fro

[clang] [clang][fatlto] Don't set ThinLTO module flag with FatLTO (PR #75079)

2023-12-11 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: Paul Kirth (ilovepi) Changes Since FatLTO now uses the UnifiedLTO pipeline, we should not set the ThinLTO module flag to true, since it may cause an assertion failure. See https://github.com/llvm/llvm-project/issues/70703 for cont

[clang] [clang][fatlto] Don't set ThinLTO module flag with FatLTO (PR #75079)

2023-12-11 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Paul Kirth (ilovepi) Changes Since FatLTO now uses the UnifiedLTO pipeline, we should not set the ThinLTO module flag to true, since it may cause an assertion failure. See https://github.com/llvm/llvm-project/issues/70703 for context. --

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 Thread via cfe-commits
isuckatcs wrote: If it's guaranteed that `ExprNode` is for `E`, I think it would be a good idea to assert it in the function. ```c++ assert(ExprNode->getStmtForDiagnostics() == E); ``` However I guess this assumption is made from the only currently known callsite of the function, which is: ``

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 Thread via cfe-commits
https://github.com/isuckatcs requested changes to this pull request. . https://github.com/llvm/llvm-project/pull/75076 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 Thread Gábor Spaits via cfe-commits
spaits wrote: It is a great idea to use assertions here. It is exactly the context in which they should be used. I will add that. Thank you for the review. I have also thought about a possible different caller but I think it is very unlikely. These `ExpressionHandler`s are basically visitor li

[clang] [clang][fatlto] Don't set ThinLTO module flag with FatLTO (PR #75079)

2023-12-11 Thread Teresa Johnson via cfe-commits
teresajohnson wrote: Added a comment to that issue, I think it would be good to understand why unified LTO is not expected in that case (for the assertion). https://github.com/llvm/llvm-project/pull/75079 ___ cfe-commits mailing list cfe-commits@lists

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 Thread Gábor Spaits via cfe-commits
https://github.com/spaits updated https://github.com/llvm/llvm-project/pull/75076 From f3d7181073996dd94e6d0b7ac403e9a3d97f4e0d Mon Sep 17 00:00:00 2001 From: Gabor Spaits Date: Mon, 11 Dec 2023 16:59:16 +0100 Subject: [PATCH 1/2] [Analyzer][NFC] Remove redundant function call PRValueHandler's

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 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 a4e67de96f0a9833756b6c79fff3cd6ee459fee0 d3b3bbce9ee6fa107c6bfa183dd7885f191300d6 --

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 Thread Gábor Spaits via cfe-commits
https://github.com/spaits updated https://github.com/llvm/llvm-project/pull/75076 From f3d7181073996dd94e6d0b7ac403e9a3d97f4e0d Mon Sep 17 00:00:00 2001 From: Gabor Spaits Date: Mon, 11 Dec 2023 16:59:16 +0100 Subject: [PATCH 1/2] [Analyzer][NFC] Remove redundant function call PRValueHandler's

[clang] [NFC][CLANG] Fix static analyzer bugs about large copy by values (PR #75060)

2023-12-11 Thread Gábor Horváth via cfe-commits
@@ -110,7 +110,7 @@ void ModuleDepCollector::addOutputPaths(CowCompilerInvocation &CI, } static CowCompilerInvocation -makeCommonInvocationForModuleBuild(CompilerInvocation CI) { +makeCommonInvocationForModuleBuild(const CompilerInvocation &CI) { Xazax-hun wr

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 Thread via cfe-commits
isuckatcs wrote: > I have also thought about a possible different caller but I think it is very > unlikely. These `ExpressionHandler`s are basically visitor like classes for > this tracking mechanism, if I am correct. Their purpose is to track other > values or append `BugReporterVisitor`s to

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 Thread via cfe-commits
@@ -2565,21 +2565,20 @@ class PRValueHandler final : public ExpressionHandler { using ExpressionHandler::ExpressionHandler; Tracker::Result handle(const Expr *E, const ExplodedNode *InputNode, - const ExplodedNode *ExprNode, +

[clang-tools-extra] [llvm] [openmp] [clang] [OpenMP] Add extra flags to libomptarget and plugin builds (PR #74520)

2023-12-11 Thread Johannes Doerfert via cfe-commits
https://github.com/jdoerfert updated https://github.com/llvm/llvm-project/pull/74520 >From f505868953d07125f67bcbb79be426a6deee1a13 Mon Sep 17 00:00:00 2001 From: Johannes Doerfert Date: Tue, 5 Dec 2023 12:35:04 -0800 Subject: [PATCH 1/2] [OpenMP] Add extra flags to libomptarget and plugin bui

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 Thread Gábor Spaits via cfe-commits
https://github.com/spaits updated https://github.com/llvm/llvm-project/pull/75076 From f3d7181073996dd94e6d0b7ac403e9a3d97f4e0d Mon Sep 17 00:00:00 2001 From: Gabor Spaits Date: Mon, 11 Dec 2023 16:59:16 +0100 Subject: [PATCH 1/3] [Analyzer][NFC] Remove redundant function call PRValueHandler's

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 Thread Gábor Spaits via cfe-commits
@@ -2565,21 +2565,20 @@ class PRValueHandler final : public ExpressionHandler { using ExpressionHandler::ExpressionHandler; Tracker::Result handle(const Expr *E, const ExplodedNode *InputNode, - const ExplodedNode *ExprNode, +

[clang] [NFC][CLANG] Fix static analyzer bugs about unnecessary object copies… (PR #75082)

2023-12-11 Thread via cfe-commits
https://github.com/smanna12 created https://github.com/llvm/llvm-project/pull/75082 … with auto >From 74442fc914b067ab2c2ea4f330da8dd196f0f7a7 Mon Sep 17 00:00:00 2001 From: "Manna, Soumi" Date: Mon, 11 Dec 2023 10:34:15 -0800 Subject: [PATCH] [NFC][CLANG] Fix static analyzer bugs about unnece

[clang] [NFC][CLANG] Fix static analyzer bugs about unnecessary object copies… (PR #75082)

2023-12-11 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (smanna12) Changes … with auto --- Full diff: https://github.com/llvm/llvm-project/pull/75082.diff 1 Files Affected: - (modified) clang/lib/CodeGen/BackendUtil.cpp (+1-1) ``diff diff --git a/clang/lib/CodeGen/BackendUtil

[clang] 3745f47 - Fix to msvc::no_unique_address causing assert when used with __declspec(empty_bases) (#74776)

2023-12-11 Thread via cfe-commits
Author: Amy Huang Date: 2023-12-11T10:38:46-08:00 New Revision: 3745f475875d763b65541e0bab195b0d774ff9c8 URL: https://github.com/llvm/llvm-project/commit/3745f475875d763b65541e0bab195b0d774ff9c8 DIFF: https://github.com/llvm/llvm-project/commit/3745f475875d763b65541e0bab195b0d774ff9c8.diff LOG

[clang] Fix to msvc::no_unique_address causing assert when used with __declspec(empty_bases) (PR #74776)

2023-12-11 Thread Amy Huang via cfe-commits
https://github.com/amykhuang closed https://github.com/llvm/llvm-project/pull/74776 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] [openmp] [clang] [OpenMP] Add extra flags to libomptarget and plugin builds (PR #74520)

2023-12-11 Thread Johannes Doerfert via cfe-commits
https://github.com/jdoerfert closed https://github.com/llvm/llvm-project/pull/74520 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][CLANG] Fix static analyzer bugs about unnecessary object copies… (PR #75082)

2023-12-11 Thread via cfe-commits
https://github.com/smanna12 edited https://github.com/llvm/llvm-project/pull/75082 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][CLANG] Fix static analyzer bugs about unnecessary object copies with auto keyword (PR #75082)

2023-12-11 Thread via cfe-commits
https://github.com/smanna12 edited https://github.com/llvm/llvm-project/pull/75082 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][CLANG] Fix static analyzer bugs about unnecessary object copies with auto keyword (PR #75082)

2023-12-11 Thread via cfe-commits
https://github.com/smanna12 edited https://github.com/llvm/llvm-project/pull/75082 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] [clang] [llvm-objcopy] Add --gap-fill and --pad-to options (PR #65815)

2023-12-11 Thread via cfe-commits
https://github.com/quic-akaryaki updated https://github.com/llvm/llvm-project/pull/65815 >From 21ba98fbed6ef3b9bbbef96feb6dfeb0679f7ce8 Mon Sep 17 00:00:00 2001 From: Alexey Karyakin Date: Tue, 5 Sep 2023 15:46:34 -0700 Subject: [PATCH 1/7] [llvm-objcopy] Add --gap-fill and --pad-to options `-

[clang-tools-extra] [llvm] [clang] [llvm-objcopy] Add --gap-fill and --pad-to options (PR #65815)

2023-12-11 Thread via cfe-commits
@@ -0,0 +1,198 @@ +# RUN: yaml2obj --docnum=1 %s -o %t + +# RUN: not llvm-objcopy --gap-fill 1 %t 2>&1 | FileCheck %s --check-prefix=NOT-BINARY +# NOT-BINARY: error: '--gap-fill' is only supported for binary output + +# RUN: not llvm-objcopy -O binary --gap-fill= %t %t.bin 2>&1 |

[clang-tools-extra] [llvm] [clang] [llvm-objcopy] Add --gap-fill and --pad-to options (PR #65815)

2023-12-11 Thread via cfe-commits
@@ -0,0 +1,198 @@ +# RUN: yaml2obj --docnum=1 %s -o %t + +# RUN: not llvm-objcopy --gap-fill 1 %t 2>&1 | FileCheck %s --check-prefix=NOT-BINARY +# NOT-BINARY: error: '--gap-fill' is only supported for binary output + +# RUN: not llvm-objcopy -O binary --gap-fill= %t %t.bin 2>&1 |

[clang-tools-extra] [llvm] [clang] [llvm-objcopy] Add --gap-fill and --pad-to options (PR #65815)

2023-12-11 Thread via cfe-commits
@@ -230,3 +230,15 @@ defm add_symbol defm update_section : Eq<"update-section", "Replace the contents of section with contents from a file ">, MetaVarName<"name=file">; + +defm gap_fill +: Eq<"gap-fill", "Fill the gaps between sections with instead of zero. "

[clang-tools-extra] [llvm] [clang] [llvm-objcopy] Add --gap-fill and --pad-to options (PR #65815)

2023-12-11 Thread via cfe-commits
@@ -738,6 +739,36 @@ objcopy::parseObjcopyOptions(ArrayRef RawArgsArr, if (auto Arg = InputArgs.getLastArg(OBJCOPY_extract_partition)) Config.ExtractPartition = Arg->getValue(); + if (const auto *A = InputArgs.getLastArg(OBJCOPY_gap_fill)) { +if (Config.OutputForma

[clang-tools-extra] [llvm] [clang] [llvm-objcopy] Add --gap-fill and --pad-to options (PR #65815)

2023-12-11 Thread via cfe-commits
@@ -230,3 +230,15 @@ defm add_symbol defm update_section : Eq<"update-section", "Replace the contents of section with contents from a file ">, MetaVarName<"name=file">; + +defm gap_fill +: Eq<"gap-fill", "Fill the gaps between sections with instead of zero. "

[clang-tools-extra] [llvm] [clang] [llvm-objcopy] Add --gap-fill and --pad-to options (PR #65815)

2023-12-11 Thread via cfe-commits
@@ -230,3 +230,15 @@ defm add_symbol defm update_section : Eq<"update-section", "Replace the contents of section with contents from a file ">, MetaVarName<"name=file">; + +defm gap_fill +: Eq<"gap-fill", "Fill the gaps between sections with instead of zero. "

[llvm] [clang] [AArch64] Correctly mark Neoverse N2 as an Armv9.0a core (PR #75055)

2023-12-11 Thread Jonathan Thackray via cfe-commits
jthackray wrote: > Looking good. Is there a document to reference in the commit message? Sure, I can put a link to the Technical Reference Manual https://github.com/llvm/llvm-project/pull/75055 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

[clang-tools-extra] [llvm] [clang] [llvm-objcopy] Add --gap-fill and --pad-to options (PR #65815)

2023-12-11 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 607f19cb947a25fe7ed131d983a90961f3c2541a 7670531cb21f0c3eeb3492106df72d7f7d2d6ae4 --

[clang-tools-extra] [llvm] [clang] [llvm-objcopy] Add --gap-fill and --pad-to options (PR #65815)

2023-12-11 Thread via cfe-commits
https://github.com/quic-akaryaki updated https://github.com/llvm/llvm-project/pull/65815 >From 21ba98fbed6ef3b9bbbef96feb6dfeb0679f7ce8 Mon Sep 17 00:00:00 2001 From: Alexey Karyakin Date: Tue, 5 Sep 2023 15:46:34 -0700 Subject: [PATCH 1/8] [llvm-objcopy] Add --gap-fill and --pad-to options `-

[llvm] [clang] [AArch64] Correctly mark Neoverse N2 as an Armv9.0a core (PR #75055)

2023-12-11 Thread Jonathan Thackray via cfe-commits
https://github.com/jthackray edited https://github.com/llvm/llvm-project/pull/75055 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] f576cbe - [AArch64] Correctly mark Neoverse N2 as an Armv9.0a core (#75055)

2023-12-11 Thread via cfe-commits
Author: Jonathan Thackray Date: 2023-12-11T18:52:25Z New Revision: f576cbe44eabb8a5ac0af817424a0d1e7c8fbf85 URL: https://github.com/llvm/llvm-project/commit/f576cbe44eabb8a5ac0af817424a0d1e7c8fbf85 DIFF: https://github.com/llvm/llvm-project/commit/f576cbe44eabb8a5ac0af817424a0d1e7c8fbf85.diff

[llvm] [clang] [AArch64] Correctly mark Neoverse N2 as an Armv9.0a core (PR #75055)

2023-12-11 Thread Jonathan Thackray via cfe-commits
https://github.com/jthackray closed https://github.com/llvm/llvm-project/pull/75055 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Substitute alias templates from correct context (PR #75069)

2023-12-11 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: > Can you point out the diff from the previous patch? To fix the following case: ``` // Test case that regressed with the first iteration of the fix template class SP { T* data; }; template class A { static SP foo(); }; template using TRet = SP>; template TRet A::fo

[lldb] [lld] [llvm] [libc] [libcxx] [flang] [compiler-rt] [clang-tools-extra] [clang] [GlobalISel] Add G_PREFETCH (PR #74863)

2023-12-11 Thread Stanislav Mekhanoshin via cfe-commits
@@ -1209,6 +1209,15 @@ def G_FENCE : GenericInstruction { let hasSideEffects = true; } +// Generic opcode equivalent to the llvm.prefetch intrinsic. +def G_PREFETCH : GenericInstruction { + let OutOperandList = (outs); + let InOperandList = (ins ptype0:$address, i32imm:$rw

[clang] fix issue 73559. (PR #74926)

2023-12-11 Thread via cfe-commits
@@ -2702,7 +2702,7 @@ Parser::ParseCXXClassMemberDeclaration(AccessSpecifier AS, bool MalformedTypeSpec = false; if (!TemplateInfo.Kind && Tok.isOneOf(tok::identifier, tok::coloncolon, tok::kw___super)) { -if (TryAnnotateCXXScopeToken()) +if (getLangOpts().CPl

[lldb] [llvm] [libc] [libcxx] [flang] [compiler-rt] [mlir] [clang-tools-extra] [openmp] [clang] [libc++][span] P2821R5: span.at() (PR #74994)

2023-12-11 Thread Hristo Hristov via cfe-commits
https://github.com/H-G-Hristov updated https://github.com/llvm/llvm-project/pull/74994 >From 6e26ca239c49e1b7d9ab72217db7339e92df163f Mon Sep 17 00:00:00 2001 From: Zingam Date: Sun, 10 Dec 2023 14:16:02 +0200 Subject: [PATCH 01/11] [libc++][span] P2821R5: span.at() --- libcxx/include/span

[clang] [clang][lex] Fix non-portability diagnostics with absolute path (PR #74782)

2023-12-11 Thread Jan Svoboda via cfe-commits
@@ -2466,15 +2466,21 @@ Preprocessor::ImportAction Preprocessor::HandleHeaderIncludeOrImport( // The drive letter is optional for absolute paths on Windows, but // clang currently cannot process absolute paths in #include lines that // don't have a driv

[clang] [clang-tools-extra] [llvm] [llvm-objcopy] Add --gap-fill and --pad-to options (PR #65815)

2023-12-11 Thread via cfe-commits
https://github.com/quic-akaryaki updated https://github.com/llvm/llvm-project/pull/65815 >From 21ba98fbed6ef3b9bbbef96feb6dfeb0679f7ce8 Mon Sep 17 00:00:00 2001 From: Alexey Karyakin Date: Tue, 5 Sep 2023 15:46:34 -0700 Subject: [PATCH 1/9] [llvm-objcopy] Add --gap-fill and --pad-to options `-

[clang] [HLSL] Vector standard conversions (PR #71098)

2023-12-11 Thread Chris B via cfe-commits
llvm-beanz wrote: @rjmccall & @efriedma-quic, do the CodeGen changes here look okay to you? https://github.com/llvm/llvm-project/pull/71098 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm

[clang] [clang] Substitute alias templates from correct context (PR #75069)

2023-12-11 Thread Erich Keane via cfe-commits
@@ -3990,9 +3991,16 @@ QualType Sema::CheckTemplateIdType(TemplateName Name, if (Inst.isInvalid()) return QualType(); -CanonType = SubstType(Pattern->getUnderlyingType(), - TemplateArgLists, AliasTemplate->getLocation(), -

[clang] [clang][lex] Fix non-portability diagnostics with absolute path (PR #74782)

2023-12-11 Thread Jan Svoboda via cfe-commits
@@ -2466,15 +2466,21 @@ Preprocessor::ImportAction Preprocessor::HandleHeaderIncludeOrImport( // The drive letter is optional for absolute paths on Windows, but // clang currently cannot process absolute paths in #include lines that // don't have a driv

[compiler-rt] [flang] [clang-tools-extra] [llvm] [libcxx] [clang] [mlir] [lldb] [libc] [openmp] [libc++][span] P2821R5: span.at() (PR #74994)

2023-12-11 Thread Hristo Hristov via cfe-commits
https://github.com/H-G-Hristov updated https://github.com/llvm/llvm-project/pull/74994 >From 6e26ca239c49e1b7d9ab72217db7339e92df163f Mon Sep 17 00:00:00 2001 From: Zingam Date: Sun, 10 Dec 2023 14:16:02 +0200 Subject: [PATCH 01/12] [libc++][span] P2821R5: span.at() --- libcxx/include/span

[lldb] [llvm] [libc] [libcxx] [flang] [compiler-rt] [mlir] [clang-tools-extra] [openmp] [clang] [libc++][span] P2821R5: span.at() (PR #74994)

2023-12-11 Thread Hristo Hristov via cfe-commits
@@ -343,6 +345,15 @@ public: return __data_[__idx]; } +# if _LIBCPP_STD_VER >= 26 +_LIBCPP_HIDE_FROM_ABI constexpr reference at(size_type __index) const { + if (__index >= size()) { H-G-Hristov wrote: Done! Sorry I missed that. https://

[clang] [clang-format] Fix operator overload inconsistency in `BreakAfterAttributes: Always` (PR #74943)

2023-12-11 Thread Björn Schäpers via cfe-commits
HazardyKnusperkeks wrote: I got a mail, but it seems you have deleted the comment? Is it a regression? Could you bisect it? And you don't need (for me) to comment, when you addressed a comment, just click on resolved. Would reduce the amount of mails in my inbox. ;) https://github.com/llvm/ll

[compiler-rt] [clang] [clang-tools-extra] [flang] [llvm] [Legalizer] Expand fmaximum and fminimum (PR #67301)

2023-12-11 Thread Artem Belevich via cfe-commits
Artem-B wrote: What are the next steps needed to move this patch forward? It would be great if we could land it, as we already have real-world need for lowering fminimum/fmaximum on targets that do not have native support for it. https://github.com/llvm/llvm-project/pull/67301 ___

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 Thread Balazs Benics via cfe-commits
https://github.com/steakhal commented: I would agree with @isuckatcs, and I'd be weak against this PR. Right now I don't see the benefit of asserting this. Consider downstream users that might use this reporting system and have their own trackers. (We don't at Sonar, but pretend), then they woul

[llvm] [clang] [CUDA] Add support for CUDA-12.3 and sm_90a (PR #74895)

2023-12-11 Thread Artem Belevich via cfe-commits
https://github.com/Artem-B updated https://github.com/llvm/llvm-project/pull/74895 >From eace5f13ee62c770a84cdaae441d4c1c6eeb07c2 Mon Sep 17 00:00:00 2001 From: Artem Belevich Date: Wed, 6 Dec 2023 12:11:38 -0800 Subject: [PATCH 1/3] [CUDA] Add support for CUDA-12.3 and sm_90a --- clang/docs/

[clang-tools-extra] [clang] [llvm] [AMDGPU] Use alias info to relax waitcounts for LDS DMA (PR #74537)

2023-12-11 Thread Stanislav Mekhanoshin via cfe-commits
https://github.com/rampitec updated https://github.com/llvm/llvm-project/pull/74537 >From 7e382620cdc5999c645ed0746f242595f0294c58 Mon Sep 17 00:00:00 2001 From: Stanislav Mekhanoshin Date: Mon, 4 Dec 2023 16:11:53 -0800 Subject: [PATCH 1/7] [AMDGPU] Use alias info to relax waitcounts for LDS D

[clang] [OpenMP][CodeGen] Improved codegen for combined loop directives (PR #72417)

2023-12-11 Thread via cfe-commits
@@ -7485,6 +7485,99 @@ void CodeGenModule::printPostfixForExternalizedDecl(llvm::raw_ostream &OS, } } +namespace { +/// A 'teams loop' with a nested 'loop bind(parallel)' or generic function +/// call in the associated loop-nest cannot be a 'parllel for'. +class TeamsLoopCh

[clang] [clang][lex] Fix non-portability diagnostics with absolute path (PR #74782)

2023-12-11 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 updated https://github.com/llvm/llvm-project/pull/74782 >From 6ab18edae7b86ca216848b7fcaff5e58fb3e186c Mon Sep 17 00:00:00 2001 From: Jan Svoboda Date: Thu, 7 Dec 2023 15:15:16 -0800 Subject: [PATCH 1/5] [clang][lex] Fix non-portability diagnostics with absolute

[clang] [clang-format] Fix operator overload inconsistency in `BreakAfterAttributes: Always` (PR #74943)

2023-12-11 Thread via cfe-commits
XDeme wrote: Is it not a regression, I didn't verify the path of clang-format correctly, I thought I was using clang 16.0.6, but it was using the one I built https://github.com/llvm/llvm-project/pull/74943 ___ cfe-commits mailing list cfe-commits@list

[libunwind] [libcxxabi] [libcxx] [runtimes] Don't link against compiler-rt explicitly when we use -nostdlib++ (PR #75089)

2023-12-11 Thread Louis Dionne via cfe-commits
https://github.com/ldionne created https://github.com/llvm/llvm-project/pull/75089 When we use the -nostdlib++ flag, we don't need to explicitly link against compiler-rt, since the compiler already links against it by default. This simplifies the flags that we need to use when building with Cl

[libunwind] [libcxx] [libcxxabi] [runtimes] Don't link against compiler-rt explicitly when we use -nostdlib++ (PR #75089)

2023-12-11 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-libcxxabi @llvm/pr-subscribers-libcxx Author: Louis Dionne (ldionne) Changes When we use the -nostdlib++ flag, we don't need to explicitly link against compiler-rt, since the compiler already links against it by default. This simplifies the flags that

[clang] [Analyzer][NFC] Remove redundant function call (PR #75076)

2023-12-11 Thread Gábor Spaits via cfe-commits
spaits wrote: My rationale behind this change is that, as I mentioned this class is for a very specific purpose. It is a module of sub-system, not a generic "library" class that is intended to be used from anywhere, so this class would not really make sense to be used anywhere else. If we tak

[clang] 1bbf722 - [RISCV] Use getBuiltinVectorTypeInfo to simplify code. NFC

2023-12-11 Thread Craig Topper via cfe-commits
Author: Craig Topper Date: 2023-12-11T11:58:58-08:00 New Revision: 1bbf7225c1f0dde8c59c8acfc0b54999391df184 URL: https://github.com/llvm/llvm-project/commit/1bbf7225c1f0dde8c59c8acfc0b54999391df184 DIFF: https://github.com/llvm/llvm-project/commit/1bbf7225c1f0dde8c59c8acfc0b54999391df184.diff

[clang] [NFC][Clang] Fix Static Code Analysis Concerns with copy without assign (PR #75091)

2023-12-11 Thread via cfe-commits
https://github.com/smanna12 created https://github.com/llvm/llvm-project/pull/75091 This patch adds missing assignment operator to the class which has user-defined copy constructor. >From 8772661bda9c93b8bcfeb67f236468c85d1d0253 Mon Sep 17 00:00:00 2001 From: "Manna, Soumi" Date: Mon, 11 Dec

[clang] [NFC][Clang] Fix Static Code Analysis Concerns with copy without assign (PR #75091)

2023-12-11 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (smanna12) Changes This patch adds missing assignment operator to the class which has user-defined copy constructor. --- Full diff: https://github.com/llvm/llvm-project/pull/75091.diff 1 Files Affected: - (modified) clang/utils/Ta

[clang] [llvm] [PseudoProbe] Mix and reorder block and call probe ID in lexical order (PR #75092)

2023-12-11 Thread Lei Wang via cfe-commits
https://github.com/wlei-llvm created https://github.com/llvm/llvm-project/pull/75092 Before all the call probe ids are after block ids, in this change, it mixed the call probe and block probe by reordering them in lexical(line-number) order. For example: ``` main(): BB1 if(...) BB2 foo(..)

[clang] [llvm] [PseudoProbe] Mix and reorder block and call probe ID in lexical order (PR #75092)

2023-12-11 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-llvm-transforms Author: Lei Wang (wlei-llvm) Changes Before all the call probe ids are after block ids, in this change, it mixed the call probe and block probe by reordering them in lexical(line-number) order. For example: `

<    1   2   3   4   >