aboutsummaryrefslogtreecommitdiffstats
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
commit623a2c54c21448d647e2cfae31ef773be5fba545 (patch)
tree349ca74872a36305e8a03d1ac201d9cb17555619 /lib/Analysis/ConstantFolding.cpp
parent692c38af5938b38d547e1541d960141e1b04299c (diff)
downloadexternal_llvm-623a2c54c21448d647e2cfae31ef773be5fba545.zip
external_llvm-623a2c54c21448d647e2cfae31ef773be5fba545.tar.gz
external_llvm-623a2c54c21448d647e2cfae31ef773be5fba545.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]);
}