This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Question about madvise(DONTNEED) in glibc malloc


(4/15/13 12:16 AM), Andreas Schwab wrote:
> KOSAKI Motohiro <kosaki.motohiro@gmail.com> writes:
> 
>> % git clone http://repo.or.cz/w/glibc/history.git glibc-history
> 
> This is the gitweb address, use git://repo.or.cz/glibc/history instead.

OK. I could see. Thanks a lot.

Ho, Hum. MADV_DONTNEED was introduced following commit. but previous one
is more worse. so, nobody observed any regression. understood. I could 
observed "too aggressive shrink" behavior as discussed this thread since
first ptmalloc import. So, I'm quite sure it is not glibc's fault.



commit 218c4301c2550e1254eb1ae51fac0ab1ecaba645
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Mon May 7 15:30:57 2007 +0000

        * malloc/arena.c (heap_info): Add mprotect_size field, adjust pad.
        (new_heap): Initialize mprotect_size.
        (grow_heap): When growing, only mprotect from mprotect_size till
        new_size if mprotect_size is smaller.  When shrinking, use PROT_NONE
        MMAP for __libc_enable_secure only, otherwise use MADV_DONTNEED.



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]