[PATCH] D96661: [RISCV] Move SHFLI matching to DAG combine. Add 32-bit support for RV64

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Jun 6 12:03:12 PDT 2021


RKSimon added inline comments.


================
Comment at: llvm/lib/Target/RISCV/RISCVISelLowering.cpp:2721
+  unsigned Width = Op.getValueType() == MVT::i64 ? 64 : 32;
+  if (ShAmt >= Width && !isPowerOf2_64(ShAmt))
     return None;
----------------
@craig.topper Shouldn't this always early-out if ShAmt >= Width? Reported by coverity.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D96661



More information about the llvm-commits mailing list