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

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

[clang] [clang][bytecode] Fix defining extern variables (PR #108940)

2024-09-17 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr edited https://github.com/llvm/llvm-project/pull/108940 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 8e2dbab - [clang][bytecode] Fix defining extern variables (#108940)

2024-09-17 Thread via cfe-commits
Author: Timm Baeder Date: 2024-09-17T15:21:28+02:00 New Revision: 8e2dbab24276a8521d241463b4161c78bc4d39d2 URL: https://github.com/llvm/llvm-project/commit/8e2dbab24276a8521d241463b4161c78bc4d39d2 DIFF: https://github.com/llvm/llvm-project/commit/8e2dbab24276a8521d241463b4161c78bc4d39d2.diff L

[clang] [clang][bytecode] Fix defining extern variables (PR #108940)

2024-09-17 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr closed https://github.com/llvm/llvm-project/pull/108940 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][AMDGPU] Add a new builtin type for buffer rsrc (PR #94830)

2024-09-17 Thread Jay Foad via cfe-commits
@@ -4778,6 +4782,8 @@ bool Type::canHaveNullability(bool ResultIfUnknown) const { #include "clang/Basic/RISCVVTypes.def" #define WASM_TYPE(Name, Id, SingletonId) case BuiltinType::Id: #include "clang/Basic/WebAssemblyReferenceTypes.def" +#define AMDGPU_TYPE(Name, Id, Singleton

[clang] [clang-tools-extra] [Clang] Implement CWG2813: Class member access with prvalues (PR #95112)

2024-09-17 Thread via cfe-commits
@@ -222,17 +222,17 @@ static bool DiagnoseNoDiscard(Sema &S, const WarnUnusedResultAttr *A, return S.Diag(Loc, diag::warn_unused_result_msg) << A << Msg << R1 << R2; } -void Sema::DiagnoseUnusedExprResult(const Stmt *S, unsigned DiagID) { - if (const LabelStmt *Label = dyn

[clang] [Clang][Sema] Fix templated array size calculation. (PR #96464)

2024-09-17 Thread Erich Keane via cfe-commits
erichkeane wrote: > > It seems reasonable to me, but I want @cor3ntin to review this, he's the > > one who got his foot stuck in array bounds for a while :D > > However, this patch needs a few changes: > > 1- A better patch title, perhaps improved commit message 2- Release note > > 1. Parti

[clang] cb98fd9 - Fix use of an uninitialized variable; NFC intended

2024-09-17 Thread Aaron Ballman via cfe-commits
Author: Aaron Ballman Date: 2024-09-17T09:39:19-04:00 New Revision: cb98fd977a25d3d778244da4012fd34acf7fab45 URL: https://github.com/llvm/llvm-project/commit/cb98fd977a25d3d778244da4012fd34acf7fab45 DIFF: https://github.com/llvm/llvm-project/commit/cb98fd977a25d3d778244da4012fd34acf7fab45.diff

[clang] [clang] Increase VecLib bitfield size to 4 bits in CodeGenOptions.def (PR #108804)

2024-09-17 Thread Erich Keane via cfe-commits
@@ -375,8 +375,13 @@ ENUM_CODEGENOPT(Inlining, InliningMethod, 2, NormalInlining) /// The maximum stack size a function can have to be considered for inlining. VALUE_CODEGENOPT(InlineMaxStackSize, 32, UINT_MAX) +// Ensure the VecLib bitfield has enough space for future vector

[clang] [clang] Increase VecLib bitfield size to 4 bits in CodeGenOptions.def (PR #108804)

2024-09-17 Thread Aaron Ballman via cfe-commits
@@ -375,8 +375,13 @@ ENUM_CODEGENOPT(Inlining, InliningMethod, 2, NormalInlining) /// The maximum stack size a function can have to be considered for inlining. VALUE_CODEGENOPT(InlineMaxStackSize, 32, UINT_MAX) +// Ensure the VecLib bitfield has enough space for future vector

[clang] [clang] Increase VecLib bitfield size to 4 bits in CodeGenOptions.def (PR #108804)

2024-09-17 Thread Erich Keane via cfe-commits
@@ -375,8 +375,13 @@ ENUM_CODEGENOPT(Inlining, InliningMethod, 2, NormalInlining) /// The maximum stack size a function can have to be considered for inlining. VALUE_CODEGENOPT(InlineMaxStackSize, 32, UINT_MAX) +// Ensure the VecLib bitfield has enough space for future vector

[clang] [Clang] Mark Clang 19 language changes as being released [NFC] (PR #108978)

2024-09-17 Thread via cfe-commits
https://github.com/cor3ntin created https://github.com/llvm/llvm-project/pull/108978 None >From c72997e787af36af159679692387f3b7bf0cf658 Mon Sep 17 00:00:00 2001 From: Corentin Jabot Date: Tue, 17 Sep 2024 15:57:27 +0200 Subject: [PATCH] [Clang] Mark Clang 19 language changes as being released

[clang] [Clang] Mark Clang 19 language changes as being released [NFC] (PR #108978)

2024-09-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: cor3ntin (cor3ntin) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/108978.diff 4 Files Affected: - (modified) clang/www/c_status.html (+4-4) - (modified) clang/www/cxx_dr_status.html (+15-15) - (modified) clang/www/

[clang] [clang-format] Handle C-style cast of qualified type (PR #108929)

2024-09-17 Thread Emilia Kond via cfe-commits
https://github.com/rymiel approved this pull request. https://github.com/llvm/llvm-project/pull/108929 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Mark Clang 19 language changes as being released [NFC] (PR #108978)

2024-09-17 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. https://github.com/llvm/llvm-project/pull/108978 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 49a754a - [Clang] Mark Clang 19 language changes as being released [NFC] (#108978)

2024-09-17 Thread via cfe-commits
Author: cor3ntin Date: 2024-09-17T16:02:43+02:00 New Revision: 49a754a43d5592e08ef177db794126ddc676d6b5 URL: https://github.com/llvm/llvm-project/commit/49a754a43d5592e08ef177db794126ddc676d6b5 DIFF: https://github.com/llvm/llvm-project/commit/49a754a43d5592e08ef177db794126ddc676d6b5.diff LOG:

[clang] [Clang] Mark Clang 19 language changes as being released [NFC] (PR #108978)

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

[clang] [clang][codegen] Don't mark "int" TBAA on FP libcalls with indirect args (PR #108853)

2024-09-17 Thread Zahira Ammarguellat via cfe-commits
zahiraam wrote: > > > > How does this interact with #107598? > > > > > > > > > Though this also changes things to ensure when TBAA data is set, it's > > > always set on the call. > > > > > > Wasn't already doing that? (setting the TBAA on the call?). > > It was setting it on `cast(Call.getS

[clang-tools-extra] [clang-tidy] Add new check bugprone-tagged-union-member-count (PR #89925)

2024-09-17 Thread via cfe-commits
___ 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 new check bugprone-tagged-union-member-count (PR #89925)

2024-09-17 Thread via cfe-commits
___ 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 new check bugprone-tagged-union-member-count (PR #89925)

2024-09-17 Thread via cfe-commits
___ 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 new check bugprone-tagged-union-member-count (PR #89925)

2024-09-17 Thread via cfe-commits
___ 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 new check bugprone-tagged-union-member-count (PR #89925)

2024-09-17 Thread via cfe-commits
___ 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 new check bugprone-tagged-union-member-count (PR #89925)

2024-09-17 Thread via cfe-commits
___ 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 new check bugprone-tagged-union-member-count (PR #89925)

2024-09-17 Thread via cfe-commits
___ 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 new check bugprone-tagged-union-member-count (PR #89925)

2024-09-17 Thread via cfe-commits
___ 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 new check bugprone-tagged-union-member-count (PR #89925)

2024-09-17 Thread via cfe-commits
___ 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 new check bugprone-tagged-union-member-count (PR #89925)

2024-09-17 Thread via cfe-commits
___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][codegen] Don't mark "int" TBAA on FP libcalls with indirect args (PR #108853)

2024-09-17 Thread Benjamin Maxwell via cfe-commits
MacDue wrote: > > > > > How does this interact with #107598? > > > > > > > > > > > > Though this also changes things to ensure when TBAA data is set, it's > > > > always set on the call. > > > > > > > > > Wasn't already doing that? (setting the TBAA on the call?). > > > > > > It was settin

[clang] [Clang][AMDGPU] Simplify builtin type definitions. NFC. (PR #108968)

2024-09-17 Thread Shilei Tian via cfe-commits
https://github.com/shiltian approved this pull request. https://github.com/llvm/llvm-project/pull/108968 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Make casting functions constexpr (PR #108902)

2024-09-17 Thread via cfe-commits
@@ -0,0 +1,10 @@ +// RUN: %clang_cc1 -finclude-default-header -triple dxil-pc-shadermodel6.6-library %s -verify + +// expected-no-diagnostics + +// Because asuint should be constant evaluated, all the static asserts below joaosaffran wrote: It looks like an upda

[clang] [llvm] [SPIR-V] Add SPIR-V structurizer (PR #107408)

2024-09-17 Thread Vyacheslav Levytskyy via cfe-commits
Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Na

[clang] [llvm] [SPIR-V] Add SPIR-V structurizer (PR #107408)

2024-09-17 Thread Vyacheslav Levytskyy via cfe-commits
Nathan =?utf-8?q?Gau=C3=ABr?= , Nathan =?utf-8?q?Gau=C3=ABr?= , Nathan =?utf-8?q?Gau=C3=ABr?= , Nathan =?utf-8?q?Gau=C3=ABr?= , Nathan =?utf-8?q?Gau=C3=ABr?= , Nathan =?utf-8?q?Gau=C3=ABr?= , Nathan =?utf-8?q?Gau=C3=ABr?= , Nathan =?utf-8?q?Gau=C3=ABr?= , Nathan =?utf-8?q?Gau=C3=ABr?= , Nathan =?ut

[clang] f4172f6 - [Clang][AMDGPU] Simplify builtin type definitions. NFC. (#108968)

2024-09-17 Thread via cfe-commits
Author: Jay Foad Date: 2024-09-17T15:35:15+01:00 New Revision: f4172f6659ef14cbc235e3d690957de068cd55d4 URL: https://github.com/llvm/llvm-project/commit/f4172f6659ef14cbc235e3d690957de068cd55d4 DIFF: https://github.com/llvm/llvm-project/commit/f4172f6659ef14cbc235e3d690957de068cd55d4.diff LOG:

[clang] [Clang][AMDGPU] Simplify builtin type definitions. NFC. (PR #108968)

2024-09-17 Thread Jay Foad via cfe-commits
https://github.com/jayfoad closed https://github.com/llvm/llvm-project/pull/108968 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Extend `bugprone-sizeof-expression` with matching `P +- sizeof(T)` and `P +- N */ sizeof(T)` cases, add `cert-arr39-c` alias (PR #106061)

2024-09-17 Thread via cfe-commits
https://github.com/whisperity closed https://github.com/llvm/llvm-project/pull/106061 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Extend `bugprone-sizeof-expression` with matching `P +- sizeof(T)` and `P +- N */ sizeof(T)` cases, add `cert-arr39-c` alias (PR #106061)

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

[clang-tools-extra] 267ad43 - [clang-tidy] Extend `bugprone-sizeof-expression` with matching `P +- sizeof(T)` and `P +- N */ sizeof(T)` cases, add `cert-arr39-c` alias (#106061)

2024-09-17 Thread via cfe-commits
Author: Zoltán Porkoláb Date: 2024-09-17T16:42:58+02:00 New Revision: 267ad430fc54d6d548cd7d25c7e59c3b6b650097 URL: https://github.com/llvm/llvm-project/commit/267ad430fc54d6d548cd7d25c7e59c3b6b650097 DIFF: https://github.com/llvm/llvm-project/commit/267ad430fc54d6d548cd7d25c7e59c3b6b650097.dif

[clang] [clang][codegen] Don't mark "int" TBAA on FP libcalls with indirect args (PR #108853)

2024-09-17 Thread Zahira Ammarguellat via cfe-commits
zahiraam wrote: > > > > > > How does this interact with #107598? > > > > > > > > > > > > > > > Though this also changes things to ensure when TBAA data is set, it's > > > > > always set on the call. > > > > > > > > > > > > Wasn't already doing that? (setting the TBAA on the call?). > > > >

[clang-tools-extra] [docs][clang-tidy] Correct StrictMode example in modernize-use-std-print (PR #108805)

2024-09-17 Thread Mainak Sil via cfe-commits
MainakSil wrote: Please merge it if it looks good to you guys... https://github.com/llvm/llvm-project/pull/108805 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Make casting functions constexpr (PR #108902)

2024-09-17 Thread Chris B via cfe-commits
https://github.com/llvm-beanz updated https://github.com/llvm/llvm-project/pull/108902 >From 9deebd707410a6ad8474f615a97c943937ceeb34 Mon Sep 17 00:00:00 2001 From: Chris Bieneman Date: Mon, 16 Sep 2024 18:21:38 -0500 Subject: [PATCH 1/3] [HLSL] Make casting functions constexpr This marks the

[clang] [HLSL] Make casting functions constexpr (PR #108902)

2024-09-17 Thread via cfe-commits
https://github.com/joaosaffran approved this pull request. https://github.com/llvm/llvm-project/pull/108902 ___ 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-17 Thread Younan Zhang via cfe-commits
zyn0217 wrote: Sorry, it might be I forgot to save the changes before I ran the tests yesterday! I looked into it again, and I think I have begun to understand  `TemplateParameterListsInfo`: The first intent is to describe out-of-line member functions that live in a templated scope. For examp

[clang] [clang-tools-extra] [llvm] [Clang] Add __builint_type_pack_dedup template to deduplicate types in template arguments (PR #106730)

2024-09-17 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov edited https://github.com/llvm/llvm-project/pull/106730 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [llvm] [Clang] Add __builin_type_pack_dedup template to deduplicate types in template arguments (PR #106730)

2024-09-17 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov edited https://github.com/llvm/llvm-project/pull/106730 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [llvm] [Clang] Add __builtin_type_pack_dedup template to deduplicate types in template arguments (PR #106730)

2024-09-17 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov edited https://github.com/llvm/llvm-project/pull/106730 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC] Move warning from CodeGen to Sema. (PR #107397)

2024-09-17 Thread Joshua Cranmer via cfe-commits
@@ -6784,6 +6784,12 @@ def warn_arc_lifetime_result_type : Warning< "ARC %select{unused|__unsafe_unretained|__strong|__weak|__autoreleasing}0 " "lifetime qualifier on return type is ignored">, InGroup; +def warn_excess_precision_not_supported : Warning< + "excess precisi

[clang] [NFC] Move warning from CodeGen to Sema. (PR #107397)

2024-09-17 Thread Joshua Cranmer via cfe-commits
@@ -780,6 +780,25 @@ class ASTContext : public RefCountedBase { const TargetInfo &getTargetInfo() const { return *Target; } const TargetInfo *getAuxTargetInfo() const { return AuxTarget; } + const QualType GetHigherPrecisionFPType(QualType ElementType) const { +const

[clang] [clang][bytecode] Allow right-shift of negative values (PR #108987)

2024-09-17 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/108987 We used to incorrectly diagnose this as a "left shift of negative value". >From 7836fe844ce9dc243d7a2b81daaaf462e02d772f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Tue, 17 Sep 2024 16:5

[clang] [clang][bytecode] Allow right-shift of negative values (PR #108987)

2024-09-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes We used to incorrectly diagnose this as a "left shift of negative value". --- Full diff: https://github.com/llvm/llvm-project/pull/108987.diff 2 Files Affected: - (modified) clang/lib/AST/ByteCode/Interp.h

[clang] [clang][codegen] Don't mark "int" TBAA on FP libcalls with indirect args (PR #108853)

2024-09-17 Thread Benjamin Maxwell via cfe-commits
MacDue wrote: > Not really! `int TBAA` in in our downstream compiler is interpreted as > describing the function arguments (they are not int) and the `load/store` of > the argument before the library call are begin eliminated which result in > unexpected behavior. > I am not objecting to anyth

[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-17 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/4] [clang-tidy]suggest use `std::span` as replacement of c

[clang] [clang-tools-extra] [llvm] [Clang] Add __builtin_type_pack_dedup template to deduplicate types in template arguments (PR #106730)

2024-09-17 Thread Ilya Biryukov via cfe-commits
ilya-biryukov wrote: Friendly ping for another round of review. https://github.com/llvm/llvm-project/pull/106730 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][codegen] Don't mark "int" TBAA on FP libcalls with indirect args (PR #108853)

2024-09-17 Thread Benjamin Maxwell via cfe-commits
MacDue wrote: > Not really! int TBAA in in our downstream compiler is interpreted as > describing the function arguments (they are not int) and the load/store of > the argument before the library call are begin eliminated which result in > unexpected behavior. Oh wait, then you say "not reall

[clang] [clang] check deduction consistency when partial ordering function templates (PR #100692)

2024-09-17 Thread Alexander Kornienko via cfe-commits
alexfh wrote: Test case #2: https://gcc.godbolt.org/z/YbTKzao7d https://github.com/llvm/llvm-project/pull/100692 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][codegen] Don't mark "int" TBAA on FP libcalls with indirect args (PR #108853)

2024-09-17 Thread Zahira Ammarguellat via cfe-commits
zahiraam wrote: > > Not really! int TBAA in in our downstream compiler is interpreted as > > describing the function arguments (they are not int) and the load/store of > > the argument before the library call are begin eliminated which result in > > unexpected behavior. > > Oh wait, then you

[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-17 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/4] [clang-tidy]suggest use `std::span` as replacement of c

[clang] [HLSL][NFC] Remove RegisterBindingFlags struct (PR #108924)

2024-09-17 Thread Chris B via cfe-commits
@@ -828,101 +831,85 @@ static void updateResourceClassFlagsFromRecordType(RegisterBindingFlags &Flags, const Type *FieldTy = FD->getType().getTypePtr(); if (const HLSLAttributedResourceType *AttrResType = dyn_cast(FieldTy)) { -updateResourceCl

[clang] [HLSL][NFC] Remove RegisterBindingFlags struct (PR #108924)

2024-09-17 Thread Chris B via cfe-commits
https://github.com/llvm-beanz approved this pull request. One minor nit inline, but I think this is fine either way. https://github.com/llvm/llvm-project/pull/108924 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin

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

2024-09-17 Thread Tomas Matheson via cfe-commits
@@ -73,8 +73,6 @@ enum CPUFeatures { FEAT_SSBS, FEAT_SSBS2, FEAT_BTI, - FEAT_LS64, - FEAT_LS64_V, tmatheson-arm wrote: > If object A uses bit 36, object B uses bit 35 and the runtime uses bit 34, > how is it ever going to work? Using them for what?

[clang] [clang] check deduction consistency when partial ordering function templates (PR #100692)

2024-09-17 Thread Matheus Izvekov via cfe-commits
mizvekov wrote: > Now I think these should cover all remaining issues we see after this commit > (and up to the current ToT): > > > > * Test case 1: https://gcc.godbolt.org/z/zMG5nsda3 > > * Test case 2: https://gcc.godbolt.org/z/YbTKzao7d > > * Test case 3: https://gcc.godbolt.org/z/89Yn3d

[clang] [clang-tools-extra] Remove clang-rename (PR #108988)

2024-09-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Aaron Ballman (AaronBallman) Changes clang-rename has largely been superseded by clangd and this project hasn't received much attention in many years. Further, our documentation on it still claims it's in very early stages of development de

[clang] [Clang] Emit error for duplicate mangled names within a lambda (PR #107581)

2024-09-17 Thread Kerry McLaughlin via cfe-commits
https://github.com/kmclaughlin-arm updated https://github.com/llvm/llvm-project/pull/107581 >From 1e6f25c517d8d1adeeaf59f826141efdcad8f05a Mon Sep 17 00:00:00 2001 From: Kerry McLaughlin Date: Fri, 6 Sep 2024 10:13:33 + Subject: [PATCH 1/4] [Clang] Emit error for duplicate mangled names wit

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

2024-09-17 Thread via cfe-commits
@@ -73,8 +73,6 @@ enum CPUFeatures { FEAT_SSBS, FEAT_SSBS2, FEAT_BTI, - FEAT_LS64, - FEAT_LS64_V, Wilco1 wrote: They are stored in the global `__aarch64_cpu_features` which is set by the init code and used by every FMV ifunc resolver. https://github.

[clang] [Clang] Emit error for duplicate mangled names within a lambda (PR #107581)

2024-09-17 Thread Kerry McLaughlin via cfe-commits
@@ -0,0 +1,31 @@ +// REQUIRES: aarch64-registered-target + +// RUN: %clang_cc1 -triple aarch64 -emit-llvm -o - %s -verify -DTEST1 +// RUN: %clang_cc1 -triple aarch64 -target-feature +sme -target-feature +sme2 -emit-llvm -o - %s -verify -DTEST2 kmclaughlin-arm wro

[clang] [Clang] Emit error for duplicate mangled names within a lambda (PR #107581)

2024-09-17 Thread Kerry McLaughlin via cfe-commits
kmclaughlin-arm wrote: > For non-lambda methods, the way this works it that we call > GetOrCreateLLVMFunction for both methods... for the first method, the > `!Entry->isDeclaration()` would be false, but for the second one, it would be > true because we've emitted the definition of the first m

[clang] [clang-format] Add new option: WrapNamespaceBodyWithNewlines (PR #106145)

2024-09-17 Thread via cfe-commits
dmasloff wrote: > Running `FormatTests` failed: > > ``` > [ RUN ] FormatTest.WrapNamespaceBodyWithEmptyLinesNever > Assertion failed: (TheLine->MatchingClosingBlockLineIndex > 0), function > tryFitMultipleLinesInOne, file UnwrappedLineFormatter.cpp, line 390. > ``` @owenca I looked throug

[clang] [llvm] [SPIR-V] Add SPIR-V structurizer (PR #107408)

2024-09-17 Thread Nathan Gauër via cfe-commits
Keenuts wrote: I created https://github.com/llvm/llvm-project/issues/108845 and https://github.com/llvm/llvm-project/issues/108844 for some of the extensive checks isues and added those to my schedule. Thanks for the review! https://github.com/llvm/llvm-project/pull/107408

[clang] [llvm] [SPIR-V] Add SPIR-V structurizer (PR #107408)

2024-09-17 Thread Nathan Gauër via cfe-commits
Keenuts wrote: @michalpaszkowski let me know when I can merge this (I see no warning on my local build, neither on the CI) https://github.com/llvm/llvm-project/pull/107408 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/

[clang] [clang][analyzer] FixedAddressChecker: no warning if system macro is used (PR #108993)

2024-09-17 Thread Balázs Kéri via cfe-commits
https://github.com/balazske created https://github.com/llvm/llvm-project/pull/108993 None From c13a4d7ed344209359ddb838b2688805ceb06304 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bal=C3=A1zs=20K=C3=A9ri?= Date: Tue, 17 Sep 2024 17:33:34 +0200 Subject: [PATCH] [clang][analyzer] FixedAddressChecke

[clang] [clang][analyzer] FixedAddressChecker: no warning if system macro is used (PR #108993)

2024-09-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 @llvm/pr-subscribers-clang Author: Balázs Kéri (balazske) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/108993.diff 3 Files Affected: - (modified) clang/lib/StaticAnalyzer/Checkers/FixedAddressChecker.cpp (

[clang] [NFC] Move warning from CodeGen to Sema. (PR #107397)

2024-09-17 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam updated https://github.com/llvm/llvm-project/pull/107397 >From 621578de568be1e71665254060956ea1971965c9 Mon Sep 17 00:00:00 2001 From: Zahira Ammarguellat Date: Thu, 5 Sep 2024 05:42:26 -0700 Subject: [PATCH 1/9] [NFC] Move warning from COdeGen to Sema. --- clang/i

[clang] [clang-format] Add new option: WrapNamespaceBodyWithNewlines (PR #106145)

2024-09-17 Thread via cfe-commits
https://github.com/dmasloff updated https://github.com/llvm/llvm-project/pull/106145 >From 219424f9cd3477d9290c8766eaa857234a1ae387 Mon Sep 17 00:00:00 2001 From: dmasloff Date: Mon, 26 Aug 2024 22:11:05 +0300 Subject: [PATCH 1/4] [clang-format] Add new option: WrapNamespaceBodyWithNewlines -

[clang] [clang] Code owners -> Maintainers transition (PR #108997)

2024-09-17 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman created https://github.com/llvm/llvm-project/pull/108997 This is the initial transition from using "code owners" to using "maintainers". >From 10f74046b87f67a6efba1ee30806e73eea14007e Mon Sep 17 00:00:00 2001 From: Aaron Ballman Date: Mon, 16 Sep 2024 08:59:45 -

[clang] [clang] Code owners -> Maintainers transition (PR #108997)

2024-09-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Aaron Ballman (AaronBallman) Changes This is the initial transition from using "code owners" to using "maintainers". --- Full diff: https://github.com/llvm/llvm-project/pull/108997.diff 5 Files Affected: - (renamed) clang/Maintainers.rs

[clang] [NFC] Move warning from CodeGen to Sema. (PR #107397)

2024-09-17 Thread Joshua Cranmer via cfe-commits
https://github.com/jcranmer-intel approved this pull request. https://github.com/llvm/llvm-project/pull/107397 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Code owners -> Maintainers transition (PR #108997)

2024-09-17 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: We've recently updated our documentation regarding what responsibilities maintainers are volunteering to take on: https://llvm.org/docs/DeveloperPolicy.html#maintainers I'm presuming that folks who have been actively performing reviews or commenting on RFCs over the past f

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-09-17 Thread Ellis Hoag via cfe-commits
@@ -164,6 +164,22 @@ publishOutlinedHashTree(std::unique_ptr HashTree) { CodeGenData::getInstance().publishOutlinedHashTree(std::move(HashTree)); } +/// Initialize the two-codegen rounds. +void initializeTwoCodegenRounds(); + +/// Save the current module before the first co

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-09-17 Thread Ellis Hoag via cfe-commits
@@ -164,6 +164,22 @@ publishOutlinedHashTree(std::unique_ptr HashTree) { CodeGenData::getInstance().publishOutlinedHashTree(std::move(HashTree)); } +/// Initialize the two-codegen rounds. ellishg wrote: This comment isn't very useful (thanks to the functio

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-09-17 Thread Ellis Hoag via cfe-commits
@@ -215,6 +224,76 @@ void warn(Error E, StringRef Whence) { } } +static std::string getPath(StringRef Dir, unsigned Task) { + return (Dir + "/" + llvm::Twine(Task) + ".saved_copy.bc").str(); ellishg wrote: Will this work on windows? Can we use `llvm::sys::

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-09-17 Thread Ellis Hoag via cfe-commits
@@ -164,6 +164,22 @@ publishOutlinedHashTree(std::unique_ptr HashTree) { CodeGenData::getInstance().publishOutlinedHashTree(std::move(HashTree)); } +/// Initialize the two-codegen rounds. +void initializeTwoCodegenRounds(); + +/// Save the current module before the first co

[clang] [clang][OpenMP] Slightly refactor EndOpenMPDSABlock for readability, NFC (PR #109003)

2024-09-17 Thread Krzysztof Parzyszek via cfe-commits
https://github.com/kparzysz created https://github.com/llvm/llvm-project/pull/109003 Change the loop ``` if (isOpenMPExecutableDirective) for (Clause) if (Clause is kind1) multi line do something1; else if (Clause is kind2) ... ...

[clang] [clang][OpenMP] Slightly refactor EndOpenMPDSABlock for readability, NFC (PR #109003)

2024-09-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Krzysztof Parzyszek (kparzysz) Changes Change the loop ``` if (isOpenMPExecutableDirective) for (Clause) if (Clause is kind1) multi line do something1; else if (Clause is kind2) ...

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-09-17 Thread Ellis Hoag via cfe-commits
ellishg wrote: Oh I just saw that you have dependent changes in https://github.com/llvm/llvm-project/pull/90934. I think when you create your PR, you can specify a base branch. If you select the branch for https://github.com/llvm/llvm-project/pull/90934, I believe it won't show those changes

[clang] [Clang][AMDGPU] Handle builtin types more generically. NFC. (PR #109004)

2024-09-17 Thread Jay Foad via cfe-commits
https://github.com/jayfoad created https://github.com/llvm/llvm-project/pull/109004 Tweak encodeTypeForFunctionPointerAuth to handle all AMDGPU builtin types generically instead of just __amdgpu_buffer_rsrc_t which happens to be the only one defined so far. >From c79c60d4488e7ddd1d8a2f0e141847

[clang] [Clang][AMDGPU] Handle builtin types more generically. NFC. (PR #109004)

2024-09-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Jay Foad (jayfoad) Changes Tweak encodeTypeForFunctionPointerAuth to handle all AMDGPU builtin types generically instead of just __amdgpu_buffer_rsrc_t which happens to be the only one defined so far. --- Full diff: https://github.com/llv

[clang] [clang][bytecode] Implement arithmetic, bitwise and compound assignment operator (PR #108949)

2024-09-17 Thread Timm Baeder via cfe-commits
@@ -1267,12 +1267,8 @@ bool Compiler::VisitVectorBinOp(const BinaryOperator *E) { assert(E->getLHS()->getType()->isVectorType()); assert(E->getRHS()->getType()->isVectorType()); - // FIXME: Current only support comparison binary operator, add support for - // other bina

[clang] [clang][bytecode] Implement arithmetic, bitwise and compound assignment operator (PR #108949)

2024-09-17 Thread Timm Baeder via cfe-commits
@@ -1371,10 +1455,27 @@ bool Compiler::VisitVectorBinOp(const BinaryOperator *E) { return false; } +// If we performed an integer promotion, we need to cast the compute result +// into result vector element type. +if (NeedIntPromot && +!this->e

[clang] [clang][bytecode] Implement arithmetic, bitwise and compound assignment operator (PR #108949)

2024-09-17 Thread Timm Baeder via cfe-commits
@@ -1281,26 +1277,67 @@ bool Compiler::VisitVectorBinOp(const BinaryOperator *E) { const Expr *LHS = E->getLHS(); const Expr *RHS = E->getRHS(); const auto *VecTy = E->getType()->getAs(); + auto Op = E->isCompoundAssignmentOp() +? BinaryOperator::getOpFo

[clang] [clang][codegen] Don't mark "int" TBAA on FP libcalls with indirect args (PR #108853)

2024-09-17 Thread Benjamin Maxwell via cfe-commits
https://github.com/MacDue updated https://github.com/llvm/llvm-project/pull/108853 >From 6db9f6d56f0bbd56d017156f858eae68653fbd1b Mon Sep 17 00:00:00 2001 From: Benjamin Maxwell Date: Mon, 16 Sep 2024 16:27:23 + Subject: [PATCH 1/4] Precommit math-libcalls-tbaa-indirect-args.c --- .../mat

[clang] [Clang][Sema] fix noexecpt mismatch of friend declaration (PR #102267)

2024-09-17 Thread Eric Niebler via cfe-commits
ericniebler wrote: nudge. i'd love to see #101330 fixed. https://github.com/llvm/llvm-project/pull/102267 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][codegen] Don't mark "int" TBAA on FP libcalls with indirect args (PR #108853)

2024-09-17 Thread Benjamin Maxwell via cfe-commits
MacDue wrote: > Yes exactly! Have you tried running the test case in patch #107598 to see > what IR it generates? I've updated my test (based on yours), and I think you can now see the TBAA metadata is only set on the call when the arguments are not being passed via pointers. https://github

[clang] [NFC] Move warning from CodeGen to Sema. (PR #107397)

2024-09-17 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/107397 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] Remove clang-rename (PR #108988)

2024-09-17 Thread via cfe-commits
cor3ntin wrote: can you inspect these files that still reference clang-rename? ``` lib/Tooling/Refactoring/Rename/RenamingAction.cpp:errs() << "clang-rename: renamed at: " << SourceMgr.getFilename(FullLoc) lib/Tooling/Refactoring/Rename/USRFindingAction.cpp:"clang-rename co

[clang] [clang][analyzer] FixedAddressChecker: no warning if system macro is used (PR #108993)

2024-09-17 Thread Balazs Benics via cfe-commits
https://github.com/steakhal approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/108993 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][OpenMP] Slightly refactor EndOpenMPDSABlock for readability, NFC (PR #109003)

2024-09-17 Thread Alexey Bataev via cfe-commits
@@ -2861,113 +2861,120 @@ void SemaOpenMP::EndOpenMPDSABlock(Stmt *CurDirective) { // clause requires an accessible, unambiguous default constructor for the // class type, unless the list item is also specified in a firstprivate // clause. - if (const auto *D = dyn_c

[clang] [clang][OpenMP] Slightly refactor EndOpenMPDSABlock for readability, NFC (PR #109003)

2024-09-17 Thread Alexey Bataev via cfe-commits
@@ -2861,113 +2861,120 @@ void SemaOpenMP::EndOpenMPDSABlock(Stmt *CurDirective) { // clause requires an accessible, unambiguous default constructor for the // class type, unless the list item is also specified in a firstprivate // clause. - if (const auto *D = dyn_c

[clang] [clang][OpenMP] Slightly refactor EndOpenMPDSABlock for readability, NFC (PR #109003)

2024-09-17 Thread Alexey Bataev via cfe-commits
@@ -2861,113 +2861,120 @@ void SemaOpenMP::EndOpenMPDSABlock(Stmt *CurDirective) { // clause requires an accessible, unambiguous default constructor for the // class type, unless the list item is also specified in a firstprivate // clause. - if (const auto *D = dyn_c

[clang] [clang-tools-extra] Remove clang-rename (PR #108988)

2024-09-17 Thread via cfe-commits
cor3ntin wrote: Also these bazel build scripts ``` llvm/utils/gn/secondary/clang-tools-extra/test/BUILD.gn: "//clang/tools/clang-rename", llvm/utils/gn/secondary/clang/test/BUILD.gn:"//clang/tools/clang-rename", llvm/utils/gn/secondary/clang/tools/clang-rename/BUILD.gn:executable("clang-

[clang] [clang][OpenMP] Slightly refactor EndOpenMPDSABlock for readability, NFC (PR #109003)

2024-09-17 Thread Alexey Bataev via cfe-commits
@@ -2861,113 +2861,120 @@ void SemaOpenMP::EndOpenMPDSABlock(Stmt *CurDirective) { // clause requires an accessible, unambiguous default constructor for the // class type, unless the list item is also specified in a firstprivate // clause. - if (const auto *D = dyn_c

<    1   2   3   4   5   >