Fix two cases I forgot to update when doing a mental "getSwappedPredicate".
[oota-llvm.git] / lib / Analysis / InstructionSimplify.cpp
index 2d202f7b9834814ba743556bfa8a1b66bd281f86..9dd5f050c5897967e8e632c2204e22b5dd7c7a78 100644 (file)
@@ -1709,7 +1709,7 @@ static Value *SimplifyICmpInst(unsigned Predicate, Value *LHS, Value *RHS,
       if (!KnownNonNegative)
         break;
       // fall-through
-    case ICmpInst::ICMP_EQ:
+    case ICmpInst::ICMP_NE:
     case ICmpInst::ICMP_UGT:
     case ICmpInst::ICMP_UGE:
       return ConstantInt::getTrue(RHS->getContext());
@@ -1719,7 +1719,7 @@ static Value *SimplifyICmpInst(unsigned Predicate, Value *LHS, Value *RHS,
       if (!KnownNonNegative)
         break;
       // fall-through
-    case ICmpInst::ICMP_NE:
+    case ICmpInst::ICMP_EQ:
     case ICmpInst::ICMP_ULT:
     case ICmpInst::ICMP_ULE:
       return ConstantInt::getFalse(RHS->getContext());