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 | dd8cec59fc6b3b3a97932c56b6e6aa8c6453df39 (patch) | |
| tree | f3bafc8afbd59018d83daf5e443aa8f080a018c9 /lib/Bytecode/Reader/Analyzer.cpp | |
| parent | 042ad36871d67a2db48bf41a8dbde3a5676fc96f (diff) | |
| download | llvm-dd8cec59fc6b3b3a97932c56b6e6aa8c6453df39.tar.gz llvm-dd8cec59fc6b3b3a97932c56b6e6aa8c6453df39.tar.bz2 llvm-dd8cec59fc6b3b3a97932c56b6e6aa8c6453df39.tar.xz | |
avoid creating a temporary string when reading the symbol table for a
module. This speeds up the bcreader 11%.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34198 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Bytecode/Reader/Analyzer.cpp')
| -rw-r--r-- | lib/Bytecode/Reader/Analyzer.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Bytecode/Reader/Analyzer.cpp b/lib/Bytecode/Reader/Analyzer.cpp index fe503f4d12..880605c40f 100644 --- a/lib/Bytecode/Reader/Analyzer.cpp +++ b/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; } |
