This is the mail archive of the libc-help@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: Impact of Increasing M_MMAP_THRESHOLD to 1GB in malloc().


* ritesh sonawane:

> I am working on system with page size 2MB and 64MB and use of malloc()
> leads to fragmentation.

What kind of fragmentation?

> To avoid this I want to increase the size of M_MMAP_THRESHOLD to
> 1GB. Is there any impact of this on bin index calculation ?

I assume this is for a 64-bit target.

You will also have to increase the heap size (the amount by which thread
arenas grow), otherwise you will end up with much more fragmenation for
certain allocation sizes.  This will mean that every thread consumes at
least 2 GiB of address space.

Thanks,
Florian


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