[PATCH] D67664: [ARM] Ensure we do not attempt to create lsll #0
Eli Friedman via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 17 09:43:44 PDT 2019
efriedma added inline comments.
================
Comment at: llvm/lib/Target/ARM/ARMISelLowering.cpp:6013
if (ShAmt->getValueType(0).getSizeInBits() > 64 ||
- (Con && Con->getZExtValue() >= 32))
+ (Con && (Con->getZExtValue() == 0 || Con->getZExtValue() >= 32)))
return SDValue();
----------------
What happens if we discover the shift amount is zero after legalization?
If MVE_LSLLi doesn't accept arbitrary immediates, the isel pattern should reflect that. (With only that fix, I think we still end up with an MVE_LSLLr, but that's not a correctness issue, just a missed optimization, I think.)
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D67664/new/
https://reviews.llvm.org/D67664
More information about the llvm-commits
mailing list