[clang] Fix Typo on cindex.py (PR #92945)

2024-05-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Thomas Applencourt (TApplencourt) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/92945.diff 1 Files Affected: - (modified) clang/bindings/python/clang/cindex.py (+2-2) ``diff diff --git a/clang/bindings/pyt

[clang] [clang] Fix Typo on cindex.py (PR #92945)

2024-05-21 Thread Thomas Applencourt via cfe-commits
https://github.com/TApplencourt edited https://github.com/llvm/llvm-project/pull/92945 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix Typo on cindex.py (PR #92945)

2024-05-21 Thread via cfe-commits
github-actions[bot] wrote: ⚠️ We detected that you are using a GitHub private e-mail address to contribute to the repo. Please turn off [Keep my email addresses private](https://github.com/settings/emails) setting in your account. See [LLVM Discourse](https://discourse.llvm.org/t/hidden-email

[clang] [clang-repl] Lay the foundation of pretty printing for C. (PR #89811)

2024-05-21 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. LGTM, feel free to apply my suggestion if you like it. https://github.com/llvm/llvm-project/pull/89811 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/ma

[clang] [clang-repl] Lay the foundation of pretty printing for C. (PR #89811)

2024-05-21 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman edited https://github.com/llvm/llvm-project/pull/89811 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-repl] Lay the foundation of pretty printing for C. (PR #89811)

2024-05-21 Thread Aaron Ballman via cfe-commits
@@ -269,7 +267,10 @@ const char *const Runtimes = R"( void __clang_Interpreter_SetValueCopyArr(const T (*Src)[N], void* Placement, unsigned long Size) { __clang_Interpreter_SetValueCopyArr(Src[0], Placement, Size); } +extern "C" AaronBallman

[clang] [clang-repl] Lay the foundation of pretty printing for C. (PR #89811)

2024-05-21 Thread Vassil Vassilev via cfe-commits
https://github.com/vgvassilev updated https://github.com/llvm/llvm-project/pull/89811 >From 0ff8aca868bfd78d4bcfd31f299e253e83c150a2 Mon Sep 17 00:00:00 2001 From: Vassil Vassilev Date: Tue, 23 Apr 2024 19:33:00 + Subject: [PATCH] [clang-repl] Lay the foundation of pretty printing for C. -

[clang] [clang-repl] Lay the foundation of pretty printing for C. (PR #89811)

2024-05-21 Thread Vassil Vassilev via cfe-commits
@@ -269,7 +267,10 @@ const char *const Runtimes = R"( void __clang_Interpreter_SetValueCopyArr(const T (*Src)[N], void* Placement, unsigned long Size) { __clang_Interpreter_SetValueCopyArr(Src[0], Placement, Size); } +extern "C" vgvassilev wr

[clang] [clang-repl] Lay the foundation of pretty printing for C. (PR #89811)

2024-05-21 Thread Vassil Vassilev via cfe-commits
vgvassilev wrote: > LGTM, feel free to apply my suggestion if you like it. Applied it. Thanks for the review this unblock whole bunch of work for us.. https://github.com/llvm/llvm-project/pull/89811 ___ cfe-commits mailing list cfe-commits@lists.llvm.

[clang] [Clang][AArch64][SVE] Allow write to SVE vector elements using the subscript operator (PR #91965)

2024-05-21 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/91965 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Throw error when calling atomic with pointer to zero size object (PR #91057)

2024-05-21 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman edited https://github.com/llvm/llvm-project/pull/91057 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Throw error when calling atomic with pointer to zero size object (PR #91057)

2024-05-21 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman commented: Thank you for the fix! Please be sure to add a release note to clang/docs/ReleaseNotes.rst so users know about the improved behavior. https://github.com/llvm/llvm-project/pull/91057 ___ cfe-commits mailing li

[clang] [Clang] Throw error when calling atomic with pointer to zero size object (PR #91057)

2024-05-21 Thread Aaron Ballman via cfe-commits
@@ -330,6 +330,9 @@ def warn_atomic_op_misaligned : Warning< "; the expected alignment (%0 bytes) exceeds the actual alignment (%1 bytes)">, InGroup; +def err_atomic_op_size_zero : Error< AaronBallman wrote: Rather than introduce a new diagnostic, I thin

[clang] [Clang] Throw error when calling atomic with pointer to zero size object (PR #91057)

2024-05-21 Thread Aaron Ballman via cfe-commits
@@ -8544,6 +8546,13 @@ ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, } } + // pointer to object of size zero is not allowed AaronBallman wrote: ```suggestion // Pointer to object of size zero is not allowed. ``` htt

[clang] [Clang] Throw error when calling atomic with pointer to zero size object (PR #91057)

2024-05-21 Thread Aaron Ballman via cfe-commits
@@ -8497,7 +8498,8 @@ ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, << 0 << AdjustedNumArgs << static_cast(Args.size()) << /*is non object*/ 0 << ExprRange; return ExprError(); - } else if (Args.size() > AdjustedNumArgs) {

[clang] [llvm] [IR] Avoid creating icmp/fcmp constant expressions (PR #92885)

2024-05-21 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/92885 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix PS "selective" DLL import/export of vtable & typeinfo (PR #92579)

2024-05-21 Thread Eli Friedman via cfe-commits
@@ -1793,6 +1793,37 @@ void ItaniumCXXABI::EmitDestructorCall(CodeGenFunction &CGF, ThisTy, VTT, VTTTy, nullptr); } +// Check if any non-inline method has the specified attribute. +template +static bool CXXRecordNonInlineHasAttr(const CXXRecordDec

[clang-tools-extra] [clang-tidy] Optimize realpath in readability-identifier-naming (PR #92659)

2024-05-21 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL updated https://github.com/llvm/llvm-project/pull/92659 >From a2ae273d083f451f44a41bd928c42a5bbdd946ae Mon Sep 17 00:00:00 2001 From: Piotr Zegar Date: Tue, 21 May 2024 17:36:08 + Subject: [PATCH] [clang-tidy] Optimize readability-identifier-naming - Reduce disk

[clang-tools-extra] [clang-tidy] Optimize realpath in readability-identifier-naming (PR #92659)

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

[clang] ce1d28e - Fix diagnostic wording style; NFC

2024-05-21 Thread Aaron Ballman via cfe-commits
Author: Aaron Ballman Date: 2024-05-21T14:47:15-04:00 New Revision: ce1d28e645b53ba9518d295dad35a4578dd8e8dc URL: https://github.com/llvm/llvm-project/commit/ce1d28e645b53ba9518d295dad35a4578dd8e8dc DIFF: https://github.com/llvm/llvm-project/commit/ce1d28e645b53ba9518d295dad35a4578dd8e8dc.diff

[clang-tools-extra] [clang-tidy] Correcting issues in `readability-implicit-bool-conversion` on C23 (PR #92241)

2024-05-21 Thread Piotr Zegar via cfe-commits
=?utf-8?q?Björn?= Svensson , =?utf-8?q?Björn?= Svensson , =?utf-8?q?Björn?= Svensson Message-ID: In-Reply-To: https://github.com/PiotrZSL edited https://github.com/llvm/llvm-project/pull/92241 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

[clang-tools-extra] [clang-tidy] Correcting issues in `readability-implicit-bool-conversion` on C23 (PR #92241)

2024-05-21 Thread Piotr Zegar via cfe-commits
=?utf-8?q?Bj=C3=B6rn?= Svensson , =?utf-8?q?Bj=C3=B6rn?= Svensson , =?utf-8?q?Bj=C3=B6rn?= Svensson Message-ID: In-Reply-To: https://github.com/PiotrZSL approved this pull request. LGTM, just nits https://github.com/llvm/llvm-project/pull/92241 ___

[clang-tools-extra] [clang-tidy] Correcting issues in `readability-implicit-bool-conversion` on C23 (PR #92241)

2024-05-21 Thread Piotr Zegar via cfe-commits
=?utf-8?q?Björn?= Svensson , =?utf-8?q?Björn?= Svensson , =?utf-8?q?Björn?= Svensson Message-ID: In-Reply-To: @@ -267,6 +275,10 @@ void ImplicitBoolConversionCheck::registerMatchers(MatchFinder *Finder) { auto BoolXor = binaryOperator(hasOperatorName("^"), hasLHS(Imp

[clang] [lldb] [llvm] Remove some `try_compile` CMake checks for compiler flags (PR #92953)

2024-05-21 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll created https://github.com/llvm/llvm-project/pull/92953 This patch remove 36 checks for compiler flags that are done via invoking the compiler across LLVM, Clang, and LLDB. It's was made possible by raising the bar for supported compilers that has been happening over

[clang] 67ae86d - [clang] Fix crash passing function pointer without prototype. (#90255)

2024-05-21 Thread via cfe-commits
Author: lolloz98 Date: 2024-05-21T11:51:21-07:00 New Revision: 67ae86d700b899979db39883f4063257513498d5 URL: https://github.com/llvm/llvm-project/commit/67ae86d700b899979db39883f4063257513498d5 DIFF: https://github.com/llvm/llvm-project/commit/67ae86d700b899979db39883f4063257513498d5.diff LOG:

[clang] [clang] solve crash due to function overloading. (PR #90255)

2024-05-21 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic closed https://github.com/llvm/llvm-project/pull/90255 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [llvm] Remove some `try_compile` CMake checks for compiler flags (PR #92953)

2024-05-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-lldb @llvm/pr-subscribers-clang Author: Vlad Serebrennikov (Endilll) Changes This patch remove 36 checks for compiler flags that are done via invoking the compiler across LLVM, Clang, and LLDB. It's was made possible by raising the bar for supported co

[clang] [clang] solve crash due to function overloading. (PR #90255)

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

[clang-tools-extra] e67f2cc - [clang-tidy] Rename out-of-line function definitions (#91954)

2024-05-21 Thread via cfe-commits
Author: Edwin Vane Date: 2024-05-21T20:51:50+02:00 New Revision: e67f2cc3fc38cec2041cfb197ac4688ed3d16e7e URL: https://github.com/llvm/llvm-project/commit/e67f2cc3fc38cec2041cfb197ac4688ed3d16e7e DIFF: https://github.com/llvm/llvm-project/commit/e67f2cc3fc38cec2041cfb197ac4688ed3d16e7e.diff LO

[clang-tools-extra] [clang-tidy] Rename out-of-line function definitions (PR #91954)

2024-05-21 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL closed https://github.com/llvm/llvm-project/pull/91954 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [llvm] Remove some `try_compile` CMake checks for compiler flags (PR #92953)

2024-05-21 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: On my setup, this patch improves CMake configuration times (from a clean state) from 51 seconds down to 46 seconds (average of 3 measurements). My setup: ancient x86 hardware, Debian Sid, nightly Clang, build directory on a RAM disk. CMake invocation: `cmake -DLLVM_ENABLE_PROJEC

[clang] [llvm] [ARM] Save floating point registers and status registers with save_fp function attribute (PR #89654)

2024-05-21 Thread Benson Chu via cfe-commits
pestctrl wrote: ping! https://github.com/llvm/llvm-project/pull/89654 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [llvm] Remove some `try_compile` CMake checks for compiler flags (PR #92953)

2024-05-21 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: Here are CE links with the set of minimum required compilers that should cover almost all the changes I made: https://godbolt.org/z/j98xzhrGa https://godbolt.org/z/errv4WhfP https://godbolt.org/z/vnoh8YqEP Windows-targeted flags were tested both on MSVC on CE, and on clang-cl 5.0

[clang-tools-extra] [clang-tidy] new check misc-use-internal-linkage (PR #90830)

2024-05-21 Thread Piotr Zegar via cfe-commits
@@ -0,0 +1,78 @@ +//===--- UseInternalLinkageCheck.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: Apa

[libcxxabi] [libunwind] [WebAssembly] __USING_WASM_EXCEPTIONS__ -> __WASM_EXCEPTIONS__ (PR #92840)

2024-05-21 Thread Heejin Ahn via cfe-commits
aheejin wrote: It is hard to fix the clang-format errors because the modified files generally don't conform to the clang-format style anyway, so clang-format my change currently affects hundreds of unrelated lines. ```console aheejin@aheejin:~/llvm-project/libunwind$ git clang-format main chang

[clang] [lldb] [llvm] Remove some `try_compile` CMake checks for compiler flags (PR #92953)

2024-05-21 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay approved this pull request. Great 👍 https://github.com/llvm/llvm-project/pull/92953 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix PS "selective" DLL import/export of vtable & typeinfo (PR #92579)

2024-05-21 Thread Andrew Ng via cfe-commits
@@ -1793,6 +1793,37 @@ void ItaniumCXXABI::EmitDestructorCall(CodeGenFunction &CGF, ThisTy, VTT, VTTTy, nullptr); } +// Check if any non-inline method has the specified attribute. +template +static bool CXXRecordNonInlineHasAttr(const CXXRecordDec

[clang] 01c600d - Reword a diagnostic for style; NFC

2024-05-21 Thread Aaron Ballman via cfe-commits
Author: Aaron Ballman Date: 2024-05-21T15:01:13-04:00 New Revision: 01c600dec6f506ae305abf04cf955e08aa59b234 URL: https://github.com/llvm/llvm-project/commit/01c600dec6f506ae305abf04cf955e08aa59b234 DIFF: https://github.com/llvm/llvm-project/commit/01c600dec6f506ae305abf04cf955e08aa59b234.diff

[clang] 32cf7a2 - Fix another diagnostic for style; NFC

2024-05-21 Thread Aaron Ballman via cfe-commits
Author: Aaron Ballman Date: 2024-05-21T15:03:26-04:00 New Revision: 32cf7a25f2f8174bc448ae7032e419dc0375fd6a URL: https://github.com/llvm/llvm-project/commit/32cf7a25f2f8174bc448ae7032e419dc0375fd6a DIFF: https://github.com/llvm/llvm-project/commit/32cf7a25f2f8174bc448ae7032e419dc0375fd6a.diff

[clang] [clang-format] Add SpacesInParensOption for filtering repeated parens (PR #77522)

2024-05-21 Thread Björn Schäpers via cfe-commits
@@ -4644,22 +4644,36 @@ struct FormatStyle { /// # Should be declared this way: /// SpacesInParens: Custom /// SpacesInParensOptions: + /// ExceptDoubleParentheses: false /// InConditionalStatements: true /// Other: true /// \endcode struct

[clang] [clang-format]: Annotate colons found in inline assembly (PR #92617)

2024-05-21 Thread Björn Schäpers via cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request. https://github.com/llvm/llvm-project/pull/92617 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] wip: Move instrumentation passes (PR #92171)

2024-05-21 Thread Egor Pasko via cfe-commits
https://github.com/pasko updated https://github.com/llvm/llvm-project/pull/92171 >From df3f8dfc47cd8d7b220ed712dc7c2cab1c563f50 Mon Sep 17 00:00:00 2001 From: Egor Pasko Date: Mon, 6 May 2024 19:48:59 +0200 Subject: [PATCH 1/4] wip: Move instrumentation passes This change is not ready for landi

[clang] [clang] Fix PS "selective" DLL import/export of vtable & typeinfo (PR #92579)

2024-05-21 Thread Eli Friedman via cfe-commits
@@ -1793,6 +1793,37 @@ void ItaniumCXXABI::EmitDestructorCall(CodeGenFunction &CGF, ThisTy, VTT, VTTTy, nullptr); } +// Check if any non-inline method has the specified attribute. +template +static bool CXXRecordNonInlineHasAttr(const CXXRecordDec

[clang] [clang] Fix PS "selective" DLL import/export of vtable & typeinfo (PR #92579)

2024-05-21 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic edited https://github.com/llvm/llvm-project/pull/92579 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 87a6865 - Fix another diagnostic wording for style; NFC

2024-05-21 Thread Aaron Ballman via cfe-commits
Author: Aaron Ballman Date: 2024-05-21T15:14:03-04:00 New Revision: 87a6865d2c8eba802a7e9f42fa8b6ac1edd0664e URL: https://github.com/llvm/llvm-project/commit/87a6865d2c8eba802a7e9f42fa8b6ac1edd0664e DIFF: https://github.com/llvm/llvm-project/commit/87a6865d2c8eba802a7e9f42fa8b6ac1edd0664e.diff

[clang] [llvm] [openmp] [PGO][OpenMP] Instrumentation for GPU devices (PR #76587)

2024-05-21 Thread Ethan Luis McDonough via cfe-commits
https://github.com/EthanLuisMcDonough updated https://github.com/llvm/llvm-project/pull/76587 >From 530eb982b9770190377bb0bd09c5cb715f34d484 Mon Sep 17 00:00:00 2001 From: Ethan Luis McDonough Date: Fri, 15 Dec 2023 20:38:38 -0600 Subject: [PATCH 01/20] Add profiling functions to libomptarget

[clang] [llvm] [openmp] [PGO][OpenMP] Instrumentation for GPU devices (PR #76587)

2024-05-21 Thread Ethan Luis McDonough via cfe-commits
https://github.com/EthanLuisMcDonough updated https://github.com/llvm/llvm-project/pull/76587 >From 530eb982b9770190377bb0bd09c5cb715f34d484 Mon Sep 17 00:00:00 2001 From: Ethan Luis McDonough Date: Fri, 15 Dec 2023 20:38:38 -0600 Subject: [PATCH 01/20] Add profiling functions to libomptarget

[clang] [llvm] [AMDGPU] Add amdgpu-as MMRA for fences (PR #78572)

2024-05-21 Thread Matt Arsenault via cfe-commits
arsenm wrote: > I thought image memory = private. It's unclear to me, what AS does OpenCL > IMAGE memory map to in our backend? (But otherwise, yes, MMRA should just > have the backend names, the mapping of the OpenCL IMAGE to a backend AS > should be in the device-lib) Images are global memo

[clang] [llvm] wip: Move instrumentation passes (PR #92171)

2024-05-21 Thread Egor Pasko via cfe-commits
pasko wrote: Hello @aeubanks, I added a couple of new tests as you suggested. I do not have good intuition on their coverage. I think I will need to add a few cases, like always_inline or slightly more complicated code. Can you please take a look at the general structure? Does it roughly matc

[clang] [llvm] [ARM] Save floating point registers and status registers with save_fp function attribute (PR #89654)

2024-05-21 Thread Benson Chu via cfe-commits
https://github.com/pestctrl updated https://github.com/llvm/llvm-project/pull/89654 >From 0e0fcca8752ff4e9478cc2e6710e188e65da71e6 Mon Sep 17 00:00:00 2001 From: Jake Vossen Date: Wed, 30 Jun 2021 15:13:13 -0500 Subject: [PATCH 1/2] [ARM] Save floating point registers with save_fp function att

[clang] [clang-format] Add space after a word token (PR #92741)

2024-05-21 Thread Björn Schäpers via cfe-commits
HazardyKnusperkeks wrote: > > Since I am by no means an expert on Clang, a few questions arose > > > > * As Clang formats the code correctly (no code changes necessary) when > > instead of `xor` a different function name e.g. `xooor` is used, I wonder > > why `xor` is tokenized as Unary operat

[clang] [ClangFormat] Add DiagHandler for getStyle function (PR #91317)

2024-05-21 Thread Björn Schäpers via cfe-commits
HazardyKnusperkeks wrote: For the record, I see no harm in this PR and would also merge it without an issue. Just giving @mydeveloperday a bit more time to answer. :) https://github.com/llvm/llvm-project/pull/91317 ___ cfe-commits mailing list cfe-com

[clang] [clang-format] Correctly annotate C++ alternative operators in C (PR #92880)

2024-05-21 Thread Björn Schäpers via cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request. https://github.com/llvm/llvm-project/pull/92880 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Offload] Move HIP and CUDA to new driver by default (PR #84420)

2024-05-21 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/84420 >From b0dc390bc52059d7a31b5f0878ffb8024201774d Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Thu, 7 Mar 2024 15:48:00 -0600 Subject: [PATCH] [Offload] Move HIP and CUDA to new driver by default Summary: This

[clang] [C] Disallow declarations where a statement is required (PR #92908)

2024-05-21 Thread Shafik Yaghmour via cfe-commits
@@ -467,15 +467,18 @@ class Parser : public CodeCompletionHandler { /// Flags describing a context in which we're parsing a statement. enum class ParsedStmtContext { +/// This context permits declarations in language modes where declarations +/// are not statements

[clang] [llvm] wip: Move instrumentation passes (PR #92171)

2024-05-21 Thread Arthur Eubanks via cfe-commits
@@ -0,0 +1,31 @@ +; RUN: opt -passes="default" -S < %s | FileCheck %s +; RUN: opt -passes="thinlto-pre-link" -S < %s | FileCheck %s +; RUN: opt -passes="thinlto-pre-link,thinlto" -S < %s | FileCheck %s aeubanks wrote: no need to run `thinlto` here, but we should

[clang] [llvm] wip: Move instrumentation passes (PR #92171)

2024-05-21 Thread Arthur Eubanks via cfe-commits
@@ -0,0 +1,31 @@ +; RUN: opt -passes="default" -S < %s | FileCheck %s aeubanks wrote: should also test `O0` versions of these, plus `lto-pre-link` https://github.com/llvm/llvm-project/pull/92171 ___ cfe-commits mailing

[clang] [llvm] wip: Move instrumentation passes (PR #92171)

2024-05-21 Thread Arthur Eubanks via cfe-commits
@@ -0,0 +1,31 @@ +; RUN: opt -passes="default" -S < %s | FileCheck %s +; RUN: opt -passes="thinlto-pre-link" -S < %s | FileCheck %s +; RUN: opt -passes="thinlto-pre-link,thinlto" -S < %s | FileCheck %s + +target triple = "x86_64-unknown-linux" + +define void @leaf_function() #0 {

[clang] [llvm] wip: Move instrumentation passes (PR #92171)

2024-05-21 Thread Arthur Eubanks via cfe-commits
@@ -0,0 +1,29 @@ +; RUN: llc -mtriple=x86_64-- -O0 < %s | FileCheck %s +; RUN: llc -mtriple=x86_64-- -O1 < %s | FileCheck %s +; RUN: llc -mtriple=x86_64-- -O2 < %s | FileCheck %s + +; The codegen should insert post-inlining instrumentation calls and should not +; insert pre-inlini

[clang] [Clang] Implement resolution for CWG1835 (PR #92957)

2024-05-21 Thread Krystian Stasiowski via cfe-commits
https://github.com/sdkrystian created https://github.com/llvm/llvm-project/pull/92957 [CWG1835](https://cplusplus.github.io/CWG/issues/1835.html) was one of the many core issues resolved by [P1787R6: Declarations and where to find them](http://wg21.link/p1787r6). Its resolution changes how [me

[clang] [Clang] Implement resolution for CWG1835 (PR #92957)

2024-05-21 Thread Krystian Stasiowski via cfe-commits
sdkrystian wrote: (this PR is by no means complete, but I would like feedback regarding the validity of my interpretation of the DR resolution and perhaps some guidance with how to best go about implementing it. The currently included implementation _works_, but I'm uncertain whether it's the

[clang] [llvm] [IR] Avoid creating icmp/fcmp constant expressions (PR #92885)

2024-05-21 Thread Philip Reames via cfe-commits
@@ -8,7 +8,8 @@ // CHECK: entry: // CHECK-NEXT: %retval = alloca i32 // CHECK-NEXT: store i32 0, ptr %retval -// CHECK-NEXT: [[ZEXT:%.*]] = zext i1 true to i32 +// CHECK-NEXT: [[CMP:%.*]] = icmp ne ptr @b, @a +// CHECK-NEXT: [[ZEXT:%.*]] = zext i1 [[CMP]] to i32

[clang] [llvm] [IR] Avoid creating icmp/fcmp constant expressions (PR #92885)

2024-05-21 Thread Philip Reames via cfe-commits
@@ -8,7 +8,8 @@ // CHECK: entry: // CHECK-NEXT: %retval = alloca i32 // CHECK-NEXT: store i32 0, ptr %retval -// CHECK-NEXT: [[ZEXT:%.*]] = zext i1 true to i32 +// CHECK-NEXT: [[CMP:%.*]] = icmp ne ptr @b, @a +// CHECK-NEXT: [[ZEXT:%.*]] = zext i1 [[CMP]] to i32

[clang] [Clang] Implement resolution for CWG1835 (PR #92957)

2024-05-21 Thread Krystian Stasiowski via cfe-commits
https://github.com/sdkrystian updated https://github.com/llvm/llvm-project/pull/92957 >From 4524db5ae7f3133b51328fbabd1f6188d7d3707b Mon Sep 17 00:00:00 2001 From: Krystian Stasiowski Date: Tue, 21 May 2024 13:15:24 -0400 Subject: [PATCH 1/2] [WIP][Clang] Implement resolution for CWG1835 ---

[clang] [libunwind] [libunwind][WebAssembly] Make libunwind compilable (PR #92192)

2024-05-21 Thread Heejin Ahn via cfe-commits
aheejin wrote: I'd appreciate if someone LGTM this. Thanks! https://github.com/llvm/llvm-project/pull/92192 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libcxxabi] [libunwind] [WebAssembly] __USING_WASM_EXCEPTIONS__ -> __WASM_EXCEPTIONS__ (PR #92840)

2024-05-21 Thread Sam Clegg via cfe-commits
sbc100 wrote: > It is hard to fix the clang-format errors because the modified files > generally don't conform to the clang-format style anyway, so clang-format my > change currently affects hundreds of unrelated lines. > > ``` > aheejin@aheejin:~/llvm-project/libunwind$ git clang-format main

[clang] [llvm] Disable compiling and testing Flang on Clang changes (PR #92740)

2024-05-21 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll closed https://github.com/llvm/llvm-project/pull/92740 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [IR] Avoid creating icmp/fcmp constant expressions (PR #92885)

2024-05-21 Thread Nikita Popov via cfe-commits
@@ -8,7 +8,8 @@ // CHECK: entry: // CHECK-NEXT: %retval = alloca i32 // CHECK-NEXT: store i32 0, ptr %retval -// CHECK-NEXT: [[ZEXT:%.*]] = zext i1 true to i32 +// CHECK-NEXT: [[CMP:%.*]] = icmp ne ptr @b, @a +// CHECK-NEXT: [[ZEXT:%.*]] = zext i1 [[CMP]] to i32

[clang-tools-extra] [clang-tidy] Added bugprone-exception-rethrow check (PR #86448)

2024-05-21 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL updated https://github.com/llvm/llvm-project/pull/86448 >From 1b5c351acca7375c577111a4c55506146ef108ef Mon Sep 17 00:00:00 2001 From: Piotr Zegar Date: Sun, 24 Mar 2024 18:39:54 + Subject: [PATCH 1/6] [clang-tidy] Added bugprone-exception-rethrow check Identifie

[clang-tools-extra] [clang-tidy] Added bugprone-exception-rethrow check (PR #86448)

2024-05-21 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL updated https://github.com/llvm/llvm-project/pull/86448 >From 1b5c351acca7375c577111a4c55506146ef108ef Mon Sep 17 00:00:00 2001 From: Piotr Zegar Date: Sun, 24 Mar 2024 18:39:54 + Subject: [PATCH 1/5] [clang-tidy] Added bugprone-exception-rethrow check Identifie

[clang-tools-extra] [clang-tidy] Added bugprone-exception-rethrow check (PR #86448)

2024-05-21 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL updated https://github.com/llvm/llvm-project/pull/86448 >From 1b5c351acca7375c577111a4c55506146ef108ef Mon Sep 17 00:00:00 2001 From: Piotr Zegar Date: Sun, 24 Mar 2024 18:39:54 + Subject: [PATCH 1/7] [clang-tidy] Added bugprone-exception-rethrow check Identifie

[clang-tools-extra] [clang-tidy] Added bugprone-exception-rethrow check (PR #86448)

2024-05-21 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL updated https://github.com/llvm/llvm-project/pull/86448 >From 1b5c351acca7375c577111a4c55506146ef108ef Mon Sep 17 00:00:00 2001 From: Piotr Zegar Date: Sun, 24 Mar 2024 18:39:54 + Subject: [PATCH 1/8] [clang-tidy] Added bugprone-exception-rethrow check Identifie

[clang-tools-extra] [clang-tidy] Added bugprone-exception-rethrow check (PR #86448)

2024-05-21 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL updated https://github.com/llvm/llvm-project/pull/86448 >From 1b5c351acca7375c577111a4c55506146ef108ef Mon Sep 17 00:00:00 2001 From: Piotr Zegar Date: Sun, 24 Mar 2024 18:39:54 + Subject: [PATCH 1/9] [clang-tidy] Added bugprone-exception-rethrow check Identifie

[clang-tools-extra] [clang-tidy] Added bugprone-exception-rethrow check (PR #86448)

2024-05-21 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL updated https://github.com/llvm/llvm-project/pull/86448 >From 1b5c351acca7375c577111a4c55506146ef108ef Mon Sep 17 00:00:00 2001 From: Piotr Zegar Date: Sun, 24 Mar 2024 18:39:54 + Subject: [PATCH 01/10] [clang-tidy] Added bugprone-exception-rethrow check Identif

[clang] [Clang] Implement resolution for CWG1835 (PR #92957)

2024-05-21 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: It was a pure accident I opened this PR. I think draft status does a good job at silencing notifications. I spend a decent amount of time in P1787R6, so I might be able to provide good feedback. I'll take a look tomorrow. It would be nice to see a test for CWG1835 among the chang

[clang] [Clang] Implement resolution for CWG1835 (PR #92957)

2024-05-21 Thread Krystian Stasiowski via cfe-commits
sdkrystian wrote: @Endilll I'm still in the process of writing tests, but I'll add several soon. I'm quite confident about my interpretation being correct but I just want to be 100% sure :). At the very least this patch gets [[basic.lookup.qual.general] example 3](http://eel.is/c++draft/basi

[clang-tools-extra] [clang-tidy] Added bugprone-exception-rethrow check (PR #86448)

2024-05-21 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL updated https://github.com/llvm/llvm-project/pull/86448 >From c99ba980b0b242fced57fb323c5069d856c68810 Mon Sep 17 00:00:00 2001 From: Piotr Zegar Date: Sun, 31 Mar 2024 12:16:53 + Subject: [PATCH 1/6] fix --- clang-tools-extra/clang-tidy/abseil/AbseilMatcher.h

[clang] [llvm] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on MI3XX (PR #92962)

2024-05-21 Thread Shilei Tian via cfe-commits
https://github.com/shiltian created https://github.com/llvm/llvm-project/pull/92962 Fixes: SWDEV-459212 >From 5c342cbb389d32468695a925a6db3b42b09b15c4 Mon Sep 17 00:00:00 2001 From: Shilei Tian Date: Tue, 21 May 2024 16:40:41 -0400 Subject: [PATCH] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS o

[clang] [llvm] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on MI3XX (PR #92962)

2024-05-21 Thread Shilei Tian via cfe-commits
https://github.com/shiltian updated https://github.com/llvm/llvm-project/pull/92962 >From 05044c94265e51f81967fd0ed783b4ed163bc003 Mon Sep 17 00:00:00 2001 From: Shilei Tian Date: Tue, 21 May 2024 16:41:23 -0400 Subject: [PATCH] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on MI3XX Fixes: SWDEV-

[clang] [llvm] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on MI3XX (PR #92962)

2024-05-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-llvm-ir @llvm/pr-subscribers-backend-amdgpu Author: Shilei Tian (shiltian) Changes Fixes: SWDEV-459212 --- Full diff: https://github.com/llvm/llvm-project/pull/92962.diff 3 Files Affected: - (modified) clang/include/clang/

[clang-tools-extra] [clang-tidy] Added bugprone-exception-rethrow check (PR #86448)

2024-05-21 Thread Piotr Zegar via cfe-commits
@@ -0,0 +1,103 @@ +// RUN: %check_clang_tidy %s bugprone-exception-rethrow %t -- -- -fexceptions + +struct exception {}; + +namespace std { PiotrZSL wrote: that's a job for separate change, as std::move is duplicated in multiple test files. https://github.com/l

[clang] [llvm] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on GFX940 (PR #92962)

2024-05-21 Thread Shilei Tian via cfe-commits
https://github.com/shiltian edited https://github.com/llvm/llvm-project/pull/92962 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Added bugprone-exception-rethrow check (PR #86448)

2024-05-21 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL updated https://github.com/llvm/llvm-project/pull/86448 >From 8ed57a657d9b87bfaaa5c4394fc3fcaf670ba94c Mon Sep 17 00:00:00 2001 From: Piotr Zegar Date: Sun, 24 Mar 2024 18:39:54 + Subject: [PATCH 1/6] [clang-tidy] Added bugprone-exception-rethrow check Identifie

[clang] [clang] fix(92755): clang/include/clang/AST/Redeclarable.h: 4 * Function parameter should be passed by const reference (PR #92963)

2024-05-21 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk created https://github.com/llvm/llvm-project/pull/92963 Fixes #92755 >From f33697ce241213136a8d34c2cc32c68f8f827d6a Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Tue, 21 May 2024 22:56:06 +0300 Subject: [PATCH] fix(92755): use const references for operator== an

[clang] [clang] fix(92755): clang/include/clang/AST/Redeclarable.h: 4 * Function parameter should be passed by const reference (PR #92963)

2024-05-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Oleksandr T. (a-tarasyuk) Changes Fixes #92755 --- Full diff: https://github.com/llvm/llvm-project/pull/92963.diff 1 Files Affected: - (modified) clang/include/clang/AST/Redeclarable.h (+2-2) ``diff diff --git a/clang/include

[clang] [llvm] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on GFX940 (PR #92962)

2024-05-21 Thread Stanislav Mekhanoshin via cfe-commits
@@ -2466,23 +2466,24 @@ def int_amdgcn_perm : // GFX9 Intrinsics //===--===// -class AMDGPUGlobalLoadLDS : Intrinsic < - [], - [LLVMQualPointerType<1>, // Base global pointer to load from - LL

[clang] [llvm] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on GFX940 (PR #92962)

2024-05-21 Thread Shilei Tian via cfe-commits
https://github.com/shiltian updated https://github.com/llvm/llvm-project/pull/92962 >From 741d71e456825c156d4a34020c6f7d8f28e11a1d Mon Sep 17 00:00:00 2001 From: Shilei Tian Date: Tue, 21 May 2024 16:57:22 -0400 Subject: [PATCH] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on MI3XX Fixes: SWDEV-

[clang] [llvm] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on GFX940 (PR #92962)

2024-05-21 Thread Shilei Tian via cfe-commits
@@ -2466,23 +2466,24 @@ def int_amdgcn_perm : // GFX9 Intrinsics //===--===// -class AMDGPUGlobalLoadLDS : Intrinsic < - [], - [LLVMQualPointerType<1>, // Base global pointer to load from - LL

[clang] [llvm] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on GFX940 (PR #92962)

2024-05-21 Thread Stanislav Mekhanoshin via cfe-commits
@@ -2466,23 +2466,20 @@ def int_amdgcn_perm : // GFX9 Intrinsics //===--===// -class AMDGPUGlobalLoadLDS : Intrinsic < - [], - [LLVMQualPointerType<1>, // Base global pointer to load from - LL

[clang] [Coverage][Expansion] handle nested macros in scratch space (PR #89869)

2024-05-21 Thread NAKAMURA Takumi via cfe-commits
chapuni wrote: @whentojump Any updates? Or Is it better for me to take this over? https://github.com/llvm/llvm-project/pull/89869 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix self-capturing `__block` variables (PR #89475)

2024-05-21 Thread via cfe-commits
https://github.com/ille-apple updated https://github.com/llvm/llvm-project/pull/89475 >From 26be4b6332bf6b58b3d99bb0065b854dcce2a944 Mon Sep 17 00:00:00 2001 From: ille-apple Date: Fri, 19 Apr 2024 15:36:44 -0700 Subject: [PATCH] [clang] Fix self-capturing `__block` variables Clang special-cas

[clang] [clang] Fix self-capturing `__block` variables (PR #89475)

2024-05-21 Thread via cfe-commits
ille-apple wrote: Rebased due to merge conflict. https://github.com/llvm/llvm-project/pull/89475 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Build out AST consumer patterns to reach the entry point into CIRGen (PR #91007)

2024-05-21 Thread Bruno Cardoso Lopes via cfe-commits
bcardosolopes wrote: Thanks @AaronBallman > But again, the important thing is to at least be self-consistent. e.g., It's a good point to reinforce, updated. > I just don't think it benefits anyone to do so other than to make it easier > to land the initial patches, which doesn't seem like a

[clang] 3a913d3 - [clang][NFC] Refactor `Sema::TagUseKind` (#92689)

2024-05-21 Thread via cfe-commits
Author: Vlad Serebrennikov Date: 2024-05-22T02:07:28+04:00 New Revision: 3a913d30bef061be9786740e14bacd3fa6d76adc URL: https://github.com/llvm/llvm-project/commit/3a913d30bef061be9786740e14bacd3fa6d76adc DIFF: https://github.com/llvm/llvm-project/commit/3a913d30bef061be9786740e14bacd3fa6d76adc.

[clang] [clang][NFC] Refactor `Sema::TagUseKind` (PR #92689)

2024-05-21 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll closed https://github.com/llvm/llvm-project/pull/92689 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [llvm] Remove some `try_compile` CMake checks for compiler flags (PR #92953)

2024-05-21 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. https://github.com/llvm/llvm-project/pull/92953 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [llvm] Remove some `try_compile` CMake checks for compiler flags (PR #92953)

2024-05-21 Thread Arthur Eubanks via cfe-commits
https://github.com/aeubanks approved this pull request. awesome, thanks! https://github.com/llvm/llvm-project/pull/92953 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on GFX940 (PR #92962)

2024-05-21 Thread Shilei Tian via cfe-commits
https://github.com/shiltian updated https://github.com/llvm/llvm-project/pull/92962 >From a9e9fa27022738b6f7b8c5c2cbba0fb9900cd993 Mon Sep 17 00:00:00 2001 From: Shilei Tian Date: Tue, 21 May 2024 18:25:38 -0400 Subject: [PATCH] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on MI3XX Fixes: SWDEV-

[clang] [llvm] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on GFX940 (PR #92962)

2024-05-21 Thread Shilei Tian via cfe-commits
https://github.com/shiltian updated https://github.com/llvm/llvm-project/pull/92962 >From 539c48a5a44392821547335bdfc3942cc03e1540 Mon Sep 17 00:00:00 2001 From: Shilei Tian Date: Tue, 21 May 2024 18:26:25 -0400 Subject: [PATCH] [AMDGPU] Clang builtin for GLOBAL_LOAD_LDS on MI3XX Fixes: SWDEV-

[clang] [clang] fix(92755): clang/include/clang/AST/Redeclarable.h: 4 * Function parameter should be passed by const reference (PR #92963)

2024-05-21 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/92963 >From f33697ce241213136a8d34c2cc32c68f8f827d6a Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Tue, 21 May 2024 22:56:06 +0300 Subject: [PATCH] fix(92755): use const references for operator== and operator!=

<    1   2   3   4   5   >