@@ -4003,7 +4003,7 @@ std::pair<Value *, FPClassTest> llvm::fcmpToClassTest(FCmpInst::Predicate Pred,
4003
4003
bool LookThroughSrc) {
4004
4004
const APFloat *ConstRHS;
4005
4005
if (!match (RHS, m_APFloatAllowUndef (ConstRHS)))
4006
- return {nullptr , fcNone };
4006
+ return {nullptr , fcAllFlags };
4007
4007
4008
4008
return fcmpToClassTest (Pred, F, LHS, ConstRHS, LookThroughSrc);
4009
4009
}
@@ -4025,7 +4025,7 @@ llvm::fcmpToClassTest(FCmpInst::Predicate Pred, const Function &F, Value *LHS,
4025
4025
// TODO: Handle DAZ by expanding masks to cover subnormal cases.
4026
4026
if (Pred != FCmpInst::FCMP_ORD && Pred != FCmpInst::FCMP_UNO &&
4027
4027
!inputDenormalIsIEEE (F, LHS->getType ()))
4028
- return {nullptr , fcNone };
4028
+ return {nullptr , fcAllFlags };
4029
4029
4030
4030
switch (Pred) {
4031
4031
case FCmpInst::FCMP_OEQ: // Match x == 0.0
@@ -4062,7 +4062,7 @@ llvm::fcmpToClassTest(FCmpInst::Predicate Pred, const Function &F, Value *LHS,
4062
4062
break ;
4063
4063
}
4064
4064
4065
- return {nullptr , fcNone };
4065
+ return {nullptr , fcAllFlags };
4066
4066
}
4067
4067
4068
4068
Value *Src = LHS;
@@ -4146,7 +4146,7 @@ llvm::fcmpToClassTest(FCmpInst::Predicate Pred, const Function &F, Value *LHS,
4146
4146
case FCmpInst::FCMP_OGE:
4147
4147
case FCmpInst::FCMP_ULT: {
4148
4148
if (ConstRHS->isNegative ()) // TODO
4149
- return {nullptr , fcNone };
4149
+ return {nullptr , fcAllFlags };
4150
4150
4151
4151
// fcmp oge fabs(x), +inf -> fcInf
4152
4152
// fcmp oge x, +inf -> fcPosInf
@@ -4160,14 +4160,14 @@ llvm::fcmpToClassTest(FCmpInst::Predicate Pred, const Function &F, Value *LHS,
4160
4160
case FCmpInst::FCMP_OGT:
4161
4161
case FCmpInst::FCMP_ULE: {
4162
4162
if (ConstRHS->isNegative ())
4163
- return {nullptr , fcNone };
4163
+ return {nullptr , fcAllFlags };
4164
4164
4165
4165
// No value is ordered and greater than infinity.
4166
4166
Mask = fcNone;
4167
4167
break ;
4168
4168
}
4169
4169
default :
4170
- return {nullptr , fcNone };
4170
+ return {nullptr , fcAllFlags };
4171
4171
}
4172
4172
} else if (ConstRHS->isSmallestNormalized () && !ConstRHS->isNegative ()) {
4173
4173
// Match pattern that's used in __builtin_isnormal.
@@ -4196,14 +4196,14 @@ llvm::fcmpToClassTest(FCmpInst::Predicate Pred, const Function &F, Value *LHS,
4196
4196
break ;
4197
4197
}
4198
4198
default :
4199
- return {nullptr , fcNone };
4199
+ return {nullptr , fcAllFlags };
4200
4200
}
4201
4201
} else if (ConstRHS->isNaN ()) {
4202
4202
// fcmp o__ x, nan -> false
4203
4203
// fcmp u__ x, nan -> true
4204
4204
Mask = fcNone;
4205
4205
} else
4206
- return {nullptr , fcNone };
4206
+ return {nullptr , fcAllFlags };
4207
4207
4208
4208
// Invert the comparison for the unordered cases.
4209
4209
if (FCmpInst::isUnordered (Pred))
0 commit comments