Reduce string trashing.
authorBenjamin Kramer <benny.kra@googlemail.com>
Wed, 31 Mar 2010 20:15:45 +0000 (20:15 +0000)
committerBenjamin Kramer <benny.kra@googlemail.com>
Wed, 31 Mar 2010 20:15:45 +0000 (20:15 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100038 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/AsmPrinter/DwarfDebug.cpp

index 302812fefb7da67d051708f92dc9e3497dafe8d7..d81c304356d4e43ff937e1ec45e59c1805a71574 100644 (file)
@@ -92,11 +92,11 @@ public:
 
   /// addGlobal - Add a new global entity to the compile unit.
   ///
-  void addGlobal(const std::string &Name, DIE *Die) { Globals[Name] = Die; }
+  void addGlobal(StringRef Name, DIE *Die) { Globals[Name] = Die; }
 
   /// addGlobalType - Add a new global type to the compile unit.
   ///
-  void addGlobalType(const std::string &Name, DIE *Die) { 
+  void addGlobalType(StringRef Name, DIE *Die) { 
     GlobalTypes[Name] = Die; 
   }