summaryrefslogtreecommitdiffstats
path: root/lib/Analysis/ConstantFolding.cpp
diff options
context:
space:
mode:
authorNate Begeman <natebegeman@mac.com>2008-07-25 17:35:37 +0000
committerNate Begeman <natebegeman@mac.com>2008-07-25 17:35:37 +0000
commitb5557abcf13a7b375cae683e9ec200d499645d02 (patch)
tree349ca74872a36305e8a03d1ac201d9cb17555619 /lib/Analysis/ConstantFolding.cpp
parentbeb572b6986d818cff33725a15dd1b6c9c29a15d (diff)
downloadexternal_llvm-b5557abcf13a7b375cae683e9ec200d499645d02.zip
external_llvm-b5557abcf13a7b375cae683e9ec200d499645d02.tar.gz
external_llvm-b5557abcf13a7b375cae683e9ec200d499645d02.tar.bz2
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
Diffstat (limited to 'lib/Analysis/ConstantFolding.cpp')
-rw-r--r--lib/Analysis/ConstantFolding.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/Analysis/ConstantFolding.cpp b/lib/Analysis/ConstantFolding.cpp
index 43597c8..1a0e4b4 100644
--- a/lib/Analysis/ConstantFolding.cpp
+++ b/lib/Analysis/ConstantFolding.cpp
@@ -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]);
}