diff options
author | Owen Anderson <resistor@mac.com> | 2009-07-22 00:24:57 +0000 |
---|---|---|
committer | Owen Anderson <resistor@mac.com> | 2009-07-22 00:24:57 +0000 |
commit | 47db941fd3e5a698c4417e38686ff6da6b2d81ee (patch) | |
tree | f1bc8ce05f4b4c0c6f5eb775c3e5b12eda35e2f1 /llvm/lib/Analysis/LoopVR.cpp | |
parent | 4565ef5b65b7d0b778b41836d70b806196cc8e24 (diff) | |
download | bcm5719-llvm-47db941fd3e5a698c4417e38686ff6da6b2d81ee.tar.gz bcm5719-llvm-47db941fd3e5a698c4417e38686ff6da6b2d81ee.zip |
Get rid of the Pass+Context magic.
llvm-svn: 76702
Diffstat (limited to 'llvm/lib/Analysis/LoopVR.cpp')
-rw-r--r-- | llvm/lib/Analysis/LoopVR.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/llvm/lib/Analysis/LoopVR.cpp b/llvm/lib/Analysis/LoopVR.cpp index e4dac8f1f9b..ccd5400df8d 100644 --- a/llvm/lib/Analysis/LoopVR.cpp +++ b/llvm/lib/Analysis/LoopVR.cpp @@ -42,6 +42,8 @@ ConstantRange LoopVR::getRange(const SCEV *S, const SCEV *T, ScalarEvolution &SE if (const SCEVConstant *C = dyn_cast<SCEVConstant>(S)) return ConstantRange(C->getValue()->getValue()); + + LLVMContext &Context = SE.getContext(); ConstantRange FullSet(cast<IntegerType>(S->getType())->getBitWidth(), true); @@ -73,8 +75,8 @@ ConstantRange LoopVR::getRange(const SCEV *S, const SCEV *T, ScalarEvolution &SE ConstantRange X = getRange(Mul->getOperand(0), T, SE); if (X.isFullSet()) return FullSet; - const IntegerType *Ty = Context->getIntegerType(X.getBitWidth()); - const IntegerType *ExTy = Context->getIntegerType(X.getBitWidth() * + const IntegerType *Ty = Context.getIntegerType(X.getBitWidth()); + const IntegerType *ExTy = Context.getIntegerType(X.getBitWidth() * Mul->getNumOperands()); ConstantRange XExt = X.zeroExtend(ExTy->getBitWidth()); |