[PATCH] D108065: [InstSimplify][AArch64] Eliminate vector reverse of ptrue/dupx intrinsics

Paul Walker via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 19 05:36:44 PDT 2021


paulwalker-arm added inline comments.


================
Comment at: llvm/lib/Analysis/VectorUtils.cpp:417
 
+  // aarch64_sve_ptrue(31) is an all true predicate i.e. splat(i1 1).
+  if (match(V, m_Intrinsic<Intrinsic::aarch64_sve_ptrue>(m_SpecificInt(31))))
----------------
david-arm wrote:
> To be honest, I'm not sure if this is the right place to be putting AArch64 specific intrinsics. Perhaps lib/Target/AArch64/SVEIntrinsicsOpt.cpp is a better location on this occasion?
Rather than SVEIntrinsicsOpts I recommend extending `AArch64TTIImpl::instCombineIntrinsic()` to canonicalise these idioms to normal LLVM splat operations.  That way we don't need to teach existing code about target specific variants of splats.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D108065



More information about the llvm-commits mailing list