[llvm] r222779 - Move a vector instead of copying it.

Craig Topper craig.topper at gmail.com
Tue Nov 25 12:11:25 PST 2014


Author: ctopper
Date: Tue Nov 25 14:11:25 2014
New Revision: 222779

URL: http://llvm.org/viewvc/llvm-project?rev=222779&view=rev
Log:
Move a vector instead of copying it.

Modified:
    llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp

Modified: llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp?rev=222779&r1=222778&r2=222779&view=diff
==============================================================================
--- llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp (original)
+++ llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp Tue Nov 25 14:11:25 2014
@@ -350,7 +350,7 @@ void AsmWriterEmitter::EmitPrintInstruct
   // in the opcode-indexed table.
   unsigned BitsLeft = 64-AsmStrBits;
 
-  std::vector<std::vector<std::string> > TableDrivenOperandPrinters;
+  std::vector<std::vector<std::string>> TableDrivenOperandPrinters;
 
   while (1) {
     std::vector<std::string> UniqueOperandCommands;
@@ -393,7 +393,7 @@ void AsmWriterEmitter::EmitPrintInstruct
     }
 
     // Remember the handlers for this set of operands.
-    TableDrivenOperandPrinters.push_back(UniqueOperandCommands);
+    TableDrivenOperandPrinters.push_back(std::move(UniqueOperandCommands));
   }
 
 





More information about the llvm-commits mailing list