[clang] 14c323c - [OpenMP][AMDGPU] Do not attach -fcuda-is-device (#99002)

2024-07-18 Thread via cfe-commits
Author: Dominik Adamski Date: 2024-07-18T09:00:09+02:00 New Revision: 14c323cfd66454c65324c4d5b9d9b6a9c5651eca URL: https://github.com/llvm/llvm-project/commit/14c323cfd66454c65324c4d5b9d9b6a9c5651eca DIFF: https://github.com/llvm/llvm-project/commit/14c323cfd66454c65324c4d5b9d9b6a9c5651eca.dif

[clang] [OpenMP][AMDGPU] Do not attach -fcuda-is-device (PR #99002)

2024-07-18 Thread Dominik Adamski via cfe-commits
https://github.com/DominikAdamski closed https://github.com/llvm/llvm-project/pull/99002 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 7aabdb8 - [clang][Interp][NFC] Protect ByteCodeEmitter against unfinished fns

2024-07-18 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2024-07-18T09:05:48+02:00 New Revision: 7aabdb8776eb11b90d43162254db47df46806ec9 URL: https://github.com/llvm/llvm-project/commit/7aabdb8776eb11b90d43162254db47df46806ec9 DIFF: https://github.com/llvm/llvm-project/commit/7aabdb8776eb11b90d43162254db47df46806ec9.diff LO

[clang-tools-extra] Ensure functions are anchored in the global namespace (PR #99084)

2024-07-18 Thread Nathan James via cfe-commits
njames93 wrote: Just a drive by comment, would it not have been nicer to use the `hasAnyName` matcher which understands `::` at the start means global namespace. https://github.com/llvm/llvm-project/pull/99084 ___ cfe-commits mailing list cfe-commits@

[clang] [Sema] Preserve ContainsUnexpandedParameterPack in TransformLambdaExpr (PR #86265)

2024-07-18 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/86265 >From 6e7b38b3e3f781e11db2fa5d552fdfb6123609df Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Fri, 22 Mar 2024 17:34:08 +0800 Subject: [PATCH 01/10] [Sema] Preserve ContainsUnexpandedParameterPack in Transfor

[clang] [Clang] Fix Microsoft ABI inheritance model when member pointer is used in a base specifier (PR #91990)

2024-07-18 Thread Mital Ashok via cfe-commits
@@ -13,3 +15,18 @@ template struct S3 { int T::*foo; }; + +template struct Base {}; +struct +S5 // #S5 +: +Base +// expected-error@-1 {{member pointer has incomplete base type 'S5'}} MitalAshok wrote: It's an error for `-fcomplete-member-pointers` which is

[clang] [Clang SA]: add support for mismatched ownership_returns+ownership_takes calls for custom allocation classes (PR #98941)

2024-07-18 Thread Pavel Skripkin via cfe-commits
https://github.com/pskrgag updated https://github.com/llvm/llvm-project/pull/98941 >From 3d362cfb1e197713a51ce798996ff4308e7ab5aa Mon Sep 17 00:00:00 2001 From: Pavel Skripkin Date: Wed, 17 Jul 2024 16:41:20 +0300 Subject: [PATCH 1/7] clang/sema: disallow more than one 'onweship_takes' with di

[clang] [Sema] Preserve ContainsUnexpandedParameterPack in TransformLambdaExpr (PR #86265)

2024-07-18 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/86265 >From 6e7b38b3e3f781e11db2fa5d552fdfb6123609df Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Fri, 22 Mar 2024 17:34:08 +0800 Subject: [PATCH 01/11] [Sema] Preserve ContainsUnexpandedParameterPack in Transfor

[clang] [Clang] Fix Microsoft ABI inheritance model when member pointer is used in a base specifier (PR #91990)

2024-07-18 Thread Mital Ashok via cfe-commits
@@ -215,6 +215,14 @@ struct NewUnspecified; SingleTemplate tmpl_single; UnspecTemplate tmpl_unspec; +// Member pointers used in base specifiers force an unspecified inheritance model +struct MemPtrInBase : UnspecTemplate {}; MitalAshok wrote: It's not for si

[clang] [Clang SA]: add support for mismatched ownership_returns+ownership_takes calls for custom allocation classes (PR #98941)

2024-07-18 Thread Pavel Skripkin via cfe-commits
pskrgag wrote: Thank you for review! I've applied your suggestions and fixed test failures. Messed up a bit with shadowing in constructor. > Usually, GitHub PRs prefer "merges" over "force-pushes". Whenever you > force-push, all the inline remarks could get lost, as it fails to track the >

[clang] [Sema] Preserve ContainsUnexpandedParameterPack in TransformLambdaExpr (PR #86265)

2024-07-18 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/86265 >From 6e7b38b3e3f781e11db2fa5d552fdfb6123609df Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Fri, 22 Mar 2024 17:34:08 +0800 Subject: [PATCH 01/12] [Sema] Preserve ContainsUnexpandedParameterPack in Transfor

[clang] [Sema] Preserve ContainsUnexpandedParameterPack in TransformLambdaExpr (PR #86265)

2024-07-18 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 edited https://github.com/llvm/llvm-project/pull/86265 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Add deprecation warning for `-Ofast` driver option (PR #98736)

2024-07-18 Thread Vlad Serebrennikov via cfe-commits
@@ -931,7 +931,9 @@ def O : Joined<["-"], "O">, Group, def O_flag : Flag<["-"], "O">, Visibility<[ClangOption, CC1Option, FC1Option]>, Alias, AliasArgs<["1"]>; def Ofast : Joined<["-"], "Ofast">, Group, - Visibility<[ClangOption, CC1Option, FlangOption]>; + Visibility<[Clan

[clang] [clang] Add deprecation warning for `-Ofast` driver option (PR #98736)

2024-07-18 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: This PR has passed CI before latest wording suggestion by Shafik, so I'll go ahead and merge this. https://github.com/llvm/llvm-project/pull/98736 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/ma

[clang] 2ef7cbf - [clang] Add deprecation warning for `-Ofast` driver option (#98736)

2024-07-18 Thread via cfe-commits
Author: Vlad Serebrennikov Date: 2024-07-18T11:49:53+04:00 New Revision: 2ef7cbf71c98246d6f3a9c63dea75b76c7b5e928 URL: https://github.com/llvm/llvm-project/commit/2ef7cbf71c98246d6f3a9c63dea75b76c7b5e928 DIFF: https://github.com/llvm/llvm-project/commit/2ef7cbf71c98246d6f3a9c63dea75b76c7b5e928.

[clang] [clang] Add deprecation warning for `-Ofast` driver option (PR #98736)

2024-07-18 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll closed https://github.com/llvm/llvm-project/pull/98736 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Add source file name for template instantiations in -ftime-trace (PR #98320)

2024-07-18 Thread Ilya Biryukov via cfe-commits
@@ -60,39 +74,65 @@ bool compileFromString(StringRef Code, StringRef Standard, StringRef FileName) { return Compiler.ExecuteAction(Action); } +std::string GetMetadata(json::Object *Event) { + std::string Metadata = ""; + if (json::Object *Args = Event->getObject("args"))

[clang] [libc] [libcxx] [libc][libcxx] Support for building libc++ against LLVM libc (PR #99287)

2024-07-18 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek updated https://github.com/llvm/llvm-project/pull/99287 >From 7d7a7882b713e056f9194b2dd7d792fb9bb86bb5 Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Wed, 17 Jul 2024 00:32:39 -0700 Subject: [PATCH 1/2] [libc][libcxx] Support for building libc++ against LLVM libc

[clang] [Sema] Fix assertion error in Sema::FindInstantiatedDecl (PR #96509)

2024-07-18 Thread Alejandro Álvarez Ayllón via cfe-commits
https://github.com/alejandro-alvarez-sonarsource updated https://github.com/llvm/llvm-project/pull/96509 From 96b0c2c18c197a1ce03d31b01c14d1b18348e9ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alejandro=20=C3=81lvarez=20Ayll=C3=B3n?= Date: Thu, 1 Jun 2023 16:30:54 +0200 Subject: [PATCH 1/6] [Se

[clang] [clang] Fix crash in concept deprecation (PR #98622)

2024-07-18 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. I think this makes sense but please give @mizvekov the day to review before landing Thank you both for working on this https://github.com/llvm/llvm-project/pull/98622 ___ cfe-commits mailing li

[clang] [clang] Fix crash in concept deprecation (PR #98622)

2024-07-18 Thread via cfe-commits
https://github.com/cor3ntin edited https://github.com/llvm/llvm-project/pull/98622 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix crash in concept deprecation (PR #98622)

2024-07-18 Thread via cfe-commits
@@ -36,4 +36,11 @@ template // expected-warning@-1 {{'C' is deprecated}} // expected-note@#C {{'C' has been explicitly marked deprecated here}} void f(); + +template +auto b() = delete; // #b + +decltype(b<0>()) x; +// expected-error@-1 {{call to deleted function 'b'}} +//

[clang] [clang] Fix crash in concept deprecation (PR #98622)

2024-07-18 Thread via cfe-commits
@@ -7416,10 +7416,11 @@ NamedDecl *Sema::ActOnVariableDeclarator( tryToFixVariablyModifiedVarType(TInfo, R, D.getIdentifierLoc(), /*DiagID=*/0); - if (const AutoType *AutoT = R->getAs()) -CheckConstrainedAuto( -AutoT, -

[clang] [clang] Extend lifetime analysis to support assignments for pointer-like objects. (PR #99032)

2024-07-18 Thread Haojian Wu via cfe-commits
@@ -34,6 +34,6 @@ struct basic_string { }; } // namespace std void test(const char* a) { - // verify we're emitting the `-Wdangling-assignment` warning. + // verify we're emitting the `-Wdangling-assignment-gsl` warning. a = std::basic_string().c_str(); // expected-warnin

[clang] 3eba28d - [clang] Extend lifetime analysis to support assignments for pointer-like objects. (#99032)

2024-07-18 Thread via cfe-commits
Author: Haojian Wu Date: 2024-07-18T10:02:35+02:00 New Revision: 3eba28d1fd3347a1658f68b63285148b0bb25fab URL: https://github.com/llvm/llvm-project/commit/3eba28d1fd3347a1658f68b63285148b0bb25fab DIFF: https://github.com/llvm/llvm-project/commit/3eba28d1fd3347a1658f68b63285148b0bb25fab.diff LO

[clang] [clang] Extend lifetime analysis to support assignments for pointer-like objects. (PR #99032)

2024-07-18 Thread Haojian Wu via cfe-commits
https://github.com/hokein closed https://github.com/llvm/llvm-project/pull/99032 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Add source file name for template instantiations in -ftime-trace (PR #98320)

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

[clang] [llvm] Add source file name for template instantiations in -ftime-trace (PR #98320)

2024-07-18 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov commented: A few more suggestions, and happy to approve as soon as the question about source events gets resolved. https://github.com/llvm/llvm-project/pull/98320 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [llvm] Add source file name for template instantiations in -ftime-trace (PR #98320)

2024-07-18 Thread Ilya Biryukov via cfe-commits
@@ -3426,11 +3426,16 @@ Sema::InstantiateClass(SourceLocation PointOfInstantiation, return true; llvm::TimeTraceScope TimeScope("InstantiateClass", [&]() { -std::string Name; -llvm::raw_string_ostream OS(Name); +llvm::TimeTraceMetadata M; +llvm::raw_stri

[clang] [llvm] Add source file name for template instantiations in -ftime-trace (PR #98320)

2024-07-18 Thread Ilya Biryukov via cfe-commits
@@ -38,14 +42,24 @@ std::string teardownProfiler() { // Returns true if code compiles successfully. // We only parse AST here. This is enough for constexpr evaluation. -bool compileFromString(StringRef Code, StringRef Standard, StringRef FileName) { +bool compileFromString(St

[clang] [llvm] Add source file name for template instantiations in -ftime-trace (PR #98320)

2024-07-18 Thread Ilya Biryukov via cfe-commits
@@ -3426,11 +3426,16 @@ Sema::InstantiateClass(SourceLocation PointOfInstantiation, return true; llvm::TimeTraceScope TimeScope("InstantiateClass", [&]() { -std::string Name; -llvm::raw_string_ostream OS(Name); +llvm::TimeTraceMetadata M; +llvm::raw_stri

[clang] [llvm] Add source file name for template instantiations in -ftime-trace (PR #98320)

2024-07-18 Thread Utkarsh Saxena via cfe-commits
@@ -60,39 +74,65 @@ bool compileFromString(StringRef Code, StringRef Standard, StringRef FileName) { return Compiler.ExecuteAction(Action); } +std::string GetMetadata(json::Object *Event) { + std::string Metadata = ""; + if (json::Object *Args = Event->getObject("args"))

[clang] [libc] [libcxx] [libc][libcxx] Support for building libc++ against LLVM libc (PR #99287)

2024-07-18 Thread Petr Hosek via cfe-commits
@@ -293,6 +293,7 @@ option(LIBCXX_ENABLE_THREADS "Build libc++ with support for threads." ON) option(LIBCXX_ENABLE_MONOTONIC_CLOCK "Build libc++ with support for a monotonic clock. This option may only be set to OFF when LIBCXX_ENABLE_THREADS=OFF." ON) +option(LIBCXX_USE_

[clang] [llvm] Add source file name for template instantiations in -ftime-trace (PR #98320)

2024-07-18 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 updated https://github.com/llvm/llvm-project/pull/98320 >From 03cc5fbebaf0c0c737e9304b8b3310ab4908fcaa Mon Sep 17 00:00:00 2001 From: Utkarsh Saxena Date: Wed, 10 Jul 2024 13:52:46 + Subject: [PATCH 01/12] Add an option to add source file info to -ftime-trace --- c

[clang] [clang] Fix crash in concept deprecation (PR #98622)

2024-07-18 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll updated https://github.com/llvm/llvm-project/pull/98622 >From 5310764fb4044bcd4229434e80b64870c4b4ee8c Mon Sep 17 00:00:00 2001 From: Vlad Serebrennikov Date: Fri, 12 Jul 2024 15:12:37 +0300 Subject: [PATCH 1/4] [clang] Fix crash in concept deprecation Apparently we

[clang] [llvm] Add source file name for template instantiations in -ftime-trace (PR #98320)

2024-07-18 Thread Utkarsh Saxena via cfe-commits
@@ -38,14 +42,24 @@ std::string teardownProfiler() { // Returns true if code compiles successfully. // We only parse AST here. This is enough for constexpr evaluation. -bool compileFromString(StringRef Code, StringRef Standard, StringRef FileName) { +bool compileFromString(St

[clang] [clang] Fix crash in concept deprecation (PR #98622)

2024-07-18 Thread Vlad Serebrennikov via cfe-commits
@@ -36,4 +36,11 @@ template // expected-warning@-1 {{'C' is deprecated}} // expected-note@#C {{'C' has been explicitly marked deprecated here}} void f(); + +template +auto b() = delete; // #b + +decltype(b<0>()) x; +// expected-error@-1 {{call to deleted function 'b'}} +//

[clang] [Clang] make SVE types known to device targets too (PR #99446)

2024-07-18 Thread Emanuele Rocca via cfe-commits
https://github.com/ema created https://github.com/llvm/llvm-project/pull/99446 For the purpose of preprocessing and declarations in header files, ensure clang accepts SVE types for both device and host targets. >From 2f7b2bbd9d2db29534dc354cfa9ada5c29c26b3f Mon Sep 17 00:00:00 2001 From: Emanue

[clang] [Clang] make SVE types known to device targets too (PR #99446)

2024-07-18 Thread via cfe-commits
github-actions[bot] wrote: Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be notified. If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you, it

[clang] [Clang] make SVE types known to device targets too (PR #99446)

2024-07-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Emanuele Rocca (ema) Changes For the purpose of preprocessing and declarations in header files, ensure clang accepts SVE types for both device and host targets. --- Full diff: https://github.com/llvm/llvm-project/pull/99446.diff 2 Files

[clang] [llvm] Add source file name for template instantiations in -ftime-trace (PR #98320)

2024-07-18 Thread Utkarsh Saxena via cfe-commits
@@ -3426,11 +3426,16 @@ Sema::InstantiateClass(SourceLocation PointOfInstantiation, return true; llvm::TimeTraceScope TimeScope("InstantiateClass", [&]() { -std::string Name; -llvm::raw_string_ostream OS(Name); +llvm::TimeTraceMetadata M; +llvm::raw_stri

[clang] [Clang][AMDGPU] Add builtins for instrinsic `llvm.amdgcn.raw.ptr.buffer.load` (PR #99258)

2024-07-18 Thread Matt Arsenault via cfe-commits
@@ -155,6 +155,12 @@ BUILTIN(__builtin_amdgcn_raw_buffer_store_b32, "viQbiiIi", "n") BUILTIN(__builtin_amdgcn_raw_buffer_store_b64, "vV2iQbiiIi", "n") BUILTIN(__builtin_amdgcn_raw_buffer_store_b96, "vV3iQbiiIi", "n") BUILTIN(__builtin_amdgcn_raw_buffer_store_b128, "vV4iQbiiIi"

[clang] [llvm] [PAC][Driver] Support `pauthtest` ABI for AArch64 Linux triples (PR #97237)

2024-07-18 Thread Daniil Kovalev via cfe-commits
https://github.com/kovdan01 updated https://github.com/llvm/llvm-project/pull/97237 >From 3b4b1b1739b810d758e68f30c48b648963cff740 Mon Sep 17 00:00:00 2001 From: Daniil Kovalev Date: Mon, 1 Jul 2024 00:50:21 +0300 Subject: [PATCH 1/8] [PAC][Driver] Implement `-mbranch-protection=pauthabi` opti

[clang] [Clang][AMDGPU] Add builtins for instrinsic `llvm.amdgcn.raw.ptr.buffer.load` (PR #99258)

2024-07-18 Thread Matt Arsenault via cfe-commits
@@ -155,6 +155,12 @@ BUILTIN(__builtin_amdgcn_raw_buffer_store_b32, "viQbiiIi", "n") BUILTIN(__builtin_amdgcn_raw_buffer_store_b64, "vV2iQbiiIi", "n") BUILTIN(__builtin_amdgcn_raw_buffer_store_b96, "vV3iQbiiIi", "n") BUILTIN(__builtin_amdgcn_raw_buffer_store_b128, "vV4iQbiiIi"

[clang] [llvm] [PAC][Driver] Support `pauthtest` ABI for AArch64 Linux triples (PR #97237)

2024-07-18 Thread Daniil Kovalev via cfe-commits
@@ -1546,16 +1581,28 @@ static void CollectARMPACBTIOptions(const ToolChain &TC, const ArgList &Args, CmdArgs.push_back( Args.MakeArgString(Twine("-msign-return-address=") + Scope)); - if (Scope != "none") + if (Scope != "none") { +if (Triple.getEnvironment() ==

[clang] [Clang][AMDGPU] Add builtins for instrinsic `llvm.amdgcn.raw.ptr.buffer.load` (PR #99258)

2024-07-18 Thread Matt Arsenault via cfe-commits
@@ -19177,6 +19177,42 @@ Value *CodeGenFunction::EmitAMDGPUBuiltinExpr(unsigned BuiltinID, case AMDGPU::BI__builtin_amdgcn_raw_buffer_store_b128: return emitBuiltinWithOneOverloadedType<5>( *this, E, Intrinsic::amdgcn_raw_ptr_buffer_store); + case AMDGPU::BI__bu

[clang] [clang] Emit bad shift warnings (PR #70307)

2024-07-18 Thread Alexander Kornienko via cfe-commits
alexfh wrote: Just to confirm: is this the intentional outcome of this patch? https://gcc.godbolt.org/z/Kf9YK1qM3 ``` enum { a = 1<<12, b = (-1)<<13 }; ``` ``` :3:9: error: expression is not an integral constant expression 3 | b = (-1)<<13 | ^~~~ :3:13: note: le

[clang] [Clang] Implement P3034R1 Module Declarations Shouldn’t be Macros (PR #90574)

2024-07-18 Thread via cfe-commits
https://github.com/cor3ntin commented: I think once you address the few remaining comments from @ChuanqiXu9, this can be landed. The general. I am glad we were able to get rid of some of the convoluted state machines https://github.com/llvm/llvm-project/pull/90574

[clang] [Clang] Implement P3034R1 Module Declarations Shouldn’t be Macros (PR #90574)

2024-07-18 Thread via cfe-commits
@@ -1121,6 +1153,149 @@ void Preprocessor::CollectPpImportSuffix(SmallVectorImpl &Toks) { } } +std::string ModuleNameInfo::getFlatName() const { + std::string FlatModuleName; + for (auto &Tok : getTokens()) { +switch (Tok.getKind()) { +case tok::identifier: +

[clang] [Clang] Implement P3034R1 Module Declarations Shouldn’t be Macros (PR #90574)

2024-07-18 Thread via cfe-commits
https://github.com/cor3ntin edited https://github.com/llvm/llvm-project/pull/90574 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Implement P3034R1 Module Declarations Shouldn’t be Macros (PR #90574)

2024-07-18 Thread via cfe-commits
@@ -3071,6 +3073,45 @@ struct EmbedAnnotationData { /// Registry of pragma handlers added by plugins using PragmaHandlerRegistry = llvm::Registry; +/// Module/Partition name token sequance. +/// +/// module-name: +/// module-name-qualifier[opt] identifier +/// +/

[clang] [Clang] Implement P3034R1 Module Declarations Shouldn’t be Macros (PR #90574)

2024-07-18 Thread via cfe-commits
@@ -1002,6 +1002,7 @@ PRAGMA_ANNOTATION(pragma_riscv) ANNOTATION(module_include) ANNOTATION(module_begin) ANNOTATION(module_end) +ANNOTATION(module_name) cor3ntin wrote: ```suggestion // Annotations for c++ named modules ANNOTATION(module_name) ``` https://g

[clang-tools-extra] 1ce8989 - [clang-tidy] Fix false in unnecessary-value-param inside templates (#98488)

2024-07-18 Thread via cfe-commits
Author: Dmitry Polukhin Date: 2024-07-18T09:55:36+01:00 New Revision: 1ce89899ad33a0d2976859d8d278dba4342cbb6b URL: https://github.com/llvm/llvm-project/commit/1ce89899ad33a0d2976859d8d278dba4342cbb6b DIFF: https://github.com/llvm/llvm-project/commit/1ce89899ad33a0d2976859d8d278dba4342cbb6b.dif

[clang] [clang-tools-extra] [clang-tidy] Fix false in unnecessary-value-param inside templates (PR #98488)

2024-07-18 Thread Dmitry Polukhin via cfe-commits
https://github.com/dmpolukhin closed https://github.com/llvm/llvm-project/pull/98488 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libclc] libclc: increase fp16 support (PR #98149)

2024-07-18 Thread Fraser Cormack via cfe-commits
frasercrmck wrote: > Also, just leave that thought here: A next step might be to use `native` > functions instead (when available). They should provide enough precision for > half, but be more performance. Also as the accuracy is undefined for those > functions, maybe it should be an opt-in op

[libclc] libclc: increase fp16 support (PR #98149)

2024-07-18 Thread Fraser Cormack via cfe-commits
frasercrmck wrote: @rjodinchr I was about to merge and noticed your email is hidden. I just wanted to check with you whether you want to make it public, as per the discussion https://discourse.llvm.org/t/hidden-emails-on-github-should-we-do-something-about-it/74223/67. AFAICT there's still no

[clang] [Parser][ObjC] Add -Wobjc-prefix-length warning option. (PR #97597)

2024-07-18 Thread Alastair Houghton via cfe-commits
https://github.com/al45tair updated https://github.com/llvm/llvm-project/pull/97597 >From c11624370bf5615c7902993052435b92ae50b41b Mon Sep 17 00:00:00 2001 From: Alastair Houghton Date: Wed, 3 Jul 2024 17:00:51 +0100 Subject: [PATCH 1/8] [Parser][ObjC] Add -Wobjc-prefix-length warning option.

[clang] [llvm] Support for assume directive : Parse & AST modules (PR #97535)

2024-07-18 Thread via cfe-commits
https://github.com/SunilKuravinakop updated https://github.com/llvm/llvm-project/pull/97535 >From a331d2343a43a9ca2030ef07a25ca93ff26a5778 Mon Sep 17 00:00:00 2001 From: Sunil Kuravinakop Date: Mon, 1 Jul 2024 03:29:45 -0500 Subject: [PATCH 1/8] Support for "#pragma omp assume" Directive in Par

[clang] [llvm] Remove 3dnow from X86TargetParser. (PR #99352)

2024-07-18 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon approved this pull request. LGTM - cheers https://github.com/llvm/llvm-project/pull/99352 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix static analyzer concerns in #embed code (PR #99331)

2024-07-18 Thread Mariya Podchishchaeva via cfe-commits
@@ -1,4 +1,5 @@ -// RUN: %clang_cc1 -std=c23 %s -E -verify +// RUN: %clang_cc1 -std=c23 %s -E -verify --embed-dir=%S --embed-dir=%S/Inputs +#embed Fznamznon wrote: Makes sense. https://github.com/llvm/llvm-project/pull/99331 __

[clang] [llvm] [RISCV][FMV] Support target_version (PR #99040)

2024-07-18 Thread Piyou Chen via cfe-commits
@@ -0,0 +1,8 @@ +// RUN: not %clang_cc1 -triple riscv64 -target-feature +i -emit-llvm -o - %s 2>&1 | FileCheck %s --check-prefix=CHECK-UNSUPPORT-OS + +// CHECK-UNSUPPORT-OS: error: target_clones is currently only supported on Linux BeMg wrote: Added. https://g

[libclc] libclc: increase fp16 support (PR #98149)

2024-07-18 Thread Romaric Jodin via cfe-commits
rjodinchr wrote: > @rjodinchr I was about to merge and noticed your email is hidden. I just > wanted to check with you whether you want to make it public, as per the > discussion > https://discourse.llvm.org/t/hidden-emails-on-github-should-we-do-something-about-it/74223/67. > AFAICT there's

[libclc] 6838c7a - [libclc] Revise IDE folder structure (#89746)

2024-07-18 Thread via cfe-commits
Author: Michael Kruse Date: 2024-07-18T12:40:55+02:00 New Revision: 6838c7afb2d2fa5eb642a4b5922ae55d97f7b344 URL: https://github.com/llvm/llvm-project/commit/6838c7afb2d2fa5eb642a4b5922ae55d97f7b344 DIFF: https://github.com/llvm/llvm-project/commit/6838c7afb2d2fa5eb642a4b5922ae55d97f7b344.diff

[libclc] [llvm] [libclc] Revise IDE folder structure (PR #89746)

2024-07-18 Thread Michael Kruse via cfe-commits
https://github.com/Meinersbur closed https://github.com/llvm/llvm-project/pull/89746 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Improve stack usage to increase recursive initialization depth (PR #88546)

2024-07-18 Thread via cfe-commits
cor3ntin wrote: @AaronBallman ping https://github.com/llvm/llvm-project/pull/88546 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] make SVE types known to device targets too (PR #99446)

2024-07-18 Thread Emanuele Rocca via cfe-commits
https://github.com/ema updated https://github.com/llvm/llvm-project/pull/99446 >From 3c11c7fb055c114084577fb51fb87f928a0cc31c Mon Sep 17 00:00:00 2001 From: Emanuele Rocca Date: Wed, 17 Jul 2024 16:03:27 +0200 Subject: [PATCH] [Clang] make SVE types known to device targets too For the purpose o

[libclc] libclc: increase fp16 support (PR #98149)

2024-07-18 Thread Fraser Cormack via cfe-commits
https://github.com/frasercrmck closed https://github.com/llvm/llvm-project/pull/98149 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libclc] 7e6a739 - libclc: increase fp16 support (#98149)

2024-07-18 Thread via cfe-commits
Author: Romaric Jodin Date: 2024-07-18T12:00:41+01:00 New Revision: 7e6a73959ae97b1f9476a90290a492ba90cb950d URL: https://github.com/llvm/llvm-project/commit/7e6a73959ae97b1f9476a90290a492ba90cb950d DIFF: https://github.com/llvm/llvm-project/commit/7e6a73959ae97b1f9476a90290a492ba90cb950d.diff

[clang] [clang] Fix static analyzer concerns in #embed code (PR #99331)

2024-07-18 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/99331 >From 178c66c9c4c68485931cf2d60063dd97f7858309 Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Wed, 17 Jul 2024 07:39:02 -0700 Subject: [PATCH 1/2] [clang] Fix static analyzer concerns in #embed c

[clang] [SystemZ][z/OS] Implement z/OS XPLINK ABI (PR #91384)

2024-07-18 Thread Ulrich Weigand via cfe-commits
https://github.com/uweigand edited https://github.com/llvm/llvm-project/pull/91384 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [SystemZ][z/OS] Implement z/OS XPLINK ABI (PR #91384)

2024-07-18 Thread Ulrich Weigand via cfe-commits
@@ -529,9 +530,355 @@ bool SystemZTargetCodeGenInfo::isVectorTypeBased(const Type *Ty, return false; } +//===--===// +// z/OS XPLINK ABI Implementation +//===

[clang] [SystemZ][z/OS] Implement z/OS XPLINK ABI (PR #91384)

2024-07-18 Thread Ulrich Weigand via cfe-commits
https://github.com/uweigand commented: This version LGTM now, I think once the transparent-union thing is resolved, this should be ready to commit. Thanks! https://github.com/llvm/llvm-project/pull/91384 ___ cfe-commits mailing list cfe-commits@lists

[clang] [clang] Diagnose use of deprecated template alias (PR #97619)

2024-07-18 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman edited https://github.com/llvm/llvm-project/pull/97619 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Diagnose use of deprecated template alias (PR #97619)

2024-07-18 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman commented: Thank you for this, the changes should also come with a release note in clang/docs/ReleaseNotes.rst so users know about the improvement. Changes generally LG, but I did have some test suggestions. https://github.com/llvm/llvm-project/pull/97619 __

[clang] [clang] Diagnose use of deprecated template alias (PR #97619)

2024-07-18 Thread Aaron Ballman via cfe-commits
@@ -0,0 +1,72 @@ +// RUN: %clang_cc1 -std=c++11 -fsyntax-only -verify %s +// +// This test checks that a deprecated attribute on an alias +// template triggers a warning diagnostic when it is used. + +template +struct NoAttr { + void foo() {} +}; + +// expected-note@+2 5{{'Using

[clang] [clang] Fix static analyzer concerns in #embed code (PR #99331)

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

[clang] [Sema] Preserve ContainsUnexpandedParameterPack in TransformLambdaExpr (PR #86265)

2024-07-18 Thread Younan Zhang via cfe-commits
@@ -14636,6 +14645,20 @@ TreeTransform::TransformLambdaExpr(LambdaExpr *E) { /*IsInstantiation*/ true); SavedContext.pop(); + // Parts other than the capture e.g. the lambda body might still contain a + // pattern that an outer fold exp

[clang] [Sema] Preserve ContainsUnexpandedParameterPack in TransformLambdaExpr (PR #86265)

2024-07-18 Thread Younan Zhang via cfe-commits
@@ -23,3 +23,104 @@ namespace PR41576 { } static_assert(f(3, 4) == 6); // expected-note {{instantiation}} } + +namespace PR85667 { + +template +struct identity { + using type = T; +}; + +template void f() { + + static_assert([](Is... x) { +return ([I(x)] { + re

[clang] [Parser][ObjC] Add -Wobjc-prefix-length warning option. (PR #97597)

2024-07-18 Thread Alastair Houghton via cfe-commits
https://github.com/al45tair updated https://github.com/llvm/llvm-project/pull/97597 >From 6dfbc7b61b137fdfd9d39b23bce62e451dca3e1c Mon Sep 17 00:00:00 2001 From: Alastair Houghton Date: Wed, 3 Jul 2024 17:00:51 +0100 Subject: [PATCH] [Sema][ObjC] Add warning options to detect bad name prefixes.

[clang] [Parser][ObjC] Add -Wobjc-prefix-length warning option. (PR #97597)

2024-07-18 Thread Alastair Houghton via cfe-commits
https://github.com/al45tair edited https://github.com/llvm/llvm-project/pull/97597 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema][ObjC] Add warning options to detect bad name prefixes. (PR #97597)

2024-07-18 Thread Alastair Houghton via cfe-commits
https://github.com/al45tair edited https://github.com/llvm/llvm-project/pull/97597 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Preserve ContainsUnexpandedParameterPack in TransformLambdaExpr (PR #86265)

2024-07-18 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: > I was waiting for the CI, but it seems Linux CI would take hours. However > that shouldn't block the review I think, because Windows CI is green now. FWIW Linux CI is recovering as we speak. I expect full recovery over the weekend. https://github.com/llvm/llvm-project/pull/86

[clang-tools-extra] [clang-tidy][NFC] Fix gsl::not_null template parameter (PR #99472)

2024-07-18 Thread Rafael Stahl via cfe-commits
https://github.com/rafzi created https://github.com/llvm/llvm-project/pull/99472 `T` is expected to be a pointer type. https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rf-nullptr >From 48e452b9032d26889dfceb7668159275015a5290 Mon Sep 17 00:00:00 2001 From: Rafael Stahl Date: Thu, 1

[clang-tools-extra] [clang-tidy][NFC] Fix gsl::not_null template parameter (PR #99472)

2024-07-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tidy Author: Rafael Stahl (rafzi) Changes `T` is expected to be a pointer type. https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rf-nullptr --- Full diff: https://github.com/llvm/llvm-project/pull/99472.diff 2 Files Affected: - (mo

[clang-tools-extra] [clang-tidy][NFC] Fix gsl::not_null template parameter (PR #99472)

2024-07-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tools-extra Author: Rafael Stahl (rafzi) Changes `T` is expected to be a pointer type. https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rf-nullptr --- Full diff: https://github.com/llvm/llvm-project/pull/99472.diff 2 Files Affected:

[clang-tools-extra] [clangd] [C++20] [Modules] Introduce initial support for C++20 Modules (PR #66462)

2024-07-18 Thread Nico Weber via cfe-commits
@@ -161,6 +163,7 @@ clang_target_link_libraries(clangDaemon clangAST clangASTMatchers clangBasic + clangDependencyScanning nico wrote: This dependency makes clangd depend (transitively) on clangCodeGen, which it didn't depend on previously. This makes

[clang] [Clang] Add __common_type builtin (PR #99473)

2024-07-18 Thread Nikolas Klauser via cfe-commits
https://github.com/philnik777 created https://github.com/llvm/llvm-project/pull/99473 This implements the logic of the `common_type` base template as a builtin alias. If there should be no `type` member, an empty class is returned. Otherwise a specialization of a `type_identity`-like class is

[clang-tools-extra] [clangd] [C++20] [Modules] Introduce initial support for C++20 Modules (PR #66462)

2024-07-18 Thread Nico Weber via cfe-commits
https://github.com/nico edited https://github.com/llvm/llvm-project/pull/66462 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] [C++20] [Modules] Introduce initial support for C++20 Modules (PR #66462)

2024-07-18 Thread Nico Weber via cfe-commits
https://github.com/nico edited https://github.com/llvm/llvm-project/pull/66462 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libcxx] [Clang] Add __common_type builtin (PR #99473)

2024-07-18 Thread Nikolas Klauser via cfe-commits
https://github.com/philnik777 updated https://github.com/llvm/llvm-project/pull/99473 >From f9b9431a97952909190c69e1dee188ef234addb2 Mon Sep 17 00:00:00 2001 From: Nikolas Klauser Date: Tue, 16 Jul 2024 14:48:10 +0200 Subject: [PATCH] [Clang] Add __common_type builtin --- clang/include/clang/

[clang] [libcxx] [Clang] Add __common_type builtin (PR #99473)

2024-07-18 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 7e2b5e233a49f1c99cf9a3696ca4322ff989a386 f9b9431a97952909190c69e1dee188ef234addb2 --e

[clang] [clang] Emit bad shift warnings (PR #70307)

2024-07-18 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > Just to confirm: is this the intentional outcome of this patch? Before C++20, left shift of -1 does not produce a mathematical result that's within the range of representable values for the result type, so it's undefined behavior, and therefore not a core constant express

[clang] Improve stack usage to increase recursive initialization depth (PR #88546)

2024-07-18 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > @AaronBallman ping I've not been able to get back on to this, unfortunately. I'm not certain when I'll have time, either. https://github.com/llvm/llvm-project/pull/88546 ___ cfe-commits mailing list cfe-commits@lists.llvm.org ht

[clang] [clang] pointer to member with qualified-id enclosed in parentheses in unevaluated context should be invalid (PR #89713)

2024-07-18 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > I can try to look at that this week. Either way be ill-formed is much better > than being incorrect Thank you @cor3ntin! If it looks like you won't have a solution by Monday sometime, let's revert the changes so they don't end up on the release branch. We can cherry-pick

[clang-tools-extra] [clang-tidy][cppcoreguidelines-missing-std-forward] Do not warn when the parameter is used in a `static_cast`. (PR #99477)

2024-07-18 Thread Clement Courbet via cfe-commits
https://github.com/legrosbuffle created https://github.com/llvm/llvm-project/pull/99477 This provides a way to inform the check that we're intending to use an the forwarding reference as a specific reference category Fixes #99474. >From b423b26cba90288912b3377c39ab4207c9fc95dc Mon Sep 17 00:0

[clang-tools-extra] [clang-tidy][cppcoreguidelines-missing-std-forward] Do not warn when the parameter is used in a `static_cast`. (PR #99477)

2024-07-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tools-extra Author: Clement Courbet (legrosbuffle) Changes This provides a way to inform the check that we're intending to use an the forwarding reference as a specific reference category Fixes #99474. --- Full diff: https://github.com/llvm/llvm

[clang-tools-extra] [clang-tidy][cppcoreguidelines-missing-std-forward] Do not warn when the parameter is used in a `static_cast`. (PR #99477)

2024-07-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tidy Author: Clement Courbet (legrosbuffle) Changes This provides a way to inform the check that we're intending to use an the forwarding reference as a specific reference category Fixes #99474. --- Full diff: https://github.com/llvm/llvm-projec

[clang] Handle constant "pointers" for `__atomic_always_lock_free`/`__atomic_is_lock_free`. (PR #99340)

2024-07-18 Thread Aaron Ballman via cfe-commits
@@ -124,6 +124,24 @@ _Static_assert(__atomic_always_lock_free(4, &i64), ""); _Static_assert(!__atomic_always_lock_free(8, &i32), ""); _Static_assert(__atomic_always_lock_free(8, &i64), ""); +// Validate use with fake pointers constants. This mechanism is used to allow +// vali

[clang-tools-extra] [clangd] [C++20] [Modules] Introduce initial support for C++20 Modules (PR #66462)

2024-07-18 Thread Chuanqi Xu via cfe-commits
@@ -161,6 +163,7 @@ clang_target_link_libraries(clangDaemon clangAST clangASTMatchers clangBasic + clangDependencyScanning ChuanqiXu9 wrote: It looks like it comes from https://github.com/llvm/llvm-project/blob/b634e057ddecc41dce046887d0f0854fed305374/

[clang] [llvm] [clang][ARM64EC] Add support for hybrid_patchable attribute. (PR #99478)

2024-07-18 Thread Jacek Caban via cfe-commits
https://github.com/cjacek created https://github.com/llvm/llvm-project/pull/99478 This adds support for `hybrid_patchable` on top of LLVM part from #92965 (so it depends on #92965 and this PR is meant only for the second commit). For the most part, it just adds LLVM attribute whenever C/C++ at

  1   2   3   4   5   >