summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Object/MachOObjectFile.cpp
diff options
context:
space:
mode:
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>2016-01-22 22:48:02 +0000
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>2016-01-22 22:48:02 +0000
commit8af8a407fe6cc4e17c0e933331cd4c6204113cba (patch)
tree6e8671e531a031a1385ba058dfe2d472d5ad626d /llvm/lib/Object/MachOObjectFile.cpp
parent31bde8762eb26c35a166292f42bd21694994bcc8 (diff)
downloadbcm5719-llvm-8af8a407fe6cc4e17c0e933331cd4c6204113cba.tar.gz
bcm5719-llvm-8af8a407fe6cc4e17c0e933331cd4c6204113cba.zip
unordered_map: Reuse insert logic in emplace when possible, NFC
An upcoming commit will add an optimization to insert() that avoids unnecessary mallocs when we can safely extract the key type. This commit shares code between emplace() and insert(): - if emplace() is given a single argument, and - value_type is constructible from that argument so that we have a single code path for the two. I also updated the debug version of emplace_hint() to defer to emplace(), like the non-debug version does. In both cases, there should be NFC here. llvm-svn: 258575
Diffstat (limited to 'llvm/lib/Object/MachOObjectFile.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud