[clang] [llvm] [mlir] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()` (PR #140289)

2025-05-19 Thread Rahul Joshi via cfe-commits
jurahul wrote: > I've landed > [195e640](https://github.com/llvm/llvm-project/commit/195e640846765402d1a622006e6a9f9fa3192955) > to fix the build failure from this PR. Thanks! Thanks so much! https://github.com/llvm/llvm-project/pull/140289 ___ cfe

[clang] [llvm] [mlir] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()` (PR #140289)

2025-05-19 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/140289 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [mlir] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()` (PR #140289)

2025-05-19 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/140289 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [mlir] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()` (PR #140289)

2025-05-19 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul edited https://github.com/llvm/llvm-project/pull/140289 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [mlir] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()` (PR #140289)

2025-05-19 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/140289 >From 6425e29aefbcacc2c43b37ed5114906edead Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Fri, 16 May 2025 10:54:33 -0700 Subject: [PATCH] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Decl/StmtOpenACC (PR #140087)

2025-05-19 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/140087 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [mlir] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()` (PR #140289)

2025-05-19 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/140289 >From 2c36635ea034a0590ba45df05e4ec87eea171654 Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Fri, 16 May 2025 10:54:33 -0700 Subject: [PATCH] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Expr.cpp/h (PR #140102)

2025-05-19 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/140102 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in DeclFriend (PR #140081)

2025-05-19 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/140081 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in DeclFriend (PR #140081)

2025-05-19 Thread Rahul Joshi via cfe-commits
@@ -90,8 +90,7 @@ class FriendDecl final : Decl(Decl::Friend, DC, L), Friend(Friend), FriendLoc(FriendL), EllipsisLoc(EllipsisLoc), UnsupportedFriend(false), NumTPLists(FriendTypeTPLists.size()) { -for (unsigned i = 0; i < NumTPLists; ++i) - getTr

[clang] [AST] Remove "const" from "const ArrayRef" (NFC) (PR #140437)

2025-05-18 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul approved this pull request. https://github.com/llvm/llvm-project/pull/140437 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [mlir] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()` (PR #140289)

2025-05-17 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/140289 >From b1f2cf5a9dd1eb27458ac586706c460bb0f00c25 Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Fri, 16 May 2025 10:54:33 -0700 Subject: [PATCH] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()

[clang] [llvm] [mlir] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()` (PR #140289)

2025-05-17 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/140289 >From a410f0a4a8eb35301ba92462ab476c8d85d7017b Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Fri, 16 May 2025 10:54:33 -0700 Subject: [PATCH] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()

[clang] [llvm] [mlir] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()` (PR #140289)

2025-05-16 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul created https://github.com/llvm/llvm-project/pull/140289 Rename `ListInit::getValues()` to `getElements()` to better match with other `ListInit` members like `getElement`. Rate limit · GitHub body { background-color: #f

[clang] [llvm] [mlir] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()` (PR #140289)

2025-05-16 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/140289 >From 95948513fbfad39731abb01f40eab586bbaa26c5 Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Fri, 16 May 2025 10:54:33 -0700 Subject: [PATCH] [LLVM][TableGen] Rename `ListInit::getValues()` to `getElements()

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Expr.cpp/h (PR #140102)

2025-05-16 Thread Rahul Joshi via cfe-commits
@@ -5043,16 +5037,18 @@ PseudoObjectExpr::PseudoObjectExpr(QualType type, ExprValueKind VK, : Expr(PseudoObjectExprClass, type, VK, OK_Ordinary) { PseudoObjectExprBits.NumSubExprs = semantics.size() + 1; PseudoObjectExprBits.ResultIndex = resultIndex + 1; - - for (uns

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Expr.cpp/h (PR #140102)

2025-05-16 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/140102 Rate limit · GitHub body { background-color: #f6f8fa; color: #24292e; font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-s

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Expr.cpp/h (PR #140102)

2025-05-16 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/140102 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in DeclFriend (PR #140081)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/140081 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in DeclCXX (PR #140078)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/140078 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Expr.cpp/h (PR #140102)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/140102 >From cec764c18d56e8a059da3065dfec9462a3c55956 Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Thu, 15 May 2025 09:52:46 -0700 Subject: [PATCH] [NFC][Clang] Adopt simplified `getTrailingObjects` in Expr.cpp/h

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Decl/StmtOpenACC (PR #140087)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/140087 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in DeclCXX (PR #140078)

2025-05-15 Thread Rahul Joshi via cfe-commits
jurahul wrote: > Hi, no objections to the patch, but I am wondering if there is a larger > reason behind this effort to simplify all these uses of getTrailingObjects. > > Are you planning on an API change in this area for instance? Not really. I added simplifications to the TrailingObjects cla

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in DeclCXX (PR #140078)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/140078 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Expr.cpp/h (PR #140102)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/140102 Rate limit · GitHub body { background-color: #f6f8fa; color: #24292e; font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-s

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Decl/StmtOpenACC (PR #140087)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/140087 Rate limit · GitHub body { background-color: #f6f8fa; color: #24292e; font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-s

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Expr.cpp/h (PR #140102)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul created https://github.com/llvm/llvm-project/pull/140102 Adopt non-templated and array-ref returning forms of `getTrailingObjects` in Expr.cpp/.h. Use ArrayRef forms to eliminate manual asserting for OOB index. Use llvm::copy() instead of std::copy() in some instanc

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Decl/StmtOpenACC (PR #140087)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul created https://github.com/llvm/llvm-project/pull/140087 Adopt non-templated and array-ref returning forms of `getTrailingObjects` in DeclOpenACC and StmtOpenACC. Also use std::uninitialized_contruct_n to make the code a little concise. Rate

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in DeclFriend (PR #140081)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul created https://github.com/llvm/llvm-project/pull/140081 - Adopt non-templated `getTrailingObjects` in DeclFriend, DeclGroup, and DeclObjC - Use indexing into ArrayRef returned by `getTrailingObjects` and eliminate explicit OOB asserts. Rate

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in DeclCXX (PR #140078)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul edited https://github.com/llvm/llvm-project/pull/140078 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in DeclXCC (PR #140078)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul edited https://github.com/llvm/llvm-project/pull/140078 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in DeclXCC (PR #140078)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul created https://github.com/llvm/llvm-project/pull/140078 Adopt non-templated and ArrayRef returning forms of `getTrailingObjects`. Additionally, replace some initialization loop with std::uninitialized_fill_n. Rate limit · GitHub

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in ASTConcept (PR #139974)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/139974 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Decl/DeclTemplate (PR #139977)

2025-05-15 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/139977 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Decl/DeclTemplate (PR #139977)

2025-05-14 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/139977 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in ASTConcept (PR #139974)

2025-05-14 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/139974 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in Decl/DeclTemplate (PR #139977)

2025-05-14 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul created https://github.com/llvm/llvm-project/pull/139977 Adopt simplied `getTrailingObjects` variants that are not templated and/or return ArrayRef in Decl/DeclTemplate .h/.cpp files. Rate limit · GitHub body { backgrou

[clang] [NFC][Clang] Adopt simplified `getTrailingObjects` in ASTConcept (PR #139974)

2025-05-14 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul created https://github.com/llvm/llvm-project/pull/139974 Use non-templated form of `getTrailingObjects` when using a single trailing type in `TrailingObjects`. Rate limit · GitHub body { background-color: #f6f8fa;

[clang] [NFC][Clang] Simplify getTrailingObjects for OpenACC/OpenMP Clause (PR #139838)

2025-05-14 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/139838 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Simplify getTrailingObjects for OpenACC/OpenMP Clause (PR #139838)

2025-05-14 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/139838 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Add `setExprs` overload to reduce some code duplication (PR #139749)

2025-05-13 Thread Rahul Joshi via cfe-commits
@@ -501,20 +501,28 @@ class OpenACCClauseWithExprs : public OpenACCClauseWithParams { /// Used only for initialization, the leaf class can initialize this to /// trailing storage. - void setExprs(MutableArrayRef NewExprs) { -assert(Exprs.empty() && "Cannot change Exp

[clang] [NFC][Clang] Add `setExprs` overload to reduce some code duplication (PR #139749)

2025-05-13 Thread Rahul Joshi via cfe-commits
@@ -501,20 +501,28 @@ class OpenACCClauseWithExprs : public OpenACCClauseWithParams { /// Used only for initialization, the leaf class can initialize this to /// trailing storage. - void setExprs(MutableArrayRef NewExprs) { -assert(Exprs.empty() && "Cannot change Exp

[clang] [NFC][Clang] Add `setExprs` overload to reduce some code duplication (PR #139749)

2025-05-13 Thread Rahul Joshi via cfe-commits
@@ -492,7 +492,7 @@ class OpenACCSelfClause final /// Represents a clause that has one or more expressions associated with it. class OpenACCClauseWithExprs : public OpenACCClauseWithParams { - MutableArrayRef Exprs; + MutableArrayRef Storage; jurahul wrote:

[clang] [NFC][Clang] Add `setExprs` overload to reduce some code duplication (PR #139749)

2025-05-13 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/139749 Rate limit · GitHub body { background-color: #f6f8fa; color: #24292e; font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-s

[clang] [NFC][Clang] Add `setExprs` overload to reduce some code duplication (PR #139749)

2025-05-13 Thread Rahul Joshi via cfe-commits
@@ -501,20 +501,28 @@ class OpenACCClauseWithExprs : public OpenACCClauseWithParams { /// Used only for initialization, the leaf class can initialize this to /// trailing storage. - void setExprs(MutableArrayRef NewExprs) { -assert(Exprs.empty() && "Cannot change Exp

[clang] [NFC][Clang] Add `setExprs` overload to reduce some code duplication (PR #139749)

2025-05-13 Thread Rahul Joshi via cfe-commits
@@ -506,6 +506,14 @@ class OpenACCClauseWithExprs : public OpenACCClauseWithParams { Exprs = NewExprs; } + /// Used only for initialization, the leaf class can initialize this to + /// trailing storage, and initialize the data in the trailing storage as well. + void

[clang] [NFC][Clang] Add `setExprs` overload to reduce some code duplication (PR #139749)

2025-05-13 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/139749 >From cddc08de74e539c47e93efc4eb65cb4417b747de Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Tue, 13 May 2025 08:04:08 -0700 Subject: [PATCH] [NFC][Clang] Add `setExprs` overload to reduce some code duplicat

[clang] [NFC][Clang] Add `setExprs` overload to reduce some code duplication (PR #139749)

2025-05-13 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/139749 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Add `setExprs` overload to reduce some code duplication (PR #139749)

2025-05-13 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul created https://github.com/llvm/llvm-project/pull/139749 Add a `setExprs` overload to `OpenACCClauseWithExprs` that allows initializing the trailing storage to help eliminate some code duplication in various subclass constructors. Rate limit

[clang] [NFC][Clang] Adopt `TrailingObjects` API to build ArrayRef (PR #139639)

2025-05-13 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/139639 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt `TrailingObjects` convenience API in MacroArgs (PR #139635)

2025-05-13 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/139635 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt `TrailingObjects` API to build ArrayRef (PR #139639)

2025-05-12 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul edited https://github.com/llvm/llvm-project/pull/139639 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt `TrailingObjects` API to build ArrayRef (PR #139639)

2025-05-12 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/139639 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt `TrailingObjects` convienence API in MacroArgs (PR #139635)

2025-05-12 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul created https://github.com/llvm/llvm-project/pull/139635 None >From 0207459bd4387a4af801cadb3c1213983563509e Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Mon, 12 May 2025 15:46:51 -0700 Subject: [PATCH] [NFC][Clang] Adopt `TrailingObjects` convienence API in Mac

[clang] [NFC][Clang] Adopt `TrailingObjects` convenience API in MacroArgs (PR #139635)

2025-05-12 Thread Rahul Joshi via cfe-commits
jurahul wrote: FYI, LLVM and MLIR change of similar nature: https://github.com/llvm/llvm-project/pull/138554 https://github.com/llvm/llvm-project/pull/139635 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailma

[clang] [NFC][Clang] Adopt `TrailingObjects` convenience API in MacroArgs (PR #139635)

2025-05-12 Thread Rahul Joshi via cfe-commits
jurahul wrote: I filled in the description now. I am doing similar changes on LLVM/MLIR side (change has been approved). I added these convenience APIs to TrailingObjects to support the common code patterns of a single trailing type as well as creating an ArrayRef from the trailing objects po

[clang] [NFC][Clang] Adopt `TrailingObjects` convenience API in MacroArgs (PR #139635)

2025-05-12 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul edited https://github.com/llvm/llvm-project/pull/139635 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Adopt `TrailingObjects` convenience API in MacroArgs (PR #139635)

2025-05-12 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul edited https://github.com/llvm/llvm-project/pull/139635 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [TableGen] Use StringRef::substr instead of StringRef::slice (NFC) (PR #139485)

2025-05-11 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul approved this pull request. https://github.com/llvm/llvm-project/pull/139485 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [TableGen] Use std::tie to implement operator< (NFC) (PR #139405)

2025-05-10 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul approved this pull request. https://github.com/llvm/llvm-project/pull/139405 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-07 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/138174 Rate limit · GitHub body { background-color: #f6f8fa; color: #24292e; font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-s

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-07 Thread Rahul Joshi via cfe-commits
jurahul wrote: Thanks @jpienaar. Given I have 2 approvals, will commit it today. https://github.com/llvm/llvm-project/pull/138174 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-05 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul edited https://github.com/llvm/llvm-project/pull/138174 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-05 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/138174 >From 278179a35bacc7c70dd1724e7ef7a41e9cdd999a Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Wed, 30 Apr 2025 23:47:37 -0700 Subject: [PATCH] [NFC][Support] Add llvm::uninitialized_copy Add `llvm::uninitiali

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-05 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul edited https://github.com/llvm/llvm-project/pull/138174 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-05 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/138174 Rate limit · GitHub body { background-color: #f6f8fa; color: #24292e; font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-s

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
@@ -2981,7 +2981,7 @@ ScalarEvolution::getOrCreateAddExpr(ArrayRef Ops, static_cast(UniqueSCEVs.FindNodeOrInsertPos(ID, IP)); if (!S) { const SCEV **O = SCEVAllocator.Allocate(Ops.size()); -std::uninitialized_copy(Ops.begin(), Ops.end(), O); +llvm::uninitial

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
@@ -22,8 +22,8 @@ Checksum &Checksum::operator=(const Checksum &checksum) { } void Checksum::SetMD5(llvm::MD5::MD5Result md5) { - const constexpr size_t md5_length = 16; - std::uninitialized_copy_n(md5.begin(), md5_length, m_checksum.begin()); + static_assert(sizeof(md5) ==

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/138174 >From 46542ce5b946735c2c0a8f65e185761ebbf77073 Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Wed, 30 Apr 2025 23:47:37 -0700 Subject: [PATCH] [NFC][Support] Add llvm::uninitialized_copy Add `llvm::uninitiali

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
@@ -22,8 +22,8 @@ Checksum &Checksum::operator=(const Checksum &checksum) { } void Checksum::SetMD5(llvm::MD5::MD5Result md5) { - const constexpr size_t md5_length = 16; - std::uninitialized_copy_n(md5.begin(), md5_length, m_checksum.begin()); + static_assert(sizeof(md5) ==

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
@@ -2981,7 +2981,7 @@ ScalarEvolution::getOrCreateAddExpr(ArrayRef Ops, static_cast(UniqueSCEVs.FindNodeOrInsertPos(ID, IP)); if (!S) { const SCEV **O = SCEVAllocator.Allocate(Ops.size()); -std::uninitialized_copy(Ops.begin(), Ops.end(), O); +llvm::uninitial

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
@@ -2038,6 +2038,11 @@ template auto mismatch(R1 &&Range1, R2 &&Range2) { adl_end(Range2)); } +template +auto uninitialized_copy(R1 &&Src, IterTy Dst) { jurahul wrote: Thanks, fixed. https://github.com/llvm/llvm-project/pull/138174

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/138174 >From 7c67ef6748f8813b7aaa91f8e6b463d9fde57d94 Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Wed, 30 Apr 2025 23:47:37 -0700 Subject: [PATCH] [NFC][Support] Add llvm::uninitialized_copy Add `llvm::uninitiali

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
jurahul wrote: > This looks right, but I'd like someone else to go through to make sure it is > right everywhere. > > Also, the md5 change looks... odd and counts a lot on the internal > representation of md5, so I'm not sure about that one, but at least it is > right NOW (Since MD5 inherits

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul edited https://github.com/llvm/llvm-project/pull/138174 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
@@ -2981,7 +2981,7 @@ ScalarEvolution::getOrCreateAddExpr(ArrayRef Ops, static_cast(UniqueSCEVs.FindNodeOrInsertPos(ID, IP)); if (!S) { const SCEV **O = SCEVAllocator.Allocate(Ops.size()); -std::uninitialized_copy(Ops.begin(), Ops.end(), O); +llvm::uninitial

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
@@ -2981,7 +2981,7 @@ ScalarEvolution::getOrCreateAddExpr(ArrayRef Ops, static_cast(UniqueSCEVs.FindNodeOrInsertPos(ID, IP)); if (!S) { const SCEV **O = SCEVAllocator.Allocate(Ops.size()); -std::uninitialized_copy(Ops.begin(), Ops.end(), O); +llvm::uninitial

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/138174 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul edited https://github.com/llvm/llvm-project/pull/138174 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/138174 Rate limit · GitHub body { background-color: #f6f8fa; color: #24292e; font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-s

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-02 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/138174 >From 705699c4b1772915f6d8773ce786d5601de0a926 Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Wed, 30 Apr 2025 23:47:37 -0700 Subject: [PATCH] [NFC][Support] Add llvm::uninitialized_copy Add `llvm::uninitiali

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-01 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/138174 >From fbe3ca0c2e4d195149f5e3e6b8d32797cf47b9df Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Wed, 30 Apr 2025 23:47:37 -0700 Subject: [PATCH] [NFC][Support] Add llvm::uninitialized_copy Add `llvm::uninitiali

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-01 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/138174 >From de1b49fc6b8819b591e48b81634567ceeffe5089 Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Wed, 30 Apr 2025 23:47:37 -0700 Subject: [PATCH] [NFC][Support] Add llvm::uninitialized_copy Add `llvm::uninitiali

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-01 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/138174 >From b34e9b6c708dfbe097504804a0a85e1169518911 Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Wed, 30 Apr 2025 23:47:37 -0700 Subject: [PATCH] [NFC][Support] Add llvm::uninitialized_copy --- clang/include/cl

[clang] [lldb] [llvm] [mlir] [NFC][Support] Add llvm::uninitialized_copy (PR #138174)

2025-05-01 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul created https://github.com/llvm/llvm-project/pull/138174 None >From d6f69414e3ac5c1a22f6509149609258ef980c13 Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Wed, 30 Apr 2025 23:47:37 -0700 Subject: [PATCH] [NFC][Support] Add llvm::uninitialized_copy --- clang/incl

[clang] [llvm] AMDGPU: Mark workitem ID intrinsics with range attribute (PR #136196)

2025-04-18 Thread Rahul Joshi via cfe-commits
jurahul wrote: I attempted to fix the failure in clang/test/Headers/gpuintrin_lang.c by removing the range() in the CHECK, but now some other build fails and complains that the range() is missing: https://lab.llvm.org/buildbot/#/builders/174/builds/16421/steps/6/logs/FAIL__Clang__gpuintrin_lan

[clang] [llvm] Fix nvptx range check (PR #136296)

2025-04-18 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul created https://github.com/llvm/llvm-project/pull/136296 None >From 8d0178850b74c568c03e98de47dbc9a94adedd05 Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Thu, 17 Apr 2025 15:59:56 -0700 Subject: [PATCH 1/2] [NFC][LLVM][TableGen] Use `decodeULEB128` for `OPC_Soft

[clang] [Clang][GPU] Make NVPTX check more permissive in unit test (PR #136301)

2025-04-18 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/136301 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] AMDGPU: Mark workitem ID intrinsics with range attribute (PR #136196)

2025-04-18 Thread Rahul Joshi via cfe-commits
jurahul wrote: https://github.com/llvm/llvm-project/pull/136301 ? Yeah, ultimately, we want the range on the intrinsic declaration. https://github.com/llvm/llvm-project/pull/136196 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.

[clang] [Clang][GPU] Make NVPTX check more permissive in unit test (PR #136301)

2025-04-18 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/136301 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][GPU] Make NVPTX check more permissive in unit test (PR #136301)

2025-04-18 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul created https://github.com/llvm/llvm-project/pull/136301 - Seems based on whether NVPTX backend is enabled or not, this call can have the range() attribute or not. So make this check more permissive. >From 196e2adb9e5e700f7c13d1655746cb79af926a04 Mon Sep 17 00:00:00

[clang] [llvm] AMDGPU: Mark workitem ID intrinsics with range attribute (PR #136196)

2025-04-18 Thread Rahul Joshi via cfe-commits
jurahul wrote: So may be we can make the check more permissive for now? https://github.com/llvm/llvm-project/pull/136196 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] AMDGPU: Mark workitem ID intrinsics with range attribute (PR #136196)

2025-04-18 Thread Rahul Joshi via cfe-commits
jurahul wrote: I think you guess is right: this one for example complains when range() is present in the checks: https://lab.llvm.org/buildbot/#/builders/65/builds/15490 and it only has AArch64 backend enabled. https://github.com/llvm/llvm-project/pull/136196 _

[clang] [Clang][GPU] Fix unit test for NVPTX tid.x intrinsic (PR #136297)

2025-04-18 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/136297 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][GPU] Fix unit test for NVPTX tid.x intrinsic (PR #136297)

2025-04-18 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/136297 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][GPU] Fix unit test for NVPTX tid.x intrinsic (PR #136297)

2025-04-18 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul created https://github.com/llvm/llvm-project/pull/136297 - llvm.nvvm.read.ptx.sreg.tid.x does not have the result range attribute yet. >From d2731a74ee04d2b11b521b76c0a87bb68f0ba03a Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Fri, 18 Apr 2025 04:56:55 -0700 Subj

[clang] [llvm] Fix nvptx range check (PR #136296)

2025-04-18 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/136296 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [IRBuilder] Add new overload for CreateIntrinsic (PR #131942)

2025-04-05 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul updated https://github.com/llvm/llvm-project/pull/131942 >From 7f7f0ea87f460a951011ce75926f3e27900bb384 Mon Sep 17 00:00:00 2001 From: Rahul Joshi Date: Tue, 18 Mar 2025 13:19:24 -0700 Subject: [PATCH] [IRBuilder] Add new overload for CreateIntrinsic Add a new `Creat

[clang] [Clang][NFC] Code cleanup in CGBuiltin.cpp (PR #132060)

2025-04-04 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/132060 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [IRBuilder] Add new overload for CreateIntrinsic (PR #131942)

2025-03-31 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul closed https://github.com/llvm/llvm-project/pull/131942 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

  1   2   3   4   5   6   >