Make {A, L}San allocator more compact. 60/98760/1
authorMaxim Ostapenko <m.ostapenko@samsung.com>
Thu, 17 Nov 2016 12:58:25 +0000 (15:58 +0300)
committerMaxim Ostapenko <m.ostapenko@samsung.com>
Fri, 18 Nov 2016 13:11:46 +0000 (16:11 +0300)
commita305b1d31e7d8b4a254cb148a1126efd9bbb75c9
treeea3ce870ca8d301b38c30822a788ebe64207496e
parent39f2b46347df63764f20e33ee29c6887c5ec7a90
Make {A, L}San allocator more compact.

This change tries to reduce memory consumption of {A, L}Saned image by hacking
primary allocator internals:

* Reduce region size 2^20 -> 2^17.
* Make largest chunk size in primary allocator 2^17 -> 2^16.

The change appears to be quite useful for LSan'ed image:

Stock version:
           total      used      free     shared    buffers     cached
Mem:        964        828       136        3         4         92

Patched version:
           total      used      free     shared    buffers     cached
Mem:        964        688       275        5         13        185

Change-Id: I80b95f7dfb5a7be0e7208567a31606a3d027256c
Signed-off-by: Maxim Ostapenko <m.ostapenko@samsung.com>
libsanitizer/asan/asan_allocator.h
libsanitizer/lsan/lsan_allocator.cc
libsanitizer/sanitizer_common/sanitizer_allocator.h