[InstSimplify] Use ICmpInst::isEquality predicate method. NFC

llvm-svn: 304770
This commit is contained in:
Craig Topper 2017-06-06 07:13:04 +00:00
parent 8cde9a7e77
commit c2790ecda8
1 changed files with 1 additions and 1 deletions

View File

@ -3308,7 +3308,7 @@ static Value *SimplifyICmpInst(unsigned Predicate, Value *LHS, Value *RHS,
}
// icmp eq|ne X, Y -> false|true if X != Y
if ((Pred == ICmpInst::ICMP_EQ || Pred == ICmpInst::ICMP_NE) &&
if (ICmpInst::isEquality(Pred) &&
isKnownNonEqual(LHS, RHS, Q.DL, Q.AC, Q.CxtI, Q.DT)) {
LLVMContext &Ctx = LHS->getType()->getContext();
return Pred == ICmpInst::ICMP_NE ?