[PATCH] D100871: [COST][AARCH64] Improve cost of reverse shuffles for AArch64.

Dave Green via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 20 12:46:32 PDT 2021


dmgreen added inline comments.


================
Comment at: llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp:1483
       { TTI::SK_PermuteSingleSrc, MVT::v2f64, 1 }, // mov.
       // Broadcast shuffle kinds for scalable vectors
       { TTI::SK_Broadcast, MVT::nxv16i8,  1 },
----------------
Can you add them here, before any "nx" scalable vectors.


================
Comment at: llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp:1494
+      { TTI::SK_Reverse, MVT::v2i32, 1 }, // mov.
+      { TTI::SK_Reverse, MVT::v4i32, 3 }, // perfectshuffle worst case.
+      { TTI::SK_Reverse, MVT::v2i64, 1 }, // mov.
----------------
Can be 2. REV64; EXT


================
Comment at: llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp:1497
+      { TTI::SK_Reverse, MVT::v2f32, 1 }, // mov.
+      { TTI::SK_Reverse, MVT::v4f32, 3 }, // perfectshuffle worst case.
+      { TTI::SK_Reverse, MVT::v2f64, 1 }, // mov.
----------------
Same here.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D100871/new/

https://reviews.llvm.org/D100871



More information about the llvm-commits mailing list