2 Commits

Author SHA1 Message Date
gonglingqin
9d8a7f780c [LoongArch] Implement the convertSelectOfConstantsToMath hook
Normally, the ISD::SELECT is lowered to maskeqz + masknez. This is
inefficient when operands are constants that can be computed easily.
To avoid that, override TargetLowering::convertSelectOfConstantsToMath.

Differential Revision: https://reviews.llvm.org/D143621
2023-02-10 14:14:47 +08:00
gonglingqin
e5489f7264 [LoongArch] Add baseline tests for translating the selection of constants into mathematical operations 2023-02-09 09:45:58 +08:00