[PATCH] D123006: [AArch64] Teach the costmodel about widening muls

Sjoerd Meijer via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 4 01:27:06 PDT 2022


SjoerdMeijer accepted this revision.
SjoerdMeijer added a comment.
This revision is now accepted and ready to land.

Looks like a good one to me.



================
Comment at: llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp:1292
   //
-  // TODO: Add additional widening operations (e.g., mul, shl, etc.) once we
+  // TODO: Add additional widening operations (e.g., shl, etc.) once we
   //       verify that their extending operands are eliminated during code
----------------
While we are at it, look at shl in a follow up? :)


================
Comment at: llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp:1856
   }
-  case ISD::MUL:
-    if (LT.second != MVT::v2i64)
-      return LT.first;
+  case ISD::MUL: {
     // Since we do not have a MUL.2d instruction, a mul <2 x i64> is expensive
----------------
Nit: we don't need the brackets?


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

https://reviews.llvm.org/D123006



More information about the llvm-commits mailing list