This is the mail archive of the
libc-help@sourceware.org
mailing list for the glibc project.
Re: pthread_exit behavior from main
(Sorry, accidentally did a Reply instead of Reply All)
On 5 October 2012 07:11, Godmar Back <godmar@gmail.com> wrote:
> Just out of curiosity, why do you madvise it with MADV_DONTNEED rather
> than munmapping it outright?
That's a performance tweak. The pthread library caches a specific
number of stacks so that they can be reused by new threads, thus
avoiding the need for repeated syscalls.
--
http://siddhesh.in