[PATCH] D99283: [GlobalISel] Combine and (lshr x, cst), mask -> ubfx x, cst, width
Jessica Paquette via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue May 25 11:34:58 PDT 2021
paquette added inline comments.
================
Comment at: llvm/lib/Target/AArch64/GISel/AArch64PostLegalizerCombiner.cpp:282-285
+ // Only legal for s32 and s64.
+ LLT Ty = MRI.getType(Dst);
+ if (Ty != LLT::scalar(32) && Ty != LLT::scalar(64))
+ return false;
----------------
arsenm wrote:
> This is the only target specific thing here which can be replaced with a legality check on UBFX
The annoying part (for AArch64) is that the legality checks don't work with custom legalization.
I'm not sure what the best way to handle custom actions is.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D99283/new/
https://reviews.llvm.org/D99283
More information about the llvm-commits
mailing list