aboutsummaryrefslogtreecommitdiffstats
path: root/lib/VMCore/Instructions.cpp
diff options
context:
space:
mode:
authorZhou Sheng <zhousheng00@gmail.com>2007-01-11 12:24:14 +0000
committerZhou Sheng <zhousheng00@gmail.com>2007-01-11 12:24:14 +0000
commit6b6b6ef1677fa71b1072c2911b4c1f9524a558c9 (patch)
tree480ecf010ac5facd1bc29ab57441253691bb42d6 /lib/VMCore/Instructions.cpp
parent057809ac1c78c3456e8f1481330fa2bcd2b85029 (diff)
downloadexternal_llvm-6b6b6ef1677fa71b1072c2911b4c1f9524a558c9.zip
external_llvm-6b6b6ef1677fa71b1072c2911b4c1f9524a558c9.tar.gz
external_llvm-6b6b6ef1677fa71b1072c2911b4c1f9524a558c9.tar.bz2
For PR1043:
Merge ConstantIntegral and ConstantBool into ConstantInt. Remove ConstantIntegral and ConstantBool from LLVM. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33073 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/Instructions.cpp')
-rw-r--r--lib/VMCore/Instructions.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/VMCore/Instructions.cpp b/lib/VMCore/Instructions.cpp
index 8063331..adcf4cd 100644
--- a/lib/VMCore/Instructions.cpp
+++ b/lib/VMCore/Instructions.cpp
@@ -1118,10 +1118,10 @@ BinaryOperator *BinaryOperator::createNot(Value *Op, const std::string &Name,
Instruction *InsertBefore) {
Constant *C;
if (const PackedType *PTy = dyn_cast<PackedType>(Op->getType())) {
- C = ConstantIntegral::getAllOnesValue(PTy->getElementType());
+ C = ConstantInt::getAllOnesValue(PTy->getElementType());
C = ConstantPacked::get(std::vector<Constant*>(PTy->getNumElements(), C));
} else {
- C = ConstantIntegral::getAllOnesValue(Op->getType());
+ C = ConstantInt::getAllOnesValue(Op->getType());
}
return new BinaryOperator(Instruction::Xor, Op, C,
@@ -1133,11 +1133,11 @@ BinaryOperator *BinaryOperator::createNot(Value *Op, const std::string &Name,
Constant *AllOnes;
if (const PackedType *PTy = dyn_cast<PackedType>(Op->getType())) {
// Create a vector of all ones values.
- Constant *Elt = ConstantIntegral::getAllOnesValue(PTy->getElementType());
+ Constant *Elt = ConstantInt::getAllOnesValue(PTy->getElementType());
AllOnes =
ConstantPacked::get(std::vector<Constant*>(PTy->getNumElements(), Elt));
} else {
- AllOnes = ConstantIntegral::getAllOnesValue(Op->getType());
+ AllOnes = ConstantInt::getAllOnesValue(Op->getType());
}
return new BinaryOperator(Instruction::Xor, Op, AllOnes,
@@ -1147,7 +1147,7 @@ BinaryOperator *BinaryOperator::createNot(Value *Op, const std::string &Name,
// isConstantAllOnes - Helper function for several functions below
static inline bool isConstantAllOnes(const Value *V) {
- return isa<ConstantIntegral>(V) &&cast<ConstantIntegral>(V)->isAllOnesValue();
+ return isa<ConstantInt>(V) &&cast<ConstantInt>(V)->isAllOnesValue();
}
bool BinaryOperator::isNeg(const Value *V) {