aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Object/IRObjectFile.cpp
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2021-07-11 15:12:24 +0200
committerDmitry Vyukov <dvyukov@google.com>2021-07-12 19:21:15 +0200
commit072669521456a369409cf9db30739a3fac740173 (patch)
treeac3af0888ba2794f57507f11abd95d45a05f03a0 /llvm/lib/Object/IRObjectFile.cpp
parentb270c3fbdeae62d4e1aeb90d848eec4fdd22b5de (diff)
downloadllvm-072669521456a369409cf9db30739a3fac740173.zip
llvm-072669521456a369409cf9db30739a3fac740173.tar.gz
llvm-072669521456a369409cf9db30739a3fac740173.tar.bz2
sanitizer_common: optimize memory drain
Currently we allocate MemoryMapper per size class. MemoryMapper mmap's and munmap's internal buffer. This results in 50 mmap/munmap calls under the global allocator mutex. Reuse MemoryMapper and the buffer for all size classes. This radically reduces number of mmap/munmap calls. Smaller size classes tend to have more objects allocated, so it's highly likely that the buffer allocated for the first size class will be enough for all subsequent size classes. Reviewed By: melver Differential Revision: https://reviews.llvm.org/D105778
Diffstat (limited to 'llvm/lib/Object/IRObjectFile.cpp')
0 files changed, 0 insertions, 0 deletions