[PATCH] D130543: [RISCV]Enable isIntDivCheap when attribute is minsize

Sergei Barannikov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 26 22:46:44 PDT 2022


barannikov88 added inline comments.


================
Comment at: llvm/lib/Target/RISCV/RISCVISelLowering.cpp:12531
+  // TODO: Add vector division?
+  bool OptSize = Attr.hasFnAttr(Attribute::MinSize);
+  return OptSize && !VT.isVector();
----------------
There is `MF->getFunction().hasOptSize()` which also checks for `Attribute::OptimizeForSize`.
Just a suggestion.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D130543



More information about the llvm-commits mailing list