Change Constant::getNullConstant to Constant::getNullValue

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2323 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner
2002-04-27 02:25:14 +00:00
parent 87e873bd3d
commit 1a18b7cf80
6 changed files with 14 additions and 17 deletions

View File

@@ -115,7 +115,7 @@ InductionVariable::InductionVariable(PHINode *P, cfg::LoopInfo *LoopInfo) {
Step = 0;
if (V2 == Phi) { // referencing the PHI directly? Must have zero step
Step = Constant::getNullConstant(Phi->getType());
Step = Constant::getNullValue(Phi->getType());
} else if (BinaryOperator *I = dyn_cast<BinaryOperator>(V2)) {
// TODO: This could be much better...
if (I->getOpcode() == Instruction::Add) {
@@ -143,7 +143,7 @@ InductionVariable::InductionVariable(PHINode *P, cfg::LoopInfo *LoopInfo) {
if (StepE.Offset)
Step = (Value*)StepE.Offset;
else
Step = Constant::getNullConstant(Step->getType());
Step = Constant::getNullValue(Step->getType());
const Type *ETy = Phi->getType();
if (ETy->isPointerType()) ETy = Type::ULongTy;
Step = (Value*)(StepE.Offset ? StepE.Offset : ConstantInt::get(ETy,0));