Fix minor issues with VICmp/VFCmp constant expressions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54030 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Nate Begeman
2008-07-25 17:35:37 +00:00
parent beb572b698
commit b5557abcf1
3 changed files with 22 additions and 16 deletions
+3 -1
View File
@@ -358,6 +358,8 @@ Constant *llvm::ConstantFoldInstOperands(unsigned Opcode, const Type *DestTy,
return 0;
case Instruction::ICmp:
case Instruction::FCmp:
case Instruction::VICmp:
case Instruction::VFCmp:
assert(0 &&"This function is invalid for compares: no predicate specified");
case Instruction::PtrToInt:
// If the input is a inttoptr, eliminate the pair. This requires knowing
@@ -473,7 +475,7 @@ Constant *llvm::ConstantFoldCompareInstOperands(unsigned Predicate,
}
}
}
return ConstantExpr::getCompare(Predicate, Ops[0], Ops[1]);
return ConstantExpr::getCompare(Predicate, Ops[0], Ops[1]);
}