diff options
author | Duncan P. N. Exon Smith <dexonsmith@apple.com> | 2014-11-11 21:30:22 +0000 |
---|---|---|
committer | Duncan P. N. Exon Smith <dexonsmith@apple.com> | 2014-11-11 21:30:22 +0000 |
commit | de36e8040fa72a8242de3fa4a2d663e1c8d0c225 (patch) | |
tree | f0f67024e641b7bbfa0282cae2ba097128370b06 /llvm/lib/Analysis/ValueTracking.cpp | |
parent | 6312f4a422ddcb6a262ffc9fd3699cd2ec570425 (diff) | |
download | bcm5719-llvm-de36e8040fa72a8242de3fa4a2d663e1c8d0c225.tar.gz bcm5719-llvm-de36e8040fa72a8242de3fa4a2d663e1c8d0c225.zip |
Revert "IR: MDNode => Value"
Instead, we're going to separate metadata from the Value hierarchy. See
PR21532.
This reverts commit r221375.
This reverts commit r221373.
This reverts commit r221359.
This reverts commit r221167.
This reverts commit r221027.
This reverts commit r221024.
This reverts commit r221023.
This reverts commit r220995.
This reverts commit r220994.
llvm-svn: 221711
Diffstat (limited to 'llvm/lib/Analysis/ValueTracking.cpp')
-rw-r--r-- | llvm/lib/Analysis/ValueTracking.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/Analysis/ValueTracking.cpp b/llvm/lib/Analysis/ValueTracking.cpp index f8b226d9515..9532e34a8c3 100644 --- a/llvm/lib/Analysis/ValueTracking.cpp +++ b/llvm/lib/Analysis/ValueTracking.cpp @@ -862,7 +862,7 @@ void computeKnownBits(Value *V, APInt &KnownZero, APInt &KnownOne, switch (I->getOpcode()) { default: break; case Instruction::Load: - if (MDNode *MD = cast<LoadInst>(I)->getMDNode(LLVMContext::MD_range)) + if (MDNode *MD = cast<LoadInst>(I)->getMetadata(LLVMContext::MD_range)) computeKnownBitsFromRangeMetadata(*MD, KnownZero); break; case Instruction::And: { @@ -1258,7 +1258,7 @@ void computeKnownBits(Value *V, APInt &KnownZero, APInt &KnownOne, } case Instruction::Call: case Instruction::Invoke: - if (MDNode *MD = cast<Instruction>(I)->getMDNode(LLVMContext::MD_range)) + if (MDNode *MD = cast<Instruction>(I)->getMetadata(LLVMContext::MD_range)) computeKnownBitsFromRangeMetadata(*MD, KnownZero); // If a range metadata is attached to this IntrinsicInst, intersect the // explicit range specified by the metadata and the implicit range of @@ -1533,7 +1533,7 @@ bool isKnownNonZero(Value *V, const DataLayout *TD, unsigned Depth, } if (Instruction* I = dyn_cast<Instruction>(V)) { - if (MDNode *Ranges = I->getMDNode(LLVMContext::MD_range)) { + if (MDNode *Ranges = I->getMetadata(LLVMContext::MD_range)) { // If the possible ranges don't contain zero, then the value is // definitely non-zero. if (IntegerType* Ty = dyn_cast<IntegerType>(V->getType())) { |