[clang-tools-extra] [llvm] [clang] [clang] Accept recursive non-dependent calls to functions with deduced return type (PR #75456)

2024-01-03 Thread Richard Smith via cfe-commits
https://github.com/zygoloid approved this pull request. Looks good, thanks! https://github.com/llvm/llvm-project/pull/75456 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] [clang] [clang] Accept recursive non-dependent calls to functions with deduced return type (PR #75456)

2024-01-03 Thread Richard Smith via cfe-commits
@@ -640,3 +640,36 @@ namespace PR46637 { template struct Y { T x; }; Y auto> y; // expected-error {{'auto' not allowed in template argument}} } + +namespace GH71015 { + +// Check that there is no error in case a templated function is recursive and +// has a placeholder

[llvm] [clang] [clang-tools-extra] [clang] Accept recursive non-dependent calls to functions with deduced return type (PR #75456)

2024-01-03 Thread Richard Smith via cfe-commits
https://github.com/zygoloid edited https://github.com/llvm/llvm-project/pull/75456 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [coroutines] Introduce [[clang::coro_disable_lifetimebound]] (PR #76818)

2024-01-03 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/76818 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[lldb] [flang] [compiler-rt] [clang-tools-extra] [llvm] [clang] [libc] [libcxx] [flang] FDATE extension implementation: get date and time in ctime format (PR #71222)

2024-01-03 Thread Yi Wu via cfe-commits
@@ -22,6 +22,9 @@ extern "C" { // CALL FLUSH(n) antedates the Fortran 2003 FLUSH statement. void FORTRAN_PROCEDURE_NAME(flush)(const int ); +// GNU extension subroutine FDATE +void FORTRAN_PROCEDURE_NAME(fdate)(std::byte *string, std::int64_t length);

[compiler-rt] [libcxx] [clang] [llvm] [libc] [flang] [lldb] [clang-tools-extra] [flang] FDATE extension implementation: get date and time in ctime format (PR #71222)

2024-01-03 Thread Yi Wu via cfe-commits
@@ -22,6 +22,9 @@ extern "C" { // CALL FLUSH(n) antedates the Fortran 2003 FLUSH statement. void FORTRAN_PROCEDURE_NAME(flush)(const int ); +// GNU extension subroutine FDATE +void FORTRAN_PROCEDURE_NAME(fdate)(std::byte *string, std::int64_t length);

[clang] [clang][modules] Print library module manifest path. (PR #76451)

2024-01-03 Thread Mark de Wever via cfe-commits
https://github.com/mordante updated https://github.com/llvm/llvm-project/pull/76451 >From f3f0db64da4d341f8e4a2054f9f25c87f8eda829 Mon Sep 17 00:00:00 2001 From: Mark de Wever Date: Wed, 27 Dec 2023 17:34:10 +0100 Subject: [PATCH 1/2] [clang][modules] Print library module manifest path. This

[clang] [Format] Fix isStartOfName to recognize attributes (PR #76804)

2024-01-03 Thread Björn Schäpers via cfe-commits
@@ -10093,11 +10090,11 @@ TEST_F(FormatTest, ReturnTypeBreakingStyle) { getGoogleStyleWithColumns(40)); verifyFormat("Tttt ppp\n" "ABSL_GUARDED_BY(mutex1)\n" - "ABSL_GUARDED_BY(mutex2);", +

[clang] [Format] Fix isStartOfName to recognize attributes (PR #76804)

2024-01-03 Thread Björn Schäpers via cfe-commits
@@ -1698,8 +1698,6 @@ FormatStyle getGoogleStyle(FormatStyle::LanguageKind Language) { /*BasedOnStyle=*/"google", }, }; - GoogleStyle.AttributeMacros.push_back("GUARDED_BY"); HazardyKnusperkeks wrote: Even if that would not be needed

[clang] [NFC][clang][test][asan] Make `instantiation-depth-default.cpp` a valid test case under `asan` and `ubsan` configs (PR #75254)

2024-01-03 Thread Duo Wang via cfe-commits
wdunicornpro wrote: @goussepi Do you have any thoughts on this? https://github.com/llvm/llvm-project/pull/75254 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libcxx] [clang-tools-extra] [flang] [lldb] [clang] [libc] [compiler-rt] [llvm] [flang] FDATE extension implementation: get date and time in ctime format (PR #71222)

2024-01-03 Thread Peter Klausler via cfe-commits
@@ -22,6 +22,9 @@ extern "C" { // CALL FLUSH(n) antedates the Fortran 2003 FLUSH statement. void FORTRAN_PROCEDURE_NAME(flush)(const int ); +// GNU extension subroutine FDATE +void FORTRAN_PROCEDURE_NAME(fdate)(std::byte *string, std::int64_t length);

[clang] [Sema] Provide `-fno-/-fvisibility-global-new-delete` option (PR #75364)

2024-01-03 Thread Paul T Robinson via cfe-commits
pogo59 wrote: Actually I kind of prefer all these options to have `-fvisibility-` as a prefix. Even if it doesn't read quite naturally, it strongly implies that the options are related (which is true) and any lexically sorted list of options will naturally group them together. WDYT @frobtech

[libcxx] [clang-tools-extra] [flang] [lldb] [clang] [libc] [compiler-rt] [llvm] [flang] FDATE extension implementation: get date and time in ctime format (PR #71222)

2024-01-03 Thread Yi Wu via cfe-commits
@@ -22,6 +22,9 @@ extern "C" { // CALL FLUSH(n) antedates the Fortran 2003 FLUSH statement. void FORTRAN_PROCEDURE_NAME(flush)(const int ); +// GNU extension subroutine FDATE +void FORTRAN_PROCEDURE_NAME(fdate)(std::byte *string, std::int64_t length);

[clang] [clang][modules] Print library module manifest path. (PR #76451)

2024-01-03 Thread Mark de Wever via cfe-commits
https://github.com/mordante edited https://github.com/llvm/llvm-project/pull/76451 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][modules] Print library module manifest path. (PR #76451)

2024-01-03 Thread Mark de Wever via cfe-commits
mordante wrote: > If this is the right thing to do (i.e., printing this information as part of > `-print-search-dirs`), then perhaps it's still worth it to try and fix? Once > you add a separate option, you will have to drag it forever (for backwards > compatibility). I have a feeling how

[clang] [UEFI] X86_64 UEFI Clang Driver (PR #76838)

2024-01-03 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Prabhuk (Prabhuk) Changes Introduce changes necessary for UEFI X86_64 target Clang driver. Addressed the review comments originally suggested in Phabricator. Differential Revision: https://reviews.llvm.org/D159541 --- Full diff:

[clang] [UEFI] X86_64 UEFI Clang Driver (PR #76838)

2024-01-03 Thread via cfe-commits
https://github.com/Prabhuk created https://github.com/llvm/llvm-project/pull/76838 Introduce changes necessary for UEFI X86_64 target Clang driver. Addressed the review comments originally suggested in Phabricator. Differential Revision: https://reviews.llvm.org/D159541 >From

[clang] [clang-format] Break after string literals with trailing line breaks (PR #76795)

2024-01-03 Thread Björn Schäpers via cfe-commits
@@ -10,6 +10,7 @@ #include "FormatTestUtils.h" #include "TestLexer.h" +#include "clang/Basic/TokenKinds.h" HazardyKnusperkeks wrote: Why do you need this? https://github.com/llvm/llvm-project/pull/76795 ___

[clang] [clang-format] Break after string literals with trailing line breaks (PR #76795)

2024-01-03 Thread Björn Schäpers via cfe-commits
https://github.com/HazardyKnusperkeks commented: Can you also add a formatting test? https://github.com/llvm/llvm-project/pull/76795 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Break after string literals with trailing line breaks (PR #76795)

2024-01-03 Thread Björn Schäpers via cfe-commits
https://github.com/HazardyKnusperkeks edited https://github.com/llvm/llvm-project/pull/76795 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][modules] Print library module manifest path. (PR #76451)

2024-01-03 Thread Mark de Wever via cfe-commits
@@ -2164,6 +2164,12 @@ bool Driver::HandleImmediateArgs(const Compilation ) { return false; } + if (C.getArgs().hasArg(options::OPT_print_library_module_manifest_path)) { +llvm::outs() << "module: =" mordante wrote: I removed the prefix and return

[clang] 3f9f8ef - ObjcRuntime.h: Add mips64, aarch64, and riscv64 to non-legacy dispatch (#76694)

2024-01-03 Thread via cfe-commits
Author: Hugo Melder Date: 2024-01-03T17:34:00Z New Revision: 3f9f8efc548d4a1dbd289bcf5fafe644d5f5c8f8 URL: https://github.com/llvm/llvm-project/commit/3f9f8efc548d4a1dbd289bcf5fafe644d5f5c8f8 DIFF: https://github.com/llvm/llvm-project/commit/3f9f8efc548d4a1dbd289bcf5fafe644d5f5c8f8.diff LOG:

[llvm] [clang] [libcxx] "Reapply "[Sema] Fix crash on invalid code with parenthesized aggrega… (PR #76833)

2024-01-03 Thread Mark de Wever via cfe-commits
https://github.com/mordante updated https://github.com/llvm/llvm-project/pull/76833 >From 77abc737eebd5cf62b52248a6e35e4c74fbeca80 Mon Sep 17 00:00:00 2001 From: Mark de Wever Date: Wed, 3 Jan 2024 18:00:43 +0100 Subject: [PATCH 1/2] "Reapply "[Sema] Fix crash on invalid code with

[clang] [analyzer] Add std::any checker (PR #76580)

2024-01-03 Thread via cfe-commits
=?utf-8?q?Gábor?= Spaits,=?utf-8?q?Gábor?= Spaits, =?utf-8?q?Gábor?= Spaits,=?utf-8?q?Gábor?= Spaits, =?utf-8?q?Gábor?= Spaits Message-ID: In-Reply-To: @@ -87,6 +85,28 @@ bool isStdVariant(const Type *Type) { return isStdType(Type, llvm::StringLiteral("variant")); } +bool

[clang-tools-extra] [clang] [llvm] [mlir] [libc] [libcxx] [flang] [openmp] [lldb] [compiler-rt] [lld] [libc++][streams] P1759R6: Native handles and file streams (PR #76632)

2024-01-03 Thread Mark de Wever via cfe-commits
@@ -0,0 +1,58 @@ +//===--===// +// +// 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:

[mlir] [openmp] [lldb] [libc] [compiler-rt] [libcxx] [llvm] [lld] [clang-tools-extra] [flang] [clang] [libc++][streams] P1759R6: Native handles and file streams (PR #76632)

2024-01-03 Thread Mark de Wever via cfe-commits
@@ -0,0 +1,30 @@ +//===--===// +// +// 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:

[libcxx] [lld] [llvm] [openmp] [libc] [lldb] [mlir] [compiler-rt] [flang] [clang] [clang-tools-extra] [libc++][streams] P1759R6: Native handles and file streams (PR #76632)

2024-01-03 Thread Mark de Wever via cfe-commits
@@ -24,6 +24,10 @@ #include "test_macros.h" +#if _LIBCPP_STD_VER >= 26 mordante wrote: This is the way to test for versions in the test suite. ```suggestion #if TEST_STD_VER >= 26 ``` The same for other places. Also since we can no longer use

[openmp] [clang-tools-extra] [flang] [mlir] [llvm] [lld] [compiler-rt] [libc] [lldb] [clang] [libcxx] [libc++][streams] P1759R6: Native handles and file streams (PR #76632)

2024-01-03 Thread Mark de Wever via cfe-commits
https://github.com/mordante edited https://github.com/llvm/llvm-project/pull/76632 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[flang] [clang] [openmp] [libcxx] [lld] [lldb] [clang-tools-extra] [llvm] [mlir] [compiler-rt] [libc] [libc++][streams] P1759R6: Native handles and file streams (PR #76632)

2024-01-03 Thread Mark de Wever via cfe-commits
https://github.com/mordante requested changes to this pull request. LGTM modulo some nits. I like to have a quick look at the final version before approving. https://github.com/llvm/llvm-project/pull/76632 ___ cfe-commits mailing list

[clang-tools-extra] [flang] [llvm] [libc] [compiler-rt] [lldb] [clang] [libcxx] [flang] FDATE extension implementation: get date and time in ctime format (PR #71222)

2024-01-03 Thread Yi Wu via cfe-commits
@@ -22,6 +22,9 @@ extern "C" { // CALL FLUSH(n) antedates the Fortran 2003 FLUSH statement. void FORTRAN_PROCEDURE_NAME(flush)(const int ); +// GNU extension subroutine FDATE +void FORTRAN_PROCEDURE_NAME(fdate)(std::byte *string, std::int64_t length);

[clang-tools-extra] [flang] [llvm] [libc] [compiler-rt] [lldb] [clang] [libcxx] [flang] FDATE extension implementation: get date and time in ctime format (PR #71222)

2024-01-03 Thread Yi Wu via cfe-commits
@@ -43,6 +66,26 @@ void FORTRAN_PROCEDURE_NAME(flush)(const int ) { } } // namespace io +// CALL FDATE(DATE) +void FORTRAN_PROCEDURE_NAME(fdate)(std::byte *arg, std::int64_t length) { + // Day Mon dd hh:mm:ss \n\0 is 26 characters, e.g. + // Tue May 26 21:51:03 2015\n\0

[clang-tools-extra] [flang] [llvm] [libc] [compiler-rt] [lldb] [clang] [libcxx] [flang] FDATE extension implementation: get date and time in ctime format (PR #71222)

2024-01-03 Thread Peter Klausler via cfe-commits
@@ -43,6 +66,26 @@ void FORTRAN_PROCEDURE_NAME(flush)(const int ) { } } // namespace io +// CALL FDATE(DATE) +void FORTRAN_PROCEDURE_NAME(fdate)(std::byte *arg, std::int64_t length) { + // Day Mon dd hh:mm:ss \n\0 is 26 characters, e.g. + // Tue May 26 21:51:03 2015\n\0

[openmp] [clang-tools-extra] [flang] [mlir] [llvm] [lld] [compiler-rt] [libc] [lldb] [clang] [libcxx] [libc++][streams] P1759R6: Native handles and file streams (PR #76632)

2024-01-03 Thread Mark de Wever via cfe-commits
mordante wrote: > > I did a full review. There are a number of comments, once these are > > addressed the patch is ready. > > Thank you for the detailed review and patience! > > I believe the failing tests are unrelated to this patch: > > > Failed Tests (2): > >

[clang] [libcxx] "Reapply "[Sema] Fix crash on invalid code with parenthesized aggrega… (PR #76833)

2024-01-03 Thread Mark de Wever via cfe-commits
mordante wrote: @ilya-biryukov this is the new attempt to land this patch, the version you committed breaks the libc++ CI. I'll try to fix it this week. https://github.com/llvm/llvm-project/pull/76833 ___ cfe-commits mailing list

[clang] [libcxx] "Reapply "[Sema] Fix crash on invalid code with parenthesized aggrega… (PR #76833)

2024-01-03 Thread Mark de Wever via cfe-commits
https://github.com/mordante created https://github.com/llvm/llvm-project/pull/76833 …te initialization" (#76272)"" With updates the libc++ tests. This reverts commit 2205d23 and relands 86dc6e1 and 7ab16fb. Original commit was reverted because of failing libc++ tests, see #76232 for the

[clang] a8f4397 - [Clang] Fix ICE where C++ Template Instantiation failed to handle attributed lambdas (#76523)

2024-01-03 Thread via cfe-commits
Author: Yuxuan Chen Date: 2024-01-03T09:01:19-08:00 New Revision: a8f43974260ec244d78336d2530f8fc097753580 URL: https://github.com/llvm/llvm-project/commit/a8f43974260ec244d78336d2530f8fc097753580 DIFF: https://github.com/llvm/llvm-project/commit/a8f43974260ec244d78336d2530f8fc097753580.diff

[clang] [Clang] Fix ICE where C++ Template Instantiation failed to handle attributed lambdas (PR #76523)

2024-01-03 Thread Yuxuan Chen via cfe-commits
https://github.com/yuxuanchen1997 closed https://github.com/llvm/llvm-project/pull/76523 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] cba217a - Revert "Reapply "[Sema] Fix crash on invalid code with parenthesized aggregate initialization" (#76272)"

2024-01-03 Thread Mark de Wever via cfe-commits
Author: Mark de Wever Date: 2024-01-03T17:56:07+01:00 New Revision: cba217a9138aa8ea8d18111b648acde8f52ada8d URL: https://github.com/llvm/llvm-project/commit/cba217a9138aa8ea8d18111b648acde8f52ada8d DIFF: https://github.com/llvm/llvm-project/commit/cba217a9138aa8ea8d18111b648acde8f52ada8d.diff

[llvm] [flang] [compiler-rt] [clang] [libc] [lldb] [clang-tools-extra] [libcxx] [flang] FDATE extension implementation: get date and time in ctime format (PR #71222)

2024-01-03 Thread Yi Wu via cfe-commits
@@ -43,6 +66,26 @@ void FORTRAN_PROCEDURE_NAME(flush)(const int ) { } } // namespace io +// CALL FDATE(DATE) +void FORTRAN_PROCEDURE_NAME(fdate)(std::byte *arg, std::int64_t length) { + // Day Mon dd hh:mm:ss \n\0 is 26 characters, e.g. + // Tue May 26 21:51:03 2015\n\0

[clang-tools-extra] [clangd] check for synthesized symbols when tracking include locations (PR #75128)

2024-01-03 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov closed https://github.com/llvm/llvm-project/pull/75128 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] a3977c9 - [clangd] check for synthesized symbols when tracking include locations (#75128)

2024-01-03 Thread via cfe-commits
Author: Matheus Izvekov Date: 2024-01-03T17:52:50+01:00 New Revision: a3977c92376ecec1838262eca68d0def14a4e14d URL: https://github.com/llvm/llvm-project/commit/a3977c92376ecec1838262eca68d0def14a4e14d DIFF:

[clang] [Clang][Sema] Diagnose unexpanded packs in the template argument lists of function template specializations (PR #76677)

2024-01-03 Thread Erich Keane via cfe-commits
https://github.com/erichkeane commented: As Corentin said, needs a release note, else LGTM. https://github.com/llvm/llvm-project/pull/76677 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [Clang] Correctly construct template arguments for file-scope template template parameters (PR #76811)

2024-01-03 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. This makes sense to me, I think this is right. https://github.com/llvm/llvm-project/pull/76811 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang-tools-extra] [flang] [llvm] [libc] [compiler-rt] [lldb] [clang] [libcxx] [flang] FDATE extension implementation: get date and time in ctime format (PR #71222)

2024-01-03 Thread Peter Klausler via cfe-commits
@@ -43,6 +66,26 @@ void FORTRAN_PROCEDURE_NAME(flush)(const int ) { } } // namespace io +// CALL FDATE(DATE) +void FORTRAN_PROCEDURE_NAME(fdate)(std::byte *arg, std::int64_t length) { + // Day Mon dd hh:mm:ss \n\0 is 26 characters, e.g. + // Tue May 26 21:51:03 2015\n\0

[flang] [clang] [libcxx] [lldb] [clang-tools-extra] [llvm] [compiler-rt] [libc] [flang] FDATE extension implementation: get date and time in ctime format (PR #71222)

2024-01-03 Thread Peter Klausler via cfe-commits
@@ -22,6 +22,9 @@ extern "C" { // CALL FLUSH(n) antedates the Fortran 2003 FLUSH statement. void FORTRAN_PROCEDURE_NAME(flush)(const int ); +// GNU extension subroutine FDATE +void FORTRAN_PROCEDURE_NAME(fdate)(std::byte *string, std::int64_t length);

[clang] [clang] Reword apologetic Clang diagnostic messages (PR #76310)

2024-01-03 Thread Erich Keane via cfe-commits
@@ -5188,7 +5188,7 @@ def err_template_arg_not_object_or_func : Error< def err_template_arg_not_pointer_to_member_form : Error< "non-type template argument is not a pointer to member constant">; def err_template_arg_member_ptr_base_derived_not_supported : Error< - "sorry,

[clang] [clang][dataflow] Fix bug in `Value` comparison. (PR #76746)

2024-01-03 Thread Gábor Horváth via cfe-commits
https://github.com/Xazax-hun approved this pull request. https://github.com/llvm/llvm-project/pull/76746 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix ICE where C++ Template Instantiation failed to handle attributed lambdas (PR #76523)

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

[clang] [clang][Sema] deleted overriding function can have lax except spec (PR #76248)

2024-01-03 Thread Erich Keane via cfe-commits
https://github.com/erichkeane commented: This needs a release note. Also, since this is implementing a core issue, this needs to update a DRs test as well. https://github.com/llvm/llvm-project/pull/76248 ___ cfe-commits mailing list

[clang] [Clang][AST] Fix crash in APValue::LValueBase::getType when we have invalid decl (PR #75130)

2024-01-03 Thread Erich Keane via cfe-commits
@@ -70,11 +70,13 @@ QualType APValue::LValueBase::getType() const { // constexpr int *p = [1]; // valid? // // For now, we take the most complete type we can find. -for (auto *Redecl = cast(D->getMostRecentDecl()); Redecl; +for (auto *Redecl =

[clang] 55d5ba9 - [NFC] Fix compilation in C++20 mode with GCC 12

2024-01-03 Thread Ilya Biryukov via cfe-commits
Author: Ilya Biryukov Date: 2024-01-03T17:02:00+01:00 New Revision: 55d5ba905da0db55282dd3985761ddf3dd452fd1 URL: https://github.com/llvm/llvm-project/commit/55d5ba905da0db55282dd3985761ddf3dd452fd1 DIFF: https://github.com/llvm/llvm-project/commit/55d5ba905da0db55282dd3985761ddf3dd452fd1.diff

[llvm] [clang] [HLSL][SPIR-V] Add Vulkan to target triple (PR #76749)

2024-01-03 Thread Natalie Chouinard via cfe-commits
@@ -3,29 +3,39 @@ // Supported targets // // RUN: %clang -target dxil-unknown-shadermodel6.2-compute %s -S -o /dev/null 2>&1 | FileCheck --allow-empty --check-prefix=CHECK-VALID %s -// RUN: %clang -target spirv-unknown-shadermodel6.2-compute %s -S -o /dev/null 2>&1 |

[llvm] [clang] [HLSL][SPIR-V] Add Vulkan to target triple (PR #76749)

2024-01-03 Thread Natalie Chouinard via cfe-commits
@@ -1328,6 +1331,31 @@ VersionTuple Triple::getDriverKitVersion() const { } } +VersionTuple Triple::getVulkanVersion() const { + if (getArch() != spirv || getOS() != Vulkan) +llvm_unreachable("invalid Vulkan SPIR-V triple"); + + VersionTuple VulkanVersion =

[llvm] [clang] [HLSL][SPIR-V] Add Vulkan to target triple (PR #76749)

2024-01-03 Thread Natalie Chouinard via cfe-commits
@@ -4236,20 +4236,35 @@ bool CompilerInvocation::ParseLangArgs(LangOptions , ArgList , // TODO: Revisit restricting SPIR-V to logical once we've figured out how to // handle PhysicalStorageBuffer64 memory model if (T.isDXIL() || T.isSPIRVLogical()) { - enum

[llvm] [clang] [HLSL][SPIR-V] Add Vulkan to target triple (PR #76749)

2024-01-03 Thread Natalie Chouinard via cfe-commits
https://github.com/sudonatalie updated https://github.com/llvm/llvm-project/pull/76749 >From 6141382cebfe0a40c054b2ce7539ec6ff85f3c14 Mon Sep 17 00:00:00 2001 From: Natalie Chouinard Date: Fri, 15 Dec 2023 20:50:43 + Subject: [PATCH 1/2] [HLSL][SPIR-V] Add Vulkan to target triple Add

[clang] [clang][dataflow] Fix bug in `Value` comparison. (PR #76746)

2024-01-03 Thread Yitzhak Mandelbaum via cfe-commits
@@ -27,9 +27,13 @@ static bool areEquivalentIndirectionValues(const Value , } bool areEquivalentValues(const Value , const Value ) { - return == || (Val1.getKind() == Val2.getKind() && -(isa() || -

[compiler-rt] [clang] [clang-tools-extra] [llvm] [libc] [flang] [lldb] [GlobalIsel] Combine select of binops (PR #76763)

2024-01-03 Thread Thorsten Schütt via cfe-commits
@@ -544,3 +544,154 @@ body: | %ext:_(s32) = G_ANYEXT %sel $w0 = COPY %ext(s32) ... +--- +# select cond, and(x, y), and(z, y) --> and (select cond, x, z), y +name:select_cond_and_x_y_and_z_y_and_select_x_z_y +body: | + bb.1: +

[compiler-rt] [clang] [clang-tools-extra] [llvm] [libc] [flang] [lldb] [GlobalIsel] Combine select of binops (PR #76763)

2024-01-03 Thread Thorsten Schütt via cfe-commits
@@ -544,3 +544,154 @@ body: | %ext:_(s32) = G_ANYEXT %sel $w0 = COPY %ext(s32) ... +--- +# select cond, and(x, y), and(z, y) --> and (select cond, x, z), y +name:select_cond_and_x_y_and_z_y_and_select_x_z_y +body: | + bb.1: +

[compiler-rt] [clang] [clang-tools-extra] [llvm] [libc] [flang] [lldb] [GlobalIsel] Combine select of binops (PR #76763)

2024-01-03 Thread Thorsten Schütt via cfe-commits
@@ -6548,6 +6534,54 @@ bool CombinerHelper::tryFoldBoolSelectToLogic(GSelect *Select, return false; } +bool CombinerHelper::tryFoldSelectOfBinOps(GSelect *Select, + BuildFnTy ) { + Register DstReg = Select->getReg(0); + Register

[compiler-rt] [clang] [clang-tools-extra] [llvm] [libc] [flang] [lldb] [GlobalIsel] Combine select of binops (PR #76763)

2024-01-03 Thread Thorsten Schütt via cfe-commits
@@ -6548,6 +6534,54 @@ bool CombinerHelper::tryFoldBoolSelectToLogic(GSelect *Select, return false; } +bool CombinerHelper::tryFoldSelectOfBinOps(GSelect *Select, + BuildFnTy ) { + Register DstReg = Select->getReg(0); + Register

[llvm] [clang] test-release.sh: Add a CMake cache file for 3-stage release builds (PR #75903)

2024-01-03 Thread Tom Stellard via cfe-commits
https://github.com/tstellar updated https://github.com/llvm/llvm-project/pull/75903 >From 88b9aac241bed0ce7c65fa798b68c9779f0615e7 Mon Sep 17 00:00:00 2001 From: Tom Stellard Date: Fri, 15 Dec 2023 01:27:25 + Subject: [PATCH 1/2] test-release.sh: Add a CMake cache file for 3-stage release

[clang] [clang] Optimize castToDeclContext for 2% improvement in build times (PR #76825)

2024-01-03 Thread Pol M via cfe-commits
Destroyerrrocket wrote: Yeah, I also saw that in O3 most of the compile time is overshadowed by LLVM, so it makes perfect sense that the -O0 are the ones showing better results! https://github.com/llvm/llvm-project/pull/76825 ___ cfe-commits mailing

[clang] [clang][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72235)

2024-01-03 Thread Michael Buch via cfe-commits
Michael137 wrote: > Should've mentioned this earlier, but we've been seeing crashes in lldb due > to this change (though possibly related to our use of GALA python/gdb interop > https://github.com/sivachandra/gala - we haven't isolated the failures from > that yet (though we've been using it

[clang] [clang] Optimize castToDeclContext for 2% improvement in build times (PR #76825)

2024-01-03 Thread Nikita Popov via cfe-commits
nikic wrote: https://llvm-compile-time-tracker.com/compare.php?from=98624914367bf9091919de330cf322fb6d5e468f=7d398e29b0180aacc646fed5406ad7fbd4b30c02=instructions%3Au Nice results for C++ code! https://github.com/llvm/llvm-project/pull/76825 ___

[clang] [llvm] test-release.sh: Add a CMake cache file for 3-stage release builds (PR #75903)

2024-01-03 Thread Konrad Kleine via cfe-commits
@@ -0,0 +1,41 @@ +# Plain options configure the first build. +# BOOTSTRAP_* options configure the second build. +# BOOTSTRAP_BOOTSTRAP_* options configure the third build. + +set(CMAKE_BUILD_TYPE RELEASE CACHE STRING "") + +# Stage 1 Bootstrap Setup +set(CLANG_ENABLE_BOOTSTRAP ON

[clang] [Format] Fix isStartOfName to recognize attributes (PR #76804)

2024-01-03 Thread Ilya Biryukov via cfe-commits
ilya-biryukov wrote: > can you also add a test to clang/unittests/Format/TokenAnnotatorTest.cpp that > ensures trailing attribute-like macros receive `StartOfName` annotation to > make sure we don't regress the signal in the future? ok, that opened a whole can of worms. ``` Tokens =

[clang] [clang] Differentiate between identifier and string EnumArgument (PR #68550)

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

[clang] [llvm] [clang-tools-extra] [Sema] When checking for constraint equivalence, do not calculate satisfaction (PR #74490)

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

[clang] [clang-tools-extra] [compiler-rt] [PGO] Exposing PGO's Counter Reset and File Dumping APIs (PR #76471)

2024-01-03 Thread Teresa Johnson via cfe-commits
teresajohnson wrote: > I realized one problem during testing IRPGO (thanks again for the suggestion > @minglotus-6 !). > > A function's control flow may change between `-fprofile-generate` and > `-fprofile-use` when we make use of definitions in the new header. For > example, one may have

[clang] [clang][ExtractAPI] Record availability information only for the target platform (PR #76823)

2024-01-03 Thread Sofía Rodríguez via cfe-commits
sofiaromorales wrote: @daniel-grumberg https://github.com/llvm/llvm-project/pull/76823 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ExtractAPI] Record availability information only for the target platform (PR #76823)

2024-01-03 Thread Sofía Rodríguez via cfe-commits
https://github.com/sofiaromorales updated https://github.com/llvm/llvm-project/pull/76823 From d459421cc3a59f56c27eaeafd81ec2c2366b9fa7 Mon Sep 17 00:00:00 2001 From: Sofia Rodriguez Date: Wed, 3 Jan 2024 15:29:45 +0100 Subject: [PATCH 1/2] [clang][ExtractAPI] Record availability information

[clang] Changed Checks from TriviallyCopyable to TriviallyCopyConstructible (PR #76680)

2024-01-03 Thread Vlad Serebrennikov via cfe-commits
@@ -2644,6 +2644,49 @@ bool QualType::isTriviallyCopyableType(const ASTContext ) const { return false; } +bool QualType::isTriviallyCopyConstructibleType( Endilll wrote: Go ahead, but it would be nice if we don't regress performance along the way (by

[clang-tools-extra] [clangd] Dont require confirmation for include-cleaner batch-fixes (PR #76826)

2024-01-03 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clangd Author: kadir çetinkaya (kadircet) Changes False negative/positive rate has decreased to the degree that these extra confirmations no longer provide any value, but only create friction in the happy case. When we have false analysis, people

[clang-tools-extra] [clangd] Dont require confirmation for include-cleaner batch-fixes (PR #76826)

2024-01-03 Thread kadir çetinkaya via cfe-commits
https://github.com/kadircet created https://github.com/llvm/llvm-project/pull/76826 False negative/positive rate has decreased to the degree that these extra confirmations no longer provide any value, but only create friction in the happy case. When we have false analysis, people usually need

[clang] [Sema] Add -Wc++11-narrowing-const-reference (PR #76094)

2024-01-03 Thread Erich Keane via cfe-commits
@@ -10410,40 +10410,53 @@ static void DiagnoseNarrowingInInitList(Sema , // No narrowing occurred. return; - case NK_Type_Narrowing: + case NK_Type_Narrowing: { // This was a floating-to-integer conversion, which is always considered a // narrowing

[clang] [Sema] Add -Wc++11-narrowing-const-reference (PR #76094)

2024-01-03 Thread Erich Keane via cfe-commits
@@ -6158,12 +6158,24 @@ def err_illegal_initializer_type : Error<"illegal initializer type %0">; def ext_init_list_type_narrowing : ExtWarn< "type %0 cannot be narrowed to %1 in initializer list">, InGroup, DefaultError, SFINAEFailure; +// *_narrowing_const_reference

[clang] [Sema] Add -Wc++11-narrowing-const-reference (PR #76094)

2024-01-03 Thread Erich Keane via cfe-commits
https://github.com/erichkeane commented: Please fix the comments in a followup. https://github.com/llvm/llvm-project/pull/76094 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Add -Wc++11-narrowing-const-reference (PR #76094)

2024-01-03 Thread Erich Keane via cfe-commits
https://github.com/erichkeane edited https://github.com/llvm/llvm-project/pull/76094 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Optimize castToDeclContext for 2% improvement in build times (PR #76825)

2024-01-03 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Pol M (Destroyerrrocket) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/76825.diff 5 Files Affected: - (modified) clang/include/clang/AST/DeclCXX.h (+8) - (modified) clang/lib/AST/DeclBase.cpp (+16-34) - (modified)

[clang] [clang] Optimize castToDeclContext for 2% improvement in build times (PR #76825)

2024-01-03 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] Optimize castToDeclContext for 2% improvement in build times (PR #76825)

2024-01-03 Thread Pol M via cfe-commits
https://github.com/Destroyerrrocket created https://github.com/llvm/llvm-project/pull/76825 None >From 1ab4538e194f9a77c500e4a93b1875eb7e76dcf5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pol=20Marcet=20Sard=C3=A0?= Date: Wed, 3 Jan 2024 16:00:42 +0100 Subject: [PATCH] [clang] Optimize

[clang] [clang] Report narrowing conversions with const references (PR #75332)

2024-01-03 Thread Erich Keane via cfe-commits
erichkeane wrote: > The change in the diagnostic happens to make it much noisier than it was > before. Our code was clean w.r.t. -Wc++11-narrowing, but now we see hundreds > if not thousands of compilation breakages (we use -Werror, which turns out to > be the only robust way to avoid

[clang] [clang][sema] make sure arguments of __atomic_exchange complete type (PR #75135)

2024-01-03 Thread Erich Keane via cfe-commits
@@ -7885,6 +7885,18 @@ ExprResult Sema::BuildAtomicExpr(SourceRange CallRange, SourceRange ExprRange, if ((IsOpenCL || IsHIP || IsScoped) && Op != AtomicExpr::AO__opencl_atomic_init) ++AdjustedNumArgs; + + // Verify if the arguments are of type CompleteType

[clang-tools-extra] 7837110 - [clangd] Track IWYU pragmas for non-preamble includes (#75612)

2024-01-03 Thread via cfe-commits
Author: kadir çetinkaya Date: 2024-01-03T15:57:30+01:00 New Revision: 7837110ed8efdd510516c849178a7af28b93aea4 URL: https://github.com/llvm/llvm-project/commit/7837110ed8efdd510516c849178a7af28b93aea4 DIFF:

[clang-tools-extra] [clangd] Track IWYU pragmas for non-preamble includes (PR #75612)

2024-01-03 Thread kadir çetinkaya via cfe-commits
https://github.com/kadircet closed https://github.com/llvm/llvm-project/pull/75612 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [lldb] [clang] [llvm] [libc] [compiler-rt] [flang] [GlobalIsel] Combine select of binops (PR #76763)

2024-01-03 Thread Thorsten Schütt via cfe-commits
https://github.com/tschuett updated https://github.com/llvm/llvm-project/pull/76763 From e713bb6e2c36ec16c731217f0c3be19b040a03d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thorsten=20Sch=C3=BCtt?= Date: Tue, 2 Jan 2024 18:00:45 +0100 Subject: [PATCH 1/4] [GlobalIsel] Combine select of binops

[clang] [clang][ExtractAPI] Record availability information only for the target platform (PR #76823)

2024-01-03 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 0d19a8983c05de321d8ab592995e7a36bca448ee d459421cc3a59f56c27eaeafd81ec2c2366b9fa7 --

[clang] [clang][ExtractAPI] Record availability information only for the target platform (PR #76823)

2024-01-03 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Sofía Rodríguez (sofiaromorales) Changes Currently, ExtractAPI provides availability information for all platforms within a given domain. With this change, we narrow down the output to include availability details only for the specified

[clang] [clang][ExtractAPI] Record availability information only for the target platform (PR #76823)

2024-01-03 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][ExtractAPI] Record availability information only for the target platform (PR #76823)

2024-01-03 Thread Sofía Rodríguez via cfe-commits
https://github.com/sofiaromorales created https://github.com/llvm/llvm-project/pull/76823 Currently, ExtractAPI provides availability information for all platforms within a given domain. With this change, we narrow down the output to include availability details only for the specified target

[clang-tools-extra] [lldb] [clang] [llvm] [libc] [compiler-rt] [flang] [GlobalIsel] Combine select of binops (PR #76763)

2024-01-03 Thread Thorsten Schütt via cfe-commits
tschuett wrote: Please review changes (C++ and mir) regarding flag handling. https://github.com/llvm/llvm-project/pull/76763 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [libc] [lldb] [mlir] [clang] [llvm] [lld] [libcxx] [compiler-rt] [flang] [openmp] [libc++][streams] P1759R6: Native handles and file streams (PR #76632)

2024-01-03 Thread Hristo Hristov via cfe-commits
H-G-Hristov wrote: > I did a full review. There are a number of comments, once these are addressed > the patch is ready. Thank you for the detailed review and patience! I believe the failing tests are unrelated to this patch. https://github.com/llvm/llvm-project/pull/76632

[clang-tools-extra] [lldb] [clang] [llvm] [libc] [compiler-rt] [flang] [GlobalIsel] Combine select of binops (PR #76763)

2024-01-03 Thread Thorsten Schütt via cfe-commits
https://github.com/tschuett updated https://github.com/llvm/llvm-project/pull/76763 From e713bb6e2c36ec16c731217f0c3be19b040a03d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thorsten=20Sch=C3=BCtt?= Date: Tue, 2 Jan 2024 18:00:45 +0100 Subject: [PATCH 1/3] [GlobalIsel] Combine select of binops

[clang-tools-extra] [lldb] [clang] [llvm] [libc] [compiler-rt] [flang] [GlobalIsel] Combine select of binops (PR #76763)

2024-01-03 Thread Thorsten Schütt via cfe-commits
https://github.com/tschuett updated https://github.com/llvm/llvm-project/pull/76763 From e713bb6e2c36ec16c731217f0c3be19b040a03d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thorsten=20Sch=C3=BCtt?= Date: Tue, 2 Jan 2024 18:00:45 +0100 Subject: [PATCH] [GlobalIsel] Combine select of binops ---

[clang] [X86] Emit Warnings for frontend options to enable knl/knm. (PR #75580)

2024-01-03 Thread Simon Pilgrim via cfe-commits
RKSimon wrote: Sorry, we'd require both avx512f and avx512cd to work without avx512vl - but everything afterward (avx512bw, avx512dq, ) we could assume avx512vl is enabled. https://github.com/llvm/llvm-project/pull/75580 ___ cfe-commits mailing

[clang] [coroutines] Introduce [[clang::coro_disable_lifetime_bound]] (PR #76818)

2024-01-03 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/76818 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [coroutines] Introduce [[clang::coro_disable_lifetime_bound]] (PR #76818)

2024-01-03 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/76818 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [coroutines] Introduce [[clang::coro_not_lifetimebound]] (PR #76818)

2024-01-03 Thread Utkarsh Saxena via cfe-commits
@@ -1121,6 +1121,14 @@ def CoroLifetimeBound : InheritableAttr { let SimpleHandler = 1; } +def CoroNotLifetimeBound : InheritableAttr { usx95 wrote: SG. https://github.com/llvm/llvm-project/pull/76818 ___

[clang] [Clang] Support MSPropertyRefExpr as placement arg to new-expression (PR #75883)

2024-01-03 Thread Erich Keane via cfe-commits
@@ -0,0 +1,52 @@ +// RUN: %clang_cc1 -emit-llvm -triple=x86_64-pc-win32 -fms-compatibility %s -o - | FileCheck %s +// RUN: %clang_cc1 -triple=x86_64-pc-win32 -fms-compatibility -emit-pch -o %t %s +// RUN: %clang_cc1 -emit-llvm -triple=x86_64-pc-win32 -fms-compatibility

[clang] [Clang] Support MSPropertyRefExpr as placement arg to new-expression (PR #75883)

2024-01-03 Thread Erich Keane via cfe-commits
@@ -2286,6 +2286,9 @@ ExprResult Sema::BuildCXXNew(SourceRange Range, bool UseGlobal, bool PassAlignment = getLangOpts().AlignedAllocation && Alignment > NewAlignment; + if (CheckArgsForPlaceholders(PlacementArgs)) erichkeane wrote:

<    1   2   3   4   5   >