diff options
author | Jessica Paquette <jpaquette@apple.com> | 2020-12-03 14:31:43 -0800 |
---|---|---|
committer | Jessica Paquette <jpaquette@apple.com> | 2020-12-08 09:18:28 -0800 |
commit | b15491eb333809e907e51d1b05da2a6a6344a427 (patch) | |
tree | 97b957d7aa28511ab68224c6751577624ef0a1e7 /llvm/lib/CodeGen/CodeGen.cpp | |
parent | 4a0528e4a0e3e4504db8650bf2bf7d6977ffa018 (diff) | |
download | llvm-b15491eb333809e907e51d1b05da2a6a6344a427.zip llvm-b15491eb333809e907e51d1b05da2a6a6344a427.tar.gz llvm-b15491eb333809e907e51d1b05da2a6a6344a427.tar.bz2 |
[AArch64][GlobalISel] Select G_SADDO and G_SSUBO
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`.
Differential Revision: https://reviews.llvm.org/D92610
Diffstat (limited to 'llvm/lib/CodeGen/CodeGen.cpp')
0 files changed, 0 insertions, 0 deletions