Re: [patch] mmap-speedup-2.5.42-C3

From: Jakub Jelinek (jakub@redhat.com)
Date: Wed Oct 16 2002 - 03:22:09 EST


On Wed, Oct 16, 2002 at 10:27:07AM +0200, Ingo Molnar wrote:
>
> On Wed, 16 Oct 2002, Jakub Jelinek wrote:
>
> > Libraries mapped by dynamic linker are mapped without MAP_FIXED and
> > unless you use prelinking, with 0 virtual address, ie. they all end up
> > above 1GB. And 99% of libraries uses different protections, for the
> > read-only and read-write segment.
>
> right - only the bss (brk-allocated) ones are below 1GB it appears. I did
> a quick check on a KDE app and 3 mappings were below 1GB, and 116(!)
> mappings were above 1GB. And even if it wasnt for the different
> protections, they use different files to map to so they have to be in
> different vmas, no matter what.
>
> i'm wondering about prelinking though - wont that reduce the number of
> mappings radically?

It won't, the number of mappings will be exactly the same. It still needs
to mmap all the libraries and honour the protections.
But you might have holes in between the mappings if prelinking, while
you usually don't have many if not prelinking.
That's because prelink assigns a separate VA slot for each library (well,
with --conserve-memory two libraries might get the same VA slot if they
never appear together in any program).

        Jakub
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Wed Oct 23 2002 - 22:00:27 EST