[clang] [HIP] Use original file path for CUID (PR #107734)

2024-09-14 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `llvm-clang-x86_64-darwin` running on `doug-worker-3` while building `clang` at step 6 "test-build-unified-tree-check-all". Full details are available at: https://lab.llvm.org/buildbot/#/builders/23/builds/3020 Here is the r

[clang] [HIP] Use original file path for CUID (PR #107734)

2024-09-14 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `llvm-clang-aarch64-darwin` running on `doug-worker-4` while building `clang` at step 6 "test-build-unified-tree-check-all". Full details are available at: https://lab.llvm.org/buildbot/#/builders/190/builds/5764 Here is the

[clang] [HIP] Use original file path for CUID (PR #107734)

2024-09-14 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `openmp-offload-amdgpu-runtime` running on `omp-vega20-0` while building `clang` at step 7 "Add check check-offload". Full details are available at: https://lab.llvm.org/buildbot/#/builders/30/builds/6192 Here is the relevan

[clang] [HIP] Use original file path for CUID (PR #107734)

2024-09-14 Thread Yaxun Liu via cfe-commits
https://github.com/yxsamliu closed https://github.com/llvm/llvm-project/pull/107734 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 9fc789d - [HIP] Use original file path for CUID (#107734)

2024-09-14 Thread via cfe-commits
Author: Yaxun (Sam) Liu Date: 2024-09-15T00:37:15-04:00 New Revision: 9fc789d922ddf1c849f62bdfbe034f3cd9354967 URL: https://github.com/llvm/llvm-project/commit/9fc789d922ddf1c849f62bdfbe034f3cd9354967 DIFF: https://github.com/llvm/llvm-project/commit/9fc789d922ddf1c849f62bdfbe034f3cd9354967.dif

[clang] [AST] Iterate redecls starting from the canonical one in getRawCommentsForAnyRedecl() (PR #108475)

2024-09-14 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 converted_to_draft https://github.com/llvm/llvm-project/pull/108475 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Iterate redecls starting from the canonical one in getRawCommentsForAnyRedecl() (PR #108475)

2024-09-14 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: Buildkite is showing the test `Clang :: Index/comment-to-html-xml-conversion.cpp` failing. Will investigate. https://github.com/llvm/llvm-project/pull/108475 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.l

[clang] [llvm] [CGData][ThinLTO][NFC] Prep for two-codegen rounds (PR #90934)

2024-09-14 Thread Kyungwoo Lee via cfe-commits
https://github.com/kyulee-com edited https://github.com/llvm/llvm-project/pull/90934 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [CGData][ThinLTO][NFC] Prep for two-codegen rounds (PR #90934)

2024-09-14 Thread Kyungwoo Lee via cfe-commits
https://github.com/kyulee-com edited https://github.com/llvm/llvm-project/pull/90934 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [CGData][ThinLTO][NFC] Prep for two-codegen rounds (PR #90934)

2024-09-14 Thread Kyungwoo Lee via cfe-commits
https://github.com/kyulee-com edited https://github.com/llvm/llvm-project/pull/90934 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [CGData][ThinLTO][NFC] Prep for two-codegen rounds (PR #90934)

2024-09-14 Thread Kyungwoo Lee via cfe-commits
https://github.com/kyulee-com edited https://github.com/llvm/llvm-project/pull/90934 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [ThinLTO][NFC] Prep for two-codegen rounds (PR #90934)

2024-09-14 Thread Kyungwoo Lee via cfe-commits
https://github.com/kyulee-com updated https://github.com/llvm/llvm-project/pull/90934 >From 95709740e820c0efddb1fdb53436a03194a1b88e Mon Sep 17 00:00:00 2001 From: Kyungwoo Lee Date: Fri, 26 Apr 2024 20:02:52 -0700 Subject: [PATCH] [ThinLTO][NFC] Prep for two-codegen rounds --- clang/lib/Code

[clang] [clang] Add -Wimplicit-fallthrough to -Wextra (PR #97926)

2024-09-14 Thread Max Coplan via cfe-commits
https://github.com/vegerot updated https://github.com/llvm/llvm-project/pull/97926 >From 7d221cbcf91248f44b016aea107109756fa9f785 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Max=20=F0=9F=91=A8=F0=9F=8F=BD=E2=80=8D=F0=9F=92=BB=20Copl?= =?UTF-8?q?an?= Date: Sat, 6 Jul 2024 17:22:55 -0700 Subject: [

[clang] [NFC] Correct the misuse of the API in the Clang test-report script. (PR #108725)

2024-09-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (c8ef) Changes ref: https://docs.python.org/3/library/unittest.html#unittest.TestCase.assertEqual --- Full diff: https://github.com/llvm/llvm-project/pull/108725.diff 1 Files Affected: - (modified) clang/tools/scan-build-py/tests/

[clang] [NFC] Correct the misuse of the API in the Clang test-report script. (PR #108725)

2024-09-14 Thread via cfe-commits
https://github.com/c8ef created https://github.com/llvm/llvm-project/pull/108725 ref: https://docs.python.org/3/library/unittest.html#unittest.TestCase.assertEqual >From 1f56fd3444b6f7667a7036a29cba825f7eac77b0 Mon Sep 17 00:00:00 2001 From: c8ef Date: Sun, 15 Sep 2024 10:00:12 +0800 Subject:

[clang] [clang] Add -Wimplicit-fallthrough to -Wextra (PR #97926)

2024-09-14 Thread Max Coplan via cfe-commits
vegerot wrote: @AaronBallman sure. Should I still use http://llvm-compile-time-tracker.com/ , or do I run the benchmark another way? https://github.com/llvm/llvm-project/pull/97926 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://list

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 edited https://github.com/llvm/llvm-project/pull/108701 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 edited https://github.com/llvm/llvm-project/pull/108701 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 commented: So I took a stab at it. In `ParseStaticAssertDeclaration()`, we parsed the message in unclosed  static_assert as a constant expression rather than an unevaluated string literal per the logic on lines 1079-1089. So this approach gives up building an express

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Younan Zhang via cfe-commits
zyn0217 wrote: > Can we figure out which PR this regression came from and make sure the code > change makes sense in light of that PR? https://github.com/llvm/llvm-project/pull/102044. We have backported the P2741R3 implementation to C++11. https://github.com/llvm/llvm-project/pull/108701 __

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Younan Zhang via cfe-commits
@@ -0,0 +1,5 @@ +// RUN: %clang_cc1 -std=c++2a -triple=x86_64-linux -fsyntax-only %s -verify zyn0217 wrote: Also, you might want to wrap the case with a namespace referring to the issue number. Furthermore, I think the test should be triaged as a Parser one. Ca

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Younan Zhang via cfe-commits
@@ -0,0 +1,5 @@ +// RUN: %clang_cc1 -std=c++2a -triple=x86_64-linux -fsyntax-only %s -verify zyn0217 wrote: I believe so, yes. See the example: clang/test/SemaCXX/constant-expression-cxx2b.cpp https://github.com/llvm/llvm-project/pull/108701 ___

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk edited https://github.com/llvm/llvm-project/pull/108701 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Oleksandr T. via cfe-commits
@@ -0,0 +1,5 @@ +// RUN: %clang_cc1 -std=c++2a -triple=x86_64-linux -fsyntax-only %s -verify a-tarasyuk wrote: The file refers to cxx26 —is it ok to add tests related to C++20 here?" https://github.com/llvm/llvm-project/pull/108701 __

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Younan Zhang via cfe-commits
@@ -0,0 +1,5 @@ +// RUN: %clang_cc1 -std=c++2a -triple=x86_64-linux -fsyntax-only %s -verify zyn0217 wrote: You can add another C++20 mode run to clang/test/SemaCXX/static-assert-cxx26.cpp, instead of adding a new file. https://github.com/llvm/llvm-project/pull

[clang] [Clang] Avoid transforming lambdas when rebuilding immediate expressions (PR #108693)

2024-09-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Younan Zhang (zyn0217) Changes When rebuilding immediate invocations inside `RemoveNestedImmediateInvocation()`, we employed a `TreeTransform` to exercise the traversal. The transformation has a side effect that, for template specializat

[clang] [Clang] Avoid transforming lambdas when rebuilding immediate expressions (PR #108693)

2024-09-14 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 ready_for_review https://github.com/llvm/llvm-project/pull/108693 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [git-clang-format] Fix: make the tool backward compatible (PR #108721)

2024-09-14 Thread Eden Reich via cfe-commits
https://github.com/edenreich edited https://github.com/llvm/llvm-project/pull/108721 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [git-clang-format] Fix: make the tool backward compatible (PR #108721)

2024-09-14 Thread Eden Reich via cfe-commits
https://github.com/edenreich edited https://github.com/llvm/llvm-project/pull/108721 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [git-clang-format] Fix: make the tool backward compatible (PR #108721)

2024-09-14 Thread Eden Reich via cfe-commits
https://github.com/edenreich edited https://github.com/llvm/llvm-project/pull/108721 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [git-clang-format] Fix: make the tool backward compatible (PR #108721)

2024-09-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Eden Reich (edenreich) Changes ## Summary Currently it's not backward compatible, because the flag -list-ignored doesn't exists on older version of clang-format. To make this tool still backward compatible, we can first check if t

[clang] [git-clang-format] Fix: make the tool backward compatible (PR #108721)

2024-09-14 Thread via cfe-commits
github-actions[bot] wrote: Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be notified. If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you, it

[clang] [git-clang-format] Fix: make the tool backward compatible (PR #108721)

2024-09-14 Thread Eden Reich via cfe-commits
https://github.com/edenreich created https://github.com/llvm/llvm-project/pull/108721 ## Summary Currently it's not backward compatible, because the flag -list-ignored doesn't exists on older version of clang-format. To make this tool still backward compatible, we can first check if the .cla

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/108701 >From cbe06cf33277f904fe002db90d428a55b777ff5d Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Sat, 14 Sep 2024 17:02:01 +0300 Subject: [PATCH 1/2] [Clang] handle invalid close location in static assert dec

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Shafik Yaghmour via cfe-commits
shafik wrote: > > So this looks like a regression: https://gcc.godbolt.org/z/h6GexT18E > > @shafik https://gcc.godbolt.org/z/Ebvnjrc8e Interesting it crashes in trunk w/o `c++20`: https://gcc.godbolt.org/z/h9xa8eaqo but the backtrace looks the same. We should test this in C++20 and C++23 as w

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Oleksandr T. via cfe-commits
a-tarasyuk wrote: > So this looks like a regression: https://gcc.godbolt.org/z/h6GexT18E @shafik https://gcc.godbolt.org/z/Ebvnjrc8e https://github.com/llvm/llvm-project/pull/108701 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik requested changes to this pull request. So this looks like a regression: https://gcc.godbolt.org/z/h6GexT18E Can we figure out which PR this regression came from and make sure the code change makes sense in light of that PR? Also please add a more detailed summary to

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Shafik Yaghmour via cfe-commits
shafik wrote: So this looks like a regression: https://gcc.godbolt.org/z/h6GexT18E Can we figure out which PR this regression came from and make sure the code change makes sense in light of that PR? Also please add a more detailed summary to this PR, describing why the crash happens and the

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Oleksandr T. via cfe-commits
a-tarasyuk wrote: @cor3ntin when you get a chance, could you merge this? I don’t have the permissions. thanks! https://github.com/llvm/llvm-project/pull/108701 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mail

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. Thanks, LGTM https://github.com/llvm/llvm-project/pull/108701 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 7d11f52 - [clang] Silence GCC warnings about control reaching end of non void function

2024-09-14 Thread Martin Storsjö via cfe-commits
Author: Martin Storsjö Date: 2024-09-15T00:02:39+03:00 New Revision: 7d11f5249c8068851270e94ac02c180e7b83590d URL: https://github.com/llvm/llvm-project/commit/7d11f5249c8068851270e94ac02c180e7b83590d DIFF: https://github.com/llvm/llvm-project/commit/7d11f5249c8068851270e94ac02c180e7b83590d.diff

[clang-tools-extra] e392056 - Reapply "Reapply "[clang] Extend diagnose_if to accept more detailed warning information (#70976)" (#108453)"

2024-09-14 Thread Nikolas Klauser via cfe-commits
Author: Nikolas Klauser Date: 2024-09-14T22:25:08+02:00 New Revision: e39205654dc11c50bd117e8ccac243a641ebd71f URL: https://github.com/llvm/llvm-project/commit/e39205654dc11c50bd117e8ccac243a641ebd71f DIFF: https://github.com/llvm/llvm-project/commit/e39205654dc11c50bd117e8ccac243a641ebd71f.dif

[clang] e392056 - Reapply "Reapply "[clang] Extend diagnose_if to accept more detailed warning information (#70976)" (#108453)"

2024-09-14 Thread Nikolas Klauser via cfe-commits
Author: Nikolas Klauser Date: 2024-09-14T22:25:08+02:00 New Revision: e39205654dc11c50bd117e8ccac243a641ebd71f URL: https://github.com/llvm/llvm-project/commit/e39205654dc11c50bd117e8ccac243a641ebd71f DIFF: https://github.com/llvm/llvm-project/commit/e39205654dc11c50bd117e8ccac243a641ebd71f.dif

[clang] [clang-tools-extra] Fix OOM in FormatDiagnostic (PR #108187)

2024-09-14 Thread Vakhurin Sergei via cfe-commits
@@ -945,50 +959,11 @@ class DiagnosticsEngine : public RefCountedBase { void Report(const StoredDiagnostic &storedDiag); - /// Determine whethere there is already a diagnostic in flight. - bool isDiagnosticInFlight() const { -return CurDiagID != std::numeric_limits::

[clang] [clang-tools-extra] Fix OOM in FormatDiagnostic (PR #108187)

2024-09-14 Thread Vakhurin Sergei via cfe-commits
https://github.com/igelbox updated https://github.com/llvm/llvm-project/pull/108187 >From aee4cf70dedaa3c8b7b6508238e01f92d60c631c Mon Sep 17 00:00:00 2001 From: Sergei Date: Tue, 10 Sep 2024 16:19:05 + Subject: [PATCH 1/4] fix quick OOM in FormatDiagnostic --- .../ClangTidyDiagnosticCons

[clang] [llvm] [Utils] Add new --update-tests flag to llvm-lit (PR #108425)

2024-09-14 Thread Nicolai Hähnle via cfe-commits
https://github.com/nhaehnle edited https://github.com/llvm/llvm-project/pull/108425 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Utils] Add new --update-tests flag to llvm-lit (PR #108425)

2024-09-14 Thread Nicolai Hähnle via cfe-commits
https://github.com/nhaehnle commented: Thanks for splitting this up. It does look mostly good to me, but I do have two comments. https://github.com/llvm/llvm-project/pull/108425 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llv

[clang] [llvm] [Utils] Add new --update-tests flag to llvm-lit (PR #108425)

2024-09-14 Thread Nicolai Hähnle via cfe-commits
@@ -1,3 +1,5 @@ +// RUN: %clang_cc1 -verify %s +// RUN: diff %s %s.expected nhaehnle wrote: I still think those new invocations of `diff` should be in `lit-plugin.test`. Those `diff` lines attempt to check that this file (or rather its temporarily copied versio

[clang] [llvm] [Utils] Add new --update-tests flag to llvm-lit (PR #108425)

2024-09-14 Thread Nicolai Hähnle via cfe-commits
@@ -2,3 +2,15 @@ config.substitutions = list(config.substitutions) config.substitutions.insert( 0, (r"%clang\b", """*** Do not use the driver in Sema tests. ***""") ) + +if lit_config.update_tests: +import sys +import os + +curdir = os.path.dirname(os.path.realp

[clang] [clang-format] Fix regression in AlwaysBreak for-await (PR #108634)

2024-09-14 Thread Gedare Bloom via cfe-commits
https://github.com/gedare updated https://github.com/llvm/llvm-project/pull/108634 >From cc3f586d2fee5b89eece3bf341d1ffe1d169e3f7 Mon Sep 17 00:00:00 2001 From: Gedare Bloom Date: Fri, 13 Sep 2024 13:41:49 -0600 Subject: [PATCH 1/2] [clang-format] Fix regression in AlwaysBreak for-await Fixes

[clang] [clang-format] Fix regression with BlockIndent of Braced Initializers (PR #108717)

2024-09-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Gedare Bloom (gedare) Changes Fixes #73584. --- Full diff: https://github.com/llvm/llvm-project/pull/108717.diff 2 Files Affected: - (modified) clang/lib/Format/ContinuationIndenter.cpp (+7) - (modified) clang/unittests/Format/F

[clang] [clang-format] Fix regression with BlockIndent of Braced Initializers (PR #108717)

2024-09-14 Thread Gedare Bloom via cfe-commits
https://github.com/gedare created https://github.com/llvm/llvm-project/pull/108717 Fixes #73584. >From a95b990e48df19b8b674fe9df6bea803415129bf Mon Sep 17 00:00:00 2001 From: Gedare Bloom Date: Sat, 14 Sep 2024 13:13:26 -0600 Subject: [PATCH] [clang-format] Fix regression with BlockIndent of B

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-14 Thread via cfe-commits
https://github.com/MK-Alias updated https://github.com/llvm/llvm-project/pull/108005 >From 4e9cbd615c56604fbc3c05f677b9da11f30977a2 Mon Sep 17 00:00:00 2001 From: MK-Alias Date: Tue, 10 Sep 2024 13:24:46 +0200 Subject: [PATCH 1/4] issue-63565: community requested small QoL fix for more configu

[clang-tools-extra] [clang-tidy] fix nullptr dereference in bugprone-forwarding-reference (PR #106856)

2024-09-14 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank approved this pull request. LGTM. https://github.com/llvm/llvm-project/pull/106856 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-14 Thread via cfe-commits
https://github.com/MK-Alias updated https://github.com/llvm/llvm-project/pull/108005 >From 4e9cbd615c56604fbc3c05f677b9da11f30977a2 Mon Sep 17 00:00:00 2001 From: MK-Alias Date: Tue, 10 Sep 2024 13:24:46 +0200 Subject: [PATCH 1/3] issue-63565: community requested small QoL fix for more configu

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-14 Thread via cfe-commits
MK-Alias wrote: Updated the source. It should now confirm to everything. To recap: `.clangd` now has a added key: `ArgumentLists` in the `Completion` block. It supports these values: `None` | `OpenDelimiter` | `Delimiters` | `FullPlaceholders`. The `.clangd` config will overwite the prevously

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-14 Thread via cfe-commits
https://github.com/MK-Alias updated https://github.com/llvm/llvm-project/pull/108005 >From 4e9cbd615c56604fbc3c05f677b9da11f30977a2 Mon Sep 17 00:00:00 2001 From: MK-Alias Date: Tue, 10 Sep 2024 13:24:46 +0200 Subject: [PATCH 1/2] issue-63565: community requested small QoL fix for more configu

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-14 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > Is this okay!? Yep. By the way, this was specified in the [original proposal](https://github.com/llvm/llvm-project/issues/63565#issuecomment-1975065771): > Here's a concrete proposal for a config file syntax that would address this > request, https://github.com/clangd/

[clang] fix(clang/**.py): fix comparison to None (PR #94014)

2024-09-14 Thread Eisuke Kawashima via cfe-commits
https://github.com/e-kwsm updated https://github.com/llvm/llvm-project/pull/94014 >From 3fcf81d949e461fb91b4e1713365da29ae1078cd Mon Sep 17 00:00:00 2001 From: Eisuke Kawashima Date: Sat, 11 May 2024 23:57:11 +0900 Subject: [PATCH] fix(clang/**.py): fix comparison to None from PEP8 (https://pe

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Oleksandr T. via cfe-commits
@@ -1110,6 +1110,8 @@ Decl *Parser::ParseStaticAssertDeclaration(SourceLocation &DeclEnd) { } T.consumeClose(); + if (T.getCloseLocation().isInvalid()) +return nullptr; a-tarasyuk wrote: @cor3ntin Thanks for the review. I've added changes to omit re

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/108701 >From cbe06cf33277f904fe002db90d428a55b777ff5d Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Sat, 14 Sep 2024 17:02:01 +0300 Subject: [PATCH] [Clang] handle invalid close location in static assert declara

[clang] Implementing `asfloat` using `bit_cast` (PR #108686)

2024-09-14 Thread via cfe-commits
@@ -361,6 +361,23 @@ bool any(double3); _HLSL_BUILTIN_ALIAS(__builtin_hlsl_any) bool any(double4); +//===--===// +// asfloat builtins +//===-

[clang] Implementing `asfloat` using `bit_cast` (PR #108686)

2024-09-14 Thread via cfe-commits
https://github.com/joaosaffran updated https://github.com/llvm/llvm-project/pull/108686 >From 32e71ea8fe790ea81163fac76bd2029991d780bd Mon Sep 17 00:00:00 2001 From: Joao Saffran Date: Sat, 14 Sep 2024 06:23:08 + Subject: [PATCH] implementing asfloat using bit_cast --- clang/lib/Headers/h

[clang] [clang-tools-extra] Fix OOM in FormatDiagnostic (PR #108187)

2024-09-14 Thread Vadim D. via cfe-commits
@@ -945,50 +959,11 @@ class DiagnosticsEngine : public RefCountedBase { void Report(const StoredDiagnostic &storedDiag); - /// Determine whethere there is already a diagnostic in flight. - bool isDiagnosticInFlight() const { -return CurDiagID != std::numeric_limits::

[clang] Implementing `asfloat` using `bit_cast` (PR #108686)

2024-09-14 Thread Chris B via cfe-commits
@@ -361,6 +361,23 @@ bool any(double3); _HLSL_BUILTIN_ALIAS(__builtin_hlsl_any) bool any(double4); +//===--===// +// asfloat builtins +//===-

[clang-tools-extra] [clang-tidy] fix false positive that floating point variable only used in increment expr in cert-flp30-c (PR #108706)

2024-09-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tools-extra Author: Congcong Cai (HerrCai0907) Changes Fixes: #108049 cert-flp30-c only provides non-compliant example with normal loop. Essentially it wants to avoid that floating point variables are used as loop counters which are checked in con

[clang-tools-extra] [clang-tidy] fix false positive that floating point variable only used in increment expr in cert-flp30-c (PR #108706)

2024-09-14 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 created https://github.com/llvm/llvm-project/pull/108706 Fixes: #108049 cert-flp30-c only provides non-compliant example with normal loop. Essentially it wants to avoid that floating point variables are used as loop counters which are checked in condition expr and

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

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

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread via cfe-commits
@@ -1110,6 +1110,8 @@ Decl *Parser::ParseStaticAssertDeclaration(SourceLocation &DeclEnd) { } T.consumeClose(); + if (T.getCloseLocation().isInvalid()) +return nullptr; cor3ntin wrote: `consumeClose` returms true on failure so this can just be `if(

[clang] [compiler-rt] [llvm] [FMV][AArch64] Unify ls64, ls64_v and ls64_accdata. (PR #108024)

2024-09-14 Thread Jon Roelofs via cfe-commits
@@ -73,8 +73,6 @@ enum CPUFeatures { FEAT_SSBS, FEAT_SSBS2, FEAT_BTI, - FEAT_LS64, - FEAT_LS64_V, jroelofs wrote: We could do that automatically every release by putting the version number in its name. https://github.com/llvm/llvm-project/pull/108024

[clang] [TableGen] Avoid repeated map lookups (NFC) (PR #108675)

2024-09-14 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/108675 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] bae275f - [TableGen] Avoid repeated map lookups (NFC) (#108675)

2024-09-14 Thread via cfe-commits
Author: Kazu Hirata Date: 2024-09-14T07:39:00-07:00 New Revision: bae275f65ecd27a16743f7b4695940dcfa70b218 URL: https://github.com/llvm/llvm-project/commit/bae275f65ecd27a16743f7b4695940dcfa70b218 DIFF: https://github.com/llvm/llvm-project/commit/bae275f65ecd27a16743f7b4695940dcfa70b218.diff L

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Oleksandr T. (a-tarasyuk) Changes Fixes #108687 --- Full diff: https://github.com/llvm/llvm-project/pull/108701.diff 3 Files Affected: - (modified) clang/docs/ReleaseNotes.rst (+1-1) - (modified) clang/lib/Parse/ParseDeclCXX.cpp (+2)

[clang] [Clang] handle invalid close location in static assert declaration (PR #108701)

2024-09-14 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk created https://github.com/llvm/llvm-project/pull/108701 Fixes #108687 >From 3e7e69e36e93f12c33ccdda9fea78e22cc9bdd84 Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Sat, 14 Sep 2024 17:02:01 +0300 Subject: [PATCH] [Clang] handle invalid close location in static

[clang] 11f9008 - [ast matcher][NFC] fix typo in release note

2024-09-14 Thread Congcong Cai via cfe-commits
Author: Congcong Cai Date: 2024-09-14T21:27:35+08:00 New Revision: 11f9008daec2b5593dfcc781ee879f93de121da2 URL: https://github.com/llvm/llvm-project/commit/11f9008daec2b5593dfcc781ee879f93de121da2 DIFF: https://github.com/llvm/llvm-project/commit/11f9008daec2b5593dfcc781ee879f93de121da2.diff

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-14 Thread via cfe-commits
MK-Alias wrote: Because the `.clangd` config is made out of blocks, and no block was specified for our new `ArgumentLists` key, I've put it under `Completion`. So now it is like ```yaml Completion: AllScopes: None ArgumentLists: None ``` It seems like the most logical choice, because it's

[clang] [Clang] Propagate elide safe context through [[clang::coro_must_await]] (PR #108474)

2024-09-14 Thread Adrian Vogelsgesang via cfe-commits
https://github.com/vogelsgesang edited https://github.com/llvm/llvm-project/pull/108474 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Propagate elide safe context through [[clang::coro_must_await]] (PR #108474)

2024-09-14 Thread Adrian Vogelsgesang via cfe-commits
https://github.com/vogelsgesang commented: Thanks for implementing this! Looking forward to using it 🙂 https://github.com/llvm/llvm-project/pull/108474 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/list

[clang] [Clang] Propagate elide safe context through [[clang::coro_must_await]] (PR #108474)

2024-09-14 Thread Adrian Vogelsgesang via cfe-commits
@@ -8261,12 +8261,19 @@ def CoroAwaitElidableDoc : Documentation { The ``[[clang::coro_await_elidable]]`` is a class attribute which can be applied to a coroutine return type. -When a coroutine function that returns such a type calls another coroutine function, -the compiler

[clang] [Clang] Propagate elide safe context through [[clang::coro_must_await]] (PR #108474)

2024-09-14 Thread Adrian Vogelsgesang via cfe-commits
@@ -880,14 +898,12 @@ ExprResult Sema::BuildUnresolvedCoawaitExpr(SourceLocation Loc, Expr *Operand, } auto *RD = Promise->getType()->getAsCXXRecordDecl(); - bool AwaitElidable = - isCoroAwaitElidableCall(Operand) && - isAttributedCoroAwaitElidable( -

[clang] [Clang] Propagate elide safe context through [[clang::coro_must_await]] (PR #108474)

2024-09-14 Thread Adrian Vogelsgesang via cfe-commits
@@ -84,4 +84,35 @@ Task nonelidable() { co_return 1; } +// CHECK-LABEL: define{{.*}} @_Z8addTasksO4TaskIiES1_{{.*}} { +Task addTasks([[clang::coro_must_await]] Task &&t1, Task &&t2) { + int i1 = co_await t1; + int i2 = co_await t2; + co_return i1 + i2; +} + +// CHECK-LABE

[clang] [Clang] Propagate elide safe context through [[clang::coro_must_await]] (PR #108474)

2024-09-14 Thread Adrian Vogelsgesang via cfe-commits
@@ -8261,12 +8261,19 @@ def CoroAwaitElidableDoc : Documentation { The ``[[clang::coro_await_elidable]]`` is a class attribute which can be applied to a coroutine return type. vogelsgesang wrote: ```suggestion to a coroutine return type. It provides a hint to

[clang] [Clang] Propagate elide safe context through [[clang::coro_must_await]] (PR #108474)

2024-09-14 Thread Adrian Vogelsgesang via cfe-commits
@@ -84,4 +84,35 @@ Task nonelidable() { co_return 1; } +// CHECK-LABEL: define{{.*}} @_Z8addTasksO4TaskIiES1_{{.*}} { +Task addTasks([[clang::coro_must_await]] Task &&t1, Task &&t2) { + int i1 = co_await t1; + int i2 = co_await t2; + co_return i1 + i2; +} + +// CHECK-LABE

[clang] [Clang] Propagate elide safe context through [[clang::coro_must_await]] (PR #108474)

2024-09-14 Thread Adrian Vogelsgesang via cfe-commits
@@ -8281,8 +8288,62 @@ Example: co_await t; } -The behavior is undefined if the caller coroutine is destroyed earlier than the -callee coroutine. +Such elision replaces the heap allocated activation frame of the callee coroutine +with a local variable within the enclosi

[clang] [Clang] Propagate elide safe context through [[clang::coro_must_await]] (PR #108474)

2024-09-14 Thread Adrian Vogelsgesang via cfe-commits
@@ -8281,8 +8288,62 @@ Example: co_await t; } -The behavior is undefined if the caller coroutine is destroyed earlier than the -callee coroutine. +Such elision replaces the heap allocated activation frame of the callee coroutine +with a local variable within the enclosi

[clang] [Clang] Propagate elide safe context through [[clang::coro_must_await]] (PR #108474)

2024-09-14 Thread Adrian Vogelsgesang via cfe-commits
@@ -8261,12 +8261,19 @@ def CoroAwaitElidableDoc : Documentation { The ``[[clang::coro_await_elidable]]`` is a class attribute which can be applied to a coroutine return type. -When a coroutine function that returns such a type calls another coroutine function, -the compiler

[clang] [Clang] Propagate elide safe context through [[clang::coro_must_await]] (PR #108474)

2024-09-14 Thread Adrian Vogelsgesang via cfe-commits
@@ -8281,8 +8288,62 @@ Example: co_await t; } -The behavior is undefined if the caller coroutine is destroyed earlier than the -callee coroutine. +Such elision replaces the heap allocated activation frame of the callee coroutine +with a local variable within the enclosi

[clang] [Clang] Propagate elide safe context through [[clang::coro_must_await]] (PR #108474)

2024-09-14 Thread Adrian Vogelsgesang via cfe-commits
@@ -249,7 +249,10 @@ Attribute Changes in Clang (#GH106864) - Introduced a new attribute ``[[clang::coro_await_elidable]]`` on coroutine return types - to express elideability at call sites where the coroutine is co_awaited as a prvalue. + to express elideability at call

[clang] [Clang] Avoid transforming lambdas when rebuilding immediate expressions (PR #108693)

2024-09-14 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 created https://github.com/llvm/llvm-project/pull/108693 When rebuilding immediate invocations inside `RemoveNestedImmediateInvocation()`, we employed a `TreeTransform` to exercise the traversal. The transformation has a side effect that, for template specialization

[clang] 223e2ef - [clang] Nits on uses of raw_string_ostream (NFC)

2024-09-14 Thread via cfe-commits
Author: JOE1994 Date: 2024-09-14T05:29:40-04:00 New Revision: 223e2efa5e886502a9467b7ef700ebce9b7886e8 URL: https://github.com/llvm/llvm-project/commit/223e2efa5e886502a9467b7ef700ebce9b7886e8 DIFF: https://github.com/llvm/llvm-project/commit/223e2efa5e886502a9467b7ef700ebce9b7886e8.diff LOG:

[clang] [analyzer] Refactor MallocChecker to use `BindExpr` in `evalCall` (PR #106081)

2024-09-14 Thread Pavel Skripkin via cfe-commits
pskrgag wrote: > LGTM, feel free to merge this patch. Thank you for review! I have no rights to push to llvm-project. So you can merge if you think it's good time to do so =) https://github.com/llvm/llvm-project/pull/106081 ___ cfe-commits mailing li

[clang-tools-extra] [clang-tidy]suggest use `std::span` as replacement of c array in C++20 for modernize-avoid-c-arrays (PR #108555)

2024-09-14 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 updated https://github.com/llvm/llvm-project/pull/108555 >From 35742b5f2f085b8f6626456cd0d21ebecbe8f831 Mon Sep 17 00:00:00 2001 From: Congcong Cai Date: Thu, 12 Sep 2024 23:11:51 +0800 Subject: [PATCH 1/3] [clang-tidy]suggest use `std::span` as replacement of c

[clang] [compiler-rt] [llvm] [FMV][AArch64] Unify ls64, ls64_v and ls64_accdata. (PR #108024)

2024-09-14 Thread via cfe-commits
@@ -73,8 +73,6 @@ enum CPUFeatures { FEAT_SSBS, FEAT_SSBS2, FEAT_BTI, - FEAT_LS64, - FEAT_LS64_V, Wilco1 wrote: It became a defacto ABI when the first implementation became available. We could change the names of the global/init function to explicitly

[clang] [libcxx] [Clang] Add __builtin_common_type (PR #99473)

2024-09-14 Thread Nikolas Klauser via cfe-commits
philnik777 wrote: gentle ping~ https://github.com/llvm/llvm-project/pull/99473 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy]suggest use `std::span` as replacement of c array in C++20 for modernize-avoid-c-arrays (PR #108555)

2024-09-14 Thread Congcong Cai via cfe-commits
@@ -72,11 +81,24 @@ void AvoidCArraysCheck::registerMatchers(MatchFinder *Finder) { void AvoidCArraysCheck::check(const MatchFinder::MatchResult &Result) { const auto *ArrayType = Result.Nodes.getNodeAs("typeloc"); - + const bool IsInParam = + Result.Nodes.getNodeAs("

[clang] [Clang] Start moving X86Builtins.def to X86Builtins.td (PR #106005)

2024-09-14 Thread Nikolas Klauser via cfe-commits
philnik777 wrote: gentle ping~ https://github.com/llvm/llvm-project/pull/106005 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Fix a bug in annotating StartOfName (PR #99791)

2024-09-14 Thread Alexander Lohnau via cfe-commits
alex1701c wrote: That is very unfortunate. It means one will either get different results for the clang-format versions, one disables the formatting, or works around it by sth. Like Q_EMIT(something()->mySignal()). https://github.com/llvm/llvm-project/pull/99791 ___

[clang] scan-build-py: respect LLVM_LIBDIR_SUFFIX like other tools do (PR #108549)

2024-09-14 Thread Michał Górny via cfe-commits
mgorny wrote: Sounds like a bug in OpenEmbedded then. CPython installs Python modules in `/usr/lib`, unconditionally. https://github.com/llvm/llvm-project/pull/108549 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-b

[clang] 918972b - [clang] Strip unneeded calls to raw_string_ostream::str() (NFC)

2024-09-14 Thread via cfe-commits
Author: JOE1994 Date: 2024-09-14T04:38:50-04:00 New Revision: 918972bded27de6a2bfacc15b4ad3edebd81f405 URL: https://github.com/llvm/llvm-project/commit/918972bded27de6a2bfacc15b4ad3edebd81f405 DIFF: https://github.com/llvm/llvm-project/commit/918972bded27de6a2bfacc15b4ad3edebd81f405.diff LOG:

[clang] [ast-matcher] Fixed a crash when traverse lambda expr with invalid captures (PR #108689)

2024-09-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Congcong Cai (HerrCai0907) Changes Fixes: #106444 --- Full diff: https://github.com/llvm/llvm-project/pull/108689.diff 3 Files Affected: - (modified) clang/docs/ReleaseNotes.rst (+2) - (modified) clang/lib/ASTMatchers/ASTMatchFinder.c

  1   2   >