summaryrefslogtreecommitdiff
path: root/libc/malloc_hooks/malloc_hooks.cpp
diff options
context:
space:
mode:
authorRyan Prichard <rprichard@google.com>2019-06-17 17:57:19 -0700
committerRyan Prichard <rprichard@google.com>2019-07-22 16:03:44 -0700
commit750faa515a232d20330e258dc4416dbc9a07446e (patch)
treea89e883ab830154cd688bfcfbb9cfab9af892e26 /libc/malloc_hooks/malloc_hooks.cpp
parent58c698f230a7efb4231801514d65998f0c925154 (diff)
Name stack+tls VMAs with PR_SET_VMA_ANON_NAME
Bionic creates a single thread mapping to hold a thread's stack and static TLS memory. Use PR_SET_VMA_ANON_NAME to name this region "stack_and_tls:tid". dumpsys meminfo can report this region as "Stack" memory. The main thread's memory is instead named stack_and_tls:main, and the VMA is renamed to stack_and_tls:main in a post-fork child. For the main thread, and threads using pthread_attr_setstack, Bionic still creates the stack_and_tls mapping, but it only has TLS memory in it. Bug: http://b/134795155 Test: run "dumpsys meminfo" and verify that this CL increases the reported stack memory usage from about 4MB to 21MB. Change-Id: Id1f39ff083329e83426130b4ef94222ffacb90ae
Diffstat (limited to 'libc/malloc_hooks/malloc_hooks.cpp')
0 files changed, 0 insertions, 0 deletions