summaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
diff options
context:
space:
mode:
authorTeresa Johnson <tejohnson@google.com>2024-06-03 20:43:52 -0700
committerGitHub <noreply@github.com>2024-06-03 20:43:52 -0700
commit2fa059195bb54f422cc996db96ac549888268eae (patch)
treed2c68acd70489a2152ee178029ac99fcfbc1bc38 /llvm/lib/Bitcode/Reader/BitcodeReader.cpp
parentd48d108bc66adb31185ee023e1eb0ccdda2065c1 (diff)
[MemProf] Use remove_if to erase MapVector elements in bulk (#94269)
A cycle profile showed that we were spending a lot of time invoking MapVector::erase. According to https://llvm.org/docs/ProgrammersManual.html#llvm-adt-mapvector-h, erasing elements one at a time is very inefficient for MapVector and it is better to use remove_if. This change resulted in around 7% time reduction on a large thin link. While here remove an unused function that also invokes erase on MapVectors.
Diffstat (limited to 'llvm/lib/Bitcode/Reader/BitcodeReader.cpp')
0 files changed, 0 insertions, 0 deletions