[clang] [SVE][InstCombine] Delete redundante sel instructions with ptrue (PR #68463)

2023-10-10 Thread David Sherwood via cfe-commits
@@ -800,6 +800,13 @@ instCombineConvertFromSVBool(InstCombiner &IC, IntrinsicInst &II) { static std::optional instCombineSVESel(InstCombiner &IC, IntrinsicInst &II) { + // svsel(ptrue, x, y) => x + auto *OpPredicate = II

[clang] [SVE][InstCombine] Delete redundante sel instructions with ptrue (PR #68463)

2023-10-10 Thread David Sherwood via cfe-commits
@@ -63,6 +63,20 @@ svint32_t test_svsel_s32(svbool_t pg, svint32_t op1, svint32_t op2) return SVE_ACLE_FUNC(svsel,_s32,,)(pg, op1, op2); } +// CHECK-LABEL: @test_svsel_s32_ptrue( david-arm wrote: I'm not sure if this test really adds any more value, since

[clang] [SVE][InstCombine] Delete redundante sel instructions with ptrue (PR #68463)

2023-10-10 Thread via cfe-commits
@@ -800,6 +800,13 @@ instCombineConvertFromSVBool(InstCombiner &IC, IntrinsicInst &II) { static std::optional instCombineSVESel(InstCombiner &IC, IntrinsicInst &II) { + // svsel(ptrue, x, y) => x + auto *OpPredicate = II

[clang] [SVE][InstCombine] Delete redundante sel instructions with ptrue (PR #68463)

2023-10-06 Thread via cfe-commits
https://github.com/vfdff created https://github.com/llvm/llvm-project/pull/68463 svsel(pture, x, y) => x. depend on D121792 >From d4d0d96afa5c98be6b4a443f017321fbd1c41112 Mon Sep 17 00:00:00 2001 From: zhongyunde 00443407 Date: Fri, 6 Oct 2023 21:54:36 -0400 Subject: [PATCH 1/2] [SVE][InstCombi

[clang] [SVE][InstCombine] Delete redundante sel instructions with ptrue (PR #68463)

2023-10-06 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Changes svsel(pture, x, y) => x. depend on D121792 --- Full diff: https://github.com/llvm/llvm-project/pull/68463.diff 3 Files Affected: - (modified) clang/test/CodeGen/aarch64-sve-intrinsics/acle_sve_sel.c (+14) - (modified) llvm/lib/Target/AA