[SVE] Add patterns for shift intrinsics with FalseLanesZero mode
authorlizhijin <lizhijin3@huawei.com>
Sun, 19 Mar 2023 05:43:01 +0000 (13:43 +0800)
committerzhongyunde <zhongyunde@huawei.com>
Sun, 19 Mar 2023 05:49:01 +0000 (13:49 +0800)
commit22c3ba4bb519e12395c676ffe436ea4b8400234a
treebad5ebff6038d4837c009c9ab07a1c39ed6a3572
parent57aeb305460406f7b822cfe6ab9fb4d730fc3b38
[SVE] Add patterns for shift intrinsics with FalseLanesZero mode

This patch adds patterns to reduce redundant mov and sel instructions
for shift intrinsics with FalseLanesZero mode, when
FeatureExperimentalZeroingPseudosis supported.

For example, before:

mov     z1.b, #0
sel     z0.b, p0, z0.b, z1.b
asr     z0.b, p0/m, z0.b, #7
After:

movprfx z0.b, p0/z, z0.b
asr     z0.b, p0/m, z0.b, #7

Reviewed By: paulwalker-arm
Differential Revision: https://reviews.llvm.org/D145551
llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td
llvm/lib/Target/AArch64/SVEInstrFormats.td
llvm/test/CodeGen/AArch64/sve-intrinsics-int-arith-imm-zero.ll [new file with mode: 0644]