diff --git a/llvm/lib/CodeGen/RDFGraph.cpp b/llvm/lib/CodeGen/RDFGraph.cpp index 6276a4722e3f0..ff0fd61078c0b 100644 --- a/llvm/lib/CodeGen/RDFGraph.cpp +++ b/llvm/lib/CodeGen/RDFGraph.cpp @@ -264,7 +264,7 @@ raw_ostream &operator<<(raw_ostream &OS, const Print &P) { MachineBasicBlock *BB = P.Obj.Addr->getCode(); unsigned NP = BB->pred_size(); std::vector Ns; - auto PrintBBs = [&OS](std::vector Ns) -> void { + auto PrintBBs = [&OS](const std::vector &Ns) -> void { unsigned N = Ns.size(); for (int I : Ns) { OS << "%bb." << I;