[PATCH] D95290: [RISCV] Add isel patterns to optimize slli.uw patterns without Zba extension.

Jessica Clarke via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Jan 23 10:15:19 PST 2021


jrtc27 added inline comments.


================
Comment at: llvm/lib/Target/RISCV/RISCVInstrInfo.td:336
+// Return an immediate subtracted from 32.
+def ThirtyTwoMinusImm : SDNodeXForm<imm, [{
+  return CurDAG->getTargetConstant(32 - N->getZExtValue(), SDLoc(N),
----------------
jrtc27 wrote:
> This is just NegImm and ImmSub32 composed?
(also a shorter name that doesn't require spelling 32 in words would be ImmSubFrom32)


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D95290



More information about the llvm-commits mailing list