diff options
author | Quentin Colombet <qcolombet@apple.com> | 2015-05-09 00:02:06 +0000 |
---|---|---|
committer | Quentin Colombet <qcolombet@apple.com> | 2015-05-09 00:02:06 +0000 |
commit | 3e93ebecb8aadbe80424ce9dc292b4bbe28dc17d (patch) | |
tree | 5923ad4b0536698433e1bb5a151662f2c4f3f193 /llvm/lib/IR/Verifier.cpp | |
parent | 2c29cd697e5e9fa00c42dd10c86a61ed183f29db (diff) | |
download | bcm5719-llvm-3e93ebecb8aadbe80424ce9dc292b4bbe28dc17d.tar.gz bcm5719-llvm-3e93ebecb8aadbe80424ce9dc292b4bbe28dc17d.zip |
Revert r236912.
Author: dblaikie
Date: Fri May 8 17:47:50 2015
New Revision: 236912
URL: http://llvm.org/viewvc/llvm-project?rev=236912&view=rev
Log:
[opaque pointer type] Cleanup a few references to pointee types using nearby non-pointee types of the same value
& cleanup a convoluted return expression while I'm here
llvm-svn: 236919
Diffstat (limited to 'llvm/lib/IR/Verifier.cpp')
-rw-r--r-- | llvm/lib/IR/Verifier.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/IR/Verifier.cpp b/llvm/lib/IR/Verifier.cpp index 49f8a7ca4a1..374f8f210be 100644 --- a/llvm/lib/IR/Verifier.cpp +++ b/llvm/lib/IR/Verifier.cpp @@ -1503,7 +1503,7 @@ void Verifier::VerifyStatepoint(ImmutableCallSite CS) { const PointerType *PT = dyn_cast<PointerType>(Target->getType()); Assert(PT && PT->getElementType()->isFunctionTy(), "gc.statepoint callee must be of function pointer type", &CI, Target); - FunctionType *TargetFuncType = CS.getFunctionType(); + FunctionType *TargetFuncType = cast<FunctionType>(PT->getElementType()); const Value *NumCallArgsV = CS.getArgument(1); Assert(isa<ConstantInt>(NumCallArgsV), @@ -3065,8 +3065,8 @@ bool Verifier::VerifyIntrinsicType(Type *Ty, dyn_cast<PointerType>(ThisArgVecTy->getVectorElementType()); if (!ThisArgEltTy) return true; - return ThisArgEltTy->getElementType() != - ReferenceType->getVectorElementType(); + return (!(ThisArgEltTy->getElementType() == + ReferenceType->getVectorElementType())); } } llvm_unreachable("unhandled"); @@ -3192,7 +3192,7 @@ void Verifier::visitIntrinsicFunctionCall(Intrinsic::ID ID, CallInst &CI) { Assert(AI, "llvm.gcroot parameter #1 must be an alloca.", &CI); Assert(isa<Constant>(CI.getArgOperand(1)), "llvm.gcroot parameter #2 must be a constant.", &CI); - if (!AI->getAllocatedType()->isPointerTy()) { + if (!AI->getType()->getElementType()->isPointerTy()) { Assert(!isa<ConstantPointerNull>(CI.getArgOperand(1)), "llvm.gcroot parameter #1 must either be a pointer alloca, " "or argument #2 must be a non-null constant.", |