[PATCH] D112443: [SelectionDAG] Optimize expansion for rotates/funnel shifts
Simon Pilgrim via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 25 10:13:06 PDT 2021
RKSimon added inline comments.
================
Comment at: llvm/lib/CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp:4427
+ // Expand to a pair of funnel shifts.
+ EVT NewShAmtVT = TLI.getShiftAmountTy(HalfVT, DAG.getDataLayout(), false);
+ SDValue NewShAmt = DAG.getAnyExtOrTrunc(ShAmt, DL, NewShAmtVT);
----------------
craig.topper wrote:
> Does passing "false" to this really solve the original problem I raised? That makes getShiftAmountTy use pointer type, but pointer type on some targets is i16 which wouldn't be enough to represent a shift amount for an i65356. Should this instead use the getShiftAmountTyForConstant helper? The name of that function is outdated.
Sorry I missed that comment on the other phab
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D112443/new/
https://reviews.llvm.org/D112443
More information about the llvm-commits
mailing list