[PATCH] D155565: [AArch64] SelectionDAG Funnel Shift Lowering
Dave Green via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 24 05:20:26 PDT 2023
dmgreen accepted this revision.
dmgreen added a comment.
This revision is now accepted and ready to land.
I looked into the BE i20 case but considering how narrow in scope it is, I think this will be OK.
LGTM, with a couple of extra suggestions.
================
Comment at: llvm/lib/Target/AArch64/AArch64ISelLowering.cpp:5809
+ SDValue Shifts = Op.getOperand(2);
+ // Check then cast if the number of shifts is a constant
+ if (auto *ShiftNo = dyn_cast<ConstantSDNode>(Shifts)) {
----------------
I'm not sure what this comment means. Is it just explaining that the funnel shifts with constant shift amounts are legal or converted to FSHR?
================
Comment at: llvm/lib/Target/AArch64/AArch64ISelLowering.cpp:5815
+ if (Op.getOpcode() == ISD::FSHL) {
+ long unsigned int NewShiftNo =
+ VT.getFixedSizeInBits() - ShiftNo->getZExtValue();
----------------
`unsigned` on its own is commonly used in LLVM as a type.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D155565/new/
https://reviews.llvm.org/D155565
More information about the llvm-commits
mailing list