diff options
author | Chris Lattner <sabre@nondot.org> | 2007-02-12 18:53:43 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2007-02-12 18:53:43 +0000 |
commit | 8d160d68b8fc40ed50c2e0f928c40f57ec886915 (patch) | |
tree | bc586072d32bf81b5d2abd1bde893614e81cc024 /llvm/lib/Bytecode/Reader/Analyzer.cpp | |
parent | 1a5de584dca538300a570502be6c15942cc7d3cd (diff) | |
download | bcm5719-llvm-8d160d68b8fc40ed50c2e0f928c40f57ec886915.tar.gz bcm5719-llvm-8d160d68b8fc40ed50c2e0f928c40f57ec886915.zip |
avoid creating a temporary string when reading the symbol table for a
module. This speeds up the bcreader 11%.
llvm-svn: 34198
Diffstat (limited to 'llvm/lib/Bytecode/Reader/Analyzer.cpp')
-rw-r--r-- | llvm/lib/Bytecode/Reader/Analyzer.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Bytecode/Reader/Analyzer.cpp b/llvm/lib/Bytecode/Reader/Analyzer.cpp index fe503f4d124..880605c40fc 100644 --- a/llvm/lib/Bytecode/Reader/Analyzer.cpp +++ b/llvm/lib/Bytecode/Reader/Analyzer.cpp @@ -250,10 +250,10 @@ public: } virtual void handleSymbolTableValue(unsigned TySlot, unsigned ValSlot, - const std::string& name) { + const char *Name, unsigned NameLen) { if (os) *os << " Value " << TySlot << " Slot=" << ValSlot - << " Name: " << name << "\n"; + << " Name: " << std::string(Name, Name+NameLen) << "\n"; if (ValSlot > bca.maxValueSlot) bca.maxValueSlot = ValSlot; } |