[clang-tools-extra] [clang-tidy] Fix false positives with deducing this in `readability-convert-member-functions-to-static` check (PR #141391)

2025-05-25 Thread Baranov Victor via cfe-commits
@@ -79,10 +79,10 @@ void ConvertMemberFunctionsToStatic::registerMatchers(MatchFinder *Finder) { cxxMethodDecl( isDefinition(), isUserProvided(), unless(anyOf( - isExpansionInSystemHeader(), isVirtual(), isStatic(), - hasTriv

[clang-tools-extra] [clang-tidy] Fix false positive for cppcoreguidelines-pro-bounds-pointer-arithmetic (PR #127394)

2025-05-25 Thread via cfe-commits
https://github.com/flovent updated https://github.com/llvm/llvm-project/pull/127394 >From 94ef3c7d8d2ea4a671c553fbcdf3c60bd1fc6ab8 Mon Sep 17 00:00:00 2001 From: flovent Date: Sun, 16 Feb 2025 21:07:55 +0800 Subject: [PATCH 1/4] [clang-tidy] Fix false positive for cppcoreguidelines-pro-bounds-

[clang-tools-extra] [clang-tidy] Add check for assignment or comparision operators' operand in `readability-math-missing-parentheses` (PR #141345)

2025-05-25 Thread via cfe-commits
https://github.com/flovent updated https://github.com/llvm/llvm-project/pull/141345 >From e6c5673a6b7b7f73ddf4b1f14391757313a65485 Mon Sep 17 00:00:00 2001 From: flovent Date: Sat, 24 May 2025 21:29:53 +0800 Subject: [PATCH 1/2] [clang-tidy] Add check for assignment or comparision operators' o

[clang] [Clang] Link libgcc_s.1.dylib when building for macOS 10.5 and older (PR #124651)

2025-05-25 Thread via cfe-commits
https://github.com/Un1q32 closed https://github.com/llvm/llvm-project/pull/124651 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Link libgcc_s.1.dylib when building for macOS 10.5 and older (PR #141401)

2025-05-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (Un1q32) Changes There are a lot of symbols that were moved from libgcc_s into libSystem in 10.6, like libunwind and some builtins. We already do this for iOS versions < 5.0 for the same reason. This matches the behavior of the vers

[clang] [Clang] Link libgcc_s.1.dylib when building for macOS 10.5 and older (PR #141401)

2025-05-25 Thread via cfe-commits
https://github.com/Un1q32 created https://github.com/llvm/llvm-project/pull/141401 There are a lot of symbols that were moved from libgcc_s into libSystem in 10.6, like libunwind and some builtins. We already do this for iOS versions < 5.0 for the same reason. This matches the behavior of the

[clang] [Clang] Link libgcc_s.1.dylib when building for macOS 10.5 and older (PR #141401)

2025-05-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver Author: None (Un1q32) Changes There are a lot of symbols that were moved from libgcc_s into libSystem in 10.6, like libunwind and some builtins. We already do this for iOS versions < 5.0 for the same reason. This matches the behavior of t

[clang-tools-extra] [clang-tidy] Fix false positives with deducing this in `readability-convert-member-functions-to-static` check (PR #141391)

2025-05-25 Thread via cfe-commits
https://github.com/flovent updated https://github.com/llvm/llvm-project/pull/141391 >From 3a7260050f8e8dc271c7fe2a5ec937026136fb6b Mon Sep 17 00:00:00 2001 From: fubowen Date: Sun, 25 May 2025 09:37:47 +0800 Subject: [PATCH 1/5] [clang-tidy] fix false positives with deducing this in `readabili

[clang-tools-extra] [clang-tidy] Fix false positive for cppcoreguidelines-pro-bounds-pointer-arithmetic (PR #127394)

2025-05-25 Thread via cfe-commits
https://github.com/flovent updated https://github.com/llvm/llvm-project/pull/127394 >From f7439943d138bdfee87f77a1c44b3d7d26618129 Mon Sep 17 00:00:00 2001 From: flovent Date: Sun, 16 Feb 2025 21:07:55 +0800 Subject: [PATCH 1/4] [clang-tidy] Fix false positive for cppcoreguidelines-pro-bounds-

[clang-tools-extra] [clang-tidy] Add check for assignment or comparision operators' operand in `readability-math-missing-parentheses` (PR #141345)

2025-05-25 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL approved this pull request. https://github.com/llvm/llvm-project/pull/141345 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] properly handle private move constructors in `modernize-pass-by-value` check (PR #141304)

2025-05-25 Thread Piotr Zegar via cfe-commits
@@ -225,8 +257,9 @@ void PassByValueCheck::registerMatchers(MatchFinder *Finder) { .bind("Param"), hasDeclaration(cxxConstructorDecl( isCopyConstructor(), unless(isDeleted()), -

[clang-tools-extra] [clang-tidy] properly handle private move constructors in `modernize-pass-by-value` check (PR #141304)

2025-05-25 Thread Baranov Victor via cfe-commits
@@ -225,8 +257,9 @@ void PassByValueCheck::registerMatchers(MatchFinder *Finder) { .bind("Param"), hasDeclaration(cxxConstructorDecl( isCopyConstructor(), unless(isDeleted()), -

[clang-tools-extra] [clang-tidy] Fix false positives with deducing this in `readability-convert-member-functions-to-static` check (PR #141391)

2025-05-25 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/141391 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Fix false positives with deducing this in `readability-convert-member-functions-to-static` check (PR #141391)

2025-05-25 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor edited https://github.com/llvm/llvm-project/pull/141391 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Fix false positives with deducing this in `readability-convert-member-functions-to-static` check (PR #141391)

2025-05-25 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,22 @@ +// RUN: %check_clang_tidy -std=c++23 %s readability-convert-member-functions-to-static %t vbvictor wrote: ```suggestion // RUN: %check_clang_tidy -std=c++23-or-later %s readability-convert-member-functions-to-static %t ``` https://github.com/

[clang-tools-extra] [clang-tidy] Fix false positives with deducing this in `readability-convert-member-functions-to-static` check (PR #141391)

2025-05-25 Thread via cfe-commits
https://github.com/flovent updated https://github.com/llvm/llvm-project/pull/141391 >From ed6afd70a94af00cbbfad19a12abce0e01452a1a Mon Sep 17 00:00:00 2001 From: flovent Date: Sun, 25 May 2025 09:37:47 +0800 Subject: [PATCH 1/5] [clang-tidy] fix false positives with deducing this in `readabili

[clang] 9a440f8 - [analyzer] Ignore [[clang::flag_enum]] enums in the EnumCastOutOfRange checker (#141232)

2025-05-25 Thread via cfe-commits
Author: Balazs Benics Date: 2025-05-25T11:59:50+02:00 New Revision: 9a440f84773c56d3803f330774acb2b4f471d5b4 URL: https://github.com/llvm/llvm-project/commit/9a440f84773c56d3803f330774acb2b4f471d5b4 DIFF: https://github.com/llvm/llvm-project/commit/9a440f84773c56d3803f330774acb2b4f471d5b4.diff

[clang] [analyzer] Ignore [[clang::flag_enum]] enums in the EnumCastOutOfRange checker (PR #141232)

2025-05-25 Thread Balazs Benics via cfe-commits
https://github.com/steakhal closed https://github.com/llvm/llvm-project/pull/141232 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] properly handle private move constructors in `modernize-pass-by-value` check (PR #141304)

2025-05-25 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor edited https://github.com/llvm/llvm-project/pull/141304 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] properly handle private move constructors in `modernize-pass-by-value` check (PR #141304)

2025-05-25 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor edited https://github.com/llvm/llvm-project/pull/141304 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] properly handle private move constructors in `modernize-pass-by-value` check (PR #141304)

2025-05-25 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor edited https://github.com/llvm/llvm-project/pull/141304 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC] Fix bad link in `clang/lib/Sema/SemaTypeTraits.cpp` (PR #141405)

2025-05-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Connector Switch (c8ef) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/141405.diff 1 Files Affected: - (modified) clang/lib/Sema/SemaTypeTraits.cpp (+1-1) ``diff diff --git a/clang/lib/Sema/SemaTypeTraits.c

[clang] [NFC] Fix bad link in `clang/lib/Sema/SemaTypeTraits.cpp` (PR #141405)

2025-05-25 Thread Connector Switch via cfe-commits
https://github.com/c8ef created https://github.com/llvm/llvm-project/pull/141405 None >From 739435d262f0da627b6ae9dbdba7065f16a56ddf Mon Sep 17 00:00:00 2001 From: Connector Switch Date: Sun, 25 May 2025 19:53:39 +0800 Subject: [PATCH] fix bad link --- clang/lib/Sema/SemaTypeTraits.cpp | 2 +-

[clang] [NFC] Fix bad link in `clang/lib/Sema/SemaTypeTraits.cpp` (PR #141405)

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

[clang] [CIR] Upstream global initialization for ComplexType (PR #141369)

2025-05-25 Thread Henrich Lauko via cfe-commits
@@ -577,12 +577,31 @@ mlir::Attribute ConstantEmitter::tryEmitPrivate(const APValue &value, case APValue::Union: cgm.errorNYI("ConstExprEmitter::tryEmitPrivate struct or union"); return {}; - case APValue::FixedPoint: case APValue::ComplexInt: - case APValue::Co

[clang] [Clang][AST] Fix HandleLValueBase to deal with references (PR #140105)

2025-05-25 Thread A. Jiang via cfe-commits
frederick-vs-ja wrote: > @frederick-vs-ja Were you able to create a PR for this backport? I created #140246 for this backport, and that PR is already merged. https://github.com/llvm/llvm-project/pull/140105 ___ cfe-commits mailing list cfe-commits@lis

[clang] [libcxx] [Clang] Add __builtin_common_reference (PR #121199)

2025-05-25 Thread via cfe-commits
huixie90 wrote: FWIW, I created patch https://github.com/llvm/llvm-project/pull/141408 to implement the libc++ counter part of the missing bit. So can i request to merge this patch after landing of my patch? the benifits are : - Avoid behaviour differences between the two branches - having mor

[clang] [llvm] Add macro to suppress -Wunnecessary-virtual-specifier (PR #139614)

2025-05-25 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `bolt-x86_64-ubuntu-shared` running on `bolt-worker` while building `clang,llvm` at step 5 "build-bolt". Full details are available at: https://lab.llvm.org/buildbot/#/builders/151/builds/5818 Here is the relevant piece of th

[clang] [llvm] Add macro to suppress -Wunnecessary-virtual-specifier (PR #139614)

2025-05-25 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `bolt-x86_64-ubuntu-dylib` running on `bolt-worker` while building `clang,llvm` at step 5 "build-bolt". Full details are available at: https://lab.llvm.org/buildbot/#/builders/119/builds/5689 Here is the relevant piece of the

[clang-tools-extra] [clang-tidy] Fix false positives with deducing this in `readability-convert-member-functions-to-static` check (PR #141391)

2025-05-25 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,14 @@ +// RUN: %check_clang_tidy -std=c++23 %s readability-convert-member-functions-to-static %t + +namespace std{ + class string {}; + void println(const char *format, const std::string &str) {} +} + +namespace PR141381 { vbvictor wrote: Nit: don't

[clang-tools-extra] [clang-tidy] Fix false positives with deducing this in `readability-convert-member-functions-to-static` check (PR #141391)

2025-05-25 Thread Baranov Victor via cfe-commits
@@ -62,6 +62,16 @@ AST_MATCHER(CXXMethodDecl, usesThis) { return false; // Stop traversal. } +bool VisitDeclRefExpr(const DeclRefExpr *E) { + if (const auto *PVD = dyn_cast_if_present(E->getDecl()); + PVD && PVD->isExplicitObjectParameter()) { +

[clang-tools-extra] [clang-tidy] Fix false positives with deducing this in `readability-convert-member-functions-to-static` check (PR #141391)

2025-05-25 Thread via cfe-commits
https://github.com/flovent updated https://github.com/llvm/llvm-project/pull/141391 >From 3a7260050f8e8dc271c7fe2a5ec937026136fb6b Mon Sep 17 00:00:00 2001 From: fubowen Date: Sun, 25 May 2025 09:37:47 +0800 Subject: [PATCH 1/3] [clang-tidy] fix false positives with deducing this in `readabili

[clang] [Clang] suggest headers on undeclared errors (PR #140247)

2025-05-25 Thread Jongmyeong Choi via cfe-commits
jongmyeong-choi wrote: I see it now. It's a good topic. I think we need to make more structural decisions and do a lot of pre-work to do this item. For now, let's close this change and discuss it in #139855. https://github.com/llvm/llvm-project/pull/140247 _

[clang] [Clang] suggest headers on undeclared errors (PR #140247)

2025-05-25 Thread Jongmyeong Choi via cfe-commits
https://github.com/jongmyeong-choi closed https://github.com/llvm/llvm-project/pull/140247 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Fix false positives with deducing this in `readability-convert-member-functions-to-static` check (PR #141391)

2025-05-25 Thread via cfe-commits
https://github.com/flovent edited https://github.com/llvm/llvm-project/pull/141391 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Fix false positives with deducing this in `readability-convert-member-functions-to-static` check (PR #141391)

2025-05-25 Thread via cfe-commits
@@ -0,0 +1,14 @@ +// RUN: %check_clang_tidy -std=c++23 %s readability-convert-member-functions-to-static %t + +namespace std{ + class string {}; + void println(const char *format, const std::string &str) {} +} + +namespace PR141381 { +struct Hello { + std::string str_; + + vo

[clang] [clang-format] Add ApplyAlwaysOnePerLineToTemplateArguments option (PR #137544)

2025-05-25 Thread via cfe-commits
rmarker wrote: > @rmarker as of now the option`ApplyAlwaysOnePerLineToTemplateArguments` makes > any changes in the formatting only when `BinPackParameters: AlwaysOnePerLine` > and it makes it behave as if `BinPackParameters` was set to `OnePerLine` for > templates, so it puts each argument on

[clang-tools-extra] [clang-tidy][clangd] Fixed removeFunctionArgs don't remove comma for use-ranges check (PR #118568)

2025-05-25 Thread Baranov Victor via cfe-commits
@@ -164,6 +165,24 @@ void UseRangesCheck::registerMatchers(MatchFinder *Finder) { static void removeFunctionArgs(DiagnosticBuilder &Diag, const CallExpr &Call, ArrayRef Indexes, const ASTContext &Ctx) { + const aut

[clang-tools-extra] Follow style configuration in clangd when inserting missing includes (PR #140594)

2025-05-25 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 requested changes to this pull request. https://github.com/llvm/llvm-project/pull/140594 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] Follow style configuration in clangd when inserting missing includes (PR #140594)

2025-05-25 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > > But since we have both config options, maybe there is a reason for > > overwrites in this direction as well. > > Hmm, I was mainly focusing on the quoted -> angled case, hence why only the > `AngledHeaders` filter is used. But I have to agree that following the config

[clang] [Clang][CodeGen] Add metadata for load from reference (PR #98746)

2025-05-25 Thread Yingwei Zheng via cfe-commits
https://github.com/dtcxzyw closed https://github.com/llvm/llvm-project/pull/98746 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Reapply CWG2369 "Ordering between constraints and substitution" (PR #122423)

2025-05-25 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/122423 >From 56bacf47c53aca276ae4fa6aa2972b7eda152ddd Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Fri, 10 Jan 2025 09:46:24 +0800 Subject: [PATCH 01/16] Reapply "[Clang] Implement CWG2369 "Ordering between const

[clang] [llvm] [Clang][LoongArch] Support target attribute for function (PR #140700)

2025-05-25 Thread via cfe-commits
https://github.com/Ami-zhang updated https://github.com/llvm/llvm-project/pull/140700 >From 3355685f4debcd901f27efccc346de0f302a796c Mon Sep 17 00:00:00 2001 From: Ami-zhang Date: Wed, 14 May 2025 15:21:54 +0800 Subject: [PATCH 1/2] [Clang][LoongArch] Support target attribute for function This

[clang] [Clang] Reapply CWG2369 "Ordering between constraints and substitution" (PR #122423)

2025-05-25 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/122423 >From 56bacf47c53aca276ae4fa6aa2972b7eda152ddd Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Fri, 10 Jan 2025 09:46:24 +0800 Subject: [PATCH 01/17] Reapply "[Clang] Implement CWG2369 "Ordering between const

[clang] [Clang] Reapply CWG2369 "Ordering between constraints and substitution" (PR #122423)

2025-05-25 Thread Younan Zhang via cfe-commits
zyn0217 wrote: @cor3ntin it's ready :) https://github.com/llvm/llvm-project/pull/122423 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [llvm] Add IR Profile-Guided Optimization (IR PGO) support to the Flang compiler (PR #136098)

2025-05-25 Thread via cfe-commits
https://github.com/fanju110 updated https://github.com/llvm/llvm-project/pull/136098 >From 9494c9752400e4708dbc8b6a5ca4993ea9565e95 Mon Sep 17 00:00:00 2001 From: fanyikang Date: Thu, 17 Apr 2025 15:17:07 +0800 Subject: [PATCH 01/13] Add support for IR PGO (-fprofile-generate/-fprofile-use=/fi

[clang-tools-extra] [clang-tidy] added `AllowedTypes` option to `readability-qualified-auto` check (PR #136571)

2025-05-25 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor updated https://github.com/llvm/llvm-project/pull/136571 >From ac83f555e2667c516bdd194d9006a2a7bc4d9af7 Mon Sep 17 00:00:00 2001 From: Victor Baranov Date: Mon, 21 Apr 2025 18:29:28 +0300 Subject: [PATCH 1/2] added Allowed types to qualified-auto --- .../readabilit

[clang-tools-extra] [clang-tidy] Improve `bugprone-exception-escape`: add stacktrace of escaped exception (PR #134375)

2025-05-25 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor edited https://github.com/llvm/llvm-project/pull/134375 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Handle Java text blocks (PR #141334)

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

[clang] [ByteCode] Drop const from a return type (NFC) (PR #141415)

2025-05-25 Thread Tim Gymnich via cfe-commits
https://github.com/tgymnich approved this pull request. https://github.com/llvm/llvm-project/pull/141415 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] d2eec93 - replace the extension with the right functions (#141110)

2025-05-25 Thread via cfe-commits
Author: Sean Perry Date: 2025-05-25T15:07:20-04:00 New Revision: d2eec93f7c652946e98b4c872ddf1d353b28dabe URL: https://github.com/llvm/llvm-project/commit/d2eec93f7c652946e98b4c872ddf1d353b28dabe DIFF: https://github.com/llvm/llvm-project/commit/d2eec93f7c652946e98b4c872ddf1d353b28dabe.diff LO

[clang] replace the extension with the right functions (PR #141110)

2025-05-25 Thread Sean Perry via cfe-commits
https://github.com/perry-ca closed https://github.com/llvm/llvm-project/pull/141110 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libcxx] [Clang] Add __builtin_common_reference (PR #121199)

2025-05-25 Thread via cfe-commits
@@ -3231,6 +3241,230 @@ static QualType builtinCommonTypeImpl(Sema &S, TemplateName BaseTemplate, } } +static QualType CopyCV(QualType From, QualType To) { + if (From.isConstQualified()) +To.addConst(); + if (From.isVolatileQualified()) +To.addVolatile(); + retur

[clang] [Driver] Remove unused includes (NFC) (PR #141448)

2025-05-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-hexagon Author: Kazu Hirata (kazutakahirata) Changes These are identified by misc-include-cleaner. I've filtered out those that break builds. Also, I'm staying away from llvm-config.h, config.h, and Compiler.h, which likely cause platform- or c

[clang] [Driver] Remove unused includes (NFC) (PR #141448)

2025-05-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-loongarch Author: Kazu Hirata (kazutakahirata) Changes These are identified by misc-include-cleaner. I've filtered out those that break builds. Also, I'm staying away from llvm-config.h, config.h, and Compiler.h, which likely cause platform- or

[clang-tools-extra] [clang-tidy] Fix false negative `modernize-use-ranges` when using getter function (PR #127377)

2025-05-25 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 requested changes to this pull request. https://github.com/llvm/llvm-project/pull/127377 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver][X86] Add -m[no-]apxf to m_x86_Features_Group (PR #140874)

2025-05-25 Thread Shengchen Kan via cfe-commits
https://github.com/KanRobert approved this pull request. https://github.com/llvm/llvm-project/pull/140874 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Add avoid-pragma-once. (PR #140388)

2025-05-25 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/140388 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 64bc35f - [NFC] Fix bad link in `clang/lib/Sema/SemaTypeTraits.cpp` (#141405)

2025-05-25 Thread via cfe-commits
Author: Connector Switch Date: 2025-05-26T10:13:14+08:00 New Revision: 64bc35f33e9d330e1bfff07436010b43ce332d9b URL: https://github.com/llvm/llvm-project/commit/64bc35f33e9d330e1bfff07436010b43ce332d9b DIFF: https://github.com/llvm/llvm-project/commit/64bc35f33e9d330e1bfff07436010b43ce332d9b.di

[clang] [llvm] [clang][RISCV] Emit RISCV function-signature-based CFI label in llvm::Function metadata (PR #111661)

2025-05-25 Thread Ming-Yi Lai via cfe-commits
mylai-mtk wrote: > For missing prototypes, we can statically detect calls which pass arguments > to function without a prototype. Generating code we know will never work, > without a diagnostic, is a bad idea. @efriedma-quic If what you need to see are diagnostics, I can add them in this PR.

[clang] [Driver] Remove unused includes (NFC) (PR #141448)

2025-05-25 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/141448 These are identified by misc-include-cleaner. I've filtered out those that break builds. Also, I'm staying away from llvm-config.h, config.h, and Compiler.h, which likely cause platform- or compiler-spec

[clang] [Driver][X86] Add -m[no-]apxf to m_x86_Features_Group (PR #140874)

2025-05-25 Thread Feng Zou via cfe-commits
https://github.com/fzou1 closed https://github.com/llvm/llvm-project/pull/140874 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Options] Add same-address constraint to the description of '-m[no]ld-seq-sa' (PR #141192)

2025-05-25 Thread via cfe-commits
https://github.com/Ami-zhang updated https://github.com/llvm/llvm-project/pull/141192 >From 31897be26bf2f2cdb43883adc9bb43dee7008887 Mon Sep 17 00:00:00 2001 From: Ami-zhang Date: Fri, 23 May 2025 10:21:00 +0800 Subject: [PATCH] [NFC][Options] Add same-address constraint to the description of

[clang-tools-extra] [clang-tidy] Fix false negative `modernize-use-ranges` when using getter function (PR #127377)

2025-05-25 Thread Congcong Cai via cfe-commits
HerrCai0907 wrote: Maybe it is more straightforward to detect function which return ref of member variable like `const std::vector& get() const { return v; }` and bypass the SideEffect check. https://github.com/llvm/llvm-project/pull/127377 ___ cfe-c

[clang] 7af14e5 - [NFC][Options] Add same-address constraint to the description of '-m[no]ld-seq-sa' (#141192)

2025-05-25 Thread via cfe-commits
Author: Ami-zhang Date: 2025-05-26T10:53:17+08:00 New Revision: 7af14e5118dcc308f32857f78886bbad12ff9e92 URL: https://github.com/llvm/llvm-project/commit/7af14e5118dcc308f32857f78886bbad12ff9e92 DIFF: https://github.com/llvm/llvm-project/commit/7af14e5118dcc308f32857f78886bbad12ff9e92.diff LOG

[clang] [llvm] [Options] Add same-address constraint to the description of '-m[no]ld-seq-sa' (PR #141192)

2025-05-25 Thread via cfe-commits
https://github.com/Ami-zhang closed https://github.com/llvm/llvm-project/pull/141192 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 641b2a5 - [Driver][X86] Add -m[no-]apxf to m_x86_Features_Group (#140874)

2025-05-25 Thread via cfe-commits
Author: Feng Zou Date: 2025-05-26T10:42:53+08:00 New Revision: 641b2a58ea55b5532639ca7eb3a8a5795c87bd5d URL: https://github.com/llvm/llvm-project/commit/641b2a58ea55b5532639ca7eb3a8a5795c87bd5d DIFF: https://github.com/llvm/llvm-project/commit/641b2a58ea55b5532639ca7eb3a8a5795c87bd5d.diff LOG:

[clang] [CodeGen] Remove unused includes (NFC) (PR #141418)

2025-05-25 Thread Shilei Tian via cfe-commits
https://github.com/shiltian approved this pull request. https://github.com/llvm/llvm-project/pull/141418 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CodeGen] Remove unused includes (NFC) (PR #141418)

2025-05-25 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm approved this pull request. https://github.com/llvm/llvm-project/pull/141418 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [StaticAnalyzer] Drop const from a return type (NFC) (PR #141414)

2025-05-25 Thread Balazs Benics via cfe-commits
https://github.com/steakhal approved this pull request. https://github.com/llvm/llvm-project/pull/141414 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver] Use StringRef::consume_front (NFC) (PR #141412)

2025-05-25 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm approved this pull request. https://github.com/llvm/llvm-project/pull/141412 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Remove unused includes (NFC) (PR #141420)

2025-05-25 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm approved this pull request. https://github.com/llvm/llvm-project/pull/141420 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] support query based custom check (PR #131804)

2025-05-25 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 updated https://github.com/llvm/llvm-project/pull/131804 >From a686695e6691fcb824b2055c3dfa8f0fd3727355 Mon Sep 17 00:00:00 2001 From: DeNiCoN Date: Mon, 17 Mar 2025 08:04:32 + Subject: [PATCH 01/12] origin pr --- clang-tools-extra/clang-tidy/CMakeLists.txt

[clang] [StaticAnalyzer] Drop const from a return type (NFC) (PR #141414)

2025-05-25 Thread Matt Arsenault via cfe-commits
@@ -537,7 +537,7 @@ class StdLibraryFunctionsChecker /// a later bug report created by ErrnoChecker. /// Empty return value means that 'errno' related bug may not happen from /// the current analyzed function. -virtual const std::string describe(CheckerContext &

[clang] [StaticAnalyzer] Drop const from a return type (NFC) (PR #141414)

2025-05-25 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm approved this pull request. https://github.com/llvm/llvm-project/pull/141414 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [TableGen] Use StringRef::contains (NFC) (PR #141413)

2025-05-25 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm approved this pull request. https://github.com/llvm/llvm-project/pull/141413 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Remove unused includes (NFC) (PR #141419)

2025-05-25 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm approved this pull request. https://github.com/llvm/llvm-project/pull/141419 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Remove unused includes (NFC) (PR #141417)

2025-05-25 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm approved this pull request. https://github.com/llvm/llvm-project/pull/141417 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [StaticAnalyzer] Drop const from a return type (NFC) (PR #141414)

2025-05-25 Thread Kazu Hirata via cfe-commits
@@ -537,7 +537,7 @@ class StdLibraryFunctionsChecker /// a later bug report created by ErrnoChecker. /// Empty return value means that 'errno' related bug may not happen from /// the current analyzed function. -virtual const std::string describe(CheckerContext &

[clang] [clang-format] Handle Java text blocks (PR #141334)

2025-05-25 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-x86_64-linux-fast` running on `sanitizer-buildbot4` while building `clang` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/169/builds/11756 Here is the relevant piece

[clang-tools-extra] eda3e96 - [clang-tidy] Fix false positives in `bugprone-crtp-constructor-accessibility` check (#132543)

2025-05-25 Thread via cfe-commits
Author: Baranov Victor Date: 2025-05-26T06:25:19+03:00 New Revision: eda3e96b401a9b86132e39432e41e2000d1ab382 URL: https://github.com/llvm/llvm-project/commit/eda3e96b401a9b86132e39432e41e2000d1ab382 DIFF: https://github.com/llvm/llvm-project/commit/eda3e96b401a9b86132e39432e41e2000d1ab382.diff

[clang-tools-extra] [clang-tidy] Fix false positives in `bugprone-crtp-constructor-accessibility` check (PR #132543)

2025-05-25 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor closed https://github.com/llvm/llvm-project/pull/132543 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libunwind] [libunwind][Haiku] Fix signal frame unwinding (PR #135367)

2025-05-25 Thread Trung Nguyen via cfe-commits
https://github.com/trungnt2910 updated https://github.com/llvm/llvm-project/pull/135367 >From 7d363093d85084e8f7f4c3994f207a36781ededc Mon Sep 17 00:00:00 2001 From: Trung Nguyen Date: Fri, 11 Apr 2025 23:53:14 +1000 Subject: [PATCH] [libunwind][Haiku] Fix signal frame unwinding The current un

[clang] [llvm] [Clang][LoongArch] Support target attribute for function (PR #140700)

2025-05-25 Thread via cfe-commits
https://github.com/heiher edited https://github.com/llvm/llvm-project/pull/140700 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Clang][LoongArch] Support target attribute for function (PR #140700)

2025-05-25 Thread via cfe-commits
@@ -388,6 +388,76 @@ bool LoongArchTargetInfo::handleTargetFeatures( return true; } +enum class AttrFeatureKind { Arch, Tune, NoFeature, Feature, Invalid }; + +static std::pair +getAttrFeatureTypeAndValue(llvm::StringRef AttrFeature) { + if (auto Split = AttrFeature.split("

[libunwind] [libunwind][Haiku] Fix signal frame unwinding (PR #135367)

2025-05-25 Thread Trung Nguyen via cfe-commits
trungnt2910 wrote: The latest commit is known to build well on `i386`. Signal frame unwinding is still not supported, but I believe this is out of scope for this PR. https://github.com/llvm/llvm-project/pull/135367 ___ cfe-commits mailing list cfe-com

[clang] [llvm] [Clang][LoongArch] Support target attribute for function (PR #140700)

2025-05-25 Thread via cfe-commits
https://github.com/heiher approved this pull request. LGTM with nits. https://github.com/llvm/llvm-project/pull/140700 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2025-05-25 Thread Fangrui Song via cfe-commits
@@ -44,7 +44,11 @@ define void @varargs_caller() nounwind { ; CHECK-NEXT:stp xzr, x30, [sp, #24] // 8-byte Folded Spill ; CHECK-NEXT:stp x9, x8, [sp] ; CHECK-NEXT:str xzr, [sp, #16] -; CHECK-NEXT:bl varargs_callee +; CHECK-NEXT:.weak_anti_dep varargs_callee

[clang-tools-extra] Follow style configuration in clangd when inserting missing includes (PR #140594)

2025-05-25 Thread Nathan Ridge via cfe-commits
@@ -262,6 +264,8 @@ TEST(IncludeCleaner, GenerateMissingHeaderDiags) { TU.Filename = "main.cpp"; TU.AdditionalFiles["a.h"] = guard("#include \"b.h\""); TU.AdditionalFiles["b.h"] = guard("void b();"); + TU.AdditionalFiles["a_angled.h"] = guard("#include \"b_angled.h\"");

[clang] [flang] [llvm] Add IR Profile-Guided Optimization (IR PGO) support to the Flang compiler (PR #136098)

2025-05-25 Thread via cfe-commits
fanju110 wrote: > Thank you for seeing this through and making all the little changes. I have > requested reviews from @MaskRay and @aeubanks for the clang side of things. hello,I noticed that this PR has been awaiting clang review for three weeks. I still haven't gotten a comment from them.wo

[clang] [llvm] [Clang][LoongArch] Support target attribute for function (PR #140700)

2025-05-25 Thread via cfe-commits
@@ -388,6 +388,76 @@ bool LoongArchTargetInfo::handleTargetFeatures( return true; } +enum class AttrFeatureKind { Arch, Tune, NoFeature, Feature, Invalid }; + +static std::pair +getAttrFeatureTypeAndValue(llvm::StringRef AttrFeature) { + if (auto Split = AttrFeature.split("

[clang] [llvm] [Clang][LoongArch] Support target attribute for function (PR #140700)

2025-05-25 Thread via cfe-commits
@@ -0,0 +1,19 @@ +// RUN: %clang_cc1 -triple loongarch64-linux-gnu -fsyntax-only -verify %s + +// expected-error@+1 {{function multiversioning is not supported on the current target}} +void __attribute__((target("default"))) bar(void){} + +// expected-error@+1 {{target(arch=..)

[clang] [llvm] [Clang][LoongArch] Support target attribute for function (PR #140700)

2025-05-25 Thread via cfe-commits
@@ -0,0 +1,19 @@ +// RUN: %clang_cc1 -triple loongarch64-linux-gnu -fsyntax-only -verify %s + +// expected-error@+1 {{function multiversioning is not supported on the current target}} +void __attribute__((target("default"))) bar(void){} + +// expected-error@+1 {{target(arch=..)

[libunwind] [libunwind][Haiku] Fix signal frame unwinding (PR #135367)

2025-05-25 Thread Trung Nguyen via cfe-commits
trungnt2910 wrote: Tried to give [x86 unwinding](https://github.com/trungnt2910/libunwind-haiku/commit/61a36e3d8ed6da29653bba63165093cadc5) a shot. The general idea is correct, but it is currently impossible to unwind past a `syscall` due to the system relying on another [magic `commpage`

[clang] 1efa366 - [StaticAnalyzer] Drop const from a return type (NFC) (#141414)

2025-05-25 Thread via cfe-commits
Author: Kazu Hirata Date: 2025-05-25T10:55:18-07:00 New Revision: 1efa366c8717ac5770803f1f4bbad65454009cee URL: https://github.com/llvm/llvm-project/commit/1efa366c8717ac5770803f1f4bbad65454009cee DIFF: https://github.com/llvm/llvm-project/commit/1efa366c8717ac5770803f1f4bbad65454009cee.diff L

[clang] 01138d3 - [AST] Remove unused includes (NFC) (#141417)

2025-05-25 Thread via cfe-commits
Author: Kazu Hirata Date: 2025-05-25T10:55:25-07:00 New Revision: 01138d3f6518c08fe14a527c21c54aefef0e6f57 URL: https://github.com/llvm/llvm-project/commit/01138d3f6518c08fe14a527c21c54aefef0e6f57 DIFF: https://github.com/llvm/llvm-project/commit/01138d3f6518c08fe14a527c21c54aefef0e6f57.diff L

[clang] 031cf05 - [Driver] Use StringRef::consume_front (NFC) (#141412)

2025-05-25 Thread via cfe-commits
Author: Kazu Hirata Date: 2025-05-25T10:55:11-07:00 New Revision: 031cf05f01157f0e4aea1fb546a052525248f74c URL: https://github.com/llvm/llvm-project/commit/031cf05f01157f0e4aea1fb546a052525248f74c DIFF: https://github.com/llvm/llvm-project/commit/031cf05f01157f0e4aea1fb546a052525248f74c.diff L

[clang] [Driver] Use StringRef::consume_front (NFC) (PR #141412)

2025-05-25 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/141412 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] f4b311b - [TableGen] Use StringRef::contains (NFC) (#141413)

2025-05-25 Thread via cfe-commits
Author: Kazu Hirata Date: 2025-05-25T10:55:14-07:00 New Revision: f4b311b5274ceb5d874b13c0daf914dd74c853f6 URL: https://github.com/llvm/llvm-project/commit/f4b311b5274ceb5d874b13c0daf914dd74c853f6 DIFF: https://github.com/llvm/llvm-project/commit/f4b311b5274ceb5d874b13c0daf914dd74c853f6.diff L

[clang] [TableGen] Use StringRef::contains (NFC) (PR #141413)

2025-05-25 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/141413 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

  1   2   >