[clang] [APINotes] Upstream Sema logic to apply API Notes to decls (PR #73017)

2024-01-12 Thread Saleem Abdulrasool via cfe-commits
@@ -2622,6 +2641,31 @@ def SwiftPrivate : InheritableAttr { let SimpleHandler = 1; } +def SwiftVersioned : Attr { + // This attribute has no spellings as it is only ever created implicitly + // from API notes. + let Spellings = []; + let Args =

[flang] [llvm] [compiler-rt] [lld] [libcxx] [clang] [mlir] [lldb] [clang-tools-extra] [DWARFLinker][NFC] Decrease DWARFLinker dependence on DwarfStreamer. (PR #77932)

2024-01-12 Thread Alexey Lapshin via cfe-commits
https://github.com/avl-llvm updated https://github.com/llvm/llvm-project/pull/77932 >From 30a603f6d37afecdb2cb150bd98acd27c8d8baf5 Mon Sep 17 00:00:00 2001 From: Alexey Lapshin Date: Fri, 12 Jan 2024 13:07:33 +0300 Subject: [PATCH] [DWARFLinker][NFC] Decrease DWARFLinker dependence on

[clang] [RISCV] Support __riscv_v_fixed_vlen for vbool types. (PR #76551)

2024-01-12 Thread Craig Topper via cfe-commits
topperc wrote: Ping https://github.com/llvm/llvm-project/pull/76551 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Add test for CWG1807 (PR #77637)

2024-01-12 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > This brings me to conclusion that hand-written style of codegen tests > presented above is a better fit for purposes of C++ defect report codegen > tests. I share that conclusion. I think the hand-written IR is easier for people to reason because it strips out unrelated

[clang-tools-extra] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-12 Thread Bhuminjay Soni via cfe-commits
@@ -0,0 +1,31 @@ +.. title:: clang-tidy - readability-use-std-min-max + +readability-use-std-min-max +=== + +Replaces certain conditional statements with equivalent ``std::min`` or ``std::max`` expressions, +improving readability and promoting the use of

[clang] [llvm] [AArch64][SME2] Refine fcvtu/fcvts/scvtf/ucvtf (PR #77947)

2024-01-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-llvm-ir @llvm/pr-subscribers-clang-codegen @llvm/pr-subscribers-backend-aarch64 Author: Matthew Devereau (MDevereau) Changes Rename intrinsics for fcvtu to fcvtzu and fcvts to fcvtzs. Use llvm_anyvector_ty for both multi vector returns and operands,

[clang] [llvm] [AArch64][SME2] Refine fcvtu/fcvts/scvtf/ucvtf (PR #77947)

2024-01-12 Thread Matthew Devereau via cfe-commits
https://github.com/MDevereau created https://github.com/llvm/llvm-project/pull/77947 Rename intrinsics for fcvtu to fcvtzu and fcvts to fcvtzs. Use llvm_anyvector_ty for both multi vector returns and operands, therefore the return and operands can be specified in the intrinsic call, e.g.

[clang-tools-extra] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-12 Thread Bhuminjay Soni via cfe-commits
https://github.com/11happy updated https://github.com/llvm/llvm-project/pull/77816 >From 1883d987b2f83adaef05fdb47ae25c7b06582a64 Mon Sep 17 00:00:00 2001 From: 11happy Date: Fri, 12 Jan 2024 00:02:46 +0530 Subject: [PATCH 01/13] Add readability check to suggest replacement of conditional

[clang] [clang] Add test for CWG1807 (PR #77637)

2024-01-12 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: Following the suggestion from @nikic, I prepared two variants of the same test, one hard-written, and one using `update_cc_test_checks.py` (with heavy manual editing afterwards). Hand-written: ``` // CHECK-LABEL: define dso_local void @dr1807::f() // CHECK:

[clang] [clang][ASTImporter] Fix import of variable template redeclarations. (PR #72841)

2024-01-12 Thread Balázs Kéri via cfe-commits
@@ -6245,17 +6245,21 @@ ExpectedDecl ASTNodeImporter::VisitVarTemplateDecl(VarTemplateDecl *D) { D->getTemplatedDecl())) continue; if (IsStructuralMatch(D, FoundTemplate)) { -// The Decl in the "From" context

[llvm] [clang] [PowerPC][X86] Make cpu id builtins target independent and lower for PPC (PR #68919)

2024-01-12 Thread via cfe-commits
@@ -16086,6 +16086,41 @@ Value *CodeGenFunction::EmitPPCBuiltinExpr(unsigned BuiltinID, switch (BuiltinID) { default: return nullptr; + case Builtin::BI__builtin_cpu_is: { +const Expr *CPUExpr = E->getArg(0)->IgnoreParenCasts(); +StringRef CPUStr =

[clang] [clang] Add test for CWG1807 (PR #77637)

2024-01-12 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll updated https://github.com/llvm/llvm-project/pull/77637 >From 545ee4900e48b186e1c9fff93dc62a459ee19754 Mon Sep 17 00:00:00 2001 From: Vlad Serebrennikov Date: Wed, 10 Jan 2024 20:27:53 +0300 Subject: [PATCH 1/7] [clang] Add test for CWG1807 The test checks that

[clang] [clang][ASTImporter] Improve structural equivalence of overloadable operators. (PR #72242)

2024-01-12 Thread Balázs Kéri via cfe-commits
@@ -2252,6 +2252,176 @@ TEST_F(StructuralEquivalenceStmtTest, UnaryOperatorDifferentOps) { EXPECT_FALSE(testStructuralMatch(t)); } +TEST_F(StructuralEquivalenceStmtTest, + CXXOperatorCallExprVsUnaryBinaryOperator) { + auto t = makeNamedDecls( + R"( +

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

2024-01-12 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 8cf6bcf5a30673dd8a234ae3ef4ab4c1e63786b1 a8f9dc9edd98416a84d524ca6b233a27882f5085 --

[clang] [clang][ASTImporter] Improve structural equivalence of overloadable operators. (PR #72242)

2024-01-12 Thread Balázs Kéri via cfe-commits
https://github.com/balazske updated https://github.com/llvm/llvm-project/pull/72242 From 5300f979c96eb2f88c298872f0519e274c155cfe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bal=C3=A1zs=20K=C3=A9ri?= Date: Tue, 14 Nov 2023 11:53:20 +0100 Subject: [PATCH 1/3] [clang][ASTImporter] Improve

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

2024-01-12 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/4] [clang][modules] Print library module manifest path. This

[clang-tools-extra] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-12 Thread via cfe-commits
@@ -0,0 +1,31 @@ +.. title:: clang-tidy - readability-use-std-min-max + +readability-use-std-min-max +=== + +Replaces certain conditional statements with equivalent ``std::min`` or ``std::max`` expressions, +improving readability and promoting the use of

[clang-tools-extra] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-12 Thread via cfe-commits
@@ -0,0 +1,31 @@ +.. title:: clang-tidy - readability-use-std-min-max + +readability-use-std-min-max +=== + +Replaces certain conditional statements with equivalent ``std::min`` or ``std::max`` expressions, +improving readability and promoting the use of

[clang-tools-extra] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-12 Thread via cfe-commits
@@ -0,0 +1,31 @@ +.. title:: clang-tidy - readability-use-std-min-max + +readability-use-std-min-max +=== + +Replaces certain conditional statements with equivalent ``std::min`` or ``std::max`` expressions, +improving readability and promoting the use of

[clang] [Clang] Amend SME attributes with support for ZT0. (PR #77941)

2024-01-12 Thread via cfe-commits
rsandifo-arm wrote: LGTM from a spec point of view, although it might be worth having some tests that have different ZA state from ZT0. (But maybe not, since the code to handle ZA and ZT0 is mostly orthogonal.) I won't approve because of the growth in `FunctionProtoType` — someone more

[clang-tools-extra] [clang-tidy] Fix false-positives in misc-static-assert caused by non-constexpr variables (PR #77203)

2024-01-12 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/77203 ___ 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-12 Thread Mark de Wever via cfe-commits
@@ -0,0 +1,9 @@ +// Test that -print-library-module-manifest-path finds the correct file. +// +// Note this file is currently not available on Apple platforms mordante wrote: I'll remove this test for now. It can be added later when it's known where Apple will

[clang-tools-extra] [clang-tid]fix modernize-use-auto incorrect fix hints for pointer (PR #77943)

2024-01-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tidy Author: Congcong Cai (HerrCai0907) Changes avoid create incorrect fix hints for pointer to array type and pointer to function type Fixes: #77891 --- Full diff: https://github.com/llvm/llvm-project/pull/77943.diff 2 Files Affected: -

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

2024-01-12 Thread Mark de Wever via cfe-commits
@@ -6135,6 +6141,42 @@ std::string Driver::GetProgramPath(StringRef Name, const ToolChain ) const { return std::string(Name); } +std::string Driver::GetStdModuleManifestPath(const Compilation , + const ToolChain ) const { + +

[clang-tools-extra] [clang-tid]fix modernize-use-auto incorrect fix hints for pointer (PR #77943)

2024-01-12 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 created https://github.com/llvm/llvm-project/pull/77943 avoid create incorrect fix hints for pointer to array type and pointer to function type Fixes: #77891 >From 537d283288f555c2bb7cff90aee89fe9b18f08b8 Mon Sep 17 00:00:00 2001 From: Congcong Cai Date: Sat,

[clang] [AVX10][Doc] Add documentation about AVX10 options and their attentions (PR #77925)

2024-01-12 Thread Evgenii Kudriashov via cfe-commits
https://github.com/e-kud edited https://github.com/llvm/llvm-project/pull/77925 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AVX10][Doc] Add documentation about AVX10 options and their attentions (PR #77925)

2024-01-12 Thread Evgenii Kudriashov via cfe-commits
https://github.com/e-kud edited https://github.com/llvm/llvm-project/pull/77925 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AVX10][Doc] Add documentation about AVX10 options and their attentions (PR #77925)

2024-01-12 Thread Evgenii Kudriashov via cfe-commits
@@ -3963,6 +3963,60 @@ implicitly included in later levels. - ``-march=x86-64-v3``: (close to Haswell) AVX, AVX2, BMI1, BMI2, F16C, FMA, LZCNT, MOVBE, XSAVE - ``-march=x86-64-v4``: AVX512F, AVX512BW, AVX512CD, AVX512DQ, AVX512VL +`Intel AVX10 ISA

[clang] [AVX10][Doc] Add documentation about AVX10 options and their attentions (PR #77925)

2024-01-12 Thread Evgenii Kudriashov via cfe-commits
@@ -3963,6 +3963,60 @@ implicitly included in later levels. - ``-march=x86-64-v3``: (close to Haswell) AVX, AVX2, BMI1, BMI2, F16C, FMA, LZCNT, MOVBE, XSAVE - ``-march=x86-64-v4``: AVX512F, AVX512BW, AVX512CD, AVX512DQ, AVX512VL +`Intel AVX10 ISA

[clang] [llvm] [CMake][PGO] Build Sema.cpp to generate profdata for PGO builds (PR #77347)

2024-01-12 Thread Chris B via cfe-commits
@@ -26,9 +30,23 @@ if(LLVM_BUILD_INSTRUMENTED) message(STATUS "To enable merging PGO data LLVM_PROFDATA has to point to llvm-profdata") else() add_custom_target(generate-profdata - COMMAND "${Python3_EXECUTABLE}" ${CMAKE_CURRENT_SOURCE_DIR}/perf-helper.py

[clang-tools-extra] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-12 Thread Bhuminjay Soni via cfe-commits
https://github.com/11happy updated https://github.com/llvm/llvm-project/pull/77816 >From 1883d987b2f83adaef05fdb47ae25c7b06582a64 Mon Sep 17 00:00:00 2001 From: 11happy Date: Fri, 12 Jan 2024 00:02:46 +0530 Subject: [PATCH 01/12] Add readability check to suggest replacement of conditional

[clang] [Clang] Amend SME attributes with support for ZT0. (PR #77941)

2024-01-12 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 9803de0e8e3abbbc94a4265d5847db435897a384 6b8d1c8cc772a14a820ab1fdcd6d368b0117d170 --

[clang] [clang] Add test for CWG1807 (PR #77637)

2024-01-12 Thread Erich Keane via cfe-commits
@@ -0,0 +1,28 @@ +// RUN: %clang_cc1 -std=c++98 %s -triple x86_64-linux-gnu -emit-llvm -o - -fexceptions -fcxx-exceptions -pedantic-errors | llvm-cxxfilt | FileCheck %s --check-prefixes CHECK,CXX98 +// RUN: %clang_cc1 -std=c++11 %s -triple x86_64-linux-gnu -emit-llvm -o -

[clang] [clang] Add test for CWG1807 (PR #77637)

2024-01-12 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. 1 nit for readability sake, else is good enough. https://github.com/llvm/llvm-project/pull/77637 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang] Add test for CWG1807 (PR #77637)

2024-01-12 Thread Erich Keane via cfe-commits
@@ -0,0 +1,28 @@ +// RUN: %clang_cc1 -std=c++98 %s -triple x86_64-linux-gnu -emit-llvm -o - -fexceptions -fcxx-exceptions -pedantic-errors | llvm-cxxfilt | FileCheck %s --check-prefixes CHECK,CXX98 +// RUN: %clang_cc1 -std=c++11 %s -triple x86_64-linux-gnu -emit-llvm -o -

[clang] [clang] Add test for CWG1807 (PR #77637)

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

[clang] [clang] Add test for CWG1807 (PR #77637)

2024-01-12 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll updated https://github.com/llvm/llvm-project/pull/77637 >From 545ee4900e48b186e1c9fff93dc62a459ee19754 Mon Sep 17 00:00:00 2001 From: Vlad Serebrennikov Date: Wed, 10 Jan 2024 20:27:53 +0300 Subject: [PATCH 1/6] [clang] Add test for CWG1807 The test checks that

[clang] 6f55c13 - [clang[test] Require x86 target for new tests

2024-01-12 Thread David Spickett via cfe-commits
Author: David Spickett Date: 2024-01-12T16:08:52Z New Revision: 6f55c134d4aaa9eab9ef53886c2532d6da72ca47 URL: https://github.com/llvm/llvm-project/commit/6f55c134d4aaa9eab9ef53886c2532d6da72ca47 DIFF: https://github.com/llvm/llvm-project/commit/6f55c134d4aaa9eab9ef53886c2532d6da72ca47.diff

[clang] [clang][analyzer] Add function 'fprintf' to StreamChecker. (PR #77613)

2024-01-12 Thread Balázs Kéri via cfe-commits
https://github.com/balazske closed https://github.com/llvm/llvm-project/pull/77613 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 8550e88 - [clang][analyzer] Add function 'fprintf' to StreamChecker. (#77613)

2024-01-12 Thread via cfe-commits
Author: Balázs Kéri Date: 2024-01-12T17:00:14+01:00 New Revision: 8550e8845c4fe1aea3bd3d69bcc33d33040b1f13 URL: https://github.com/llvm/llvm-project/commit/8550e8845c4fe1aea3bd3d69bcc33d33040b1f13 DIFF: https://github.com/llvm/llvm-project/commit/8550e8845c4fe1aea3bd3d69bcc33d33040b1f13.diff

[clang] [coroutines][coro_lifetimebound] Detect lifetime issues with lambda captures (PR #77066)

2024-01-12 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 updated https://github.com/llvm/llvm-project/pull/77066 >From 3e0d0ab6c4fc6cba68285816a95e423bc18e8e55 Mon Sep 17 00:00:00 2001 From: Utkarsh Saxena Date: Fri, 5 Jan 2024 10:11:20 +0100 Subject: [PATCH 1/7] [coroutines] Detect lifetime issues with coroutine lambda

[clang-tools-extra] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-12 Thread via cfe-commits
@@ -0,0 +1,35 @@ +// RUN: %check_clang_tidy %s readability-use-std-min-max %t + +void foo() { + int value1,value2,value3; + short value4; + + // CHECK-MESSAGES: :[[@LINE+1]]:3: warning: use `std::max` instead of `<` [readability-use-std-min-max] + if (value1 < value2) +

[clang-tools-extra] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-12 Thread via cfe-commits
@@ -0,0 +1,33 @@ +.. title:: clang-tidy - readability-use-std-min-max + +readability-use-std-min-max +=== + +Replaces certain conditional statements with equivalent ``std::min`` or ``std::max`` expressions, +improving readability and promoting the use of

[clang-tools-extra] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-12 Thread via cfe-commits
@@ -0,0 +1,33 @@ +.. title:: clang-tidy - readability-use-std-min-max + +readability-use-std-min-max +=== + +Replaces certain conditional statements with equivalent ``std::min`` or ``std::max`` expressions, EugeneZelenko wrote: Please

[clang-tools-extra] Add clang-tidy check to suggest replacement of conditional statement with std::min/std::max (PR #77816)

2024-01-12 Thread via cfe-commits
@@ -0,0 +1,97 @@ +//===--- UseStdMinMaxCheck.cpp - clang-tidy ---===// +// +// 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:

[clang] [clang][analyzer] Improve modeling of 'fseeko' and 'ftello' in StdLibraryFunctionsChecker (PR #77902)

2024-01-12 Thread Balázs Kéri via cfe-commits
@@ -2859,13 +2859,19 @@ void StdLibraryFunctionsChecker::initFunctionSummaries( "fseeko", Signature(ArgTypes{FilePtrTy, Off_tTy, IntTy}, RetType{IntTy}), Summary(NoEvalCall) -.Case(ReturnsZeroOrMinusOne, ErrnoIrrelevant) -

[clang] [clang][analyzer] Improve modeling of 'fseeko' and 'ftello' in StdLibraryFunctionsChecker (PR #77902)

2024-01-12 Thread Balázs Kéri via cfe-commits
@@ -2859,13 +2859,19 @@ void StdLibraryFunctionsChecker::initFunctionSummaries( "fseeko", Signature(ArgTypes{FilePtrTy, Off_tTy, IntTy}, RetType{IntTy}), Summary(NoEvalCall) -.Case(ReturnsZeroOrMinusOne, ErrnoIrrelevant) -

[clang-tools-extra] [clang-tidy] Fix false-positives in misc-static-assert caused by non-constexpr variables (PR #77203)

2024-01-12 Thread Justin Cady via cfe-commits
https://github.com/justincady approved this pull request. Context: I have limited experience writing AST matchers, but I saw [the request for reviewers](https://discourse.llvm.org/t/clang-tidy-18-reviewers-wanted/76108). I'm basing this review on that limited experience and the tests put in

[clang] [llvm] [clang-tools-extra] [compiler-rt] [flang] [libcxx] [Clang][Sema] Fix qualifier restriction of overriden methods (PR #71696)

2024-01-12 Thread Aaron Ballman via cfe-commits
@@ -289,3 +289,29 @@ namespace PR8168 { static void foo() {} // expected-error{{'static' member function 'foo' overrides a virtual function}} }; } + +namespace T13 { AaronBallman wrote: I'd like to see additional test cases involving type aliases with

[libcxx] [clang-tools-extra] [compiler-rt] [llvm] [flang] [clang] [Clang][Sema] Fix qualifier restriction of overriden methods (PR #71696)

2024-01-12 Thread Aaron Ballman via cfe-commits
@@ -799,6 +799,11 @@ Bug Fixes to C++ Support completes (except deduction guides). Fixes: (`#59827 `_) +- Clang now reports error when overriden method's non-class return type drops + qualifiers, or qualifiers of class

[clang] [Clang][SME] Detect always_inline used with mismatched streaming attributes (PR #77936)

2024-01-12 Thread Sam Tebbs via cfe-commits
https://github.com/SamTebbs33 updated https://github.com/llvm/llvm-project/pull/77936 >From bbc6c11cd3def5acbb2ba2f2ddc45df2c399f9d6 Mon Sep 17 00:00:00 2001 From: Samuel Tebbs Date: Wed, 10 Jan 2024 14:57:04 + Subject: [PATCH 1/2] [Clang][SME] Detect always_inline used with mismatched

[clang] [coroutines][coro_lifetimebound] Detect lifetime issues with lambda captures (PR #77066)

2024-01-12 Thread Utkarsh Saxena via cfe-commits
@@ -297,6 +297,26 @@ struct ReadySuspendResumeResult { bool IsInvalid; }; +// Adds [[clang::coro_wrapper]] and [[clang::coro_disable_lifetimebound]] +// attributes to `get_return_object`. +static void handleGetReturnObject(Sema , MemberExpr *ME) { + if (!ME ||

[clang] [coroutines][coro_lifetimebound] Detect lifetime issues with lambda captures (PR #77066)

2024-01-12 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 updated https://github.com/llvm/llvm-project/pull/77066 >From 3e0d0ab6c4fc6cba68285816a95e423bc18e8e55 Mon Sep 17 00:00:00 2001 From: Utkarsh Saxena Date: Fri, 5 Jan 2024 10:11:20 +0100 Subject: [PATCH 1/6] [coroutines] Detect lifetime issues with coroutine lambda

[clang] [llvm] [LLVM][DWARF] Fix accelerator table switching between CU and TU (PR #77511)

2024-01-12 Thread Alexander Yermolovich via cfe-commits
https://github.com/ayermolo closed https://github.com/llvm/llvm-project/pull/77511 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] d199ab4 - [LLVM][DWARF] Fix accelerator table switching between CU and TU (#77511)

2024-01-12 Thread via cfe-commits
Author: Alexander Yermolovich Date: 2024-01-12T07:01:17-08:00 New Revision: d199ab469949b104bc4fbb888251ee184fd53de1 URL: https://github.com/llvm/llvm-project/commit/d199ab469949b104bc4fbb888251ee184fd53de1 DIFF:

[clang] [clang][Interp] Diagnose reads from non-const global variables (PR #71919)

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

[clang] [clang][Interp] Diagnose reads from non-const global variables (PR #71919)

2024-01-12 Thread Aaron Ballman via cfe-commits
@@ -1005,12 +1008,23 @@ bool SetThisField(InterpState , CodePtr OpPC, uint32_t I) { template ::T> bool GetGlobal(InterpState , CodePtr OpPC, uint32_t I) { const Block *B = S.P.getGlobal(I); + + if (!CheckConstant(S, OpPC, B->getDescriptor())) +return false; if

[clang] [clang][Interp] Diagnose reads from non-const global variables (PR #71919)

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

[clang] [Clang][SME] Detect always_inline used with mismatched streaming attributes (PR #77936)

2024-01-12 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 124efcaa973306ce42633cea07ed3cf55d63afde bbc6c11cd3def5acbb2ba2f2ddc45df2c399f9d6 --

[clang] [BoundsSafety] Initial documentation for -fbounds-safety (PR #70749)

2024-01-12 Thread Aaron Ballman via cfe-commits
@@ -0,0 +1,362 @@ +== +``-fbounds-safety``: Enforcing bounds safety for C +== + +.. contents:: + :local: + +Overview + + +``-fbounds-safety`` is a C extension to enforce

[clang] [BoundsSafety] Initial documentation for -fbounds-safety (PR #70749)

2024-01-12 Thread Aaron Ballman via cfe-commits
@@ -0,0 +1,844 @@ +== +``-fbounds-safety``: Enforcing bounds safety for C +== + +.. contents:: + :local: + +Overview + + +``-fbounds-safety`` is a C extension to enforce

[clang] [BoundsSafety] Initial documentation for -fbounds-safety (PR #70749)

2024-01-12 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. Thank you for the updates; the changes LGTM! https://github.com/llvm/llvm-project/pull/70749 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [BoundsSafety] Initial documentation for -fbounds-safety (PR #70749)

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

[clang] [Clang][SME] Detect always_inline used with mismatched streaming attributes (PR #77936)

2024-01-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-aarch64 Author: Sam Tebbs (SamTebbs33) Changes This patch adds an error that is emitted when a streaming function is marked as always_inline and is called from a non-streaming function. --- Full diff:

[clang] [Clang][SME] Detect always_inline used with mismatched streaming attributes (PR #77936)

2024-01-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Sam Tebbs (SamTebbs33) Changes This patch adds an error that is emitted when a streaming function is marked as always_inline and is called from a non-streaming function. --- Full diff: https://github.com/llvm/llvm-project/pull/77936.diff

[clang] [Clang][SME] Detect always_inline used with mismatched streaming attributes (PR #77936)

2024-01-12 Thread Sam Tebbs via cfe-commits
https://github.com/SamTebbs33 edited https://github.com/llvm/llvm-project/pull/77936 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][SME] Detect always_inline used with mismatched streaming attibutes (PR #77936)

2024-01-12 Thread Sam Tebbs via cfe-commits
https://github.com/SamTebbs33 created https://github.com/llvm/llvm-project/pull/77936 This patch adds an error that is emitted when a streaming function is marked as always_inline and is called from a non-streaming function. >From bbc6c11cd3def5acbb2ba2f2ddc45df2c399f9d6 Mon Sep 17 00:00:00

[clang] [llvm] [X86] Use vXi1 for `k` constraint in inline asm (PR #77733)

2024-01-12 Thread Phoebe Wang via cfe-commits
phoebewang wrote: > Should we add test coverage for the gpr <-> mask transfers? Is the concern about existing BC files using gpr? It's covered by existing test case, e.g., function `@a` in pr41678.ll We don't remove the iN type support in X86ISelLowering.cpp, but add extra vXi1 support.

[clang] [llvm] [lld] [libcxx] [openmp] [mlir] [libc++] Deprecate the _LIBCPP_ENABLE_CXX20_REMOVED_ALLOCATOR_MEMBERS macro (PR #77692)

2024-01-12 Thread Louis Dionne via cfe-commits
https://github.com/ldionne closed https://github.com/llvm/llvm-project/pull/77692 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [lld] [llvm] [AMDGPU] Introduce GFX9/10.1/10.3/11 Generic Targets (PR #76955)

2024-01-12 Thread Pierre van Houtryve via cfe-commits
@@ -520,6 +520,106 @@ Every processor supports every OS ABI (see :ref:`amdgpu-os`) with the following === === = = === === == +Generic processors also exist. They group

[clang] [flang] [lld] [llvm] [AMDGPU] Introduce GFX9/10.1/10.3/11 Generic Targets (PR #76955)

2024-01-12 Thread Pierre van Houtryve via cfe-commits
@@ -520,6 +520,106 @@ Every processor supports every OS ABI (see :ref:`amdgpu-os`) with the following === === = = === === == +Generic processors also exist. They group

[llvm] [clang] [X86] Use vXi1 for `k` constraint in inline asm (PR #77733)

2024-01-12 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon commented: Should we add test coverage for the gpr <-> mask transfers? https://github.com/llvm/llvm-project/pull/77733 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [AVX10][Doc] Add documentation about AVX10 options and their attentions (PR #77925)

2024-01-12 Thread Phoebe Wang via cfe-commits
https://github.com/phoebewang updated https://github.com/llvm/llvm-project/pull/77925 >From cc0f2b24299bdfc9216ee87ab1aba08707f95503 Mon Sep 17 00:00:00 2001 From: Phoebe Wang Date: Fri, 12 Jan 2024 21:29:50 +0800 Subject: [PATCH 1/2] [AVX10][Doc] Add documentation about AVX10 options and

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

2024-01-12 Thread Ilya Biryukov via cfe-commits
ilya-biryukov wrote: @owenca, @HazardyKnusperkeks could you please take another look and approve if this looks good to you? I believe all comments should be addressed at this point. https://github.com/llvm/llvm-project/pull/76804 ___ cfe-commits

[clang] 7700ea1 - [OpenACC] Implement the 'rest' of the simple 'var-list' clauses

2024-01-12 Thread via cfe-commits
Author: erichkeane Date: 2024-01-12T06:14:48-08:00 New Revision: 7700ea103187ba6e547deb501ca4a1402e8a23fd URL: https://github.com/llvm/llvm-project/commit/7700ea103187ba6e547deb501ca4a1402e8a23fd DIFF: https://github.com/llvm/llvm-project/commit/7700ea103187ba6e547deb501ca4a1402e8a23fd.diff

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

2024-01-12 Thread Ilya Biryukov via cfe-commits
@@ -1698,8 +1698,6 @@ FormatStyle getGoogleStyle(FormatStyle::LanguageKind Language) { /*BasedOnStyle=*/"google", }, }; - GoogleStyle.AttributeMacros.push_back("GUARDED_BY"); ilya-biryukov wrote: I think we should postpone the inclusion of

[clang] [Clang][Sema] improve sema check of clang::musttail attribute (PR #77727)

2024-01-12 Thread Erich Keane via cfe-commits
https://github.com/erichkeane commented: Just needs a release note, else LGTM. https://github.com/llvm/llvm-project/pull/77727 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Clang] Make sdot builtins available to SME (PR #77792)

2024-01-12 Thread Kerry McLaughlin via cfe-commits
https://github.com/kmclaughlin-arm approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/77792 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2024-01-12 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov updated https://github.com/llvm/llvm-project/pull/76804 >From d8598a382fb1496a96d6ff8317c06cf73606ad84 Mon Sep 17 00:00:00 2001 From: Ilya Biryukov Date: Wed, 3 Jan 2024 11:07:17 +0100 Subject: [PATCH 1/4] [Format] Fix isStartOfName to recognize attributes

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

2024-01-12 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov updated https://github.com/llvm/llvm-project/pull/76804 >From d8598a382fb1496a96d6ff8317c06cf73606ad84 Mon Sep 17 00:00:00 2001 From: Ilya Biryukov Date: Wed, 3 Jan 2024 11:07:17 +0100 Subject: [PATCH 1/3] [Format] Fix isStartOfName to recognize attributes

[flang] [clang] [flang][Driver] Support -pthread in the frontend (PR #77360)

2024-01-12 Thread Kareem Ergawy via cfe-commits
https://github.com/ergawy approved this pull request. https://github.com/llvm/llvm-project/pull/77360 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[flang] [clang] [flang][Driver] Support -pthread in the frontend (PR #77360)

2024-01-12 Thread Leandro Lupori via cfe-commits
luporl wrote: > Could someone test this on AArch64 and/or Windows just to make sure that it > passes there? Works fine on AArch64. https://github.com/llvm/llvm-project/pull/77360 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang][Interp] Implement IntegralAP::{div, rem} (PR #72614)

2024-01-12 Thread Aaron Ballman via cfe-commits
@@ -44,6 +44,24 @@ static_assert(MulA * MulB == 50, ""); // ref-error {{not an integral constant ex static_assert(MulA * 5 == 25, ""); static_assert(-1 * MulB == -7, ""); + +constexpr _BitInt(4) DivA = 2; +constexpr _BitInt(2) DivB = 1; +static_assert(DivA / DivB == 2, "");

[clang] [clang][Interp] Implement IntegralAP::{div, rem} (PR #72614)

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

[clang] [clang][Interp] Implement IntegralAP::{div, rem} (PR #72614)

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

[clang] [AVX10][Doc] Add documentation about AVX10 options and their attentions (PR #77925)

2024-01-12 Thread Simon Pilgrim via cfe-commits
@@ -3963,6 +3963,60 @@ implicitly included in later levels. - ``-march=x86-64-v3``: (close to Haswell) AVX, AVX2, BMI1, BMI2, F16C, FMA, LZCNT, MOVBE, XSAVE - ``-march=x86-64-v4``: AVX512F, AVX512BW, AVX512CD, AVX512DQ, AVX512VL +`Intel AVX10 ISA

[clang] [AVX10][Doc] Add documentation about AVX10 options and their attentions (PR #77925)

2024-01-12 Thread Simon Pilgrim via cfe-commits
@@ -3963,6 +3963,60 @@ implicitly included in later levels. - ``-march=x86-64-v3``: (close to Haswell) AVX, AVX2, BMI1, BMI2, F16C, FMA, LZCNT, MOVBE, XSAVE - ``-march=x86-64-v4``: AVX512F, AVX512BW, AVX512CD, AVX512DQ, AVX512VL +`Intel AVX10 ISA

[clang] [AVX10][Doc] Add documentation about AVX10 options and their attentions (PR #77925)

2024-01-12 Thread Simon Pilgrim via cfe-commits
@@ -3963,6 +3963,60 @@ implicitly included in later levels. - ``-march=x86-64-v3``: (close to Haswell) AVX, AVX2, BMI1, BMI2, F16C, FMA, LZCNT, MOVBE, XSAVE - ``-march=x86-64-v4``: AVX512F, AVX512BW, AVX512CD, AVX512DQ, AVX512VL +`Intel AVX10 ISA

[clang] [AVX10][Doc] Add documentation about AVX10 options and their attentions (PR #77925)

2024-01-12 Thread Simon Pilgrim via cfe-commits
@@ -3963,6 +3963,60 @@ implicitly included in later levels. - ``-march=x86-64-v3``: (close to Haswell) AVX, AVX2, BMI1, BMI2, F16C, FMA, LZCNT, MOVBE, XSAVE - ``-march=x86-64-v4``: AVX512F, AVX512BW, AVX512CD, AVX512DQ, AVX512VL +`Intel AVX10 ISA

[clang] [AVX10][Doc] Add documentation about AVX10 options and their attentions (PR #77925)

2024-01-12 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon commented: A few minors https://github.com/llvm/llvm-project/pull/77925 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AVX10][Doc] Add documentation about AVX10 options and their attentions (PR #77925)

2024-01-12 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon edited https://github.com/llvm/llvm-project/pull/77925 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Reapply Handle templated operators with reversed arguments (PR #72213)

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

[clang] 460ff58 - [clang] Reapply Handle templated operators with reversed arguments (#72213)

2024-01-12 Thread via cfe-commits
Author: Utkarsh Saxena Date: 2024-01-12T15:03:01+01:00 New Revision: 460ff58f62456a1f3ccf61ec9cf9d10781bd41bb URL: https://github.com/llvm/llvm-project/commit/460ff58f62456a1f3ccf61ec9cf9d10781bd41bb DIFF:

[clang] 4556813 - [Sema] Use lexical DC for friend functions when getting constraint instantiation args (#77552)

2024-01-12 Thread via cfe-commits
Author: antangelo Date: 2024-01-12T09:02:01-05:00 New Revision: 45568135cbb31bb3b345a8355134970742248120 URL: https://github.com/llvm/llvm-project/commit/45568135cbb31bb3b345a8355134970742248120 DIFF: https://github.com/llvm/llvm-project/commit/45568135cbb31bb3b345a8355134970742248120.diff

[compiler-rt] [libc] [clang] [clang-tools-extra] [libunwind] [llvm] [libcxx] [lldb] [lld] [libcxxabi] [flang] [Sema] Use lexical DC for friend functions when getting constraint instantiation args (PR

2024-01-12 Thread via cfe-commits
https://github.com/antangelo closed https://github.com/llvm/llvm-project/pull/77552 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Reapply Handle templated operators with reversed arguments (PR #72213)

2024-01-12 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 updated https://github.com/llvm/llvm-project/pull/72213 >From b0183f23ffad814080e82c725ee4cb7902aea23f Mon Sep 17 00:00:00 2001 From: Utkarsh Saxena Date: Fri, 12 Jan 2024 13:38:15 + Subject: [PATCH 1/4] rebase --- clang/docs/ReleaseNotes.rst |

[clang] [clang] Reapply Handle templated operators with reversed arguments (PR #72213)

2024-01-12 Thread Utkarsh Saxena via cfe-commits
@@ -10088,9 +10088,13 @@ static bool allowAmbiguity(ASTContext , const FunctionDecl *F1, const FunctionDecl *F2) { if (declaresSameEntity(F1, F2)) return true; - if (F1->isTemplateInstantiation() && F2->isTemplateInstantiation() && -

[clang] [clang] Reapply Handle templated operators with reversed arguments (PR #72213)

2024-01-12 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 updated https://github.com/llvm/llvm-project/pull/72213 >From b0183f23ffad814080e82c725ee4cb7902aea23f Mon Sep 17 00:00:00 2001 From: Utkarsh Saxena Date: Fri, 12 Jan 2024 13:38:15 + Subject: [PATCH 1/2] rebase --- clang/docs/ReleaseNotes.rst |

[clang] [clang] Reapply Handle templated operators with reversed arguments (PR #72213)

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

[clang] [clang] Reapply Handle templated operators with reversed arguments (PR #72213)

2024-01-12 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 updated https://github.com/llvm/llvm-project/pull/72213 >From b0183f23ffad814080e82c725ee4cb7902aea23f Mon Sep 17 00:00:00 2001 From: Utkarsh Saxena Date: Fri, 12 Jan 2024 13:38:15 + Subject: [PATCH] rebase --- clang/docs/ReleaseNotes.rst | 21

<    1   2   3   4   5   >