diff --git a/llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp b/llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp index 4616ea6ab5487..175c653f17f07 100644 --- a/llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp +++ b/llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp @@ -3072,8 +3072,7 @@ static Instruction *matchFunnelShift(Instruction &Or, InstCombinerImpl &IC) { } /// Attempt to combine or(zext(x),shl(zext(y),bw/2) concat packing patterns. -static Instruction *matchOrConcat(Instruction &Or, - InstCombiner::BuilderTy &Builder) { +static Value *matchOrConcat(Instruction &Or, InstCombiner::BuilderTy &Builder) { assert(Or.getOpcode() == Instruction::Or && "bswap requires an 'or'"); Value *Op0 = Or.getOperand(0), *Op1 = Or.getOperand(1); Type *Ty = Or.getType(); @@ -3614,7 +3613,7 @@ Instruction *InstCombinerImpl::visitOr(BinaryOperator &I) { if (Instruction *Funnel = matchFunnelShift(I, *this)) return Funnel; - if (Instruction *Concat = matchOrConcat(I, Builder)) + if (Value *Concat = matchOrConcat(I, Builder)) return replaceInstUsesWith(I, Concat); if (Instruction *R = foldBinOpShiftWithShift(I))