aboutsummaryrefslogtreecommitdiff
path: root/libc/utils
diff options
context:
space:
mode:
authorKostya Kortchinsky <kostyak@google.com>2020-07-27 09:13:42 -0700
committerKostya Kortchinsky <kostyak@google.com>2020-07-28 11:57:54 -0700
commit6f00f3b56e5a13286142facd929be15ab7b17aa3 (patch)
tree784f92b2da443d0fc112b4d14d8164a39f7ca6f1 /libc/utils
parent3f7249046a87e08272957d12bff73295fc4f0e8c (diff)
downloadllvm-6f00f3b56e5a13286142facd929be15ab7b17aa3.zip
llvm-6f00f3b56e5a13286142facd929be15ab7b17aa3.tar.gz
llvm-6f00f3b56e5a13286142facd929be15ab7b17aa3.tar.bz2
[scudo][standalone] mallopt runtime configuration options
Summary: Partners have requested the ability to configure more parts of Scudo at runtime, notably the Secondary cache options (maximum number of blocks cached, maximum size) as well as the TSD registry options (the maximum number of TSDs in use). This CL adds a few more Scudo specific `mallopt` parameters that are passed down to the various subcomponents of the Combined allocator. - `M_CACHE_COUNT_MAX`: sets the maximum number of Secondary cached items - `M_CACHE_SIZE_MAX`: sets the maximum size of a cacheable item in the Secondary - `M_TSDS_COUNT_MAX`: sets the maximum number of TSDs that can be used (Shared Registry only) Regarding the TSDs maximum count, this is a one way option, only allowing to increase the count. In order to allow for this, I rearranged the code to have some `setOption` member function to the relevant classes, using the `scudo::Option` class enum to determine what is to be set. This also fixes an issue where a static variable (`Ready`) was used in templated functions without being set back to `false` every time. Reviewers: pcc, eugenis, hctim, cferris Subscribers: jfb, llvm-commits, #sanitizers Tags: #sanitizers Differential Revision: https://reviews.llvm.org/D84667
Diffstat (limited to 'libc/utils')
0 files changed, 0 insertions, 0 deletions