aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin Bogner <mail@justinbogner.com>2016-08-26 22:29:36 +0000
committerJustin Bogner <mail@justinbogner.com>2016-08-26 22:29:36 +0000
commit39b6b2f0b0e71856eb17e0eb6ca84a35f0d2b7ab (patch)
tree205212f8bb8618ca371e8233ec848c9322cf9e83
parente609a9a80a1dcf8d4eb95a679972e22c5aa0c8cb (diff)
downloadllvm-39b6b2f0b0e71856eb17e0eb6ca84a35f0d2b7ab.zip
llvm-39b6b2f0b0e71856eb17e0eb6ca84a35f0d2b7ab.tar.gz
llvm-39b6b2f0b0e71856eb17e0eb6ca84a35f0d2b7ab.tar.bz2
TableGen: Switch from a std::map to a DenseMap in CodeGenSubRegIndex. NFC
This mapping is between pointers, which DenseMap is particularly good at. Most targets aren't really affected, but if there's a lot of subregister composition this can shave off a good chunk of time from generating registers. llvm-svn: 279875
-rw-r--r--llvm/utils/TableGen/CodeGenRegisters.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/utils/TableGen/CodeGenRegisters.h b/llvm/utils/TableGen/CodeGenRegisters.h
index b8d47aa4..7a8fa12 100644
--- a/llvm/utils/TableGen/CodeGenRegisters.h
+++ b/llvm/utils/TableGen/CodeGenRegisters.h
@@ -74,8 +74,7 @@ namespace llvm {
std::string getQualifiedName() const;
// Map of composite subreg indices.
- typedef std::map<CodeGenSubRegIndex *, CodeGenSubRegIndex *,
- deref<llvm::less>> CompMap;
+ typedef DenseMap<CodeGenSubRegIndex *, CodeGenSubRegIndex *> CompMap;
// Returns the subreg index that results from composing this with Idx.
// Returns NULL if this and Idx don't compose.