diff --git a/llvm/lib/Transforms/Scalar/InferAddressSpaces.cpp b/llvm/lib/Transforms/Scalar/InferAddressSpaces.cpp --- a/llvm/lib/Transforms/Scalar/InferAddressSpaces.cpp +++ b/llvm/lib/Transforms/Scalar/InferAddressSpaces.cpp @@ -523,7 +523,7 @@ collectRewritableIntrinsicOperands(II, PostorderStack, Visited); else if (ICmpInst *Cmp = dyn_cast(&I)) { // FIXME: Handle vectors of pointers - if (getPtrOrVecOfPtrsAddressSpace(Cmp->getOperand(0)->getType())) { + if (isPtrOrVecOfPtrsType(Cmp->getOperand(0)->getType())) { PushPtrOperand(Cmp->getOperand(0)); PushPtrOperand(Cmp->getOperand(1)); } @@ -802,7 +802,7 @@ const PredicatedAddrSpaceMapTy &PredicatedAS, SmallVectorImpl *UndefUsesToFix) const { // All values in Postorder are flat address expressions. - assert(isPtrOrVecOfPtrsType(V->getType()) == FlatAddrSpace && + assert(getPtrOrVecOfPtrsAddressSpace(V->getType()) == FlatAddrSpace && isAddressExpression(*V, *DL, TTI)); if (Instruction *I = dyn_cast(V)) {