Linker: Share a single Metadata map for the lifetime of IRMover
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>
Sun, 17 Apr 2016 23:30:31 +0000 (23:30 +0000)
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>
Sun, 17 Apr 2016 23:30:31 +0000 (23:30 +0000)
commit565a0aa1c4130a3e252a7d210b0f5d954644e98a
tree9ce86373ed3d2a78ae29d8409b9dfca73afa09c3
parentabf6c650ac8d20f9774787e4571f82a7ea8eb2b8
Linker: Share a single Metadata map for the lifetime of IRMover

Cache the result of mapping metadata nodes between instances of IRLinker
(i.e., for the lifetime of IRMover).  There shouldn't be any real
functional change here, but this should give a major speedup.  I had
loaned this to Mehdi when he tested performance of r266446, and the two
patches together gave a 10x speedup in metadata mapping.

llvm-svn: 266579
llvm/include/llvm/Linker/IRMover.h
llvm/lib/Linker/IRMover.cpp