[clang] 02a28ee - [Clang] Update feature test macros for Clang 18 (#78991)

2024-01-22 Thread via cfe-commits
Author: cor3ntin Date: 2024-01-22T21:19:29+01:00 New Revision: 02a28ee8d981b2a8416c50e41c74cb21e73b8340 URL: https://github.com/llvm/llvm-project/commit/02a28ee8d981b2a8416c50e41c74cb21e73b8340 DIFF: https://github.com/llvm/llvm-project/commit/02a28ee8d981b2a8416c50e41c74cb21e73b8340.diff LOG:

[clang] [Clang] Update feature test macros for Clang 18 (PR #78991)

2024-01-22 Thread via cfe-commits
https://github.com/cor3ntin closed https://github.com/llvm/llvm-project/pull/78991 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [FatLTO] output of -ffat-lto-objects -S should be assembly. (PR #79041)

2024-01-22 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi approved this pull request. Thanks for the patch. This is a great catch! https://github.com/llvm/llvm-project/pull/79041 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/

[clang] [clang-format] Limit how much work guessLanguage() can do (PR #78925)

2024-01-22 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/78925 >From 47ebe97c199ade54a9538eaed02171d78e6a5a46 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Sun, 21 Jan 2024 02:45:16 -0500 Subject: [PATCH] [clang-format] Limit how much work guessLanguage() can do

[clang] [clang-format] Limit how much work guessLanguage() can do (PR #78925)

2024-01-22 Thread Nathan Ridge via cfe-commits
@@ -243,6 +247,14 @@ void UnwrappedLineParser::parse() { Callback.consumeUnwrappedLine(Line); } Callback.finishRun(); +TotalLinesProcessed += Lines.size(); +if ((TotalLinesProcessed / 1) > LastReport) { HighCommander4 wrote: My bad, I

[clang] [Headers][X86] Add macro descriptions to bmiintrin.h (PR #79048)

2024-01-22 Thread Paul T Robinson via cfe-commits
pogo59 wrote: I note that these macros are just name substitutions, unlike the function-style macros in ia32intrin.h. I didn't change the definitions. https://github.com/llvm/llvm-project/pull/79048 ___ cfe-commits mailing list cfe-commits@lists.llvm.

[clang-tools-extra] [lld] [llvm] [compiler-rt] [clang] [libc] [libcxx] [flang] [lldb] [AMDGPU][GFX12] VOP encoding and codegen - add support for v_cvt fp8/… (PR #78414)

2024-01-22 Thread Joe Nash via cfe-commits
Mirko =?utf-8?q?Brkušanin?= , Mirko =?utf-8?q?Brkušanin?= Message-ID: In-Reply-To: @@ -305,6 +305,11 @@ class VOP3OpSel_gfx10 op, VOPProfile p> : VOP3e_gfx10 { class VOP3OpSel_gfx11_gfx12 op, VOPProfile p> : VOP3OpSel_gfx10; +class VOP3FP8OpSel_gfx11_gfx12 op, VOPProfile

[clang] [clang-format] Limit how much work guessLanguage() can do (PR #78925)

2024-01-22 Thread via cfe-commits
mydeveloperday wrote: While I get this fixes the guessLanguage limitation, if its OOM the I guess isn't it going to be OOM for any format? (as you mention above), couldn't we just use the .clang-format-ignore file to say... hey don't bother with this file, we can't do it... I feel like this w

[lld] [clang-tools-extra] [clang] [compiler-rt] [libc] [llvm] [libcxx] [flang] [mlir] [libc++][hardening] Don't trigger redundant checks in the fast mode. (PR #77176)

2024-01-22 Thread Louis Dionne via cfe-commits
https://github.com/ldionne edited https://github.com/llvm/llvm-project/pull/77176 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[lld] [flang] [compiler-rt] [clang] [libcxx] [libc] [clang-tools-extra] [mlir] [llvm] [libc++][hardening] Don't trigger redundant checks in the fast mode. (PR #77176)

2024-01-22 Thread Louis Dionne via cfe-commits
@@ -350,6 +363,9 @@ _LIBCPP_HARDENING_MODE_DEBUG #define _LIBCPP_ASSERT_PEDANTIC(expression, message) _LIBCPP_ASSUME(expression) #define _LIBCPP_ASSERT_INTERNAL(expression, message) _LIBCPP_ASSUME(expression) #define _LIBCPP_ASSERT_

[llvm] [clang] [lld] [libc] [mlir] [libcxx] [clang-tools-extra] [flang] [compiler-rt] [libc++][hardening] Don't trigger redundant checks in the fast mode. (PR #77176)

2024-01-22 Thread Louis Dionne via cfe-commits
https://github.com/ldionne approved this pull request. @philnik777 > Does this actually improve the performance anywhere? AFAICT all we gain is > avoiding the messages being generated in the binary, but I'm not convinced > that's much of a problem. e.g. in the `std::next` case, there doesn't s

[clang] [NVPTX][AMDGPU][CodeGen] Fix `local_space nullptr` handling for NVPTX and local/private `nullptr` value for AMDGPU. (PR #78759)

2024-01-22 Thread via cfe-commits
mmoadeli wrote: > It would be great to add some tests for local AS null pointers for NVPTX and > AMDGPU back-ends. They already have it [here](https://github.com/llvm/llvm-project/blob/286ac8f3ea6aec711827ccab9608b010e78b18cf/clang/test/CodeGenSYCL/amd-address-space-conversions.cpp#L24) https

[clang] [clang-format] Add options to set number of empty lines after includes (PR #78957)

2024-01-22 Thread Björn Schäpers via cfe-commits
@@ -3220,6 +3220,25 @@ the configuration (without a prefix: ``Auto``). +.. _EmptyLinesAfterIncludes: + +**EmptyLinesAfterIncludes** (``Unsigned``) :versionbadge:`clang-format 18` :ref:`¶ ` HazardyKnusperkeks wrote: Where do I have to sign up for that knowl

[clang] [clang-format] Limit how much work guessLanguage() can do (PR #78925)

2024-01-22 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > Can we write a unit test for this? I'm open to trying but there are a few open questions in my mind: * Is it fine if the failure mode of a testcase is triggering an OOM? * Triggering the problematic codepath requires a combination of a large file (thousands of lines)

[clang] [clang] Improved isSimpleTypeSpecifier (PR #79037)

2024-01-22 Thread Carl Peto via cfe-commits
carlos4242 wrote: @owenca ... is this better for you? https://github.com/llvm/llvm-project/pull/79037 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add options to set number of empty lines after includes (PR #78957)

2024-01-22 Thread Björn Schäpers via cfe-commits
@@ -4831,6 +4848,7 @@ struct FormatStyle { DerivePointerAlignment == R.DerivePointerAlignment && DisableFormat == R.DisableFormat && EmptyLineAfterAccessModifier == R.EmptyLineAfterAccessModifier && + EmptyLinesAfterIncludes == R.Empty

[clang] [clang-format] Add options to set number of empty lines after includes (PR #78957)

2024-01-22 Thread Björn Schäpers via cfe-commits
@@ -0,0 +1,159 @@ +//===--- IncludesSeparator.cpp ---*- C++ -*-===// HazardyKnusperkeks wrote: Does this have to be done in a separate pass? Couldn't it be done in the normal formatting? https://github.com/llvm/llvm-project/pull/78957 __

[clang] [Format] Fix detection of languages when reading from stdin (PR #79051)

2024-01-22 Thread Ben Hamilton via cfe-commits
https://github.com/bhamiltoncx created https://github.com/llvm/llvm-project/pull/79051 The code cleanup in #74794 accidentally broke detection of languages by reading file content from stdin, e.g. via `clang-format -dump-config - < /path/to/filename`. This PR adds unit and integration tests t

[clang-tools-extra] [llvm] [clang] [libcxx] [libc++][hardening] Categorize assertions related to strict weak ordering (PR #77405)

2024-01-22 Thread Louis Dionne via cfe-commits
https://github.com/ldionne edited https://github.com/llvm/llvm-project/pull/77405 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Format] Fix detection of languages when reading from stdin (PR #79051)

2024-01-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Ben Hamilton (Ben Gertzfield) (bhamiltoncx) Changes The code cleanup in #74794 accidentally broke detection of languages by reading file content from stdin, e.g. via `clang-format -dump-config - < /path/to/filename`. This PR adds

[clang] [clang-format][NFC] Clean up the driver and getStyle() in Format.cpp (PR #74794)

2024-01-22 Thread Ben Hamilton via cfe-commits
@@ -544,28 +544,23 @@ static void PrintVersion(raw_ostream &OS) { } // Dump the configuration. -static int dumpConfig() { - StringRef FileName; +static int dumpConfig(bool IsSTDIN) { std::unique_ptr Code; - if (FileNames.empty()) { -// We can't read the code to detect

[flang] [lldb] [libcxx] [lld] [clang-tools-extra] [clang] [llvm] [libclc] [compiler-rt] [libc] [libcxxabi] [Thumb,ELF] Fix access to dso_preemptable __stack_chk_guard with static relocation model (PR

2024-01-22 Thread Nick Desaulniers via cfe-commits
@@ -135,14 +135,14 @@ void Thumb1InstrInfo::loadRegFromStackSlot(MachineBasicBlock &MBB, void Thumb1InstrInfo::expandLoadStackGuard( MachineBasicBlock::iterator MI) const { MachineFunction &MF = *MI->getParent()->getParent(); - const TargetMachine &TM = MF.getTarget();

[clang] [Format] Fix detection of languages when reading from stdin (PR #79051)

2024-01-22 Thread Björn Schäpers via cfe-commits
@@ -547,18 +547,20 @@ static void PrintVersion(raw_ostream &OS) { // Dump the configuration. static int dumpConfig(bool IsSTDIN) { std::unique_ptr Code; - // We can't read the code to detect the language if there's no file name. - if (!IsSTDIN) { -// Read in the code in

[clang] [Format] Fix detection of languages when reading from stdin (PR #79051)

2024-01-22 Thread Björn Schäpers via cfe-commits
@@ -0,0 +1,5 @@ +// RUN: clang-format -dump-config - < %s | FileCheck %s HazardyKnusperkeks wrote: I don't think you need this, right? The unit tests does the same, or not? https://github.com/llvm/llvm-project/pull/79051 _

[clang] [clang-tools-extra] [llvm] [libcxx] [libc++][hardening] Categorize assertions related to strict weak ordering (PR #77405)

2024-01-22 Thread Louis Dionne via cfe-commits
@@ -53,10 +53,9 @@ struct __debug_less { _LIBCPP_CONSTEXPR_SINCE_CXX14 inline _LIBCPP_HIDE_FROM_ABI void __do_compare_assert(long, _LHS&, _RHS&) {} }; -// Pass the comparator by lvalue reference. Or in debug mode, using a -// debugging wrapper that stores a reference. -#if

[clang] [clang-format] Limit how much work guessLanguage() can do (PR #78925)

2024-01-22 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > couldn't we just use the .clang-format-ignore file to say... hey don't bother > with this file, we can't do it... I think that's a good solution for avoiding the OOM when actually trying to format the file, in combination with this patch for avoiding the OOM in `guessL

[clang] [Clang][Driver] Fix `--save-temps` for OpenCL AoT compilation (PR #78333)

2024-01-22 Thread Shilei Tian via cfe-commits
https://github.com/shiltian updated https://github.com/llvm/llvm-project/pull/78333 >From 2fb901b2379290b162647f0b6d152b93df1b1e7f Mon Sep 17 00:00:00 2001 From: Shilei Tian Date: Mon, 22 Jan 2024 15:39:19 -0500 Subject: [PATCH] [Clang][Driver] Fix `--save-temps` for OpenCL AoT compilation We

[clang] [Clang] Implement the 'counted_by' attribute (PR #76348)

2024-01-22 Thread Bill Wendling via cfe-commits
bwendling wrote: > @bwendling is there any plan / possibility for simple expressions (with no > side effects)? Like: > > ```c > struct libusb_bos_dev_capability_descriptor { > uint8_t bLength; > uint8_t bDescriptorType; > uint8_t bDevCapabilityType; > uint8_t dev_cap

[clang] [Format] Fix detection of languages when reading from stdin (PR #79051)

2024-01-22 Thread Ben Hamilton via cfe-commits
@@ -0,0 +1,5 @@ +// RUN: clang-format -dump-config - < %s | FileCheck %s bhamiltoncx wrote: In this case, we do want two tests (at least, we do need the integration test in `clang/test/Format/dump-config-objc-stdin.m` to reproduce the issue). The reason is, the

[clang] [Format] Fix detection of languages when reading from stdin (PR #79051)

2024-01-22 Thread via cfe-commits
https://github.com/gulfemsavrun updated https://github.com/llvm/llvm-project/pull/79051 >From 893c295ea7ff5fda9953420068fae2af7457c5c1 Mon Sep 17 00:00:00 2001 From: Ben Hamilton Date: Mon, 22 Jan 2024 11:33:18 -0700 Subject: [PATCH] [Format] Fix detection of languages when reading from stdin

[clang] [Format] Fix detection of languages when reading from stdin (PR #79051)

2024-01-22 Thread Ben Hamilton via cfe-commits
https://github.com/bhamiltoncx updated https://github.com/llvm/llvm-project/pull/79051 >From 893c295ea7ff5fda9953420068fae2af7457c5c1 Mon Sep 17 00:00:00 2001 From: Ben Hamilton Date: Mon, 22 Jan 2024 11:33:18 -0700 Subject: [PATCH] [Format] Fix detection of languages when reading from stdin -

[clang] [Format] Fix detection of languages when reading from stdin (PR #79051)

2024-01-22 Thread Ben Hamilton via cfe-commits
@@ -547,18 +547,20 @@ static void PrintVersion(raw_ostream &OS) { // Dump the configuration. static int dumpConfig(bool IsSTDIN) { std::unique_ptr Code; - // We can't read the code to detect the language if there's no file name. - if (!IsSTDIN) { -// Read in the code in

[llvm] [clang-tools-extra] [clang] [lld] [compiler-rt] [libunwind] [libcxx] [flang] [lldb] [libc] [libcxxabi] Fix a bug in implementation of Smith's algorithm used in complex div. (PR #78330)

2024-01-22 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam edited https://github.com/llvm/llvm-project/pull/78330 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 364a5b5 - Fix a bug in implementation of Smith's algorithm used in complex div. (#78330)

2024-01-22 Thread via cfe-commits
Author: Zahira Ammarguellat Date: 2024-01-22T15:50:24-05:00 New Revision: 364a5b5b850a4f3e564da4bde080567a5d1e14d2 URL: https://github.com/llvm/llvm-project/commit/364a5b5b850a4f3e564da4bde080567a5d1e14d2 DIFF: https://github.com/llvm/llvm-project/commit/364a5b5b850a4f3e564da4bde080567a5d1e14d2

[llvm] [clang-tools-extra] [clang] [lld] [compiler-rt] [libunwind] [libcxx] [flang] [lldb] [libc] [libcxxabi] Fix a bug in implementation of Smith's algorithm used in complex div. (PR #78330)

2024-01-22 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam closed https://github.com/llvm/llvm-project/pull/78330 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NVPTX][AMDGPU][CodeGen] Fix `local_space nullptr` handling for NVPTX and local/private `nullptr` value for AMDGPU. (PR #78759)

2024-01-22 Thread Artem Belevich via cfe-commits
@@ -285,6 +289,20 @@ void NVPTXTargetCodeGenInfo::addNVVMMetadata(llvm::GlobalValue *GV, bool NVPTXTargetCodeGenInfo::shouldEmitStaticExternCAliases() const { return false; } + +llvm::Constant * +NVPTXTargetCodeGenInfo::getNullPointer(const CodeGen::CodeGenModule &CGM, +

[clang-tools-extra] [clang] [clang-tidy] fix misc-const-correctnes false-positive for fold expressions (PR #78320)

2024-01-22 Thread Julian Schmidt via cfe-commits
https://github.com/5chmidti edited https://github.com/llvm/llvm-project/pull/78320 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 9f8ccf5 - [clang-tidy] fix misc-const-correctnes false-positive for fold expressions (#78320)

2024-01-22 Thread via cfe-commits
Author: Julian Schmidt Date: 2024-01-22T21:51:39+01:00 New Revision: 9f8ccf50dde17adae1368a0cf41edadc8327aaf4 URL: https://github.com/llvm/llvm-project/commit/9f8ccf50dde17adae1368a0cf41edadc8327aaf4 DIFF: https://github.com/llvm/llvm-project/commit/9f8ccf50dde17adae1368a0cf41edadc8327aaf4.diff

[clang-tools-extra] [clang] [clang-tidy] fix misc-const-correctnes false-positive for fold expressions (PR #78320)

2024-01-22 Thread Julian Schmidt via cfe-commits
https://github.com/5chmidti closed https://github.com/llvm/llvm-project/pull/78320 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NVPTX][AMDGPU][CodeGen] Fix `local_space nullptr` handling for NVPTX and local/private `nullptr` value for AMDGPU. (PR #78759)

2024-01-22 Thread Artem Belevich via cfe-commits
Artem-B wrote: > * Address space cast of nullptr in local_space into a generic_space for the > CUDA backend. I think you mean "NVPTX back-end". CUDA is a front-end entity (C++ w/ GPU extensions) https://github.com/llvm/llvm-project/pull/78759 ___ cf

[llvm] [clang-tools-extra] [clang] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-22 Thread Piotr Zegar via cfe-commits
@@ -0,0 +1,151 @@ +//===--- UseStdMinMaxCheck.cpp - clang-tidy ---===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [clang] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-22 Thread Piotr Zegar via cfe-commits
@@ -0,0 +1,151 @@ +//===--- UseStdMinMaxCheck.cpp - clang-tidy ---===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [clang] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-22 Thread Piotr Zegar via cfe-commits
@@ -0,0 +1,151 @@ +//===--- UseStdMinMaxCheck.cpp - clang-tidy ---===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[llvm] [clang] [clang-tools-extra] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-22 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL edited https://github.com/llvm/llvm-project/pull/77816 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang-tools-extra] [clang] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-22 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL approved this pull request. Except reported nits, looks fine. https://github.com/llvm/llvm-project/pull/77816 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

[clang-tools-extra] [clang] [llvm] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-22 Thread Piotr Zegar via cfe-commits
@@ -0,0 +1,151 @@ +//===--- UseStdMinMaxCheck.cpp - clang-tidy ---===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [clang] [llvm] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-22 Thread Piotr Zegar via cfe-commits
@@ -0,0 +1,151 @@ +//===--- UseStdMinMaxCheck.cpp - clang-tidy ---===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [clang] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-22 Thread Piotr Zegar via cfe-commits
@@ -0,0 +1,151 @@ +//===--- UseStdMinMaxCheck.cpp - clang-tidy ---===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[lldb] [clang-tools-extra] [libunwind] [compiler-rt] [lld] [flang] [libc] [llvm] [libclc] [libcxxabi] [libcxx] [clang] [RISCV] Support Global Dynamic TLSDESC in the RISC-V backend (PR #66915)

2024-01-22 Thread Paul Kirth via cfe-commits
ilovepi wrote: @topperc Is there anything else you think needs to be done for the code generation? https://github.com/llvm/llvm-project/pull/66915 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/

[clang] [Clang] Implement the 'counted_by' attribute (PR #76348)

2024-01-22 Thread Sean McBride via cfe-commits
seanm wrote: @bwendling thanks for your reply. No idea how representative it is of other projects, but 3 of the 6 flexible arrays in [libusb](https://github.com/libusb/libusb) structures have these kinds of non-trivial counts. The GCC folks seem to have [considered](https://gcc.gnu.org/bugzi

[libcxx] [clang-tools-extra] [clang] [llvm] [libc++][hardening] Categorize assertions related to strict weak ordering (PR #77405)

2024-01-22 Thread Konstantin Varlamov via cfe-commits
@@ -283,9 +283,20 @@ // - `_LIBCPP_ASSERT_COMPATIBLE_ALLOCATOR` -- checks any operations that exchange nodes between containers to make sure // the containers have compatible allocators. // +// - `_LIBCPP_ASSERT_ARGUMENT_WITHIN_DOMAIN` -- checks that the given argument is w

[clang] fa4780f - [OpenMP][USM] Introduces -fopenmp-force-usm flag (#76571)

2024-01-22 Thread via cfe-commits
Author: Jan Patrick Lehr Date: 2024-01-22T21:59:26+01:00 New Revision: fa4780fa6cc36188b84b2a977ac15351c39d45dd URL: https://github.com/llvm/llvm-project/commit/fa4780fa6cc36188b84b2a977ac15351c39d45dd DIFF: https://github.com/llvm/llvm-project/commit/fa4780fa6cc36188b84b2a977ac15351c39d45dd.di

[clang] [openmp] [OpenMP][USM] Introduces -fopenmp-force-usm flag (PR #76571)

2024-01-22 Thread Jan Patrick Lehr via cfe-commits
https://github.com/jplehr closed https://github.com/llvm/llvm-project/pull/76571 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add options to set number of empty lines after includes (PR #78957)

2024-01-22 Thread via cfe-commits
https://github.com/seranu edited https://github.com/llvm/llvm-project/pull/78957 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [clang][FatLTO] Avoid UnifiedLTO until it can support (PR #79061)

2024-01-22 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi created https://github.com/llvm/llvm-project/pull/79061 Currently, the UnifiedLTO pipeline seems to have trouble with several LTO features, like SplitLTO units, which means we cannot use important optimizations like Whole Program Devirtualization or security hardening

[clang] [llvm] [clang][FatLTO] Avoid UnifiedLTO until it can support (PR #79061)

2024-01-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-x86 Author: Paul Kirth (ilovepi) Changes Currently, the UnifiedLTO pipeline seems to have trouble with several LTO features, like SplitLTO units, which means we cannot use important optimizations like Whole Program Devirtualization or security ha

[llvm] [clang] [clang][FatLTO] Avoid UnifiedLTO until it can support WPD/CFI (PR #79061)

2024-01-22 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi edited https://github.com/llvm/llvm-project/pull/79061 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libcxx] [clang] [llvm] [clang-tools-extra] [libc++][hardening] Categorize assertions related to strict weak ordering (PR #77405)

2024-01-22 Thread Louis Dionne via cfe-commits
@@ -52,204 +51,234 @@ class ComparisonResults { ldionne wrote: We need to take the parts of this test that would reproduce an OOB access inside `std::sort` & friends to a new test file. And that one should be enabled whenever the valid-element-access checks

[clang] [clang-tools-extra] [libcxx] [llvm] [libc++][hardening] Categorize assertions related to strict weak ordering (PR #77405)

2024-01-22 Thread Louis Dionne via cfe-commits
@@ -360,11 +365,13 @@ _LIBCPP_HARDENING_MODE_DEBUG #define _LIBCPP_ASSERT_VALID_ELEMENT_ACCESS(expression, message) _LIBCPP_ASSERT(expression, message) #define _LIBCPP_ASSERT_NON_NULL(expression, message) _LIBCPP_ASSERT(expression, message) #de

[clang] [libcxx] [libc] [lld] [llvm] [mlir] [compiler-rt] [clang-tools-extra] [flang] [libc++][hardening] Don't trigger redundant checks in the fast mode. (PR #77176)

2024-01-22 Thread Louis Dionne via cfe-commits
https://github.com/ldionne demilestoned https://github.com/llvm/llvm-project/pull/77176 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libunwind] [libc] [libcxx] [clang-tools-extra] [lld] [lldb] [libclc] [flang] [llvm] [libcxxabi] [compiler-rt] [RISCV] Support Global Dynamic TLSDESC in the RISC-V backend (PR #66915)

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

[clang] [llvm] [RISCV] Add experimental support of Zaamo and Zalrsc (PR #78970)

2024-01-22 Thread Craig Topper via cfe-commits
https://github.com/topperc edited https://github.com/llvm/llvm-project/pull/78970 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang] [RISCV] Add experimental support of Zaamo and Zalrsc (PR #78970)

2024-01-22 Thread Craig Topper via cfe-commits
https://github.com/topperc requested changes to this pull request. https://github.com/llvm/llvm-project/pull/78970 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Add experimental support of Zaamo and Zalrsc (PR #78970)

2024-01-22 Thread Craig Topper via cfe-commits
@@ -1105,7 +1129,7 @@ def FeatureForcedAtomics : SubtargetFeature< "forced-atomics", "HasForcedAtomics", "true", "Assume that lock-free native-width atomics are available">; def HasAtomicLdSt -: Predicate<"Subtarget->hasStdExtA() || Subtarget->hasForcedAtomics()">;

[llvm] [clang] [RISCV] Add experimental support of Zaamo and Zalrsc (PR #78970)

2024-01-22 Thread Craig Topper via cfe-commits
@@ -100,6 +100,8 @@ on support follow. ``V``Supported ``Za128rs`` Supported (`See note <#riscv-profiles-extensions-note>`__) ``Za64rs`` Supported (`See note <#riscv-profiles-extensions-note>`__) + ``Zaamo``Supported --

[llvm] [clang] [RISCV] Add experimental support of Zaamo and Zalrsc (PR #78970)

2024-01-22 Thread Craig Topper via cfe-commits
@@ -0,0 +1,11 @@ +# RUN: not llvm-mc -triple riscv32 -mattr=+experimental-zaamo < %s 2>&1 | FileCheck %s topperc wrote: Is this duplicating existing A test cases? If so can we split the A extension tests into 2 files as a pre-commit and add these the new Zaamo

[clang] b83b8d3 - Reland [Clang][CMake] Support perf, LBR, and Instrument CLANG_BOLT options (#69133)

2024-01-22 Thread Amir Ayupov via cfe-commits
Author: Amir Ayupov Date: 2024-01-22T14:47:42-08:00 New Revision: b83b8d3fd17885438b0ea154e07088d877d293a8 URL: https://github.com/llvm/llvm-project/commit/b83b8d3fd17885438b0ea154e07088d877d293a8 DIFF: https://github.com/llvm/llvm-project/commit/b83b8d3fd17885438b0ea154e07088d877d293a8.diff L

[llvm] [clang] [RISCV] Add experimental support of Zaamo and Zalrsc (PR #78970)

2024-01-22 Thread Craig Topper via cfe-commits
topperc wrote: Please add "MC" to the title to distinquish from the other patch. https://github.com/llvm/llvm-project/pull/78970 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang] Arm64EC entry/exit thunks, consolidated. (PR #79067)

2024-01-22 Thread Daniel Paoliello via cfe-commits
https://github.com/dpaoliello approved this pull request. https://github.com/llvm/llvm-project/pull/79067 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Use LazyDetector for all toolchains. (PR #79073)

2024-01-22 Thread via cfe-commits
https://github.com/cooperp approved this pull request. Not code i'm familiar with, but looks like a mechanical change. LGTM https://github.com/llvm/llvm-project/pull/79073 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/

[clang] [Clang][AArch64] Define __USER_LABEL_PREFIX__ to # for ARM64EC (PR #78913)

2024-01-22 Thread Eli Friedman via cfe-commits
efriedma-quic wrote: I can sort of see how a define could be useful, but this doesn't match any existing usage of __USER_LABEL_PREFIX__ given the relevant rules. I think reusing the name is more likely to cause confusion, rather than help anyone. https://github.com/llvm/llvm-project/pull/78913

[clang-tools-extra] [llvm] [clang] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-22 Thread Félix-Antoine Constantin via cfe-commits
felix642 wrote: @11happy I've compiled your code to test it on llvm's project and clang-tidy seems to sometimes crash. Would you be able to have a look before we merge this PR ? ``` PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace. Sta

[clang] [Clang][CMake] Support perf, LBR, and Instrument CLANG_BOLT options (PR #69133)

2024-01-22 Thread Nick Desaulniers via cfe-commits
nickdesaulniers wrote: I think the libc buildbots are now failing as a result of this change. @aaupov can you PTAL? - https://lab.llvm.org/buildbot/#/builders/223/builds/34823 - https://lab.llvm.org/buildbot/#/builders/225/builds/29950 https://github.com/llvm/llvm-project/pull/69133 __

[clang-tools-extra] [clang-tidy] Ignore user-defined literals in google-runtime-int (PR #78859)

2024-01-22 Thread Félix-Antoine Constantin via cfe-commits
felix642 wrote: @PiotrZSL would you be able to commit those changes for me please ? https://github.com/llvm/llvm-project/pull/78859 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 6953b36 - Revert "Reland [Clang][CMake] Support perf, LBR, and Instrument CLANG_BOLT options (#69133)"

2024-01-22 Thread Amir Ayupov via cfe-commits
Author: Amir Ayupov Date: 2024-01-22T14:56:43-08:00 New Revision: 6953b367027e4234607a6718a0a1d57eb52ef57e URL: https://github.com/llvm/llvm-project/commit/6953b367027e4234607a6718a0a1d57eb52ef57e DIFF: https://github.com/llvm/llvm-project/commit/6953b367027e4234607a6718a0a1d57eb52ef57e.diff L

[clang] [Clang][CMake] Support perf, LBR, and Instrument CLANG_BOLT options (PR #69133)

2024-01-22 Thread Amir Ayupov via cfe-commits
aaupov wrote: Reverted. Strangely I couldn't repro from https://lab.llvm.org/buildbot/#/builders/225/builds/29950/ the failure locally. But will get to the bottom of it. https://github.com/llvm/llvm-project/pull/69133 ___ cfe-commits mailing list cfe

[clang-tools-extra] [clangd] Make sure ninja can clean "ClangdXPC.framework" (PR #75669)

2024-01-22 Thread via cfe-commits
https://github.com/jkorous-apple approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/75669 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [WIP] Correct lowering of `fp128` intrinsics (PR #76558)

2024-01-22 Thread Eli Friedman via cfe-commits
efriedma-quic wrote: Putting a function in TargetMachine seems reasonable. https://github.com/llvm/llvm-project/pull/76558 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [-Wunsafe-buffer-usage] Add a new warning for uses of std::span two-parameter constructors (PR #77148)

2024-01-22 Thread Ziqing Luo via cfe-commits
https://github.com/ziqingluo-90 updated https://github.com/llvm/llvm-project/pull/77148 >From 6ba957670ca593094b4545c35801585da2ee02a8 Mon Sep 17 00:00:00 2001 From: ziqingluo-90 Date: Fri, 5 Jan 2024 13:39:39 -0800 Subject: [PATCH 1/2] [-Wunsafe-buffer-usage] Add a new warning for use of two-

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

2024-01-22 Thread Yeoul Na via cfe-commits
https://github.com/rapidsna updated https://github.com/llvm/llvm-project/pull/78000 >From 1a17c254ddf09cd4faf5217b2f72da3f44622f8a 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 CountAttributedType

[clang-tools-extra] [libclc] [compiler-rt] [lldb] [libcxxabi] [libunwind] [llvm] [libcxx] [lld] [flang] [libc] [clang] [RISCV] Support Global Dynamic TLSDESC in the RISC-V backend (PR #66915)

2024-01-22 Thread Fangrui Song via cfe-commits
@@ -89,8 +89,8 @@ RISCVTargetLowering::RISCVTargetLowering(const TargetMachine &TM, if ((ABI == RISCVABI::ABI_ILP32F || ABI == RISCVABI::ABI_LP64F) && !Subtarget.hasStdExtF()) { errs() << "Hard-float 'f' ABI can't be used for a target that " -"doesn

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

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

[clang] 907f2a0 - [HIP][Driver] Automatically include `hipstdpar` forwarding header (#78915)

2024-01-22 Thread via cfe-commits
Author: Alex Voicu Date: 2024-01-23T00:55:59Z New Revision: 907f2a0927d94d72d59f27e411c595b95aa673e9 URL: https://github.com/llvm/llvm-project/commit/907f2a0927d94d72d59f27e411c595b95aa673e9 DIFF: https://github.com/llvm/llvm-project/commit/907f2a0927d94d72d59f27e411c595b95aa673e9.diff LOG: [H

[clang] [HIP][Driver] Automatically include `hipstdpar` forwarding header (PR #78915)

2024-01-22 Thread Alex Voicu via cfe-commits
https://github.com/AlexVlx closed https://github.com/llvm/llvm-project/pull/78915 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][AST] fix crash in mangle lambda expression (PR #78896)

2024-01-22 Thread Qizhi Hu via cfe-commits
@@ -0,0 +1,4 @@ +// RUN: %clang_cc1 -fsyntax-only -std=c++20 -verify %s jcsxky wrote: Sorry, I am afraid that I misunderstand root cause of this issue and still need more working on it. https://github.com/llvm/llvm-project/pull/78896 ___

[clang] [compiler-rt] [NFC] Size and element numbers are often swapped when calling calloc (PR #79081)

2024-01-22 Thread via cfe-commits
https://github.com/AtariDreams created https://github.com/llvm/llvm-project/pull/79081 gcc-14 will now throw a warning if size and elements are swapped. >From 104cef5e78448fd0a15a077f4cc1b9be9f340aad Mon Sep 17 00:00:00 2001 From: Rose <83477269+ataridre...@users.noreply.github.com> Date: Fri,

[clang] [compiler-rt] [NFC] Size and element numbers are often swapped when calling calloc (PR #79081)

2024-01-22 Thread via cfe-commits
https://github.com/AtariDreams updated https://github.com/llvm/llvm-project/pull/79081 >From bda35bd77adc4b137a8e9c8dab1f58f233db6c7c Mon Sep 17 00:00:00 2001 From: Rose <83477269+ataridre...@users.noreply.github.com> Date: Fri, 21 Apr 2023 16:57:10 -0400 Subject: [PATCH] Size and element number

[clang] [compiler-rt] [NFC] Size and element numbers are often swapped when calling calloc (PR #79081)

2024-01-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-pgo Author: AtariDreams (AtariDreams) Changes gcc-14 will now throw a warning if size and elements are swapped. --- Full diff: https://github.com/llvm/llvm-project/pull/79081.diff 5 Files Affected: - (modified) clang/test/A

[clang] [compiler-rt] [NFC] Size and element numbers are often swapped when calling calloc (PR #79081)

2024-01-22 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 d4933b3241f463871cae55bbeec8563e7ffe03a2 bda35bd77adc4b137a8e9c8dab1f58f233db6c7c --

[compiler-rt] [clang] [NFC] Size and element numbers are often swapped when calling calloc (PR #79081)

2024-01-22 Thread Florian Mayer via cfe-commits
https://github.com/fmayer approved this pull request. https://github.com/llvm/llvm-project/pull/79081 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[compiler-rt] [clang] [NFC] Size and element numbers are often swapped when calling calloc (PR #79081)

2024-01-22 Thread via cfe-commits
https://github.com/AtariDreams updated https://github.com/llvm/llvm-project/pull/79081 >From e10238c4801df03f869db835eac160f5cff66937 Mon Sep 17 00:00:00 2001 From: Rose <83477269+ataridre...@users.noreply.github.com> Date: Fri, 21 Apr 2023 16:57:10 -0400 Subject: [PATCH] Size and element number

[clang-tools-extra] [libc] [lldb] [compiler-rt] [flang] [libcxxabi] [llvm] [lld] [libcxx] [mlir] [clang] [libc++] Fix the behavior of throwing `operator new` under -fno-exceptions (PR #69498)

2024-01-22 Thread Louis Dionne via cfe-commits
https://github.com/ldionne updated https://github.com/llvm/llvm-project/pull/69498 >From 6f89b118ed56ad7a3af1996e19ccd30cc893c51e Mon Sep 17 00:00:00 2001 From: Louis Dionne Date: Wed, 14 Jun 2023 17:49:22 -0700 Subject: [PATCH 01/11] [libc++] Fix the behavior of throwing `operator new` under

[clang] [Clang][RISCV][RVV Intrinsic] Fix codegen redundant intrinsic names (PR #77889)

2024-01-22 Thread Brandon Wu via cfe-commits
4vtomat wrote: Since it only reduces about 160 of 54100 intrinsics generated, I have no opinion on this, just left the final decision to others~ But if this PR is finally decided to be merged, please add some comments around the code you added to explain, thanks! https://github.com/llvm/llvm-p

[clang] [compiler-rt] [NFC] Size and element numbers are often swapped when calling calloc (PR #79081)

2024-01-22 Thread via cfe-commits
https://github.com/AtariDreams updated https://github.com/llvm/llvm-project/pull/79081 >From 1155a5d6cc94a9c0b923487d7653be0cd0484d2d Mon Sep 17 00:00:00 2001 From: Rose <83477269+ataridre...@users.noreply.github.com> Date: Fri, 21 Apr 2023 16:57:10 -0400 Subject: [PATCH] [NFC] Size and element

[mlir] [clang-tools-extra] [llvm] [mlir][ArithToAMDGPU] Add option for saturating truncation to fp8 (PR #74153)

2024-01-22 Thread Jakub Kuderski via cfe-commits
https://github.com/kuhar approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/74153 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 3b171cb - [clang-format] Fix a bug in ContinuationIndenter (#78921)

2024-01-22 Thread via cfe-commits
Author: Owen Pan Date: 2024-01-22T18:59:08-08:00 New Revision: 3b171cb968b3f8495b096139fc57ff6263727e40 URL: https://github.com/llvm/llvm-project/commit/3b171cb968b3f8495b096139fc57ff6263727e40 DIFF: https://github.com/llvm/llvm-project/commit/3b171cb968b3f8495b096139fc57ff6263727e40.diff LOG:

[clang] [clang-format] Fix a bug in ContinuationIndenter (PR #78921)

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

[clang] [Headers][X86] Add macro descriptions to bmiintrin.h (PR #79048)

2024-01-22 Thread Phoebe Wang via cfe-commits
https://github.com/phoebewang approved this pull request. LGTM. https://github.com/llvm/llvm-project/pull/79048 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format]: Fix formatting of if statements with BlockIndent (PR #77699)

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

[clang] 4ef646e - [clang-format]: Fix formatting of if statements with BlockIndent (#77699)

2024-01-22 Thread via cfe-commits
Author: Gedare Bloom Date: 2024-01-22T19:01:16-08:00 New Revision: 4ef646eab3023b52ce8ee529d16605c92caba8ba URL: https://github.com/llvm/llvm-project/commit/4ef646eab3023b52ce8ee529d16605c92caba8ba DIFF: https://github.com/llvm/llvm-project/commit/4ef646eab3023b52ce8ee529d16605c92caba8ba.diff

<    1   2   3   4   5   6   7   >