[clang] [clang][Interp] Fix IntAP(s) to IntAP(s) casts (PR #69915)

2023-10-23 Thread Timm Baeder via cfe-commits
tbaederr wrote: This was still `assert(false)`'ed out, it's for casts between two `IntAP`/`IntAPS` expressions. We can't just short-circuit for `FromT == ToT` because we need to consider the bitwidth when doing the cast. https://github.com/llvm/llvm-project/pull/69915 _

[clang] [SVE2.1][Clang][LLVM]Int/FP reduce builtin in Clang and LLVM intrinsic (PR #69926)

2023-10-23 Thread via cfe-commits
https://github.com/CarolineConcatto created https://github.com/llvm/llvm-project/pull/69926 This patch implements the builtins in Clang and the LLVM-IR intrinsic for the following: // Variants are also available for: // _s8, _s16, _u16, _s32, _u32, _s64, _u64, // _f16, _f32, _f64uint8x16_t svad

[clang] [SVE2.1][Clang][LLVM]Int/FP reduce builtin in Clang and LLVM intrinsic (PR #69926)

2023-10-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (CarolineConcatto) Changes This patch implements the builtins in Clang and the LLVM-IR intrinsic for the following: // Variants are also available for: // _s8, _s16, _u16, _s32, _u32, _s64, _u64, // _f16, _f32, _f64uint8x16_t svaddqv[

[clang] [clang-format] Don't break between string literal operands of << (PR #69871)

2023-10-23 Thread Tsarkov Maksim via cfe-commits
s1Sharp wrote: I think adding the possibility of breaking '<<' is a good idea if it's optional, what do u think? https://github.com/llvm/llvm-project/pull/69871 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mai

[clang] [Clang] Handle real and imaginary parts of complex lvalue in `APValue::printPretty` (PR #69252)

2023-10-23 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/69252 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D157252: [clang][ExprConst] Handle 0 type size in builtin_memcpy etc.

2023-10-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM with a fixme comment added. Comment at: clang/test/Sema/builtin-memcpy.c:4-8 +int b() { + struct { } a[10]; + __builtin_memcpy(&a[2], a, 2); // expe

[clang] [clang] Prioritze decl comments from macro expansion site (PR #65481)

2023-10-23 Thread Daniel Grumberg via cfe-commits
https://github.com/daniel-grumberg updated https://github.com/llvm/llvm-project/pull/65481 >From 32155e8b5ac01242c3e16968f9a7c821d16b7007 Mon Sep 17 00:00:00 2001 From: Daniel Grumberg Date: Wed, 6 Sep 2023 12:20:30 +0100 Subject: [PATCH 1/2] [clang] Prioritze decl comments from macro expansion

[clang] [clang] Prioritze decl comments from macro expansion site (PR #65481)

2023-10-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Daniel Grumberg (daniel-grumberg) Changes For declarations declared inside a macro, e.g.: ``` `#define MAKE_FUNC(suffix) \ /// Not selected doc comment \ void func_##suffix(void) { } /// Doc comment foo MAKE_FUNC(foo) /

[clang] [Clang] Handle real and imaginary parts of complex lvalue in `APValue::printPretty` (PR #69252)

2023-10-23 Thread Yingwei Zheng via cfe-commits
https://github.com/dtcxzyw closed https://github.com/llvm/llvm-project/pull/69252 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 48508c1 - [Clang] Handle real and imaginary parts of complex lvalue in `APValue::printPretty` (#69252)

2023-10-23 Thread via cfe-commits
Author: Yingwei Zheng Date: 2023-10-23T21:40:04+08:00 New Revision: 48508c13500908079ae605ad4bd6be075e46f5fb URL: https://github.com/llvm/llvm-project/commit/48508c13500908079ae605ad4bd6be075e46f5fb DIFF: https://github.com/llvm/llvm-project/commit/48508c13500908079ae605ad4bd6be075e46f5fb.diff

[clang] [clang][Interp] Only diagnose null field access in constant contexts (PR #69223)

2023-10-23 Thread Timm Baeder via cfe-commits
Timm =?utf-8?q?Bäder?= Message-ID: In-Reply-To: @@ -295,7 +295,7 @@ class Pointer { bool isUnion() const; /// Checks if the storage is extern. - bool isExtern() const { return Pointee->isExtern(); } + bool isExtern() const { return Pointee && Pointee->isExtern(); } --

[PATCH] D154581: [clang][Interp] Track existing InitMaps in InterpState

2023-10-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154581/new/ https://reviews.llvm.org/D154581 ___ cfe-commits mailing lis

[clang] 0a1472b - Update my contact email in CodeOwners.rst

2023-10-23 Thread via cfe-commits
Author: erichkeane Date: 2023-10-23T06:49:57-07:00 New Revision: 0a1472bbcaae6803a5be70c9e841c5acc814c5c1 URL: https://github.com/llvm/llvm-project/commit/0a1472bbcaae6803a5be70c9e841c5acc814c5c1 DIFF: https://github.com/llvm/llvm-project/commit/0a1472bbcaae6803a5be70c9e841c5acc814c5c1.diff LO

[clang] [clang][Sema] Avoid non-empty unexpanded pack assertion for FunctionParmPackExpr (PR #69224)

2023-10-23 Thread Younan Zhang via cfe-commits
@@ -402,6 +402,20 @@ bool Sema::DiagnoseUnexpandedParameterPack(Expr *E, if (!E->containsUnexpandedParameterPack()) return false; + // Exception: The `CollectUnexpandedParameterPacksVisitor` collects nothing + // from a FunctionParmPackExpr. In the context where the co

[clang] [clang][Sema] Avoid non-empty unexpanded pack assertion for FunctionParmPackExpr (PR #69224)

2023-10-23 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/69224 >From ec6425590890e050dc212a7e13ca27c866a4fb22 Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Mon, 16 Oct 2023 22:50:08 +0800 Subject: [PATCH 1/2] [clang][Sema] Avoid non-empty unexpanded pack assertion for F

[clang] [mlir] Add config for PDL (PR #69927)

2023-10-23 Thread Jacques Pienaar via cfe-commits
https://github.com/jpienaar updated https://github.com/llvm/llvm-project/pull/69927 >From eea36708d838411d70eb99265c3a2f3aabb91460 Mon Sep 17 00:00:00 2001 From: Jacques Pienaar Date: Sun, 22 Oct 2023 09:33:40 -0700 Subject: [PATCH] [mlir] Add config for PDL Make it so that PDL can be optional

[clang-tools-extra] [mlir] Add config for PDL (PR #69927)

2023-10-23 Thread Jacques Pienaar via cfe-commits
https://github.com/jpienaar updated https://github.com/llvm/llvm-project/pull/69927 >From eea36708d838411d70eb99265c3a2f3aabb91460 Mon Sep 17 00:00:00 2001 From: Jacques Pienaar Date: Sun, 22 Oct 2023 09:33:40 -0700 Subject: [PATCH] [mlir] Add config for PDL Make it so that PDL can be optional

[clang] [clang] Support fixed point types in C++ (PR #67750)

2023-10-23 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: This is introducing an extension from C into C++ -- was there an RFC or something discussed about whether we wish to support this in C++? This breaks code in system headers entirely unrelated to fixed point: ``` #include #include int main(int argc, char* argv[]) { std

[clang-tools-extra] [ConstantRange] Handle `Intrinsic::cttz` (PR #67917)

2023-10-23 Thread Nikita Popov via cfe-commits
https://github.com/nikic commented: I think most of the comments from the ctpop review also apply to this one. https://github.com/llvm/llvm-project/pull/67917 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailma

[clang] [ConstantRange] Handle `Intrinsic::cttz` (PR #67917)

2023-10-23 Thread Nikita Popov via cfe-commits
https://github.com/nikic commented: I think most of the comments from the ctpop review also apply to this one. https://github.com/llvm/llvm-project/pull/67917 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailma

[clang] [NFC] use `StringSet::insert(iter, iter)` instead for loop to insert (PR #69851)

2023-10-23 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. Ends up being completely NFC, new form of insert is just the same loop. https://github.com/llvm/llvm-project/pull/69851 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm

[clang] [clang-format] Don't alter SpacesRequiredBefore of finalized tokens (PR #69897)

2023-10-23 Thread Emilia Kond via cfe-commits
https://github.com/rymiel approved this pull request. Thank you so much! https://github.com/llvm/llvm-project/pull/69897 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Adapt Inlay Hint support for Deducing This (PR #68177)

2023-10-23 Thread Younan Zhang via cfe-commits
@@ -859,7 +872,9 @@ class InlayHintVisitor : public RecursiveASTVisitor { else ForwardedParams = {Params.begin(), Params.end()}; -NameVec ParameterNames = chooseParameterNames(ForwardedParams); +auto ForwardedParamsRef = zyn0217 wrote: Than

[clang-tools-extra] [clangd] Adapt Inlay Hint support for Deducing This (PR #68177)

2023-10-23 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/68177 >From f83f28d0d055066bb7660e24e2253a61273f014a Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Wed, 4 Oct 2023 11:59:31 +0800 Subject: [PATCH 1/3] [clangd] Adapt Inlay Hint support for Deducing This This is a

[clang-tools-extra] [clangd] Fix RawStringLiteral being available to C and C++ versions prior to C++11 (PR #69775)

2023-10-23 Thread via cfe-commits
https://github.com/robozati updated https://github.com/llvm/llvm-project/pull/69775 >From e8eb79384dcd90c8a2e96a3e4e8c35bb0f42031c Mon Sep 17 00:00:00 2001 From: Gabriel Pezati Date: Mon, 23 Oct 2023 11:26:47 -0300 Subject: [PATCH] Fix RawStringLiteral being available to C and C++ versions pri

[clang-tools-extra] [clangd] Fix RawStringLiteral being available to C and C++ versions prior to C++11 (PR #69775)

2023-10-23 Thread via cfe-commits
https://github.com/robozati updated https://github.com/llvm/llvm-project/pull/69775 >From d7537012cc7adea063338ea8ede9a2e0f7decb50 Mon Sep 17 00:00:00 2001 From: Gabriel Pezati Date: Mon, 23 Oct 2023 11:36:19 -0300 Subject: [PATCH] Fix RawStringLiteral being available for C and C++ versions pr

[clang-tools-extra] [clangd] Adapt Inlay Hint support for Deducing This (PR #68177)

2023-10-23 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/68177 >From f83f28d0d055066bb7660e24e2253a61273f014a Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Wed, 4 Oct 2023 11:59:31 +0800 Subject: [PATCH 1/4] [clangd] Adapt Inlay Hint support for Deducing This This is a

[clang-tools-extra] [mlir] Verify TestBuiltinAttributeInterfaces eltype (PR #69878)

2023-10-23 Thread Rik Huijzer via cfe-commits
https://github.com/rikhuijzer closed https://github.com/llvm/llvm-project/pull/69878 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [mlir] Verify TestBuiltinAttributeInterfaces eltype (PR #69878)

2023-10-23 Thread Rik Huijzer via cfe-commits
https://github.com/rikhuijzer closed https://github.com/llvm/llvm-project/pull/69878 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] unexpected break after binOp '<<' (PR #69859)

2023-10-23 Thread Tsarkov Maksim via cfe-commits
https://github.com/s1Sharp edited https://github.com/llvm/llvm-project/pull/69859 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 9022f40 - [clang][Interp] Only evaluate the source array initialization of an `ArrayInitLoopExpr` once (#68039)

2023-10-23 Thread via cfe-commits
Author: isuckatcs Date: 2023-10-23T17:52:27+02:00 New Revision: 9022f402120b4e55ec1201c16f8f6d2388498e1d URL: https://github.com/llvm/llvm-project/commit/9022f402120b4e55ec1201c16f8f6d2388498e1d DIFF: https://github.com/llvm/llvm-project/commit/9022f402120b4e55ec1201c16f8f6d2388498e1d.diff LOG

[clang] [clang][Interp] Only evaluate the source array initialization of an `ArrayInitLoopExpr` once (PR #68039)

2023-10-23 Thread via cfe-commits
https://github.com/isuckatcs closed https://github.com/llvm/llvm-project/pull/68039 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Prioritze decl comments from macro expansion site (PR #65481)

2023-10-23 Thread Daniel Grumberg via cfe-commits
https://github.com/daniel-grumberg updated https://github.com/llvm/llvm-project/pull/65481 >From e9be513c357d7bb01a3acf69871e2e9889cb2079 Mon Sep 17 00:00:00 2001 From: Daniel Grumberg Date: Wed, 6 Sep 2023 12:20:30 +0100 Subject: [PATCH] [clang] Prioritze decl comments from macro expansion sit

[clang] [Profile] Add binary profile correlation to offload profile metadata at runtime. (PR #69493)

2023-10-23 Thread David Li via cfe-commits
david-xl wrote: > > This should works with PGO when value profiling is disabled > > Is this not compatible with value profiling? or just not implemented yet? Not compatible, but this feature is mainly for coverage testing. https://github.com/llvm/llvm-project/pull/69493 ___

[clang] [clang][dataflow] Remove `declToLocConsistent()` assertion. (PR #69819)

2023-10-23 Thread Gábor Horváth via cfe-commits
https://github.com/Xazax-hun approved this pull request. LG, thanks! https://github.com/llvm/llvm-project/pull/69819 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AArch64] Implement reinterpret builtins for SVE vector tuples (PR #69598)

2023-10-23 Thread Momchil Velikov via cfe-commits
https://github.com/momchil-velikov edited https://github.com/llvm/llvm-project/pull/69598 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AArch64] Implement reinterpret builtins for SVE vector tuples (PR #69598)

2023-10-23 Thread Momchil Velikov via cfe-commits
momchil-velikov wrote: > I think it is fine to point also the PR in the acle in the commit message: > https://github.com/ARM-software/acle/pull/275/files Done. https://github.com/llvm/llvm-project/pull/69598 ___ cfe-commits mailing list cfe-commits@l

[clang] Revert [clang] Handle templated operators with reversed arguments and [STLExtras] Undo C++20 hack (PR #69937)

2023-10-23 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 created https://github.com/llvm/llvm-project/pull/69937 None >From b100ca6f219fda1fed5b92aba8471aa9a6ef8906 Mon Sep 17 00:00:00 2001 From: Utkarsh Saxena Date: Mon, 23 Oct 2023 18:02:35 +0200 Subject: [PATCH 1/2] Revert "[STLExtras] Undo C++20 hack" This reverts commit

[clang] [AMDGPU] Add an option to disable unsafe uses of atomic xor (PR #69229)

2023-10-23 Thread Pierre-Andre Saulais via cfe-commits
pasaulais wrote: Ping @hdelan https://github.com/llvm/llvm-project/pull/69229 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Add clang::preferred_type attribute for bitfields (PR #69104)

2023-10-23 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > The changes should also come with a release note, but I'm generally happy > with the code. I did have some suggestions for changes to documentation > though. Suggestion for the release note would be something along these lines: ``` - Clang now supports ``[[clang::preferre

[clang] Update stdckdint.h and make it available in pre-C23 modes. (PR #69649)

2023-10-23 Thread Aaron Ballman via cfe-commits
@@ -1,4 +1,5 @@ // NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --version 3 +// RUN: %clang_cc1 -triple=x86_64 -verify -ffreestanding -std=c2x %s AaronBallman wrote: This triple is the same as the one below (c2x and c23 a

[clang-tools-extra] Update stdckdint.h and make it available in pre-C23 modes. (PR #69649)

2023-10-23 Thread Aaron Ballman via cfe-commits
@@ -23,6 +23,7 @@ #if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 202311L #define __STDC_VERSION_STDCKDINT_H__ 202311L +#endif AaronBallman wrote: GCC exposes this value in all C and C++ language modes, so we should go ahead and remove the `#if` entirel

[clang] Update stdckdint.h and make it available in pre-C23 modes. (PR #69649)

2023-10-23 Thread Aaron Ballman via cfe-commits
@@ -23,6 +23,7 @@ #if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 202311L #define __STDC_VERSION_STDCKDINT_H__ 202311L +#endif AaronBallman wrote: GCC exposes this value in all C and C++ language modes, so we should go ahead and remove the `#if` entirel

[clang] [Sema] Add check for bitfield assignments to integral types (PR #69049)

2023-10-23 Thread kadir çetinkaya via cfe-commits
kadircet wrote: hi folks! this seems to be triggering crashes on some valid code, e.g: a.cc: ``` template bool c = __is_constructible(a, b...); struct d { int q : 1; }; struct i { virtual void g() { (void)c; } }; i n; ``` ``` clang -xc++ -std=c++20 -fsyntax-only a.cc clang: /usr/local

[clang] Revert [clang] Handle templated operators with reversed arguments and [STLExtras] Undo C++20 hack (PR #69937)

2023-10-23 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/69937 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] b997ff4 - Revert [clang] Handle templated operators with reversed arguments and [STLExtras] Undo C++20 hack (#69937)

2023-10-23 Thread via cfe-commits
Author: Utkarsh Saxena Date: 2023-10-23T18:09:56+02:00 New Revision: b997ff41c11cc69cfcb6c8a3ed39ed47229cf891 URL: https://github.com/llvm/llvm-project/commit/b997ff41c11cc69cfcb6c8a3ed39ed47229cf891 DIFF: https://github.com/llvm/llvm-project/commit/b997ff41c11cc69cfcb6c8a3ed39ed47229cf891.diff

[clang] Revert [clang] Handle templated operators with reversed arguments and [STLExtras] Undo C++20 hack (PR #69937)

2023-10-23 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 closed https://github.com/llvm/llvm-project/pull/69937 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 65c9c92 - [NFC] use `StringSet::insert(iter, iter)` instead for loop to insert (#69851)

2023-10-23 Thread via cfe-commits
Author: Congcong Cai Date: 2023-10-24T00:19:12+08:00 New Revision: 65c9c9235075d6e4cd7d70d95a1aca6611e39744 URL: https://github.com/llvm/llvm-project/commit/65c9c9235075d6e4cd7d70d95a1aca6611e39744 DIFF: https://github.com/llvm/llvm-project/commit/65c9c9235075d6e4cd7d70d95a1aca6611e39744.diff

[clang] [NFC] use `StringSet::insert(iter, iter)` instead for loop to insert (PR #69851)

2023-10-23 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 closed https://github.com/llvm/llvm-project/pull/69851 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][Interp] Fix scalar inits of void type (PR #69868)

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

[clang] e214bda - Revert "[Sema] Add check for bitfield assignments to integral types (#69049)"

2023-10-23 Thread Kadir Cetinkaya via cfe-commits
Author: Kadir Cetinkaya Date: 2023-10-23T18:23:21+02:00 New Revision: e214bdac51c46b554e1fb99de6b6b6c735b75bf1 URL: https://github.com/llvm/llvm-project/commit/e214bdac51c46b554e1fb99de6b6b6c735b75bf1 DIFF: https://github.com/llvm/llvm-project/commit/e214bdac51c46b554e1fb99de6b6b6c735b75bf1.dif

[clang] [clang] Add clang::preferred_type attribute for bitfields (PR #69104)

2023-10-23 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll updated https://github.com/llvm/llvm-project/pull/69104 >From 976aa5c8f3d936a15e7123069a49d97ad3bf7a05 Mon Sep 17 00:00:00 2001 From: Vlad Serebrennikov Date: Sun, 15 Oct 2023 13:14:55 +0300 Subject: [PATCH 01/14] [clang] Add clang::debug_info_type attribute --- cla

[clang] [clang] Add clang::preferred_type attribute for bitfields (PR #69104)

2023-10-23 Thread Vlad Serebrennikov via cfe-commits
@@ -7219,6 +7219,31 @@ its underlying representation to be a WebAssembly ``funcref``. }]; } +def PreferredTypeDocumentation : Documentation { + let Category = DocCatField; + let Content = [{ +This attribute allows adjusting the type of a bit-field in debug information. +T

[clang] [clang] Add clang::preferred_type attribute for bitfields (PR #69104)

2023-10-23 Thread Vlad Serebrennikov via cfe-commits
@@ -7219,6 +7219,31 @@ its underlying representation to be a WebAssembly ``funcref``. }]; } +def PreferredTypeDocumentation : Documentation { + let Category = DocCatField; + let Content = [{ +This attribute allows adjusting the type of a bit-field in debug information. +T

[clang] [clang] Add clang::preferred_type attribute for bitfields (PR #69104)

2023-10-23 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: Thank you @AaronBallman for writing even more documentation! https://github.com/llvm/llvm-project/pull/69104 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Add clang::preferred_type attribute for bitfields (PR #69104)

2023-10-23 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. These changes LGTM, but please give @erichkeane a chance to chime in given his previous feedback. https://github.com/llvm/llvm-project/pull/69104 ___ cfe-commits mailing list cfe-commits@list

[clang] [libc] Enable remaining string functions on the GPU (PR #68346)

2023-10-23 Thread Johannes Doerfert via cfe-commits
https://github.com/jdoerfert approved this pull request. Seems a reasonable solution, given that nothing in this space is really nice and clean. Nobody complained for a while, LG. https://github.com/llvm/llvm-project/pull/68346 ___ cfe-commits mailin

[clang] Revert [clang] Handle templated operators with reversed arguments and [STLExtras] Undo C++20 hack (PR #69937)

2023-10-23 Thread Nico Weber via cfe-commits
nico wrote: Looks like the revert broke tests: http://45.33.8.238/linux/121332/step_7.txt Please take a look. https://github.com/llvm/llvm-project/pull/69937 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailma

[clang] [Profile] Add binary profile correlation to offload profile metadata at runtime. (PR #69493)

2023-10-23 Thread via cfe-commits
WenleiHe wrote: > > > This should works with PGO when value profiling is disabled > > > > > > Is this not compatible with value profiling? or just not implemented yet? > > Not compatible, but this feature is mainly for coverage testing. Ok, not a big deal as it's probably not worth the effort

[clang] [clang] Add clang::preferred_type attribute for bitfields (PR #69104)

2023-10-23 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. LGTM, i think we're in an acceptable way forward, particularly on diagnostics. https://github.com/llvm/llvm-project/pull/69104 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lis

[clang] [Sema] Add check for bitfield assignments to integral types (PR #69049)

2023-10-23 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: It looks like these changes surfaced an existing bug with `GetExprRange()`: https://github.com/llvm/llvm-project/blob/4554eac5d4fd7c7a02f947767fc25bd27f004106/clang/lib/Sema/SemaChecking.cpp#L13734 `getSourceExpr()` can return nullptr: https://github.com/llvm/llvm-project/b

[clang] [libc] Enable remaining string functions on the GPU (PR #68346)

2023-10-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/68346 >From 28dec98632ace2e48d57736bb9eb9db311f46aaf Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Fri, 29 Sep 2023 18:50:10 -0500 Subject: [PATCH] [libc] Enable remaining string functions on the GPU Summary: We p

[clang] [LTO] A static relocation model can override the PIC level wrt treating external address as directly accessible (PR #65512)

2023-10-23 Thread Wolfgang Pieb via cfe-commits
wolfy1961 wrote: Ping... Any takers? https://github.com/llvm/llvm-project/pull/65512 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Add check for bitfield assignments to larger integral types (PR #68276)

2023-10-23 Thread David Stone via cfe-commits
davidstone wrote: The documentation for this should also explain how to write code such that the warning does not fire (by giving an example with `x & bitmask`) https://github.com/llvm/llvm-project/pull/68276 ___ cfe-commits mailing list cfe-commits@l

[clang] [libc] Enable remaining string functions on the GPU (PR #68346)

2023-10-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/68346 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 25bf1ae - [libc] Enable remaining string functions on the GPU (#68346)

2023-10-23 Thread via cfe-commits
Author: Joseph Huber Date: 2023-10-23T13:16:20-04:00 New Revision: 25bf1ae99b3985a62f00ebf764f17a12f30c257c URL: https://github.com/llvm/llvm-project/commit/25bf1ae99b3985a62f00ebf764f17a12f30c257c DIFF: https://github.com/llvm/llvm-project/commit/25bf1ae99b3985a62f00ebf764f17a12f30c257c.diff

[clang] [clang][ExprConst] Fix crash on uninitialized array subobject (PR #67817)

2023-10-23 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/67817 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][CodeGen] Handle template parameter objects with explicit address spaces (PR #69266)

2023-10-23 Thread Alex Voicu via cfe-commits
https://github.com/AlexVlx updated https://github.com/llvm/llvm-project/pull/69266 >From ded7435220d2c3527c4798d1b328a5f2940e279a Mon Sep 17 00:00:00 2001 From: Alex Voicu Date: Mon, 16 Oct 2023 22:43:55 +0100 Subject: [PATCH] Handle trying to bind a generic reference to a template parameter o

[clang] Update stdckdint.h and make it available in pre-C23 modes. (PR #69649)

2023-10-23 Thread via cfe-commits
https://github.com/ZijunZhaoCCK updated https://github.com/llvm/llvm-project/pull/69649 >From 0c57e45f6ee16e43cc6388b1ca6beb88bbc7b925 Mon Sep 17 00:00:00 2001 From: zijunzhao Date: Thu, 19 Oct 2023 22:23:03 + Subject: [PATCH 1/3] Update stdckdint.h and make it available in pre-C23 modes.

[clang] [C++20] [Modules] [Driver] Don't enable -fdelayed-template-parsing by default on windows with C++20 modules (PR #69431)

2023-10-23 Thread via cfe-commits
zeroomega wrote: FYI, we are seeing libc++ test failures on Windows after this patch landed, for example: llvm-libc++-static-clangcl.cfg.in :: std/numerics/c.math/cmath.pass.cpp: ``` # .---command stderr # | In file included from C:\b\s\w\ir\x\w\llvm-llvm-project\libcxx\test\std\num

[clang] [clang][Interp] Fix `ArrayInitLoopExpr` handling (PR #67886)

2023-10-23 Thread via cfe-commits
https://github.com/isuckatcs updated https://github.com/llvm/llvm-project/pull/67886 >From e623c9713dfaecd83aa8bcbd606b0a6e4c593c61 Mon Sep 17 00:00:00 2001 From: isuckatcs <65320245+isucka...@users.noreply.github.com> Date: Sat, 30 Sep 2023 17:05:02 +0200 Subject: [PATCH 1/2] implement fix in i

[clang] [clang][Interp] Fix `ArrayInitLoopExpr` handling (PR #67886)

2023-10-23 Thread via cfe-commits
https://github.com/isuckatcs updated https://github.com/llvm/llvm-project/pull/67886 >From e623c9713dfaecd83aa8bcbd606b0a6e4c593c61 Mon Sep 17 00:00:00 2001 From: isuckatcs <65320245+isucka...@users.noreply.github.com> Date: Sat, 30 Sep 2023 17:05:02 +0200 Subject: [PATCH 1/2] implement fix in i

[clang] [C++20] [Modules] [Driver] Don't enable -fdelayed-template-parsing by default on windows with C++20 modules (PR #69431)

2023-10-23 Thread Petr Hosek via cfe-commits
petrhosek wrote: This broke the following tests on Windows: ``` llvm-libc++-static-clangcl.cfg.in :: libcxx/atomics/diagnose_invalid_memory_order.verify.cpp llvm-libc++-static-clangcl.cfg.in :: libcxx/fuzzing/random.pass.cpp llvm-libc++-static-clangcl.cfg.in :: std/depr/depr.c.headers/math_h.pas

[clang] [MLIR] Add SyclRuntimeWrapper (PR #69648)

2023-10-23 Thread Nishant Patel via cfe-commits
nbpatel wrote: @grypp @joker-eph https://github.com/llvm/llvm-project/pull/69648 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][Interp] Fix `ArrayInitLoopExpr` handling (PR #67886)

2023-10-23 Thread via cfe-commits
isuckatcs wrote: This change conflicted with #68039 and ended up crahing, which needed to be addressed. Please take a look at again when you have time @tbaederr. https://github.com/llvm/llvm-project/pull/67886 ___ cfe-commits mailing list cfe-commits@

[clang-tools-extra] [MLIR] Add SyclRuntimeWrapper (PR #69648)

2023-10-23 Thread Nishant Patel via cfe-commits
nbpatel wrote: @grypp @joker-eph https://github.com/llvm/llvm-project/pull/69648 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Update stdckdint.h and make it available in pre-C23 modes. (PR #69649)

2023-10-23 Thread via cfe-commits
@@ -1,4 +1,5 @@ // NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --version 3 +// RUN: %clang_cc1 -triple=x86_64 -verify -ffreestanding -std=c2x %s ZijunZhaoCCK wrote: Nope, I just want to test c20 and c23. But yes I think

[clang-tools-extra] Update stdckdint.h and make it available in pre-C23 modes. (PR #69649)

2023-10-23 Thread via cfe-commits
https://github.com/ZijunZhaoCCK edited https://github.com/llvm/llvm-project/pull/69649 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Update stdckdint.h and make it available in pre-C23 modes. (PR #69649)

2023-10-23 Thread via cfe-commits
https://github.com/ZijunZhaoCCK edited https://github.com/llvm/llvm-project/pull/69649 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][Diagnostics] Provide source range to constexpr function diags (PR #69721)

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

[clang] [clang][Interp] Fix `ArrayInitLoopExpr` handling (PR #67886)

2023-10-23 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff 25da9bb7d44c91b0339382af6c91b6a346685212 d44be70de99dfbe00ea2dc366222a797ca92d9d5 --

[clang] SwiftCallingConv: Fix the splitVectorEntry function (PR #69953)

2023-10-23 Thread Arnold Schwaighofer via cfe-commits
https://github.com/aschwaighofer created https://github.com/llvm/llvm-project/pull/69953 When splitting an entry into multiple entries, the indices of the split entries are a combination of the original split entry's and the number of elements we split that entry to. Failure to do so resulted

[clang] SwiftCallingConv: Fix the splitVectorEntry function (PR #69953)

2023-10-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Arnold Schwaighofer (aschwaighofer) Changes When splitting an entry into multiple entries, the indices of the split entries are a combination of the original split entry's and the number of elements we split that entry to. Failure to do

[clang] [OpenMP][OMPIRBuilder] Add support to omp target parallel (PR #67000)

2023-10-23 Thread Johannes Doerfert via cfe-commits
@@ -1126,6 +1133,185 @@ void OpenMPIRBuilder::emitCancelationCheckImpl(Value *CancelFlag, Builder.SetInsertPoint(NonCancellationBlock, NonCancellationBlock->begin()); } +// Callback used to create OpenMP runtime calls to support +// omp parallel clause for the device. +// W

[clang] [OpenMP][OMPIRBuilder] Add support to omp target parallel (PR #67000)

2023-10-23 Thread Johannes Doerfert via cfe-commits
@@ -1126,6 +1133,185 @@ void OpenMPIRBuilder::emitCancelationCheckImpl(Value *CancelFlag, Builder.SetInsertPoint(NonCancellationBlock, NonCancellationBlock->begin()); } +// Callback used to create OpenMP runtime calls to support +// omp parallel clause for the device. +// W

[clang] [OpenMP][OMPIRBuilder] Add support to omp target parallel (PR #67000)

2023-10-23 Thread Johannes Doerfert via cfe-commits
@@ -1126,6 +1133,185 @@ void OpenMPIRBuilder::emitCancelationCheckImpl(Value *CancelFlag, Builder.SetInsertPoint(NonCancellationBlock, NonCancellationBlock->begin()); } +// Callback used to create OpenMP runtime calls to support +// omp parallel clause for the device. +// W

[clang] [OpenMP][OMPIRBuilder] Add support to omp target parallel (PR #67000)

2023-10-23 Thread Johannes Doerfert via cfe-commits
@@ -1126,6 +1133,185 @@ void OpenMPIRBuilder::emitCancelationCheckImpl(Value *CancelFlag, Builder.SetInsertPoint(NonCancellationBlock, NonCancellationBlock->begin()); } +// Callback used to create OpenMP runtime calls to support +// omp parallel clause for the device. +// W

[clang] [OpenMP][OMPIRBuilder] Add support to omp target parallel (PR #67000)

2023-10-23 Thread Johannes Doerfert via cfe-commits
@@ -1126,6 +1133,185 @@ void OpenMPIRBuilder::emitCancelationCheckImpl(Value *CancelFlag, Builder.SetInsertPoint(NonCancellationBlock, NonCancellationBlock->begin()); } +// Callback used to create OpenMP runtime calls to support +// omp parallel clause for the device. +// W

[clang] [OpenMP][OMPIRBuilder] Add support to omp target parallel (PR #67000)

2023-10-23 Thread Johannes Doerfert via cfe-commits
@@ -1126,6 +1133,185 @@ void OpenMPIRBuilder::emitCancelationCheckImpl(Value *CancelFlag, Builder.SetInsertPoint(NonCancellationBlock, NonCancellationBlock->begin()); } +// Callback used to create OpenMP runtime calls to support +// omp parallel clause for the device. +// W

[clang] [OpenMP][OMPIRBuilder] Add support to omp target parallel (PR #67000)

2023-10-23 Thread Johannes Doerfert via cfe-commits
@@ -1026,25 +1026,25 @@ for (int i = 0; i < argc; ++i) { // CHECK3-NEXT:call void @llvm.experimental.noalias.scope.decl(metadata [[META8:![0-9]+]]) // CHECK3-NEXT:call void @llvm.experimental.noalias.scope.decl(metadata [[META10:![0-9]+]]) // CHECK3-NEXT:call void

[clang] [OpenMP][OMPIRBuilder] Add support to omp target parallel (PR #67000)

2023-10-23 Thread Johannes Doerfert via cfe-commits
@@ -1126,6 +1133,185 @@ void OpenMPIRBuilder::emitCancelationCheckImpl(Value *CancelFlag, Builder.SetInsertPoint(NonCancellationBlock, NonCancellationBlock->begin()); } +// Callback used to create OpenMP runtime calls to support +// omp parallel clause for the device. +// W

[clang-tools-extra] [MLIR] Add SyclRuntimeWrapper (PR #69648)

2023-10-23 Thread Ivan Butygin via cfe-commits
@@ -0,0 +1,222 @@ +//===- SyclRuntimeWrappers.cpp - MLIR SYCL wrapper library ===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-

[clang] [clang][Interp] Fix `ArrayInitLoopExpr` handling (PR #67886)

2023-10-23 Thread via cfe-commits
https://github.com/isuckatcs updated https://github.com/llvm/llvm-project/pull/67886 >From e623c9713dfaecd83aa8bcbd606b0a6e4c593c61 Mon Sep 17 00:00:00 2001 From: isuckatcs <65320245+isucka...@users.noreply.github.com> Date: Sat, 30 Sep 2023 17:05:02 +0200 Subject: [PATCH 1/3] implement fix in i

[clang] Update stdckdint.h and make it available in pre-C23 modes. (PR #69649)

2023-10-23 Thread Aaron Ballman via cfe-commits
@@ -1,4 +1,5 @@ // NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --version 3 +// RUN: %clang_cc1 -triple=x86_64 -verify -ffreestanding -std=c2x %s AaronBallman wrote: Ah! There is no c20 release. There is C89/C90, C99, C11

[clang] 70982ef - [clang] Add clang::preferred_type attribute for bitfields (#69104)

2023-10-23 Thread via cfe-commits
Author: Vlad Serebrennikov Date: 2023-10-23T22:22:00+04:00 New Revision: 70982ef9d17ce57909ab202dc0850182b29c7da1 URL: https://github.com/llvm/llvm-project/commit/70982ef9d17ce57909ab202dc0850182b29c7da1 DIFF: https://github.com/llvm/llvm-project/commit/70982ef9d17ce57909ab202dc0850182b29c7da1.

[clang] [clang] Add clang::preferred_type attribute for bitfields (PR #69104)

2023-10-23 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll closed https://github.com/llvm/llvm-project/pull/69104 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Support vector swizzles on scalars (PR #67700)

2023-10-23 Thread Chris B via cfe-commits
@@ -930,7 +930,11 @@ NumericLiteralParser::NumericLiteralParser(StringRef TokSpelling, // and FP constants (specifically, the 'pp-number' regex), and assumes that // the byte at "*end" is both valid and not part of the regex. Because of // this, it doesn't have to check

[clang] [OpenMP][OMPIRBuilder] Add support to omp target parallel (PR #67000)

2023-10-23 Thread via cfe-commits
shraiysh wrote: > @shraiysh `ParallelSimpleGPU` tests only the LLVM IR for the target device. > `kmpc_parallel_51` is the function which needs to be executed on the GPU. The > aim of this patch is to add GPU code generation for `omp target parallel > pragma`. Okay, I misunderstood the testcas

[clang] [HLSL] Support vector swizzles on scalars (PR #67700)

2023-10-23 Thread Chris B via cfe-commits
@@ -0,0 +1,14 @@ +// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.6-library -x hlsl -finclude-default-header -verify %s + + +int2 ToTwoInts(int V) { + return V.xy; // expected-error{{vector component access exceeds type 'int __attribute__((ext_vector_type(1)))' (vector of 1 'i

[clang] [clang][Interp] Only diagnose null field access in constant contexts (PR #69223)

2023-10-23 Thread Aaron Ballman via cfe-commits
Timm =?utf-8?q?B=C3=A4der?= Message-ID: In-Reply-To: @@ -295,7 +295,7 @@ class Pointer { bool isUnion() const; /// Checks if the storage is extern. - bool isExtern() const { return Pointee->isExtern(); } + bool isExtern() const { return Pointee && Pointee->isExtern();

<    1   2   3   4   >