[mlir] [llvm] [libc] [libcxx] [clang-tools-extra] [clang] [compiler-rt] [lldb] [lld] [MLIR][LLVM] Add Continuous Loop Peeling transform to SCF (PR #71555)

2024-01-08 Thread Matthias Springer via cfe-commits
@@ -0,0 +1,46 @@ +// RUN: mlir-opt %s -scf-for-loop-continuous-peeling=convert-single-iter-loops-to-if=true -split-input-file | FileCheck %s + +#map = affine_map<(d0, d1)[s0] -> (s0, d0 - d1)> +func.func @foo(%ub: index) -> index { + %c0 = arith.constant 0 : index + %step = ar

[mlir] [clang-tools-extra] [libcxx] [lld] [libc] [clang] [lldb] [llvm] [compiler-rt] [MLIR][LLVM] Add Continuous Loop Peeling transform to SCF (PR #71555)

2024-01-08 Thread Matthias Springer via cfe-commits
@@ -105,6 +106,167 @@ static void specializeForLoopForUnrolling(ForOp op) { op.erase(); } +/// Create a new for loop for the remaining iterations (partiaIteration) +/// after a for loop has been peeled. This is followed by correcting the +/// loop bounds for both loops given

[llvm] [libc] [lldb] [mlir] [libcxx] [clang] [clang-tools-extra] [compiler-rt] [lld] [MLIR][LLVM] Add Continuous Loop Peeling transform to SCF (PR #71555)

2024-01-08 Thread Matthias Springer via cfe-commits
@@ -105,6 +106,167 @@ static void specializeForLoopForUnrolling(ForOp op) { op.erase(); } +/// Create a new for loop for the remaining iterations (partiaIteration) +/// after a for loop has been peeled. This is followed by correcting the +/// loop bounds for both loops given

[mlir] [libc] [clang-tools-extra] [libcxx] [clang] [llvm] [lld] [compiler-rt] [lldb] [MLIR][LLVM] Add Continuous Loop Peeling transform to SCF (PR #71555)

2024-01-08 Thread Matthias Springer via cfe-commits
@@ -105,6 +106,167 @@ static void specializeForLoopForUnrolling(ForOp op) { op.erase(); } +/// Create a new for loop for the remaining iterations (partiaIteration) +/// after a for loop has been peeled. This is followed by correcting the +/// loop bounds for both loops given

[clang] [lld] [compiler-rt] [lldb] [libcxx] [clang-tools-extra] [mlir] [libc] [llvm] [MLIR][LLVM] Add Continuous Loop Peeling transform to SCF (PR #71555)

2024-01-08 Thread Matthias Springer via cfe-commits
@@ -0,0 +1,46 @@ +// RUN: mlir-opt %s -scf-for-loop-continuous-peeling=convert-single-iter-loops-to-if=true -split-input-file | FileCheck %s + +#map = affine_map<(d0, d1)[s0] -> (s0, d0 - d1)> +func.func @foo(%ub: index) -> index { + %c0 = arith.constant 0 : index + %step = ar

[mlir] [clang-tools-extra] [lld] [lldb] [clang] [libcxx] [llvm] [compiler-rt] [libc] [MLIR][LLVM] Add Continuous Loop Peeling transform to SCF (PR #71555)

2024-01-08 Thread Matthias Springer via cfe-commits
@@ -189,16 +188,17 @@ LogicalResult scf::canonicalizeMinMaxOpInLoop(RewriterBase &rewriter, /// * Inside the peeled loop: min(step, ub - iv) == step /// * Inside the partial iteration: min(step, ub - iv) == ub - iv /// -/// Returns `success` if the given operation was replaced

[libcxx] [libc] [lldb] [clang-tools-extra] [llvm] [mlir] [compiler-rt] [lld] [clang] [MLIR][LLVM] Add Continuous Loop Peeling transform to SCF (PR #71555)

2024-01-08 Thread Matthias Springer via cfe-commits
@@ -105,6 +106,167 @@ static void specializeForLoopForUnrolling(ForOp op) { op.erase(); } +/// Create a new for loop for the remaining iterations (partiaIteration) +/// after a for loop has been peeled. This is followed by correcting the +/// loop bounds for both loops given

[clang-tools-extra] [lldb] [libcxx] [libc] [compiler-rt] [clang] [llvm] [mlir] [lld] [MLIR][LLVM] Add Continuous Loop Peeling transform to SCF (PR #71555)

2024-01-08 Thread Matthias Springer via cfe-commits
@@ -105,6 +106,167 @@ static void specializeForLoopForUnrolling(ForOp op) { op.erase(); } +/// Create a new for loop for the remaining iterations (partiaIteration) +/// after a for loop has been peeled. This is followed by correcting the +/// loop bounds for both loops given

[lldb] [clang-tools-extra] [compiler-rt] [mlir] [libcxx] [clang] [libc] [lld] [llvm] [MLIR][LLVM] Add Continuous Loop Peeling transform to SCF (PR #71555)

2024-01-08 Thread Matthias Springer via cfe-commits
@@ -105,6 +106,167 @@ static void specializeForLoopForUnrolling(ForOp op) { op.erase(); } +/// Create a new for loop for the remaining iterations (partiaIteration) matthias-springer wrote: typo: partiaIteration https://github.com/llvm/llvm-project/pull/715

[llvm] [lld] [lldb] [mlir] [clang] [libc] [clang-tools-extra] [compiler-rt] [libcxx] [MLIR][LLVM] Add Continuous Loop Peeling transform to SCF (PR #71555)

2024-01-08 Thread Matthias Springer via cfe-commits
@@ -105,6 +106,167 @@ static void specializeForLoopForUnrolling(ForOp op) { op.erase(); } +/// Create a new for loop for the remaining iterations (partiaIteration) +/// after a for loop has been peeled. This is followed by correcting the +/// loop bounds for both loops given

[clang] [AST] Teach TextNodeDumper to print the "implicit" bit for coroutine AST nodes (PR #77311)

2024-01-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Haojian Wu (hokein) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/77311.diff 3 Files Affected: - (modified) clang/include/clang/AST/TextNodeDumper.h (+2) - (modified) clang/lib/AST/TextNodeDumper.cpp (+10) - (added

[clang] [clang] pop explicit to keep context stack balance (PR #77312)

2024-01-08 Thread Qizhi Hu via cfe-commits
https://github.com/jcsxky created https://github.com/llvm/llvm-project/pull/77312 None >From d0a51d88d54420570bfa351e8ca70777ea15e4b7 Mon Sep 17 00:00:00 2001 From: huqizhi Date: Mon, 8 Jan 2024 22:15:09 +0800 Subject: [PATCH] [clang] pop explicit to keep context stack balance --- clang/lib/

[clang] [clang] pop explicit to keep context stack balance (PR #77312)

2024-01-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Qizhi Hu (jcsxky) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/77312.diff 1 Files Affected: - (modified) clang/lib/Parse/ParseDecl.cpp (+6-1) ``diff diff --git a/clang/lib/Parse/ParseDecl.cpp b/clang/lib/

[clang] [AST] Teach TextNodeDumper to print the "implicit" bit for coroutine AST nodes (PR #77311)

2024-01-08 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 d02c7931d1be794a230943e300fec4172032e6a8 b0efa2e20f1ca7bc9e18b81231574895fe2281c3 --

[clang] [clang][ASTImporter] Only reorder fields of RecordDecls (PR #77079)

2024-01-08 Thread Michael Buch via cfe-commits
Michael137 wrote: Tried to find a way to test "objective-c fields aren't reordered". After talking to some objective-c experts, there doesn't seem to be a good way to force such "incorrect field order", because it's strictly an in-order language. Reducing the LLDB crashes has been tricky becau

[flang] [mlir] [clang] [Flang][OpenMP][MLIR] Add support for -nogpulib option (PR #71045)

2024-01-08 Thread via cfe-commits
agozillon wrote: It would be very nice to have this option added to Flang in the near future, as this option would allow the OpenMP libomptarget runtime tests for offload to be ran without failure due to this missing option. I believe we are currently in the process of setting up a buildbot th

[clang] [Sema] Clean up -Wc++11-narrowing-const-reference code after #76094. NFC (PR #77278)

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

[clang] [clang] Fix assertion failure when initializing union with FAM (PR #77298)

2024-01-08 Thread Nikita Popov via cfe-commits
https://github.com/nikic updated https://github.com/llvm/llvm-project/pull/77298 >From 68e21b7604964b7b391d9a077ca52175af21b65a Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Mon, 8 Jan 2024 12:41:34 +0100 Subject: [PATCH 1/2] [clang] Fix assertion failure when initializing union with FAM W

[flang] [mlir] [clang] [Flang][OpenMP][MLIR] Add support for -nogpulib option (PR #71045)

2024-01-08 Thread Jan Patrick Lehr via cfe-commits
jplehr wrote: We have the buildbot now up in staging: https://lab.llvm.org/staging/#/builders/188 https://github.com/llvm/llvm-project/pull/71045 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/c

[clang] [Clang] Fix IsOverload for function templates (PR #77323)

2024-01-08 Thread via cfe-commits
https://github.com/cor3ntin created https://github.com/llvm/llvm-project/pull/77323 Functions which correspond but have different template parameter lists are not redeclarations. Fixes a regression introduced by af4751 (The patch just moves the template parameters check above if the signature

[clang] [Clang] Fix IsOverload for function templates (PR #77323)

2024-01-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: cor3ntin (cor3ntin) Changes Functions which correspond but have different template parameter lists are not redeclarations. Fixes a regression introduced by af4751 (The patch just moves the template parameters check above if the signature

[clang] [Clang][Sema] Print more static_assert exprs (PR #74852)

2024-01-08 Thread Erich Keane via cfe-commits
@@ -0,0 +1,117 @@ +// RUN: %clang_cc1 -std=c++2a -verify %s + +struct A { + int a, b[3], c; + bool operator==(const A&) const = default; +}; + +constexpr auto a0 = A{0, 0, 3, 4, 5}; + +// expected-note@+1 {{evaluates to '{0, {0, 3, 4}, 5} == {1, {2, 3, 4}, 5}'}} +static_assert(a

[clang] [Clang][NFC] Fix out-of-bounds access (PR #77193)

2024-01-08 Thread Yitzhak Mandelbaum via cfe-commits
https://github.com/ymand approved this pull request. Thanks! https://github.com/llvm/llvm-project/pull/77193 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][NFC] Fix out-of-bounds access (PR #77193)

2024-01-08 Thread Yitzhak Mandelbaum via cfe-commits
@@ -1215,7 +1215,7 @@ class CFG { //======// class BuildOptions { -std::bitset alwaysAddMask; ymand wrote: Maybe add a comment explaining the new size? I see why it might be obvious,

[clang] [Clang][NFC] Fix out-of-bounds access (PR #77193)

2024-01-08 Thread Yitzhak Mandelbaum via cfe-commits
https://github.com/ymand edited https://github.com/llvm/llvm-project/pull/77193 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang] [llvm] [LoopVectorize] Refine runtime memory check costs when there is an outer loop (PR #76034)

2024-01-08 Thread David Sherwood via cfe-commits
https://github.com/david-arm updated https://github.com/llvm/llvm-project/pull/76034 >From a4caa47dc8d2db75f6bb2ac3f880da4e1f6bea82 Mon Sep 17 00:00:00 2001 From: David Sherwood Date: Tue, 19 Dec 2023 16:07:33 + Subject: [PATCH 1/2] Add tests showing runtime checks cost with low trip count

[clang] [RISCV] Fix collectNonISAExtFeature returning negative extension features (PR #76962)

2024-01-08 Thread Piyou Chen via cfe-commits
https://github.com/BeMg approved this pull request. https://github.com/llvm/llvm-project/pull/76962 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [ARM] arm_acle.h add Coprocessor Instrinsics (PR #75440)

2024-01-08 Thread David Green via cfe-commits
https://github.com/davemgreen approved this pull request. Thanks. LGTM https://github.com/llvm/llvm-project/pull/75440 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 16cd344 - [RISCV] Fix collectNonISAExtFeature returning negative extension features (#76962)

2024-01-08 Thread via cfe-commits
Author: Luke Lau Date: 2024-01-08T22:11:54+07:00 New Revision: 16cd344380aa89a4bc47939ae65fd59fe8c77181 URL: https://github.com/llvm/llvm-project/commit/16cd344380aa89a4bc47939ae65fd59fe8c77181 DIFF: https://github.com/llvm/llvm-project/commit/16cd344380aa89a4bc47939ae65fd59fe8c77181.diff LOG:

[clang] [RISCV] Fix collectNonISAExtFeature returning negative extension features (PR #76962)

2024-01-08 Thread Luke Lau via cfe-commits
https://github.com/lukel97 closed https://github.com/llvm/llvm-project/pull/76962 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] pop explicit to keep context stack balance (PR #77312)

2024-01-08 Thread via cfe-commits
cor3ntin wrote: Can you explain why this change is needed, and provide a test case? (in `clang/test/Parser`) Thanks https://github.com/llvm/llvm-project/pull/77312 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/

[clang-tools-extra] [llvm] [clang] Dont alter cold function alignment unless using Os (PR #72387)

2024-01-08 Thread Paul T Robinson via cfe-commits
pogo59 wrote: > Edit: Actually we still have the problem of when in LLVM not knowing if > optimze-by-size got set on the cold funtion by it being cold or if Os was > used. Not sure I understand the question (sorry I missed this comment when it was made). The suggestion is that for our target,

[clang] [Clang][NFC] Fix out-of-bounds access (PR #77193)

2024-01-08 Thread Krystian Stasiowski via cfe-commits
https://github.com/sdkrystian updated https://github.com/llvm/llvm-project/pull/77193 >From b737ce548ad554bc351820cedd693b9f8737be45 Mon Sep 17 00:00:00 2001 From: Krystian Stasiowski Date: Sat, 6 Jan 2024 07:26:06 -0500 Subject: [PATCH] [Clang][NFC] Fix out-of-bounds access --- clang/include

[clang] [Clang][NFC] Fix out-of-bounds access (PR #77193)

2024-01-08 Thread Krystian Stasiowski via cfe-commits
@@ -1215,7 +1215,7 @@ class CFG { //======// class BuildOptions { -std::bitset alwaysAddMask; sdkrystian wrote: @ymand Fair enough, I added one. https://github.com/llvm/llvm-project

[clang] [flang] [Flang][Driver] Enable gpulibc/nogpulibc options for Flang, which allows linking of GPU LIBC for the fortran and OpenMP runtime (PR #77135)

2024-01-08 Thread via cfe-commits
https://github.com/agozillon updated https://github.com/llvm/llvm-project/pull/77135 >From 71fee19666806c331555fdb9453d792063f8ffd8 Mon Sep 17 00:00:00 2001 From: Andrew Gozillon Date: Fri, 5 Jan 2024 14:16:16 -0600 Subject: [PATCH 1/2] [Flang][Driver] Enable gpulibc/nogpulibc options for Flan

[clang] [flang] [Flang][Driver] Enable gpulibc/nogpulibc options for Flang, which allows linking of GPU LIBC for the fortran and OpenMP runtime (PR #77135)

2024-01-08 Thread via cfe-commits
agozillon wrote: Added a similar test for the options to Flang's omp-driver-offload.f90 in the last commit, happy to add more tests if desired, just might need some suggestions if that's the case! https://github.com/llvm/llvm-project/pull/77135 ___

[clang] [Clang] Wide delimiters ('{{{') for expect strings (PR #77326)

2024-01-08 Thread via cfe-commits
https://github.com/sethp created https://github.com/llvm/llvm-project/pull/77326 Prior to this commit, it was impossible to use the simple string matching directives to look for most content that contains `{{`, such as: ``` // expected-note {{my_struct{{1}, 2}}} ``` Which would parse like so:

[clang] [Clang] Wide delimiters ('{{{') for expect strings (PR #77326)

2024-01-08 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 i

[clang] [Clang] Wide delimiters ('{{{') for expect strings (PR #77326)

2024-01-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (sethp) Changes Prior to this commit, it was impossible to use the simple string matching directives to look for most content that contains `{{`, such as: ``` // expected-note {{my_struct{{1}, 2}}} ``` Which would parse like so: ``

[clang] [Clang] Wide delimiters ('{{{') for expect strings (PR #77326)

2024-01-08 Thread via cfe-commits
https://github.com/sethp edited https://github.com/llvm/llvm-project/pull/77326 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Teach TextNodeDumper to print the "implicit" bit for coroutine AST nodes (PR #77311)

2024-01-08 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov approved this pull request. LGTM, other nodes also do this. But please take a look at suggestions for improving the test before landing. https://github.com/llvm/llvm-project/pull/77311 ___ cfe-commits mailing list cfe-c

[clang] [AST] Teach TextNodeDumper to print the "implicit" bit for coroutine AST nodes (PR #77311)

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

[clang] [AST] Teach TextNodeDumper to print the "implicit" bit for coroutine AST nodes (PR #77311)

2024-01-08 Thread Ilya Biryukov via cfe-commits
@@ -0,0 +1,46 @@ +// RUN: %clang_cc1 -triple x86_64-unknown-unknown %s -std=c++20 \ +// RUN:-fsyntax-only -ast-dump -ast-dump-filter test | FileCheck %s + +#include "Inputs/std-coroutine.h" + +using namespace std; + +struct Task { + struct promise_type { +std::suspend_alw

[clang] e6b7c8c - [OpenACC] Implement 'if' clause

2024-01-08 Thread via cfe-commits
Author: erichkeane Date: 2024-01-08T07:33:28-08:00 New Revision: e6b7c8c4951a470cc63a1721bc5f5ac7f3748a2f URL: https://github.com/llvm/llvm-project/commit/e6b7c8c4951a470cc63a1721bc5f5ac7f3748a2f DIFF: https://github.com/llvm/llvm-project/commit/e6b7c8c4951a470cc63a1721bc5f5ac7f3748a2f.diff LO

[clang] [Clang][Sema] Print more static_assert exprs (PR #74852)

2024-01-08 Thread via cfe-commits
https://github.com/sethp updated https://github.com/llvm/llvm-project/pull/74852 >From f281d34a51f662c934f158e4770774b0dc3588a2 Mon Sep 17 00:00:00 2001 From: Seth Pellegrino Date: Thu, 7 Dec 2023 08:45:51 -0800 Subject: [PATCH 1/6] [Clang][Sema] Print more static_assert exprs This change intro

[clang] [llvm] [Clang][RISCV] Move getVScaleRange logic into libLLVMFrontendDriver. NFC (PR #77327)

2024-01-08 Thread Luke Lau via cfe-commits
https://github.com/lukel97 created https://github.com/llvm/llvm-project/pull/77327 In #77277, we would like to be able to reuse the logic for calculating the vscale_range in Flang. This is currently in clang::TargetInfo which is quite C specific, and given that only two targets implement getVSca

[clang] [llvm] [Clang][RISCV] Move getVScaleRange logic into libLLVMFrontendDriver. NFC (PR #77327)

2024-01-08 Thread Luke Lau via cfe-commits
https://github.com/lukel97 edited https://github.com/llvm/llvm-project/pull/77327 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Clang][RISCV] Move getVScaleRange logic into libLLVMFrontendDriver. NFC (PR #77327)

2024-01-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-risc-v Author: Luke Lau (lukel97) Changes In #77277, we would like to be able to reuse the logic for calculating the vscale_range in Flang. This is currently in clang::TargetInfo which is quite C specific, and given that only two targets impleme

[clang] [Clang] Wide delimiters ('{{{') for expect strings (PR #77326)

2024-01-08 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. Looks reasonable to me, thanks! https://github.com/llvm/llvm-project/pull/77326 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix IsOverload for function templates (PR #77323)

2024-01-08 Thread via cfe-commits
cor3ntin wrote: @erichkeane https://github.com/llvm/llvm-project/pull/77323 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [lld] [llvm-driver] Fix usage of `InitLLVM` on Windows (PR #76306)

2024-01-08 Thread Chris B via cfe-commits
llvm-beanz wrote: @aganea, this ends up being a nice way to collapse down a tiny bit of shared tool boilerplate. Thank you! This LGTM, but let's make sure @MaskRay is happy too. https://github.com/llvm/llvm-project/pull/76306 ___ cfe-commits mailing

[clang] [Clang] Fix IsOverload for function templates (PR #77323)

2024-01-08 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. Seems fine to me, I don't see any reason that anything in the middle would cause a problem, so moving this is fine. https://github.com/llvm/llvm-project/pull/77323 ___ cfe-commits mailing lis

[clang] [Clang] Wide delimiters ('{{{') for expect strings (PR #77326)

2024-01-08 Thread Erich Keane via cfe-commits
erichkeane wrote: Can you update https://clang.llvm.org/docs/InternalsManual.html#verifying-diagnostics as well please? It should be in-repo, but we should make sure that keeps up to date here. Else, LGTM, thanks! https://github.com/llvm/llvm-project/pull/77326 _

[clang] [llvm] [AIX][TOC] Add -mtocdata/-mno-tocdata options on AIX (PR #67999)

2024-01-08 Thread via cfe-commits
@@ -245,6 +245,30 @@ class PPCSubtarget : public PPCGenSubtargetInfo { /// True if the GV will be accessed via an indirect symbol. bool isGVIndirectSymbol(const GlobalValue *GV) const; + bool tocDataChecks(unsigned PointerSize, const GlobalVariable *GV) const { --

[clang] [llvm] [AIX][TOC] Add -mtocdata/-mno-tocdata options on AIX (PR #67999)

2024-01-08 Thread via cfe-commits
@@ -245,6 +245,30 @@ class PPCSubtarget : public PPCGenSubtargetInfo { /// True if the GV will be accessed via an indirect symbol. bool isGVIndirectSymbol(const GlobalValue *GV) const; + bool tocDataChecks(unsigned PointerSize, const GlobalVariable *GV) const { --

[llvm] [clang] [AIX][TOC] Add -mtocdata/-mno-tocdata options on AIX (PR #67999)

2024-01-08 Thread via cfe-commits
@@ -2520,7 +2520,9 @@ void PPCAIXAsmPrinter::emitGlobalVariable(const GlobalVariable *GV) { // If the Global Variable has the toc-data attribute, it needs to be emitted // when we emit the .toc section. if (GV->hasAttribute("toc-data")) { -TOCDataGlobalVars.push_back

[clang] [Clang] Wide delimiters ('{{{') for expect strings (PR #77326)

2024-01-08 Thread via cfe-commits
sethp wrote: Ah, I was looking for those docs, thank you! I'll be sure to tweak the description there. https://github.com/llvm/llvm-project/pull/77326 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listi

[clang] [clang][ASTImporter] Only reorder fields of RecordDecls (PR #77079)

2024-01-08 Thread Balázs Kéri via cfe-commits
https://github.com/balazske approved this pull request. This reordering is not a significant feature (and may change in the future) and no test existed before, it is enough (if this exists) if there is a GDB test for the crash. https://github.com/llvm/llvm-project/pull/77079 __

[clang] 34dbadd - [clang][ASTImporter] Only reorder fields of RecordDecls (#77079)

2024-01-08 Thread via cfe-commits
Author: Michael Buch Date: 2024-01-08T15:57:53Z New Revision: 34dbaddc6fa1ce0892ecf3ca06866e7038b2a9b3 URL: https://github.com/llvm/llvm-project/commit/34dbaddc6fa1ce0892ecf3ca06866e7038b2a9b3 DIFF: https://github.com/llvm/llvm-project/commit/34dbaddc6fa1ce0892ecf3ca06866e7038b2a9b3.diff LOG:

[clang] [clang][ASTImporter] Only reorder fields of RecordDecls (PR #77079)

2024-01-08 Thread Michael Buch via cfe-commits
https://github.com/Michael137 closed https://github.com/llvm/llvm-project/pull/77079 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 69066ab - [Clang] Fix IsOverload for function templates (#77323)

2024-01-08 Thread via cfe-commits
Author: cor3ntin Date: 2024-01-08T16:58:48+01:00 New Revision: 69066ab31959968ebcbca71f3872bdedef8fb8cd URL: https://github.com/llvm/llvm-project/commit/69066ab31959968ebcbca71f3872bdedef8fb8cd DIFF: https://github.com/llvm/llvm-project/commit/69066ab31959968ebcbca71f3872bdedef8fb8cd.diff LOG:

[clang] [Clang] Fix IsOverload for function templates (PR #77323)

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

[clang] Improve modeling of 'getcwd' in the StdLibraryFunctionsChecker (PR #77040)

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

[clang] [flang] [mlir] [llvm] [MLIR][LLVM] Add Continuous Loop Peeling transform to SCF (PR #77328)

2024-01-08 Thread via cfe-commits
https://github.com/muneebkhan85 created https://github.com/llvm/llvm-project/pull/77328 This patch adds continuous loop peeling to scf loop transforms in the MLIR backend. This transforms the target loop into a chain of loops, with step sizes that are powers of two and decrease exponentially a

[llvm] [mlir] [clang] [flang] [MLIR][LLVM] Add Continuous Loop Peeling transform to SCF (PR #77328)

2024-01-08 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 i

[clang-tools-extra] [libcxxabi] [flang] [lldb] [mlir] [llvm] [openmp] [compiler-rt] [libcxx] [clang] [libc] [OpenMP] Patch for Support to loop bind clause : Checking Parent Region (PR #76938)

2024-01-08 Thread via cfe-commits
https://github.com/SunilKuravinakop updated https://github.com/llvm/llvm-project/pull/76938 >From 1dcd4703002acdde370a285089008e409043717b Mon Sep 17 00:00:00 2001 From: Sunil Kuravinakop Date: Thu, 4 Jan 2024 04:08:28 -0600 Subject: [PATCH 1/3] Changes uploaded to the phabricator on Dec 16th a

[clang] [Clang] Wide delimiters ('{{{') for expect strings (PR #77326)

2024-01-08 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik commented: Can we add a few tests for this change? https://github.com/llvm/llvm-project/pull/77326 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] move -Wcast-function-type under -Wextra (PR #77178)

2024-01-08 Thread Nick Desaulniers via cfe-commits
@@ -0,0 +1,42 @@ +// RUN: %clang_cc1 %s -fsyntax-only -Wextra -verify nickdesaulniers wrote: If this diagnostic is not already well tested, adding all of these additional unit tests makes sense. But it looks like there's quite a number of existing tests in othe

[clang] [clang-tools-extra] [clang-tidy] Handle C++ structured bindings in `performance-for-range-copy` (PR #77105)

2024-01-08 Thread Felix Berger via cfe-commits
https://github.com/fberger edited https://github.com/llvm/llvm-project/pull/77105 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang] [clang-tidy] Handle C++ structured bindings in `performance-for-range-copy` (PR #77105)

2024-01-08 Thread Felix Berger via cfe-commits
@@ -234,6 +239,22 @@ void positiveOnlyAccessedFieldAsConst() { } } +void positiveOnlyAccessedFieldAsConstBinding() { + for (auto [X, Y] : View>()) { +// CHECK-MESSAGES: [[@LINE-1]]:13: warning: loop variable is copied but +// CHECK-FIXES: for (const auto& [X, Y] : V

[clang] [clang-tools-extra] [clang-tidy] Handle C++ structured bindings in `performance-for-range-copy` (PR #77105)

2024-01-08 Thread Felix Berger via cfe-commits
https://github.com/fberger approved this pull request. https://github.com/llvm/llvm-project/pull/77105 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang-tidy] Handle C++ structured bindings in `performance-for-range-copy` (PR #77105)

2024-01-08 Thread Felix Berger via cfe-commits
@@ -234,6 +239,22 @@ void positiveOnlyAccessedFieldAsConst() { } } +void positiveOnlyAccessedFieldAsConstBinding() { fberger wrote: Why `AccessedField` here, it seems to be `JustUsedAsConst` as in other test names? https://github.com/llvm/llvm-project/pul

[clang] [clang] move -Wcast-function-type under -Wextra (PR #77178)

2024-01-08 Thread Nick Desaulniers via cfe-commits
nickdesaulniers wrote: Github trick not specific to llvm-project. If you put ``` Fixes: #76872 ``` In the commit message, then merging this PR will automatically close https://github.com/llvm/llvm-project/issues/76872. https://github.com/llvm/llvm-project/pull/77178 __

[clang] [llvm] [AIX][TOC] Add -mtocdata/-mno-tocdata options on AIX (PR #67999)

2024-01-08 Thread via cfe-commits
https://github.com/diggerlin edited https://github.com/llvm/llvm-project/pull/67999 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][analyzer] Add function 'ungetc' to StreamChecker. (PR #77331)

2024-01-08 Thread Balázs Kéri via cfe-commits
https://github.com/balazske created https://github.com/llvm/llvm-project/pull/77331 `StdLibraryFunctionsChecker` is updated too with `ungetc`. From 9bcc43b5c62ba969f91c495d4d570c5c4337aca2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bal=C3=A1zs=20K=C3=A9ri?= Date: Mon, 8 Jan 2024 16:42:58 +0100 S

[clang] [clang][analyzer] Add function 'ungetc' to StreamChecker. (PR #77331)

2024-01-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Balázs Kéri (balazske) Changes `StdLibraryFunctionsChecker` is updated too with `ungetc`. --- Full diff: https://github.com/llvm/llvm-project/pull/77331.diff 7 Files Affected: - (modified) clang/docs/ReleaseNotes.rst (+2-2) - (modified

[clang] [clang][analyzer] Add function 'ungetc' to StreamChecker. (PR #77331)

2024-01-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 Author: Balázs Kéri (balazske) Changes `StdLibraryFunctionsChecker` is updated too with `ungetc`. --- Full diff: https://github.com/llvm/llvm-project/pull/77331.diff 7 Files Affected: - (modified) clang/docs/ReleaseNotes.rst (

[clang] [clang][NFC] Adjust TBAA Base Info API (PR #73263)

2024-01-08 Thread Aaron Ballman via cfe-commits
@@ -95,8 +95,6 @@ static bool TypeHasMayAlias(QualType QTy) { /// Check if the given type is a valid base type to be used in access tags. static bool isValidBaseType(QualType QTy) { - if (QTy->isReferenceType()) -return false; AaronBallman wrote: This lo

[clang] [clang] Fix assertion failure when initializing union with FAM (PR #77298)

2024-01-08 Thread Timm Baeder via cfe-commits
@@ -696,6 +696,9 @@ Bug Fixes in This Version - Clang now accepts recursive non-dependent calls to functions with deduced return type. Fixes (`#71015 `_) +- Fix assertion failure when initializing union containing struct wi

[clang] [clang] Fix assertion failure when initializing union with FAM (PR #77298)

2024-01-08 Thread Nikita Popov via cfe-commits
https://github.com/nikic updated https://github.com/llvm/llvm-project/pull/77298 >From 68e21b7604964b7b391d9a077ca52175af21b65a Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Mon, 8 Jan 2024 12:41:34 +0100 Subject: [PATCH 1/3] [clang] Fix assertion failure when initializing union with FAM W

[clang] [clang] Fix assertion failure when initializing union with FAM (PR #77298)

2024-01-08 Thread Nikita Popov via cfe-commits
@@ -696,6 +696,9 @@ Bug Fixes in This Version - Clang now accepts recursive non-dependent calls to functions with deduced return type. Fixes (`#71015 `_) +- Fix assertion failure when initializing union containing struct wi

[clang-tools-extra] [clang-tidy]unused using decls only check cpp files (PR #77335)

2024-01-08 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 created https://github.com/llvm/llvm-project/pull/77335 using decls can be used in cpp >From 39fae7adcdc97b4781911097f5f09c5bf8266d1c Mon Sep 17 00:00:00 2001 From: Congcong Cai Date: Tue, 9 Jan 2024 00:25:44 +0800 Subject: [PATCH] [clang-tidy]unused using decls

[clang-tools-extra] [clang-tidy]unused using decls only check cpp files (PR #77335)

2024-01-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tidy Author: Congcong Cai (HerrCai0907) Changes using decls can be used in cpp --- Full diff: https://github.com/llvm/llvm-project/pull/77335.diff 2 Files Affected: - (modified) clang-tools-extra/clang-tidy/misc/UnusedUsingDeclsCheck.h (+4-1)

[libcxxabi] [libc] [flang] [llvm] [lldb] [mlir] [compiler-rt] [clang-tools-extra] [libcxx] [openmp] [clang] [OpenMP] Patch for Support to loop bind clause : Checking Parent Region (PR #76938)

2024-01-08 Thread Alexey Bataev via cfe-commits
@@ -6124,35 +6136,39 @@ processImplicitMapsWithDefaultMappers(Sema &S, DSAStackTy *Stack, bool Sema::mapLoopConstruct(llvm::SmallVector &ClausesWithoutBind, ArrayRef Clauses, -OpenMPBindClauseKind BindKind, +

[clang-tools-extra] [clang-tidy]unused using decls only check cpp files (PR #77335)

2024-01-08 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 bda562519b89ea3832be00d8ac75cfcdb924dce2 39fae7adcdc97b4781911097f5f09c5bf8266d1c --

[clang-tools-extra] [clang] [clang-tidy] Handle C++ structured bindings in `performance-for-range-copy` (PR #77105)

2024-01-08 Thread Clement Courbet via cfe-commits
https://github.com/legrosbuffle updated https://github.com/llvm/llvm-project/pull/77105 >From 7420ce9460fa0e07bc570087c39b8ee98775713a Mon Sep 17 00:00:00 2001 From: Clement Courbet Date: Fri, 5 Jan 2024 15:48:51 +0100 Subject: [PATCH] [clang-tidy] Handle C++ bindings in `performance-for-range

[clang] [clang-tools-extra] [clang-tidy] Handle C++ structured bindings in `performance-for-range-copy` (PR #77105)

2024-01-08 Thread Clement Courbet via cfe-commits
@@ -234,6 +239,22 @@ void positiveOnlyAccessedFieldAsConst() { } } +void positiveOnlyAccessedFieldAsConstBinding() { + for (auto [X, Y] : View>()) { +// CHECK-MESSAGES: [[@LINE-1]]:13: warning: loop variable is copied but +// CHECK-FIXES: for (const auto& [X, Y] : V

[clang] [clang-tools-extra] [clang-tidy] Handle C++ structured bindings in `performance-for-range-copy` (PR #77105)

2024-01-08 Thread Clement Courbet via cfe-commits
@@ -234,6 +239,22 @@ void positiveOnlyAccessedFieldAsConst() { } } +void positiveOnlyAccessedFieldAsConstBinding() { legrosbuffle wrote: Done. https://github.com/llvm/llvm-project/pull/77105 ___ cfe-commits maili

[clang-tools-extra] [clangd] Do not offer extraction to variable for decl init expression (PR #69477)

2024-01-08 Thread Christian Kandeler via cfe-commits
@@ -490,6 +491,13 @@ bool eligibleForExtraction(const SelectionTree::Node *N) { BO->getRHS() == OuterImplicit.ASTNode.get()) return false; } + if (const auto *Decl = Parent->ASTNode.get()) { +if (!Decl->isInitCapture() && ckandeler wrote:

[clang] [Clang] Rename and enable boolean get, set, create and undef for sme2 (PR #77338)

2024-01-08 Thread Sam Tebbs via cfe-commits
https://github.com/SamTebbs33 created https://github.com/llvm/llvm-project/pull/77338 This patch renames the get, set, create and undef functions that deal with tuples of booleans to match the ACLE at https://github.com/ARM-software/acle/pull/257/files . It also enables them for SME2. >From 0

[clang] [Clang] Rename and enable boolean get, set, create and undef for sme2 (PR #77338)

2024-01-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Sam Tebbs (SamTebbs33) Changes This patch renames the get, set, create and undef functions that deal with tuples of booleans to match the ACLE at https://github.com/ARM-software/acle/pull/257/files . It also enables them for SME2. --- P

[libunwind] [llvm] [libcxx] [lld] [lldb] [flang] [libc] [clang] [compiler-rt] [clang-tools-extra] [libc++][test] try to directly create socket file in /tmp when filepath is too long (PR #77058)

2024-01-08 Thread Mark de Wever via cfe-commits
https://github.com/mordante approved this pull request. Thanks! LGTM! https://github.com/llvm/llvm-project/pull/77058 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lld] [compiler-rt] [flang] [llvm] [libcxx] [lldb] [libunwind] [libc] [clang-tools-extra] [libc++][test] try to directly create socket file in /tmp when filepath is too long (PR #77058)

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

[clang-tools-extra] [libcxx] [clang] [lldb] [compiler-rt] [lld] [llvm] [libunwind] [libc] [flang] [libc++][test] try to directly create socket file in /tmp when filepath is too long (PR #77058)

2024-01-08 Thread Mark de Wever via cfe-commits
@@ -320,16 +320,26 @@ struct scoped_test_env // allow tests to call this unguarded. #if !defined(__FreeBSD__) && !defined(__APPLE__) && !defined(_WIN32) std::string create_socket(std::string file) { -file = sanitize_path(std::move(file)); - -::sockaddr_un

[clang] [clang-format] Handle templated elaborated type specifier in function… (PR #77013)

2024-01-08 Thread Emilia Kond via cfe-commits
@@ -3903,6 +3903,15 @@ void UnwrappedLineParser::parseRecord(bool ParseAsExpr) { parseParens(); } + auto IsTemplate = [&] { +FormatToken *Tok = InitialToken.Previous; +while (Tok) { + if (Tok->is(tok::kw_template)) +return true; + Tok = Tok->

[clang] [clang-format] Handle templated elaborated type specifier in function… (PR #77013)

2024-01-08 Thread Emilia Kond via cfe-commits
https://github.com/rymiel edited https://github.com/llvm/llvm-project/pull/77013 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Handle templated elaborated type specifier in function… (PR #77013)

2024-01-08 Thread Emilia Kond via cfe-commits
https://github.com/rymiel approved this pull request. https://github.com/llvm/llvm-project/pull/77013 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang] [AArch64][PAC] Support ptrauth builtins and -fptrauth-intrinsics. (PR #65996)

2024-01-08 Thread Ahmed Bougacha via cfe-commits
https://github.com/ahmedbougacha updated https://github.com/llvm/llvm-project/pull/65996 >From c4e7c86eb967b4313e19587e33fdc6b50c8cd6a7 Mon Sep 17 00:00:00 2001 From: Ahmed Bougacha Date: Wed, 16 Aug 2023 09:17:12 -0700 Subject: [PATCH] [AArch64][PAC] Support and document ptrauth builtins and

[llvm] [clang] [AArch64][PAC] Support ptrauth builtins and -fptrauth-intrinsics. (PR #65996)

2024-01-08 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 f9aba820eb6478a617145eb690ba8b06490d7ac5 c4e7c86eb967b4313e19587e33fdc6b50c8cd6a7 --

[clang-tools-extra] [clang-tidy]unused using decls only check cpp files (PR #77335)

2024-01-08 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 updated https://github.com/llvm/llvm-project/pull/77335 >From 832bb78fd8cac372ec5560bb280f11e11be8d2e6 Mon Sep 17 00:00:00 2001 From: Congcong Cai Date: Tue, 9 Jan 2024 00:41:33 +0800 Subject: [PATCH] [clang-tidy]unused using decls only check cpp files --- clang

<    1   2   3   4   5   >