[PATCH] D92610: [AArch64][GlobalISel] Select G_SADDO and G_SSUBO
Jessica Paquette via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 3 14:42:03 PST 2020
paquette created this revision.
paquette added a reviewer: aemerson.
Herald added subscribers: danielkiss, hiraditya, kristof.beyls, rovka.
paquette requested review of this revision.
Herald added a project: LLVM.
We didn't have selector support for these.
Selection code is similar to `getAArch64XALUOOp` in AArch64ISelLowering. Similar to that code, this returns the AArch64CC and the instruction produced. In SDAG, this is used to optimize select + overflow and condition branch + overflow pairs. (See `AArch64TargetLowering::LowerBR_CC` and `AArch64TargetLowering::LowerSelect`)
(G_USUBO should be easy to add here, but it isn't legalized right now.)
This also factors out the existing G_UADDO selection code, and removes an unnecessary check for s32/s64. AFAIK, we shouldn't ever get anything other than s32/s64. It makes more sense for this to be handled by the type assertion in `emitAddSub`.
https://reviews.llvm.org/D92610
Files:
llvm/lib/Target/AArch64/GISel/AArch64InstructionSelector.cpp
llvm/lib/Target/AArch64/GISel/select-saddo.mir
llvm/lib/Target/AArch64/GISel/select-ssubo.mir
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D92610.309372.patch
Type: text/x-patch
Size: 14653 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20201203/47347623/attachment.bin>
More information about the llvm-commits
mailing list