diff --git a/llvm/include/llvm/CodeGen/TargetLowering.h b/llvm/include/llvm/CodeGen/TargetLowering.h --- a/llvm/include/llvm/CodeGen/TargetLowering.h +++ b/llvm/include/llvm/CodeGen/TargetLowering.h @@ -3134,7 +3134,7 @@ /// It returns the types of the sequence of memory ops to perform /// memset / memcpy by reference. bool findOptimalMemOpLowering(std::vector &MemOps, unsigned Limit, - const MemOp &Op, unsigned DstAS, unsigned SrcAS, + const MemOp &Op, unsigned DstAS, const AttributeList &FuncAttributes) const; /// Check to see if the specified operand of the specified instruction is a diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp --- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp @@ -5912,8 +5912,7 @@ MemOps, Limit, MemOp::Copy(Size, DstAlignCanChange, Alignment, isZeroConstant ? 0 : SrcAlign, isVol, CopyFromConstant), - DstPtrInfo.getAddrSpace(), SrcPtrInfo.getAddrSpace(), - MF.getFunction().getAttributes())) + DstPtrInfo.getAddrSpace(), MF.getFunction().getAttributes())) return SDValue(); if (DstAlignCanChange) { @@ -6091,8 +6090,7 @@ MemOps, Limit, MemOp::Copy(Size, DstAlignCanChange, Align, SrcAlign, /*IsVolatile*/ true), - DstPtrInfo.getAddrSpace(), SrcPtrInfo.getAddrSpace(), - MF.getFunction().getAttributes())) + DstPtrInfo.getAddrSpace(), MF.getFunction().getAttributes())) return SDValue(); if (DstAlignCanChange) { @@ -6191,7 +6189,7 @@ if (!TLI.findOptimalMemOpLowering( MemOps, TLI.getMaxStoresPerMemset(OptSize), MemOp::Set(Size, DstAlignCanChange, Align, IsZeroVal, isVol), - DstPtrInfo.getAddrSpace(), ~0u, MF.getFunction().getAttributes())) + DstPtrInfo.getAddrSpace(), MF.getFunction().getAttributes())) return SDValue(); if (DstAlignCanChange) { diff --git a/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp b/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp --- a/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp @@ -178,7 +178,7 @@ bool TargetLowering::findOptimalMemOpLowering( std::vector &MemOps, unsigned Limit, const MemOp &Op, unsigned DstAS, - unsigned SrcAS, const AttributeList &FuncAttributes) const { + const AttributeList &FuncAttributes) const { // If 'SrcAlign' is zero, that means the memory operation does not need to // load the value, i.e. memset or memcpy from constant string. Otherwise, // it's the inferred alignment of the source. 'DstAlign', on the other hand, diff --git a/llvm/lib/Target/ARM/ARMTargetTransformInfo.cpp b/llvm/lib/Target/ARM/ARMTargetTransformInfo.cpp --- a/llvm/lib/Target/ARM/ARMTargetTransformInfo.cpp +++ b/llvm/lib/Target/ARM/ARMTargetTransformInfo.cpp @@ -579,8 +579,7 @@ MemOps, Limit, MemOp::Copy(Size, /*DstAlignCanChange*/ false, DstAlign, SrcAlign, /*IsVolatile*/ true), - MI->getDestAddressSpace(), MI->getSourceAddressSpace(), - F->getAttributes())) + MI->getDestAddressSpace(), F->getAttributes())) return MemOps.size() * 2; // If we can't find an optimal memop lowering, return the default cost