[clang] [webkit.UncountedLambdaCapturesChecker] Fix a crash in declProtectsThis (PR #127309)

2025-02-15 Thread Ryosuke Niwa via cfe-commits
rniwa wrote: Thanks for the timely review! https://github.com/llvm/llvm-project/pull/127309 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [webkit.UncountedLambdaCapturesChecker] Fix a crash in declProtectsThis (PR #127309)

2025-02-15 Thread Ryosuke Niwa via cfe-commits
https://github.com/rniwa closed https://github.com/llvm/llvm-project/pull/127309 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Disallow virtual inheritance and functions (PR #127346)

2025-02-15 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-hlsl Author: Chris B (llvm-beanz) Changes This PR disallows virtual inheritance and virtual functions in HLSL. --- Full diff: https://github.com/llvm/llvm-project/pull/127346.diff 4 Files Affected: - (modified) clang/include/clang/Basic/DiagnosticPar

[clang] [clang] [Driver] Fix respecting libdir when locating flang runtime (PR #127345)

2025-02-15 Thread Fangrui Song via cfe-commits
MaskRay wrote: CLANG_INSTALL_LIBDIR_BASENAME can be "lib" or "lib64". I think it should only be used for libraries outside of llvm-project, like how cuda/amdgpu libs are installed by system. For llvm-project installed libs, it's much better to stick with a uniform "lib", which is easy to test

[clang] [FreeBSD] Support -stdlib=libstdc++ (PR #126302)

2025-02-15 Thread Alexander Richardson via cfe-commits
arichardson wrote: ping, is this ok to merge? https://github.com/llvm/llvm-project/pull/126302 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] [Driver] Fix respecting libdir when locating flang runtime (PR #127345)

2025-02-15 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver @llvm/pr-subscribers-clang Author: Michał Górny (mgorny) Changes Fix `tools::addFortranRuntimeLibraryPath` to use `CLANG_INSTALL_LIBDIR_BASENAME` rather than hardwired `lib` directory. This fixes flang being unable to find its runtime when

[clang] [HLSL] Implement HLSL intialization list support (PR #123141)

2025-02-15 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `ppc64le-lld-multistage-test` running on `ppc64le-lld-multistage-test` while building `clang` at step 12 "build-stage2-unified-tree". Full details are available at: https://lab.llvm.org/buildbot/#/builders/168/builds/8747 He

[clang] [clang] [Driver] Fix respecting libdir when locating flang runtime (PR #127345)

2025-02-15 Thread Michał Górny via cfe-commits
https://github.com/mgorny created https://github.com/llvm/llvm-project/pull/127345 Fix `tools::addFortranRuntimeLibraryPath` to use `CLANG_INSTALL_LIBDIR_BASENAME` rather than hardwired `lib` directory. This fixes flang being unable to find its runtime when installed into nonstandard directory

[clang] [clang-tools-extra] [libcxx] [llvm] [libc++][ranges] P2542R8: Implement `views::concat` (PR #120920)

2025-02-15 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung updated https://github.com/llvm/llvm-project/pull/120920 error: too big or took too long to generate ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

[clang] [HLSL] Implement HLSL intialization list support (PR #123141)

2025-02-15 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-ppc64le-linux` running on `ppc64le-sanitizer` while building `clang` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/72/builds/8263 Here is the relevant piece of the bu

[clang] [HLSL] Implement HLSL intialization list support (PR #123141)

2025-02-15 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-ppc64le-rhel` running on `ppc64le-clang-rhel-test` while building `clang` at step 5 "build-unified-tree". Full details are available at: https://lab.llvm.org/buildbot/#/builders/145/builds/5160 Here is the relevant pi

[clang] [HLSL] Disallow virtual inheritance and functions (PR #127346)

2025-02-15 Thread Chris B via cfe-commits
https://github.com/llvm-beanz created https://github.com/llvm/llvm-project/pull/127346 This PR disallows virtual inheritance and virtual functions in HLSL. >From e62dc4bfc4f1cff2a624caf70fcc7bb0dc4a6236 Mon Sep 17 00:00:00 2001 From: Chris Bieneman Date: Sat, 15 Feb 2025 14:34:05 -0600 Subject

[clang] 50581ef - [NFC] Fix warning in recent commit

2025-02-15 Thread Chris Bieneman via cfe-commits
Author: Chris Bieneman Date: 2025-02-15T14:19:31-06:00 New Revision: 50581ef1ee45815b9230043319de5ae93680d4ad URL: https://github.com/llvm/llvm-project/commit/50581ef1ee45815b9230043319de5ae93680d4ad DIFF: https://github.com/llvm/llvm-project/commit/50581ef1ee45815b9230043319de5ae93680d4ad.diff

[clang] [HLSL] Disallow virtual inheritance and functions (PR #127346)

2025-02-15 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff 50581ef1ee45815b9230043319de5ae93680d4ad e62dc4bfc4f1cff2a624caf70fcc7bb0dc4a6236 --e

[clang] Reapply "[Analyzer][CFG] Correctly handle rebuilt default arg and default init expression" (PR #127338)

2025-02-15 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (yronglin) Changes This PR reapply https://github.com/llvm/llvm-project/pull/117437. --- Full diff: https://github.com/llvm/llvm-project/pull/127338.diff 10 Files Affected: - (modified) clang/docs/ReleaseNotes.rst (+4) - (modifie

[clang] Reapply "[Analyzer][CFG] Correctly handle rebuilt default arg and default init expression" (PR #127338)

2025-02-15 Thread via cfe-commits
https://github.com/yronglin edited https://github.com/llvm/llvm-project/pull/127338 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Reapply "[Analyzer][CFG] Correctly handle rebuilt default arg and default init expression" (PR #127338)

2025-02-15 Thread via cfe-commits
https://github.com/yronglin created https://github.com/llvm/llvm-project/pull/127338 This PR reapply https://github.com/llvm/llvm-project/pull/117437. >From 092af69607909859e9d352e51122d9569c050464 Mon Sep 17 00:00:00 2001 From: yronglin Date: Sat, 15 Feb 2025 17:03:32 +0800 Subject: [PATCH 1

[clang-tools-extra] [clang-tidy] Add support for `-ignore-insert-conflict` in `run-clang-tidy.py` (PR #127066)

2025-02-15 Thread Nicolas van Kempen via cfe-commits
Vicente Mataix =?utf-8?q?Ferrándiz?= , Vicente Mataix =?utf-8?q?Ferrándiz?= , Vicente Mataix =?utf-8?q?Ferrándiz?= Message-ID: In-Reply-To: @@ -446,6 +448,12 @@ async def main() -> None: action="store_true", help="Allow empty enabled checks.", ) +pars

[clang-tools-extra] [clang-tidy] Add performance-redundant-lookup check (PR #125420)

2025-02-15 Thread Balazs Benics via cfe-commits
@@ -91,6 +91,12 @@ Improvements to clang-tidy New checks ^^ +- New :doc:`performance-redundant-lookup + ` check. + + This check warns about potential redundant container lookup operations within steakhal wrote: Dropped in c6a681c955fef8b933374a05a15

[clang] [webkit.UncountedLambdaCapturesChecker] Fix a crash in declProtectsThis (PR #127309)

2025-02-15 Thread Rashmi Mudduluru via cfe-commits
https://github.com/t-rasmud approved this pull request. https://github.com/llvm/llvm-project/pull/127309 ___ 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 performance-redundant-lookup check (PR #125420)

2025-02-15 Thread Balazs Benics via cfe-commits
steakhal wrote: > @steakhal: Please fix documentation and Release Notes wording that I > mentioned already. Thanks, fixed! I'm actually more curious about the semantic requirements, and about what directions should I explore more. https://github.com/llvm/llvm-project/pull/125420 _

[clang] Reapply "[Analyzer][CFG] Correctly handle rebuilt default arg and default init expression" (PR #127338)

2025-02-15 Thread Balazs Benics via cfe-commits
@@ -2464,6 +2464,10 @@ CFGBlock *CFGBuilder::VisitCXXDefaultInitExpr(CXXDefaultInitExpr *Init, autoCreateBlock(); appendStmt(Block, Init); } + +// Unlike CXXDefaultArgExpr::getExpr stripped off the top level FullExpr and +// ConstantExpr, CXXDefaultIni

[clang] Reapply "[Analyzer][CFG] Correctly handle rebuilt default arg and default init expression" (PR #127338)

2025-02-15 Thread via cfe-commits
https://github.com/yronglin updated https://github.com/llvm/llvm-project/pull/127338 >From 092af69607909859e9d352e51122d9569c050464 Mon Sep 17 00:00:00 2001 From: yronglin Date: Sat, 15 Feb 2025 17:03:32 +0800 Subject: [PATCH 1/2] [Analyzer][CFG] Correctly handle rebuilt default arg and defaul

[clang] [clang][CodeGen] `sret` args should always point to the `alloca` AS, so use that (PR #114062)

2025-02-15 Thread Matt Arsenault via cfe-commits
arsenm wrote: > seeing breaks in downstream build of rocPRIM Probably need to revert the downstream revert of the original problematic patch https://github.com/llvm/llvm-project/pull/114062 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http

[clang] [clang] [Driver] Fix respecting libdir when locating flang runtime (PR #127345)

2025-02-15 Thread Michał Górny via cfe-commits
mgorny wrote: But `lib` is used for 32-bit libraries, and `lib64` for 64-bit libraries. https://github.com/llvm/llvm-project/pull/127345 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [CMake][Release] Statically link clang with stage1 runtimes (PR #127268)

2025-02-15 Thread Tom Stellard via cfe-commits
https://github.com/tstellar updated https://github.com/llvm/llvm-project/pull/127268 >From a705acfd439e6310648b0ed1ad612eaffc408ad5 Mon Sep 17 00:00:00 2001 From: Tom Stellard Date: Fri, 14 Feb 2025 17:46:25 + Subject: [PATCH 1/6] [CMake][Release] Statically link clang with stage1 runtimes

[clang] [clang-tools-extra] [libcxx] [llvm] [libc++][ranges] P2542R8: Implement `views::concat` (PR #120920)

2025-02-15 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung updated https://github.com/llvm/llvm-project/pull/120920 error: too big or took too long to generate ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

[clang] [HLSL] Disallow virtual inheritance and functions (PR #127346)

2025-02-15 Thread Chris B via cfe-commits
https://github.com/llvm-beanz updated https://github.com/llvm/llvm-project/pull/127346 >From e62dc4bfc4f1cff2a624caf70fcc7bb0dc4a6236 Mon Sep 17 00:00:00 2001 From: Chris Bieneman Date: Sat, 15 Feb 2025 14:34:05 -0600 Subject: [PATCH 1/2] [HLSL] Disallow virtual inheritance and functions This

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Chris B via cfe-commits
https://github.com/llvm-beanz approved this pull request. https://github.com/llvm/llvm-project/pull/127098 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [FreeBSD] Support -stdlib=libstdc++ (PR #126302)

2025-02-15 Thread Fangrui Song via cfe-commits
@@ -1,9 +1,13 @@ // RUN: %clangxx %s -### -o %t.o --target=amd64-unknown-freebsd -stdlib=platform 2>&1 \ // RUN: | FileCheck --check-prefix=CHECK-DEFAULT %s // RUN: %clangxx %s -### -o %t.o --target=amd64-unknown-freebsd10.0 -stdlib=platform 2>&1 \ -// RUN: | FileCheck --

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Farzon Lotfi via cfe-commits
@@ -4765,6 +4765,12 @@ def HLSLAll : LangBuiltin<"HLSL_LANG"> { let Prototype = "bool(...)"; } +def HLSLAnd : LangBuiltin<"HLSL_LANG"> { + let Spellings = ["__builtin_hlsl_and"]; farzonl wrote: I suppose the reason there is no c++ builtin existing here is

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Farzon Lotfi via cfe-commits
@@ -19463,6 +19463,11 @@ Value *CodeGenFunction::EmitHLSLBuiltinExpr(unsigned BuiltinID, CGM.getHLSLRuntime().getAllIntrinsic(), ArrayRef{Op0}, nullptr, "hlsl.all"); } + case Builtin::BI__builtin_hlsl_and: { +Value *Op0 = EmitScalarExpr(E->getArg(0)); +

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Farzon Lotfi via cfe-commits
@@ -2245,6 +2245,36 @@ bool SemaHLSL::CheckBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall) { break; } + case Builtin::BI__builtin_hlsl_and: { +if (SemaRef.checkArgCount(TheCall, 2)) + return true; +if (CheckVectorElementCallArgs(&SemaRef, TheCal

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Farzon Lotfi via cfe-commits
@@ -2245,6 +2245,36 @@ bool SemaHLSL::CheckBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall) { break; } + case Builtin::BI__builtin_hlsl_and: { +if (SemaRef.checkArgCount(TheCall, 2)) + return true; +if (CheckVectorElementCallArgs(&SemaRef, TheCal

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl requested changes to this pull request. Codgen and testing is fine. SemaHLSL needs work to conform to how we have been doing things. https://github.com/llvm/llvm-project/pull/127098 ___ cfe-commits mailing list cfe-commits@

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Deric Cheung via cfe-commits
@@ -2245,6 +2245,36 @@ bool SemaHLSL::CheckBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall) { break; } + case Builtin::BI__builtin_hlsl_and: { +if (SemaRef.checkArgCount(TheCall, 2)) + return true; +if (CheckVectorElementCallArgs(&SemaRef, TheCal

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Deric Cheung via cfe-commits
https://github.com/Icohedron edited https://github.com/llvm/llvm-project/pull/127098 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Farzon Lotfi via cfe-commits
@@ -2245,6 +2245,36 @@ bool SemaHLSL::CheckBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall) { break; } + case Builtin::BI__builtin_hlsl_and: { +if (SemaRef.checkArgCount(TheCall, 2)) + return true; +if (CheckVectorElementCallArgs(&SemaRef, TheCal

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Chris B via cfe-commits
@@ -2245,6 +2245,36 @@ bool SemaHLSL::CheckBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall) { break; } + case Builtin::BI__builtin_hlsl_and: { +if (SemaRef.checkArgCount(TheCall, 2)) + return true; +if (CheckVectorElementCallArgs(&SemaRef, TheCal

[clang] [cindex] Add API to query the class methods of a type (PR #123539)

2025-02-15 Thread Trevor Laughlin via cfe-commits
https://github.com/trelau updated https://github.com/llvm/llvm-project/pull/123539 >From bb0542e8f2ad50892ee9d2c1f76ec1def85c3e56 Mon Sep 17 00:00:00 2001 From: Trevor Laughlin Date: Sun, 19 Jan 2025 19:21:10 -0500 Subject: [PATCH] [cindex] Add API to query the class methods of a type --- cla

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Deric Cheung via cfe-commits
https://github.com/Icohedron edited https://github.com/llvm/llvm-project/pull/127098 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [cindex] Add API to query the class methods of a type (PR #123539)

2025-02-15 Thread Trevor Laughlin via cfe-commits
trelau wrote: Not sure what happen, but there was a merge conflict with ReleaseNotes.rst where it looked like previous enhancements to liblang and Python bindings had been removed. To resolve the conflict I only left changes relevant to this PR. https://github.com/llvm/llvm-project/pull/123539

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Farzon Lotfi via cfe-commits
@@ -2245,6 +2245,36 @@ bool SemaHLSL::CheckBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall) { break; } + case Builtin::BI__builtin_hlsl_and: { +if (SemaRef.checkArgCount(TheCall, 2)) + return true; +if (CheckVectorElementCallArgs(&SemaRef, TheCal

[clang] [cindex] Add API to query the class methods of a type (PR #123539)

2025-02-15 Thread Trevor Laughlin via cfe-commits
trelau wrote: Ping https://github.com/llvm/llvm-project/pull/123539 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [FreeBSD] Support -stdlib=libstdc++ (PR #126302)

2025-02-15 Thread John Baldwin via cfe-commits
bsdjhb wrote: > It's not missing as in like someone forgot. It is intentional. Same goes for > FreeBSD and OpenBSD's Drivers. The base OS uses libc++ and anything else is > not supported. You could use it with a libstdc++ from ports. GCC supports both variants for the same reason. FreeBSD's

[clang-tools-extra] [clang-tidy] Fix invalid fixit from modernize-use-ranges for nullptr used with std::unique_ptr (PR #127162)

2025-02-15 Thread via cfe-commits
https://github.com/Andrewyuan34 updated https://github.com/llvm/llvm-project/pull/127162 >From c6a732cb59340adfc045196c9c27ad9b2227c377 Mon Sep 17 00:00:00 2001 From: Andrewyuan34 Date: Thu, 13 Feb 2025 22:35:36 -0500 Subject: [PATCH] [clang-tidy] Fix invalid fixit from modernize-use-ranges for

[clang-tools-extra] [clang-tidy] Add support for `-ignore-insert-conflict` in `run-clang-tidy.py` (PR #127066)

2025-02-15 Thread Congcong Cai via cfe-commits
Vicente Mataix =?utf-8?q?Ferrándiz?= , Vicente Mataix =?utf-8?q?Ferrándiz?= , Vicente Mataix =?utf-8?q?Ferrándiz?= Message-ID: In-Reply-To: HerrCai0907 wrote: > Can you help me?, I have no experience in this repository release-note is placed `clang-tools-extra/docs/ReleaseNotes.rst`. You can

[libclc] dbc98cf - [libclc] [cmake] Fix per-target *_convert.cl dependencies (#127315)

2025-02-15 Thread via cfe-commits
Author: Michał Górny Date: 2025-02-16T08:48:52+01:00 New Revision: dbc98cfa46d52ede06e8be7fc5e855d807ba0fac URL: https://github.com/llvm/llvm-project/commit/dbc98cfa46d52ede06e8be7fc5e855d807ba0fac DIFF: https://github.com/llvm/llvm-project/commit/dbc98cfa46d52ede06e8be7fc5e855d807ba0fac.diff

[libclc] [libclc] [cmake] Fix per-target *_convert.cl dependencies (PR #127315)

2025-02-15 Thread Sylvestre Ledru via cfe-commits
https://github.com/sylvestre edited https://github.com/llvm/llvm-project/pull/127315 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libclc] [libclc] [cmake] Fix per-target *_convert.cl dependencies (PR #127315)

2025-02-15 Thread Sylvestre Ledru via cfe-commits
https://github.com/sylvestre closed https://github.com/llvm/llvm-project/pull/127315 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libclc] [libclc] [cmake] Fix per-target *_convert.cl dependencies (PR #127315)

2025-02-15 Thread Sylvestre Ledru via cfe-commits
sylvestre wrote: I will merge it as it as it fixes https://github.com/llvm/llvm-project/issues/127378 and apt.llvm.org has been broken for a few days because of this This PR can be improved later. https://github.com/llvm/llvm-project/pull/127315 __

[clang] Reapply "[Analyzer][CFG] Correctly handle rebuilt default arg and default init expression" (PR #127338)

2025-02-15 Thread via cfe-commits
yronglin wrote: > Well, I don't really know much about these default init exprs but your > explanation looks reasonable. I'd say, we should try it and revert it again > if there are still some problems. Many thanks for the review! https://github.com/llvm/llvm-project/pull/127338 _

[clang] c17df0a - [webkit.UncountedLambdaCapturesChecker] Fix a crash in declProtectsThis (#127309)

2025-02-15 Thread via cfe-commits
Author: Ryosuke Niwa Date: 2025-02-15T11:04:06-08:00 New Revision: c17df0af23c941cd4fc97851ea51c91eee7c49e4 URL: https://github.com/llvm/llvm-project/commit/c17df0af23c941cd4fc97851ea51c91eee7c49e4 DIFF: https://github.com/llvm/llvm-project/commit/c17df0af23c941cd4fc97851ea51c91eee7c49e4.diff

[clang-tools-extra] [clang-tidy] Fix invalid fixit from modernize-use-ranges for nullptr used with std::unique_ptr (PR #127162)

2025-02-15 Thread Baranov Victor via cfe-commits
@@ -109,6 +109,9 @@ Changes in existing checks - Improved :doc:`misc-redundant-expression ` check by providing additional examples and fixing some macro related false positives. + +- Improved :doc:`modernize-use-ranges + ` check by updating suppress warnings logic for `

[clang-tools-extra] [clang-tidy] Fix invalid fixit from modernize-use-ranges for nullptr used with std::unique_ptr (PR #127162)

2025-02-15 Thread via cfe-commits
https://github.com/Andrewyuan34 updated https://github.com/llvm/llvm-project/pull/127162 >From 101ec5ef672d385d91d35c23e3472b7b1d91bc15 Mon Sep 17 00:00:00 2001 From: Andrewyuan34 Date: Thu, 13 Feb 2025 22:35:36 -0500 Subject: [PATCH 1/2] [clang-tidy] Fix invalid fixit from modernize-use-ranges

[clang] [HLSL] Disallow virtual inheritance and functions (PR #127346)

2025-02-15 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl approved this pull request. https://github.com/llvm/llvm-project/pull/127346 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [FreeBSD] Support -stdlib=libstdc++ (PR #126302)

2025-02-15 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay approved this pull request. code/test looks good for me as a driver maintainer. Needs a stamp from a FreeBSD reviewer. https://github.com/llvm/llvm-project/pull/126302 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang-tools-extra] [libcxx] [llvm] [libc++][ranges] P2542R8: Implement `views::concat` (PR #120920)

2025-02-15 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung updated https://github.com/llvm/llvm-project/pull/120920 error: too big or took too long to generate ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl edited https://github.com/llvm/llvm-project/pull/127098 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [FreeBSD] Support -stdlib=libstdc++ (PR #126302)

2025-02-15 Thread Dimitry Andric via cfe-commits
https://github.com/DimitryAndric approved this pull request. https://github.com/llvm/llvm-project/pull/126302 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][CodeGen] `sret` args should always point to the `alloca` AS, so use that (PR #114062)

2025-02-15 Thread via cfe-commits
ronlieb wrote: seeing breaks in downstream build of rocPRIM https://github.com/llvm/llvm-project/pull/114062 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][x86] Support -masm=intel in cpuid.h (PR #127331)

2025-02-15 Thread Phoebe Wang via cfe-commits
phoebewang wrote: Please update test in clang\test\Headers\cpuid.c https://github.com/llvm/llvm-project/pull/127331 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Chris B via cfe-commits
@@ -2245,6 +2245,36 @@ bool SemaHLSL::CheckBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall) { break; } + case Builtin::BI__builtin_hlsl_and: { +if (SemaRef.checkArgCount(TheCall, 2)) + return true; +if (CheckVectorElementCallArgs(&SemaRef, TheCal

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Chris B via cfe-commits
@@ -2245,6 +2245,36 @@ bool SemaHLSL::CheckBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall) { break; } + case Builtin::BI__builtin_hlsl_and: { +if (SemaRef.checkArgCount(TheCall, 2)) + return true; +if (CheckVectorElementCallArgs(&SemaRef, TheCal

[clang] [cindex] Add API to query the class methods of a type (PR #123539)

2025-02-15 Thread Jannick Kremer via cfe-commits
DeinAlptraum wrote: @Endilll can you also review the non-Python part, or do you know someone who can? https://github.com/llvm/llvm-project/pull/123539 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listi

[clang] [cindex] Add API to query the class methods of a type (PR #123539)

2025-02-15 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: > edit: looks like release notes were "reset" after cutting rc (?) Yes, this happens every time a release branch is created. I checked your release notes, they seem fine to me. https://github.com/llvm/llvm-project/pull/123539 ___ cfe-co

[clang] [clang][x86] Support -masm=intel in cpuid.h (PR #127331)

2025-02-15 Thread via cfe-commits
https://github.com/Alcaro updated https://github.com/llvm/llvm-project/pull/127331 >From 90e3f502e582f44cd19e1b8b71d218330b13c9e4 Mon Sep 17 00:00:00 2001 From: Alcaro Date: Sat, 15 Feb 2025 16:05:40 +0100 Subject: [PATCH 1/4] [clang][x86] Support -masm=intel in cpuid.h --- clang/lib/Headers/

[clang] [cindex] Add API to query the class methods of a type (PR #123539)

2025-02-15 Thread Vlad Serebrennikov via cfe-commits
@@ -54,6 +54,33 @@ unsigned clang_visitCXXBaseClasses(CXType PT, CXFieldVisitor visitor, return true; } +unsigned clang_visitCXXMethods(CXType PT, CXFieldVisitor visitor, + CXClientData client_data) { + CXCursor PC = clang_getTypeDeclaration(P

[clang-tools-extra] [clangd] Enable parsing of forwarding functions in the preamble by default (PR #127359)

2025-02-15 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 created https://github.com/llvm/llvm-project/pull/127359 Fixes https://github.com/clangd/clangd/issues/2324 >From 0ff06807c2c8255f472fc45e9a8922201384bf08 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Sat, 15 Feb 2025 01:57:10 -0500 Subject: [PATCH] [clang

[clang] [cindex] Add API to query the class methods of a type (PR #123539)

2025-02-15 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll commented: Seems fine to me, but I'd like @AaronBallman to take a look, too, because libclang doesn't have a dedicated maintainer and I'm not familiar enough with it to sign off new functions we add to it. https://github.com/llvm/llvm-project/pull/123539

[clang] [cindex] Add API to query the class methods of a type (PR #123539)

2025-02-15 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll edited https://github.com/llvm/llvm-project/pull/123539 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Enable parsing of forwarding functions in the preamble by default (PR #127359)

2025-02-15 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clangd @llvm/pr-subscribers-clang-tools-extra Author: Nathan Ridge (HighCommander4) Changes Fixes https://github.com/clangd/clangd/issues/2324 --- Full diff: https://github.com/llvm/llvm-project/pull/127359.diff 1 Files Affected: - (modified) clang-t

[clang] [cindex] Add API to query the class methods of a type (PR #123539)

2025-02-15 Thread Trevor Laughlin via cfe-commits
https://github.com/trelau updated https://github.com/llvm/llvm-project/pull/123539 >From bb0542e8f2ad50892ee9d2c1f76ec1def85c3e56 Mon Sep 17 00:00:00 2001 From: Trevor Laughlin Date: Sun, 19 Jan 2025 19:21:10 -0500 Subject: [PATCH 1/2] [cindex] Add API to query the class methods of a type ---

[clang] [clang][x86] Support -masm=intel in cpuid.h (PR #127331)

2025-02-15 Thread Phoebe Wang via cfe-commits
https://github.com/phoebewang approved this pull request. LGTM. https://github.com/llvm/llvm-project/pull/127331 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Implement the 'and' HLSL function (PR #127098)

2025-02-15 Thread Farzon Lotfi via cfe-commits
@@ -2245,6 +2245,36 @@ bool SemaHLSL::CheckBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall) { break; } + case Builtin::BI__builtin_hlsl_and: { +if (SemaRef.checkArgCount(TheCall, 2)) + return true; +if (CheckVectorElementCallArgs(&SemaRef, TheCal

[clang] [AST] Avoid repeated map lookups (NFC) (PR #127369)

2025-02-15 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Kazu Hirata (kazutakahirata) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/127369.diff 1 Files Affected: - (modified) clang/lib/AST/ExternalASTMerger.cpp (+7-9) ``diff diff --git a/clang/lib/AST/ExternalAS

[clang] [AST] Avoid repeated map lookups (NFC) (PR #127369)

2025-02-15 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/127369 None >From 9400819602c7c8b79cb21528cd668070132bc608 Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Sat, 15 Feb 2025 01:41:07 -0800 Subject: [PATCH] [AST] Avoid repeated map lookups (NFC) --- clang/li

[clang-tools-extra] [clang-tidy] Avoid repeated hash lookups (NFC) (PR #127370)

2025-02-15 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tools-extra Author: Kazu Hirata (kazutakahirata) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/127370.diff 1 Files Affected: - (modified) clang-tools-extra/clang-tidy/bugprone/VirtualNearMissCheck.cpp (+3-3) ``di

[clang-tools-extra] [clang-tidy] Avoid repeated hash lookups (NFC) (PR #127370)

2025-02-15 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/127370 None >From 356e99802d0d77be7fad4f9297a605334e08ffbd Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Sat, 15 Feb 2025 01:40:13 -0800 Subject: [PATCH] [clang-tidy] Avoid repeated hash lookups (NFC) ---

[clang] [clang-tools-extra] [libcxx] [llvm] [libc++][ranges] P2542R8: Implement `views::concat` (PR #120920)

2025-02-15 Thread Hristo Hristov via cfe-commits
@@ -0,0 +1,638 @@ +// -*- C++ -*- +//===--===// +// +// 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

[clang-tools-extra] [clang-tidy] Add bugprone-smartptr-reset-ambiguous-call check (PR #121291)

2025-02-15 Thread Baranov Victor via cfe-commits
vbvictor wrote: @PiotrZSL, @5chmidti Ping https://github.com/llvm/llvm-project/pull/121291 ___ 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 bugprone-smartptr-reset-ambiguous-call check (PR #121291)

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

[clang-tools-extra] [clang-tidy] Add bugprone-smartptr-reset-ambiguous-call check (PR #121291)

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

[clang-tools-extra] [clang-tidy] Add bugprone-smartptr-reset-ambiguous-call check (PR #121291)

2025-02-15 Thread Piotr Zegar via cfe-commits
@@ -0,0 +1,47 @@ +.. title:: clang-tidy - bugprone-smartptr-reset-ambiguous-call + +bugprone-smartptr-reset-ambiguous-call +== + +Finds potentially erroneous calls to ``reset`` method on smart pointers when +the pointee type also has a ``reset``

[clang-tools-extra] [clang-tidy] Add bugprone-smartptr-reset-ambiguous-call check (PR #121291)

2025-02-15 Thread Piotr Zegar via cfe-commits
@@ -0,0 +1,34 @@ +//===--- SmartptrResetAmbiguousCallCheck.h - clang-tidy -*- C++ -*-===// +// +// 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

[clang-tools-extra] [clang-tidy] Add bugprone-smartptr-reset-ambiguous-call check (PR #121291)

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

[clang-tools-extra] [clang-tidy] Add bugprone-smartptr-reset-ambiguous-call check (PR #121291)

2025-02-15 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL edited https://github.com/llvm/llvm-project/pull/121291 ___ 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 bugprone-smartptr-reset-ambiguous-call check (PR #121291)

2025-02-15 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL commented: 1. Overall ok, please work a little bit on an warning message. 2. Probably better name would be: readability-ambiguous-smartptr-reset-call 3. Same issue exist on other objects like std::optional, and other methods like std::optional and call to `emplace`. M

[libunwind] Silence -Wunused-parameter warnings in Unwind-wasm.c (PR #125412)

2025-02-15 Thread Yuriy Chernyshov via cfe-commits
https://github.com/georgthegreat updated https://github.com/llvm/llvm-project/pull/125412 >From 69307d52fc749c847da74e98624ce1c39f2fe2d9 Mon Sep 17 00:00:00 2001 From: Yuriy Chernyshov Date: Sun, 2 Feb 2025 14:35:53 +0100 Subject: [PATCH 1/3] Silence -Wunused-parameter warnings in Unwind-wasm.c

[clang] [Sema] Add code completion for if constexpr (PR #124315)

2025-02-15 Thread Younan Zhang via cfe-commits
@@ -6749,6 +6749,21 @@ void SemaCodeCompletion::CodeCompleteInitializer(Scope *S, Decl *D) { CodeCompleteExpression(S, Data); } +void SemaCodeCompletion::CodeCompleteIfConstExpr(Scope *S) const { + ResultBuilder Results(SemaRef, CodeCompleter->getAllocator(), +

[libclc] [libclc] Move conversion builtins to the CLC library (PR #124727)

2025-02-15 Thread Michał Górny via cfe-commits
mgorny wrote: I'm guessing that both `amdgcn` and `nvptx` targets now require `clspv-generate_convert.cl`, but the targets for them are defined only when `clspv` targets are enabled. No clue whether it means that the targets need to be defined unconditionally, or `clc-convert.cl` skipped when

[clang] [Sema] Add code completion for if constexpr (PR #124315)

2025-02-15 Thread Younan Zhang via cfe-commits
@@ -6749,6 +6749,21 @@ void SemaCodeCompletion::CodeCompleteInitializer(Scope *S, Decl *D) { CodeCompleteExpression(S, Data); } +void SemaCodeCompletion::CodeCompleteIfConstExpr(Scope *S) const { + ResultBuilder Results(SemaRef, CodeCompleter->getAllocator(), +

[libunwind] Silence -Wunused-parameter warnings in Unwind-wasm.c (PR #125412)

2025-02-15 Thread Yuriy Chernyshov via cfe-commits
https://github.com/georgthegreat updated https://github.com/llvm/llvm-project/pull/125412 >From 69307d52fc749c847da74e98624ce1c39f2fe2d9 Mon Sep 17 00:00:00 2001 From: Yuriy Chernyshov Date: Sun, 2 Feb 2025 14:35:53 +0100 Subject: [PATCH 1/3] Silence -Wunused-parameter warnings in Unwind-wasm.c

[libclc] [libclc] Move conversion builtins to the CLC library (PR #124727)

2025-02-15 Thread Michał Górny via cfe-commits
mgorny wrote: Ah, it's just incorrect dependency. Filed #127315 to fix it. https://github.com/llvm/llvm-project/pull/124727 ___ 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 bugprone-smartptr-reset-ambiguous-call check (PR #121291)

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

[clang] [Sema] Add code completion for if constexpr (PR #124315)

2025-02-15 Thread via cfe-commits
@@ -6749,6 +6749,21 @@ void SemaCodeCompletion::CodeCompleteInitializer(Scope *S, Decl *D) { CodeCompleteExpression(S, Data); } +void SemaCodeCompletion::CodeCompleteIfConstExpr(Scope *S) const { + ResultBuilder Results(SemaRef, CodeCompleter->getAllocator(), +

[clang-tools-extra] [clang-tidy] Add performance-redundant-lookup check (PR #125420)

2025-02-15 Thread Balazs Benics via cfe-commits
steakhal wrote: > Thanks for the insight. Take your time. So, I spent a few hours experimenting and it's really difficult to do, only using `ExprSequence`. Just to recap, my idea was to match the assignments and inc/dec unary operator calls to detect if the container or the key object is mutat

[clang] [clang][x86] Support -masm=intel in cpuid.h (PR #127331)

2025-02-15 Thread via cfe-commits
https://github.com/Alcaro updated https://github.com/llvm/llvm-project/pull/127331 >From 90e3f502e582f44cd19e1b8b71d218330b13c9e4 Mon Sep 17 00:00:00 2001 From: Alcaro Date: Sat, 15 Feb 2025 16:05:40 +0100 Subject: [PATCH 1/2] [clang][x86] Support -masm=intel in cpuid.h --- clang/lib/Headers/

[clang] [llvm] [RISCV] Support Zb*/P Shared Instructions (PR #127160)

2025-02-15 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-s390x-linux` running on `systemz-1` while building `clang,llvm` at step 5 "ninja check 1". Full details are available at: https://lab.llvm.org/buildbot/#/builders/42/builds/3287 Here is the relevant piece of the build

[clang] [clang][x86] Support -masm=intel in cpuid.h (PR #127331)

2025-02-15 Thread via cfe-commits
Alcaro wrote: Oh come on, it was like that when I found it. https://github.com/llvm/llvm-project/pull/127331 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

  1   2   >