[clang] [Sema] Allow zero-size allocations for -Walloc-size (PR #155793)

2025-08-28 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: Hi, thanks for the fix. I that is going to fix https://github.com/llvm/llvm-project/issues/155633 , you can also add ``Fixes #155633`` to the PR desc and merging this PR will close the issue automatically. https://github.com/llvm/llvm-project/pull/155793

[clang] [clang] Optimize EmbedExpr child iterator callback (PR #155803)

2025-08-28 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon approved this pull request. wow, thanks! https://github.com/llvm/llvm-project/pull/155803 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Make sure EvalInfo pointer isn't null (PR #155563)

2025-08-27 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon approved this pull request. https://github.com/llvm/llvm-project/pull/155563 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][initlist] handle incomplete array type in Constant Expr Calculation (PR #155080)

2025-08-27 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon edited https://github.com/llvm/llvm-project/pull/155080 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Make sure EvalInfo pointer isn't null (PR #155563)

2025-08-27 Thread Mariya Podchishchaeva via cfe-commits
@@ -391,3 +391,10 @@ void ghissue109095() { _Static_assert(i == c[0]); // expected-error {{static assertion expression is not an integral constant expression}}\ // expected-note {{initializer of 'i' is not a constant expression}} } + +typedef bo

[clang] [clang][initlist] handle incomplete array type in Constant Expr Calculation (PR #155080)

2025-08-27 Thread Mariya Podchishchaeva via cfe-commits
@@ -4029,10 +4029,12 @@ findSubobject(EvalInfo &Info, const Expr *E, const CompleteObject &Obj, LastField = nullptr; if (ObjType->isArrayType()) { // Next subobject is an array element. - const ConstantArrayType *CAT = Info.Ctx.getAsConstantArrayType(ObjType

[clang] [clang] Make sure EvalInfo pointer isn't null (PR #155563)

2025-08-27 Thread Mariya Podchishchaeva via cfe-commits
@@ -391,3 +391,10 @@ void ghissue109095() { _Static_assert(i == c[0]); // expected-error {{static assertion expression is not an integral constant expression}}\ // expected-note {{initializer of 'i' is not a constant expression}} } + +typedef bo

[clang] [Clang][Sema] Reject unsupported opencl address space attributes in SYCL and HLSL (PR #152528)

2025-08-19 Thread Mariya Podchishchaeva via cfe-commits
=?utf-8?q?M=C3=A9sz=C3=A1ros?= Gergely , =?utf-8?q?M=C3=A9sz=C3=A1ros?= Gergely ,Gergely Meszaros ,Gergely Meszaros Message-ID: In-Reply-To: https://github.com/Fznamznon approved this pull request. Thanks! https://github.com/llvm/llvm-project/pull/152528

[clang] [SYCL] SYCL host kernel launch support for the sycl_kernel_entry_point attribute. (PR #152403)

2025-08-18 Thread Mariya Podchishchaeva via cfe-commits
@@ -79,6 +88,14 @@ int main() { // CHECK-HOST-LINUX-NEXT: %kernelFunc = alloca %class.anon, align 4 // CHECK-HOST-LINUX-NEXT: %coerce.dive = getelementptr inbounds nuw %class.anon, ptr %kernelFunc, i32 0, i32 0 // CHECK-HOST-LINUX-NEXT: store i32 %kernelFunc.coerce, ptr

[clang] [SYCL] SYCL host kernel launch support for the sycl_kernel_entry_point attribute. (PR #152403)

2025-08-18 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon edited https://github.com/llvm/llvm-project/pull/152403 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] improve -Wstring-concatenation to warn on every missing comma in initializer lists (PR #154018)

2025-08-18 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon approved this pull request. https://github.com/llvm/llvm-project/pull/154018 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] improve -Wstring-concatenation to warn on every missing comma in initializer lists (PR #154018)

2025-08-18 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon edited https://github.com/llvm/llvm-project/pull/154018 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] improve -Wstring-concatenation to warn on every missing comma in initializer lists (PR #154018)

2025-08-18 Thread Mariya Podchishchaeva via cfe-commits
@@ -168,3 +168,17 @@ const char *extra_parens_to_suppress_warning[] = { "promise"), "shared_future" }; + +const char *multiple_missing_commas[] = { +"1", +"2" // expected-note {{place parentheses around the string literal to silence warning}} +"3", // expe

[clang] [Clang] improve -Wstring-concatenation to warn on every missing comma in initializer lists (PR #154018)

2025-08-18 Thread Mariya Podchishchaeva via cfe-commits
@@ -14708,7 +14708,16 @@ void Sema::CheckCompleteVariableDeclaration(VarDecl *var) { isa(var->getInit())) { const auto *ILE = cast(var->getInit()); unsigned NumInits = ILE->getNumInits(); -if (NumInits > 2) +if (NumInits > 2) { + auto concatenatedPar

[clang] [Clang][Sema] Reject unsupported opencl address space attributes in SYCL and HLSL (PR #152528)

2025-08-18 Thread Mariya Podchishchaeva via cfe-commits
=?utf-8?q?Mészáros?= Gergely , =?utf-8?q?Mészáros?= Gergely ,Gergely Meszaros Message-ID: In-Reply-To: @@ -0,0 +1,25 @@ +// RUN: %clang_cc1 -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -x c++ -fsycl-is-host -verify %s +// RUN: %clang_cc1 -fsyntax-only -x c++ -fsy

[clang] [Clang][NFC] Clarify some SourceManager related code (PR #153527)

2025-08-18 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon approved this pull request. as someone dealing with c/c++ I don't really get why 0 column number is invalid, but that is already clearer, thanks https://github.com/llvm/llvm-project/pull/153527 ___ cfe-commits mailing list

[clang] [Clang] Do not consider a variadic function ellipsis part of a default arg (PR #153496)

2025-08-14 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon approved this pull request. https://github.com/llvm/llvm-project/pull/153496 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][NFC] Clarify some SourceManager related code (PR #153527)

2025-08-14 Thread Mariya Podchishchaeva via cfe-commits
@@ -1095,6 +1095,8 @@ prepareAndFilterRanges(const SmallVectorImpl &Ranges, unsigned StartColumn = SM.getExpansionColumnNumber(Begin); unsigned EndColumn = SM.getExpansionColumnNumber(End); +assert(StartColumn && "StartColumn has a value of 0"); F

[clang] [Clang] Do not consider a variadic function ellipsis part of a default arg (PR #153496)

2025-08-14 Thread Mariya Podchishchaeva via cfe-commits
@@ -6,3 +6,15 @@ void f(...) { } void h(int n..., int m); // expected-error {{expected ')'}} expected-note {{to match}} + + +namespace GH153445 { +void f(int = {}...); + +struct S { + void f(int = {}...); + void g(int...); +}; + +void S::g(int = {}...) {} F

[clang] [Clang] Do not consider a variadic function ellipsis part of a default arg (PR #153496)

2025-08-14 Thread Mariya Podchishchaeva via cfe-commits
@@ -206,6 +206,8 @@ Bug Fixes to C++ Support casts that are guaranteed to fail (#GH137518). - Fix bug rejecting partial specialization of variable templates with auto NTTPs (#GH118190). - Fix a crash when using ``explicit(bool)`` in pre-C++11 language modes. (#GH152729) +-

[clang] [Clang] Fixed a crash when parsing #embed parameters with unmatched closing brackets (PR #152877)

2025-08-11 Thread Mariya Podchishchaeva via cfe-commits
@@ -94,6 +94,9 @@ char buffer[] = { #embed "embed_parsing_errors.c" prefix() // OK: tokens within parens are optional #embed "embed_parsing_errors.c" prefix) // expected-error@-1 {{expected '('}} +#embed "embed_parsing_errors.c" prefix()) // expected-error {{expected identifi

[clang] [Clang] Fixed a crash when parsing #embed parameters with unmatched closing brackets (PR #152877)

2025-08-11 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon approved this pull request. https://github.com/llvm/llvm-project/pull/152877 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fixed a crash when parsing #embed parameters with unmatched closing brackets (PR #152877)

2025-08-11 Thread Mariya Podchishchaeva via cfe-commits
@@ -94,6 +94,9 @@ char buffer[] = { #embed "embed_parsing_errors.c" prefix() // OK: tokens within parens are optional #embed "embed_parsing_errors.c" prefix) // expected-error@-1 {{expected '('}} +#embed "embed_parsing_errors.c" prefix()) // expected-error {{expected identifi

[clang] [Clang] Fixed a crash when parsing #embed parameters with unmatched closing brackets (PR #152877)

2025-08-11 Thread Mariya Podchishchaeva via cfe-commits
@@ -94,6 +94,9 @@ char buffer[] = { #embed "embed_parsing_errors.c" prefix() // OK: tokens within parens are optional #embed "embed_parsing_errors.c" prefix) // expected-error@-1 {{expected '('}} +#embed "embed_parsing_errors.c" prefix()) // expected-error {{expected identifi

[clang] [SYCL] SYCL host kernel launch support for the sycl_kernel_entry_point attribute. (PR #152403)

2025-08-07 Thread Mariya Podchishchaeva via cfe-commits
@@ -367,6 +370,67 @@ void SemaSYCL::CheckSYCLEntryPointFunctionDecl(FunctionDecl *FD) { namespace { +CompoundStmt *BuildSYCLKernelLaunchStmt(Sema &SemaRef, FunctionDecl *FD, +const std::string &KernelName) { + ASTContext &Ctx = SemaRe

[clang] [SYCL] SYCL host kernel launch support for the sycl_kernel_entry_point attribute. (PR #152403)

2025-08-07 Thread Mariya Podchishchaeva via cfe-commits
@@ -367,6 +370,67 @@ void SemaSYCL::CheckSYCLEntryPointFunctionDecl(FunctionDecl *FD) { namespace { +CompoundStmt *BuildSYCLKernelLaunchStmt(Sema &SemaRef, FunctionDecl *FD, +const std::string &KernelName) { + ASTContext &Ctx = SemaRe

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-08-07 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/139566 >From 1b0b6242e5749e776f02581ba8600d853bfef322 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Mon, 12 May 2025 07:25:57 -0700 Subject: [PATCH 01/18] [win][clang] Align scalar deleting destructor

[clang] [Clang][NFC] Enumerate Clang ABI versions in a separate header file (PR #151995)

2025-08-07 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon approved this pull request. Thank you for working on this! Honestly, I'm not a fan of .def files, but I don't have any other good ideas atm, LGTM! https://github.com/llvm/llvm-project/pull/151995 ___ cfe-commits mailing li

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-08-06 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: ping @tahonermann https://github.com/llvm/llvm-project/pull/139566 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] constexpr integer `__builtin_elementwise_{max,min}` (PR #152294)

2025-08-06 Thread Mariya Podchishchaeva via cfe-commits
@@ -11654,6 +11654,41 @@ bool VectorExprEvaluator::VisitCallExpr(const CallExpr *E) { return Success(APValue(ResultElements.data(), ResultElements.size()), E); } + case Builtin::BI__builtin_elementwise_max: + case Builtin::BI__builtin_elementwise_min: { --

[clang] [SYCL] Restrict the sycl_kernel_entry_point attribute spelling to C++11 style. (PR #151405)

2025-07-31 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon approved this pull request. https://github.com/llvm/llvm-project/pull/151405 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-07-14 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: ping @tahonermann https://github.com/llvm/llvm-project/pull/139566 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][SYCL] Add sycl_external attribute and restrict emitting device code (PR #140282)

2025-07-10 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: Oops new tests are failing. https://github.com/llvm/llvm-project/pull/140282 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][SYCL] Add sycl_external attribute and restrict emitting device code (PR #140282)

2025-07-08 Thread Mariya Podchishchaeva via cfe-commits
@@ -25,20 +40,29 @@ int main() { auto lambda2 = [](int){}; auto lambda3 = [](double){}; - kernel(lambda1); - kernel2(lambda2); - kernel3(lambda3); + kernel_wrapper(lambda1); + kernel2_wrapper(lambda2); + kernel3_wrapper(lambda3); // Ensure the kernels are named

[clang] [clang][SYCL] Add sycl_external attribute and restrict emitting device code (PR #140282)

2025-07-08 Thread Mariya Podchishchaeva via cfe-commits
@@ -25,20 +40,29 @@ int main() { auto lambda2 = [](int){}; auto lambda3 = [](double){}; - kernel(lambda1); - kernel2(lambda2); - kernel3(lambda3); + kernel_wrapper(lambda1); + kernel2_wrapper(lambda2); + kernel3_wrapper(lambda3); // Ensure the kernels are named

[clang] [clang][SYCL] Add sycl_external attribute and restrict emitting device code (PR #140282)

2025-07-08 Thread Mariya Podchishchaeva via cfe-commits
@@ -25,20 +40,29 @@ int main() { auto lambda2 = [](int){}; auto lambda3 = [](double){}; - kernel(lambda1); - kernel2(lambda2); - kernel3(lambda3); + kernel_wrapper(lambda1); + kernel2_wrapper(lambda2); + kernel3_wrapper(lambda3); // Ensure the kernels are named

[clang] [clang][SYCL] Add sycl_external attribute and restrict emitting device code (PR #140282)

2025-07-08 Thread Mariya Podchishchaeva via cfe-commits
@@ -25,20 +40,29 @@ int main() { auto lambda2 = [](int){}; auto lambda3 = [](double){}; - kernel(lambda1); - kernel2(lambda2); - kernel3(lambda3); + kernel_wrapper(lambda1); + kernel2_wrapper(lambda2); + kernel3_wrapper(lambda3); // Ensure the kernels are named

[clang] [win][clang] Do not inject static_assert macro definition (PR #147030)

2025-07-08 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon closed https://github.com/llvm/llvm-project/pull/147030 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][clang] Fix CodeGenSYCL::unique_stable_name_windows_diff test (PR #146854)

2025-07-08 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon closed https://github.com/llvm/llvm-project/pull/146854 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][clang] Fix CodeGenSYCL::unique_stable_name_windows_diff test (PR #146854)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/146854 >From 9a640eefb5d27a65f236b5f7df1398bdf1bcc017 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Thu, 3 Jul 2025 03:46:41 -0700 Subject: [PATCH 1/4] [NFC][clang] Fix CodeGenSYCL::unique_stable_nam

[clang] [C23][Parser] Diagnostic for attribute declaration where statement is required (PR #146224)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
@@ -747,6 +747,10 @@ Bug Fixes in This Version - Fixed an infinite recursion when checking constexpr destructors. (#GH141789) - Fixed a crash when a malformed using declaration appears in a ``constexpr`` function. (#GH144264) - Fixed a bug when use unicode character name in ma

[clang] [clang][SYCL] Add sycl_external attribute and restrict emitting device code (PR #140282)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
@@ -25,20 +40,29 @@ int main() { auto lambda2 = [](int){}; auto lambda3 = [](double){}; - kernel(lambda1); - kernel2(lambda2); - kernel3(lambda3); + kernel_wrapper(lambda1); + kernel2_wrapper(lambda2); + kernel3_wrapper(lambda3); // Ensure the kernels are named

[clang] [NFC][clang] Fix CodeGenSYCL::unique_stable_name_windows_diff test (PR #146854)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: > I noticed there is a problem with __builtin_sycl_unique_stable_name and > sycl_kernel_etnry_point attribute. If I add this wrapping of > __builtin_sycl_unique_stable_name calls AND sycl_kernel_entry_point > attribute, the strings disappear from the IR. They are in here > ht

[clang] [NFC][clang] Fix CodeGenSYCL::unique_stable_name_windows_diff test (PR #146854)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon edited https://github.com/llvm/llvm-project/pull/146854 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][clang] Fix CodeGenSYCL::unique_stable_name_windows_diff test (PR #146854)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon ready_for_review https://github.com/llvm/llvm-project/pull/146854 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][clang] Fix CodeGenSYCL::unique_stable_name_windows_diff test (PR #146854)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/146854 >From 9a640eefb5d27a65f236b5f7df1398bdf1bcc017 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Thu, 3 Jul 2025 03:46:41 -0700 Subject: [PATCH 1/3] [NFC][clang] Fix CodeGenSYCL::unique_stable_nam

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
@@ -46,6 +46,22 @@ Potentially Breaking Changes ``endbr64`` instruction at the labels named as possible branch destinations, so it is not safe to use a register-controlled branch instruction to branch to one. (In line with gcc.) +- Scalar deleting destructor support has b

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: Ping @tahonermann https://github.com/llvm/llvm-project/pull/139566 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [win][clang] Do not inject static_assert macro definition (PR #147030)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
@@ -1450,7 +1450,6 @@ def MicrosoftAnonTag : DiagGroup<"microsoft-anon-tag">; def MicrosoftCommentPaste : DiagGroup<"microsoft-comment-paste">; def MicrosoftEndOfFile : DiagGroup<"microsoft-end-of-file">; def MicrosoftInaccessibleBase : DiagGroup<"microsoft-inaccessible-base">;

[clang] [win][clang] Do not inject static_assert macro definition (PR #147030)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/147030 >From 3060e6f416ea62bdf62470e6636278d736cc49d0 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Fri, 4 Jul 2025 02:50:38 -0700 Subject: [PATCH 1/4] [win][clang] Do not inject static_assert macro d

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/139566 >From 1b0b6242e5749e776f02581ba8600d853bfef322 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Mon, 12 May 2025 07:25:57 -0700 Subject: [PATCH 01/17] [win][clang] Align scalar deleting destructor

[clang] [win][clang] Do not inject static_assert macro definition (PR #147030)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
@@ -1450,7 +1450,6 @@ def MicrosoftAnonTag : DiagGroup<"microsoft-anon-tag">; def MicrosoftCommentPaste : DiagGroup<"microsoft-comment-paste">; def MicrosoftEndOfFile : DiagGroup<"microsoft-end-of-file">; def MicrosoftInaccessibleBase : DiagGroup<"microsoft-inaccessible-base">;

[clang] [win][clang] Do not inject static_assert macro definition (PR #147030)

2025-07-07 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/147030 >From 3060e6f416ea62bdf62470e6636278d736cc49d0 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Fri, 4 Jul 2025 02:50:38 -0700 Subject: [PATCH 1/3] [win][clang] Do not inject static_assert macro d

[clang] [win][clang] Do not inject static_assert macro definition (PR #147030)

2025-07-04 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon created https://github.com/llvm/llvm-project/pull/147030 In ms-compatibility mode we inject static_assert macro definition if assert macro is defined. This is done by 8da090381d567d0ec555840f6b2a651d2997e4b3 for the sake of better diagnosing, in particular to emit a

[clang] [NFC][clang] Fix CodeGenSYCL::unique_stable_name_windows_diff test (PR #146854)

2025-07-03 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon converted_to_draft https://github.com/llvm/llvm-project/pull/146854 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][clang] Fix CodeGenSYCL::unique_stable_name_windows_diff test (PR #146854)

2025-07-03 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: I noticed there is a problem with __builtin_sycl_unique_stable_name and sycl_kernel_etnry_point attribute. If I add this wrapping of __builtin_sycl_unique_stable_name calls AND sycl_kernel_entry_point attribute, the strings disappear from the IR. They are in here https://godb

[clang] [NFC][clang] Fix CodeGenSYCL::unique_stable_name_windows_diff test (PR #146854)

2025-07-03 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon ready_for_review https://github.com/llvm/llvm-project/pull/146854 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][clang] Fix CodeGenSYCL::unique_stable_name_windows_diff test (PR #146854)

2025-07-03 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/146854 >From 9a640eefb5d27a65f236b5f7df1398bdf1bcc017 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Thu, 3 Jul 2025 03:46:41 -0700 Subject: [PATCH 1/2] [NFC][clang] Fix CodeGenSYCL::unique_stable_nam

[clang] [NFC][clang] Fix CodeGenSYCL::unique_stable_name_windows_diff test (PR #146854)

2025-07-03 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon created https://github.com/llvm/llvm-project/pull/146854 The test checks x86 target in fsycl-is-device mode. x86 is not a valid offloading target and IMO test meant to check fsycl-is-host mode to make sure host invocations of __builtin_sycl_unique_stable_name work

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-26 Thread Mariya Podchishchaeva via cfe-commits
@@ -1587,28 +1587,82 @@ namespace { } }; + // This function implements generation of scalar deleting destructor body for + // the case when the destructor also accepts an implicit flag. Right now only + // Microsoft ABI requires deleting destructors to accept implicit

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-26 Thread Mariya Podchishchaeva via cfe-commits
@@ -3101,6 +3101,17 @@ void CXXDestructorDecl::setOperatorDelete(FunctionDecl *OD, Expr *ThisArg) { } } +void CXXDestructorDecl::setOperatorGlobalDelete(FunctionDecl *OD) { + assert(!OD || (OD->getDeclName().getCXXOverloadedOperator() == OO_Delete && + OD-

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-26 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/139566 >From 1b0b6242e5749e776f02581ba8600d853bfef322 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Mon, 12 May 2025 07:25:57 -0700 Subject: [PATCH 01/16] [win][clang] Align scalar deleting destructor

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-26 Thread Mariya Podchishchaeva via cfe-commits
@@ -194,9 +217,31 @@ I::~I() { call_in_dtor(); } // CHECK-MSABI32-LABEL: define {{.*}} @"??_GI@@UAEPAXI@Z"( // CHECK-MSABI-NOT: call{{ }} // CHECK-MSABI: load i32 -// CHECK-MSABI: icmp eq i32 {{.*}}, 0 -// CHECK-MSABI: br i1 +// CHECK-MSABI-NEXT: and i32 %[[IMP_PARAM:.*]], 4 +/

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-25 Thread Mariya Podchishchaeva via cfe-commits
@@ -2886,6 +2887,16 @@ class CXXDestructorDecl : public CXXMethodDecl { return getCanonicalDecl()->OperatorDelete; } + const FunctionDecl *getOperatorGlobalDelete() const { +return getCanonicalDecl()->OperatorGlobalDelete; + } + + void setOperatorGlobalDelete(Func

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-25 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/139566 >From 1b0b6242e5749e776f02581ba8600d853bfef322 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Mon, 12 May 2025 07:25:57 -0700 Subject: [PATCH 01/11] [win][clang] Align scalar deleting destructor

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-25 Thread Mariya Podchishchaeva via cfe-commits
@@ -2886,6 +2887,16 @@ class CXXDestructorDecl : public CXXMethodDecl { return getCanonicalDecl()->OperatorDelete; } + const FunctionDecl *getOperatorGlobalDelete() const { +return getCanonicalDecl()->OperatorGlobalDelete; + } + + void setOperatorGlobalDelete(Func

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-25 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/139566 >From 1b0b6242e5749e776f02581ba8600d853bfef322 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Mon, 12 May 2025 07:25:57 -0700 Subject: [PATCH 01/14] [win][clang] Align scalar deleting destructor

[clang] [clang] Fix __builtin_mul_overflow for big _BitInts (PR #145497)

2025-06-25 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon closed https://github.com/llvm/llvm-project/pull/145497 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix __builtin_mul_overflow for big _BitInts (PR #145497)

2025-06-24 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon edited https://github.com/llvm/llvm-project/pull/145497 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-24 Thread Mariya Podchishchaeva via cfe-commits
@@ -2886,6 +2887,16 @@ class CXXDestructorDecl : public CXXMethodDecl { return getCanonicalDecl()->OperatorDelete; } + const FunctionDecl *getOperatorGlobalDelete() const { +return getCanonicalDecl()->OperatorGlobalDelete; + } + + void setOperatorGlobalDelete(Func

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-24 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/139566 >From 1b0b6242e5749e776f02581ba8600d853bfef322 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Mon, 12 May 2025 07:25:57 -0700 Subject: [PATCH 01/12] [win][clang] Align scalar deleting destructor

[clang] [clang] Fix __builtin_mul_overflow for big _BitInts (PR #145497)

2025-06-24 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon created https://github.com/llvm/llvm-project/pull/145497 For long enough _BitInt types we use different types for memory, storing-loading and operations. Makes sure it is correct for mixed sign __builtin_mul_overflow cases. Using pointer element type as a result ty

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-18 Thread Mariya Podchishchaeva via cfe-commits
@@ -194,9 +217,31 @@ I::~I() { call_in_dtor(); } // CHECK-MSABI32-LABEL: define {{.*}} @"??_GI@@UAEPAXI@Z"( // CHECK-MSABI-NOT: call{{ }} // CHECK-MSABI: load i32 -// CHECK-MSABI: icmp eq i32 {{.*}}, 0 -// CHECK-MSABI: br i1 +// CHECK-MSABI-NEXT: and i32 %[[IMP_PARAM:.*]], 4 +/

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-18 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon edited https://github.com/llvm/llvm-project/pull/139566 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-18 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon edited https://github.com/llvm/llvm-project/pull/139566 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-18 Thread Mariya Podchishchaeva via cfe-commits
@@ -2886,6 +2887,16 @@ class CXXDestructorDecl : public CXXMethodDecl { return getCanonicalDecl()->OperatorDelete; } + const FunctionDecl *getOperatorGlobalDelete() const { +return getCanonicalDecl()->OperatorGlobalDelete; + } + + void setOperatorGlobalDelete(Func

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-18 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/139566 >From 1b0b6242e5749e776f02581ba8600d853bfef322 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Mon, 12 May 2025 07:25:57 -0700 Subject: [PATCH 01/11] [win][clang] Align scalar deleting destructor

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-18 Thread Mariya Podchishchaeva via cfe-commits
@@ -1590,25 +1590,70 @@ namespace { void EmitConditionalDtorDeleteCall(CodeGenFunction &CGF, Fznamznon wrote: Added a comment. https://github.com/llvm/llvm-project/pull/139566 ___ cfe-commits mailing list cfe-commit

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-18 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/139566 >From 1b0b6242e5749e776f02581ba8600d853bfef322 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Mon, 12 May 2025 07:25:57 -0700 Subject: [PATCH 01/10] [win][clang] Align scalar deleting destructor

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-18 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/139566 >From 1b0b6242e5749e776f02581ba8600d853bfef322 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Mon, 12 May 2025 07:25:57 -0700 Subject: [PATCH 1/8] [win][clang] Align scalar deleting destructors

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-17 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/139566 >From 1b0b6242e5749e776f02581ba8600d853bfef322 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Mon, 12 May 2025 07:25:57 -0700 Subject: [PATCH 1/7] [win][clang] Align scalar deleting destructors

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-16 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/139566 >From 1b0b6242e5749e776f02581ba8600d853bfef322 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Mon, 12 May 2025 07:25:57 -0700 Subject: [PATCH 1/5] [win][clang] Align scalar deleting destructors

[clang] [clang] Fix -fclang-abi-compat for clang 20 (PR #144109)

2025-06-16 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon closed https://github.com/llvm/llvm-project/pull/144109 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-13 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: Thanks @AaronBallman , It seems -fclang-abi-compat=20 doesn't work, so first we need https://github.com/llvm/llvm-project/pull/144109 . https://github.com/llvm/llvm-project/pull/139566 ___ cfe-commits mailing list cfe-commits@lists.ll

[clang] [clang] Fix -fclang-abi-compat for clang 20 (PR #144109)

2025-06-13 Thread Mariya Podchishchaeva via cfe-commits
@@ -11,6 +12,7 @@ struct XMM2 : XMM1<0>, XMM1<1> { }; // CHECK: define{{.*}} @_Z3foov({{.*}} [[ARG:%.*]]){{.*}} +// CLANG-20: define{{.*}} <4 x double> @_Z3foov() Fznamznon wrote: I think this is the only test which is different between clang 20 and clang 21,

[clang] [clang] Fix -fclang-abi-compat for clang 20 (PR #144109)

2025-06-13 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon created https://github.com/llvm/llvm-project/pull/144109 The value was known already, but it was parsed as latest which is incorrect because we are already doing clang 21. >From a48dd54fb4918a89e6a98f82860332ab59be6df6 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva

[clang] [Clang] use colon char instead of token name (PR #144068)

2025-06-13 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon approved this pull request. https://github.com/llvm/llvm-project/pull/144068 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] use colon char instead of token name (PR #144068)

2025-06-13 Thread Mariya Podchishchaeva via cfe-commits
@@ -836,8 +836,7 @@ StmtResult Parser::ParseCaseStatement(ParsedStmtContext StmtCtx, Diag(ExpectedLoc, diag::err_expected_after) << "'case'" << tok::colon - << FixItHint::CreateInsertion(ExpectedLoc, -tok::getTo

[clang] [Clang] use colon char instead of token name (PR #144068)

2025-06-13 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon commented: Can we add a test? https://github.com/llvm/llvm-project/pull/144068 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] use colon char instead of token name (PR #144068)

2025-06-13 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon edited https://github.com/llvm/llvm-project/pull/144068 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-12 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: Ok, I added the release note. > we'd use ABI version tags for it at that point. @AaronBallman Could you please elaborate a bit more on that? https://github.com/llvm/llvm-project/pull/139566 ___ cfe-commits mailing list cfe-commits@li

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-12 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/139566 >From 1b0b6242e5749e776f02581ba8600d853bfef322 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Mon, 12 May 2025 07:25:57 -0700 Subject: [PATCH 1/4] [win][clang] Align scalar deleting destructors

[clang] [clang] Implement StmtPrinter for EmbedExpr (PR #135957)

2025-06-12 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: > Was there a backport request created for this one? No, when I applied the patch locally to release20.x branch, one of the tests that this patch adds crashed, so probably additional fixes required to be backported. https://github.com/llvm/llvm-project/pull/135957 ___

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-11 Thread Mariya Podchishchaeva via cfe-commits
@@ -1589,25 +1589,74 @@ namespace { void EmitConditionalDtorDeleteCall(CodeGenFunction &CGF, llvm::Value *ShouldDeleteCondition, bool ReturnAfterDelete) { +const CXXDestructorDecl *Dtor = cast(CGF.C

[clang] [win][clang] Align scalar deleting destructors with MSABI (PR #139566)

2025-06-11 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/139566 >From 1b0b6242e5749e776f02581ba8600d853bfef322 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Mon, 12 May 2025 07:25:57 -0700 Subject: [PATCH 1/2] [win][clang] Align scalar deleting destructors

[clang] [Clang][Attr] Fix possible crash when trying to check for DeviceKernel spelling (PR #143546)

2025-06-10 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon approved this pull request. https://github.com/llvm/llvm-project/pull/143546 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][Attr] Fix possible crash when trying to check for DeviceKernel spelling (PR #143546)

2025-06-10 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: > I didn't add a test because this can't be reproduced yet in this repo, I > reproduced this only in intel's fork with more SYCL support. But that does sound specific to the downstream, right? Do we observe the issue there because intel's fork used to add OpenCLKernelAttr impl

[clang] [clang][SYCL Upstreaming] Add sycl_external attribute and restrict emitting device code (PR #140282)

2025-06-10 Thread Mariya Podchishchaeva via cfe-commits
@@ -7179,6 +7179,12 @@ ProcessDeclAttribute(Sema &S, Scope *scope, Decl *D, const ParsedAttr &AL, case ParsedAttr::AT_EnumExtensibility: handleEnumExtensibilityAttr(S, D, AL); break; + case ParsedAttr::AT_SYCLKernel: +S.SYCL().handleKernelAttr(D, AL); +break

[clang] [clang][SYCL Upstreaming] Add sycl_external attribute and restrict emitting device code (PR #140282)

2025-06-10 Thread Mariya Podchishchaeva via cfe-commits
@@ -1,128 +1,128 @@ // RUN: %clang_cc1 -triple amdgcn-amd-amdhsa -fsycl-is-device -disable-llvm-passes -emit-llvm %s -o - | FileCheck %s void bar(int &Data) {} -// CHECK: define dso_local void @[[RAW_REF:[a-zA-Z0-9_]+]](ptr noundef nonnull align 4 dereferenceable(4) % +// CHEC

[clang] [clang][SYCL Upstreaming] Add sycl_external attribute and restrict emitting device code (PR #140282)

2025-06-10 Thread Mariya Podchishchaeva via cfe-commits
@@ -0,0 +1,38 @@ +// RUN: %clang_cc1 -fsycl-is-device -fsyntax-only -verify %s + +// Semantic tests for sycl_external attribute + +[[clang::sycl_external(3)]] // expected-error {{'sycl_external' attribute takes no arguments}} +void bar() {} + +[[clang::sycl_external]] // expected

  1   2   3   4   5   6   7   8   9   10   >