mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
[aarch32] fix bug 18268: Incorrect condition of vsel
Given vsel_cc, op1, op2, since vsel has no LE/LT, to generate vsel for such selection, it needs to inverse cc and swap op1 and op2. To inverse cc, both L/G and E bits should be flipped. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@197615 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -3232,7 +3232,7 @@ SDValue ARMTargetLowering::LowerSELECT(SDValue Op, SelectionDAG &DAG) const {
|
||||
static ISD::CondCode getInverseCCForVSEL(ISD::CondCode CC) {
|
||||
if (CC == ISD::SETNE)
|
||||
return ISD::SETEQ;
|
||||
return ISD::getSetCCSwappedOperands(CC);
|
||||
return ISD::getSetCCInverse(CC, true);
|
||||
}
|
||||
|
||||
static void checkVSELConstraints(ISD::CondCode CC, ARMCC::CondCodes &CondCode,
|
||||
|
Reference in New Issue
Block a user