[PATCH] D143283: [AArch64][SVE]: custom lower AVGFloor/AVGCeil.
Dave Green via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 6 00:10:49 PST 2023
dmgreen added a comment.
Thanks. here are some alive proofs for the transform in https://alive2.llvm.org/ce/z/N6hwQY and https://alive2.llvm.org/ce/z/u_GjYJ.
Can you extend the testing to include both ashr and lshr versions? They should both be useful if we are custom legalizing the nodes. Otherwise I think this looks good.
================
Comment at: llvm/test/CodeGen/AArch64/sve-hadd.ll:25
%m = add nsw <vscale x 2 x i128> %s0s, %s1s
- %s = lshr <vscale x 2 x i128> %m, shufflevector (<vscale x 2 x i128> insertelement (<vscale x 2 x i128> poison, i128 1, i32 0), <vscale x 2 x i128> poison, <vscale x 2 x i32> zeroinitializer)
+ %s = ashr <vscale x 2 x i128> %m, shufflevector (<vscale x 2 x i128> insertelement (<vscale x 2 x i128> poison, i128 1, i32 0), <vscale x 2 x i128> poison, <vscale x 2 x i32> zeroinitializer)
%s2 = trunc <vscale x 2 x i128> %s to <vscale x 2 x i64>
----------------
Can you copy these tests so there are versions with both lshr and ashr.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D143283/new/
https://reviews.llvm.org/D143283
More information about the llvm-commits
mailing list