[PATCH] D116890: [RISCV] Add initial support for getRegUsageForType and getNumberOfRegisters

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 10 11:13:14 PST 2022


craig.topper added inline comments.


================
Comment at: llvm/lib/Target/RISCV/RISCVTargetTransformInfo.cpp:289
+    if (ST->useRVVForFixedLengthVectors())
+      return divideCeil(Size, ST->getMinRVVVectorSizeInBits());
+  }
----------------
craig.topper wrote:
> Does this give a different answer than what the default implementation using getTypeLegalizationCost would give?
Err nevermind. Of course it would


================
Comment at: llvm/lib/Target/RISCV/RISCVTargetTransformInfo.cpp:292
+
+  unsigned FLen = ST->getFLen();
+  if (FLen && Ty->isFloatingPointTy())
----------------
Can we fall back to the default implementation for non-vector?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D116890



More information about the llvm-commits mailing list