[llvm-commits] CVS: llvm/lib/Transforms/ExprTypeConvert.cpp
Chris Lattner
sabre at nondot.org
Sun Jan 14 18:28:13 PST 2007
Changes in directory llvm/lib/Transforms:
ExprTypeConvert.cpp updated: 1.120 -> 1.121
---
Log message:
rename Type::isIntegral to Type::isInteger, eliminating the old Type::isInteger.
rename Type::getIntegralTypeMask to Type::getIntegerTypeMask.
This makes naming much more consistent. For example, there are now no longer any
instances of IntegerType that are not considered isInteger! :)
---
Diffs of the changes: (+6 -6)
ExprTypeConvert.cpp | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
Index: llvm/lib/Transforms/ExprTypeConvert.cpp
diff -u llvm/lib/Transforms/ExprTypeConvert.cpp:1.120 llvm/lib/Transforms/ExprTypeConvert.cpp:1.121
--- llvm/lib/Transforms/ExprTypeConvert.cpp:1.120 Sun Jan 14 19:55:30 2007
+++ llvm/lib/Transforms/ExprTypeConvert.cpp Sun Jan 14 20:27:26 2007
@@ -69,19 +69,19 @@
case Instruction::Add:
case Instruction::Sub:
- if (!Ty->isIntegral() && !Ty->isFloatingPoint()) return false;
+ if (!Ty->isInteger() && !Ty->isFloatingPoint()) return false;
if (!ExpressionConvertibleToType(I->getOperand(0), Ty, CTMap, TD) ||
!ExpressionConvertibleToType(I->getOperand(1), Ty, CTMap, TD))
return false;
break;
case Instruction::LShr:
case Instruction::AShr:
- if (!Ty->isIntegral()) return false;
+ if (!Ty->isInteger()) return false;
if (!ExpressionConvertibleToType(I->getOperand(0), Ty, CTMap, TD))
return false;
break;
case Instruction::Shl:
- if (!Ty->isIntegral()) return false;
+ if (!Ty->isInteger()) return false;
if (!ExpressionConvertibleToType(I->getOperand(0), Ty, CTMap, TD))
return false;
break;
@@ -458,7 +458,7 @@
case Instruction::Add:
case Instruction::Sub: {
- if (!Ty->isIntegral() && !Ty->isFloatingPoint()) return false;
+ if (!Ty->isInteger() && !Ty->isFloatingPoint()) return false;
Value *OtherOp = I->getOperand((V == I->getOperand(0)) ? 1 : 0);
return ValueConvertibleToType(I, Ty, CTMap, TD) &&
@@ -476,7 +476,7 @@
case Instruction::AShr:
case Instruction::Shl:
if (I->getOperand(1) == V) return false; // Cannot change shift amount type
- if (!Ty->isIntegral()) return false;
+ if (!Ty->isInteger()) return false;
return ValueConvertibleToType(I, Ty, CTMap, TD);
case Instruction::Free:
@@ -576,7 +576,7 @@
// Can convert store if the incoming value is convertible and if the
// result will preserve semantics...
const Type *Op0Ty = I->getOperand(0)->getType();
- if (!(Op0Ty->isIntegral() ^ ElTy->isIntegral()) &&
+ if (!(Op0Ty->isInteger() ^ ElTy->isInteger()) &&
!(Op0Ty->isFloatingPoint() ^ ElTy->isFloatingPoint()))
return ExpressionConvertibleToType(I->getOperand(0), ElTy, CTMap, TD);
}
More information about the llvm-commits
mailing list