diff options
author | Wilco Dijkstra <wdijkstr@arm.com> | 2017-10-24 12:39:24 +0100 |
---|---|---|
committer | Wilco Dijkstra <wdijkstr@arm.com> | 2017-10-24 12:39:24 +0100 |
commit | 3f6bb8a32e5f5efd78ac08c41e623651cc242a89 (patch) | |
tree | 268b445ef692deca0158cdd4832b0cc925538703 /sysdeps/unix/bsd | |
parent | 1d479c8c33bab8c47f66c2199a353b5459881be3 (diff) | |
download | glibc-3f6bb8a32e5f5efd78ac08c41e623651cc242a89.zip glibc-3f6bb8a32e5f5efd78ac08c41e623651cc242a89.tar.gz glibc-3f6bb8a32e5f5efd78ac08c41e623651cc242a89.tar.bz2 |
Add single-threaded path to malloc/realloc/calloc/memalloc
This patch adds a single-threaded fast path to malloc, realloc,
calloc and memalloc. When we're single-threaded, we can bypass
arena_get (which always locks the arena it returns) and just use
the main arena. Also avoid retrying a different arena since
there is just the main arena.
* malloc/malloc.c (__libc_malloc): Add SINGLE_THREAD_P path.
(__libc_realloc): Likewise.
(_mid_memalign): Likewise.
(__libc_calloc): Likewise.
Diffstat (limited to 'sysdeps/unix/bsd')
0 files changed, 0 insertions, 0 deletions