diff options
author | Owen Anderson <resistor@mac.com> | 2008-06-26 17:20:16 +0000 |
---|---|---|
committer | Owen Anderson <resistor@mac.com> | 2008-06-26 17:20:16 +0000 |
commit | 8001524f43c0d04b7576efceefeac9be27f7dc0c (patch) | |
tree | 0bf490fee63590c73520ae9d379ce309da4899c1 | |
parent | f77e46be6d7c15656009c1e96423c4cdc3e60aa2 (diff) | |
download | llvm-8001524f43c0d04b7576efceefeac9be27f7dc0c.tar.gz llvm-8001524f43c0d04b7576efceefeac9be27f7dc0c.tar.bz2 llvm-8001524f43c0d04b7576efceefeac9be27f7dc0c.tar.xz |
Use a DenseMap instead of an std::map for mangled name lookup. This is
improves AsmPrinter runtime on instcombine from 0.3920s to 0.3836s.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52787 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | include/llvm/Support/Mangler.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/llvm/Support/Mangler.h b/include/llvm/Support/Mangler.h index 39ac26dd1b..0a7b33a232 100644 --- a/include/llvm/Support/Mangler.h +++ b/include/llvm/Support/Mangler.h @@ -14,6 +14,7 @@ #ifndef LLVM_SUPPORT_MANGLER_H #define LLVM_SUPPORT_MANGLER_H +#include "llvm/ADT/DenseMap.h" #include <map> #include <set> #include <string> @@ -40,7 +41,7 @@ class Mangler { /// Memo - This is used to remember the name that we assign a value. /// - std::map<const Value*, std::string> Memo; + DenseMap<const Value*, std::string> Memo; /// Count - This simple counter is used to unique value names. /// |