[PATCH] D100476: [AArch64][SVEIntrinsicOpts] Replace last{a,b} intrinsic calls with extracts...

Paul Walker via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 19 02:28:49 PDT 2021


paulwalker-arm accepted this revision.
paulwalker-arm added inline comments.
This revision is now accepted and ready to land.


================
Comment at: llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp:285-286
+                                                  IntrinsicInst &II) {
+  Value *Pg = II.getArgOperand(0);
+  Value *Vec = II.getArgOperand(1);
+  bool IsAfter = II.getIntrinsicID() == Intrinsic::aarch64_sve_lasta;
----------------
Are these needed? I can only see one use of either within the `IsAfter` block but then the following code falls back to `II.getArgOperand` calls. It'll be nice to unify to one or the other.


================
Comment at: llvm/test/Transforms/InstCombine/AArch64/sve-intrinsic-opts-lasta-lastb.ll:2
+; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
+; RUN: opt -instcombine -S < %s | FileCheck --check-prefix OPT %s
+
----------------
I suspect this is fallout from code we have downstream where a single test was used for opt and llc.  Given we're not going to do that here can this be removed and thus have us fall back to the usual `CHECK` identifier?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D100476



More information about the llvm-commits mailing list