9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory usage]
@ 2006-05-12 15:46 Ronald G Minnich
  2006-05-12 15:58 ` [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory quanstro
  2006-05-12 16:23 ` [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory usage] David Leimbach
  0 siblings, 2 replies; 5+ messages in thread
From: Ronald G Minnich @ 2006-05-12 15:46 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Just got this from the OLPC list. Another reason to love shared 
libaries. Are things getting kludgy here or what ...


=====
LWN lwn.net had an article this week discussing a patch that can
result is some nice memory savings for 'multi-protection VMAs'

Here is a link the relevant kernel mailing list thread

http://thread.gmane.org/gmane.linux.kernel/402675

and here is an excerpt from the lwn article,

"Ordinary Linux users could also benefit from this patch, however.
Ulrich Drepper explained how the C library uses VMAs currently; it
turns out that linking to a single shared library can create up to
five separate VMAs. An application which brings in a large number of
libraries - as many desktop applications do - can end up creating
hundreds of VMAs for shared library mappings. That leads to many VMAs
being created on the system; just how many can be seen by looking at
the vm_area_struct line in /proc/slabinfo. Your editor's system
currently has over 13,000 VMAs active, using about 2.5MB of memory.

Of the five VMAs potentially created by glibc for each shared library
mapping, four are mappings into the same file with different
permissions. The ability to have multiple permissions settings within
a single VMA has the potential to collapse those four VMAs into one,
leaving a single file mapping and an anonymous memory segment for each
library. The result would be significantly reduced memory usage and
faster kernel performance. Those benefits are likely to motivate the
inclusion of this patch, sooner or later. "



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory
  2006-05-12 15:46 [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory usage] Ronald G Minnich
@ 2006-05-12 15:58 ` quanstro
  2006-05-16 10:47   ` Paweł Lasek
  2006-05-12 16:23 ` [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory usage] David Leimbach
  1 sibling, 1 reply; 5+ messages in thread
From: quanstro @ 2006-05-12 15:58 UTC (permalink / raw)
  To: 9fans

isn't wrong to blame shared libraries for this?  don't misunderstand --- shared
libraries have plenty of drawbacks --- but this seems at first glance to be a problem with
the crossproduct of bloated applications and glibc badness?

and yes, things are getting kludgy.

- erik

> Just got this from the OLPC list. Another reason to love shared 
> libaries. Are things getting kludgy here or what ...
> 
> 



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory usage]
  2006-05-12 15:46 [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory usage] Ronald G Minnich
  2006-05-12 15:58 ` [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory quanstro
@ 2006-05-12 16:23 ` David Leimbach
  1 sibling, 0 replies; 5+ messages in thread
From: David Leimbach @ 2006-05-12 16:23 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

I love the Video Music Awards too...  and all other 3 letter acronyms

On 5/12/06, Ronald G Minnich <rminnich@lanl.gov> wrote:
> Just got this from the OLPC list. Another reason to love shared
> libaries. Are things getting kludgy here or what ...
>
>
> =====
> LWN lwn.net had an article this week discussing a patch that can
> result is some nice memory savings for 'multi-protection VMAs'
>
> Here is a link the relevant kernel mailing list thread
>
> http://thread.gmane.org/gmane.linux.kernel/402675
>
> and here is an excerpt from the lwn article,
>
> "Ordinary Linux users could also benefit from this patch, however.
> Ulrich Drepper explained how the C library uses VMAs currently; it
> turns out that linking to a single shared library can create up to
> five separate VMAs. An application which brings in a large number of
> libraries - as many desktop applications do - can end up creating
> hundreds of VMAs for shared library mappings. That leads to many VMAs
> being created on the system; just how many can be seen by looking at
> the vm_area_struct line in /proc/slabinfo. Your editor's system
> currently has over 13,000 VMAs active, using about 2.5MB of memory.
>
> Of the five VMAs potentially created by glibc for each shared library
> mapping, four are mappings into the same file with different
> permissions. The ability to have multiple permissions settings within
> a single VMA has the potential to collapse those four VMAs into one,
> leaving a single file mapping and an anonymous memory segment for each
> library. The result would be significantly reduced memory usage and
> faster kernel performance. Those benefits are likely to motivate the
> inclusion of this patch, sooner or later. "
>
>


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory
  2006-05-12 15:58 ` [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory quanstro
@ 2006-05-16 10:47   ` Paweł Lasek
  2006-05-16 16:59     ` LiteStar numnums
  0 siblings, 1 reply; 5+ messages in thread
From: Paweł Lasek @ 2006-05-16 10:47 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

On 5/12/06, quanstro@quanstro.net <quanstro@quanstro.net> wrote:
> isn't wrong to blame shared libraries for this?  don't misunderstand --- shared
> libraries have plenty of drawbacks --- but this seems at first glance to be a problem with
> the crossproduct of bloated applications and glibc badness?

I have a strong feeling that if you kick out glibc and prepare more
sensible set of core libraries (keeping all standard-compliant
functions + things like RSBAC), most of linux badness would vanish....
:D

> and yes, things are getting kludgy.
>



-- 
Paul Lasek

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory
  2006-05-16 10:47   ` Paweł Lasek
@ 2006-05-16 16:59     ` LiteStar numnums
  0 siblings, 0 replies; 5+ messages in thread
From: LiteStar numnums @ 2006-05-16 16:59 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

[-- Attachment #1: Type: text/plain, Size: 1474 bytes --]

Considering that glibc contains things like Sun RPC, I think that this is a
sensible approach. It would be nice if Dietlibc would become more
compliant...

On 5/16/06, Paweł Lasek <pawel.lasek@gmail.com> wrote:
>
> On 5/12/06, quanstro@quanstro.net <quanstro@quanstro.net> wrote:
> > isn't wrong to blame shared libraries for this?  don't misunderstand ---
> shared
> > libraries have plenty of drawbacks --- but this seems at first glance to
> be a problem with
> > the crossproduct of bloated applications and glibc badness?
>
> I have a strong feeling that if you kick out glibc and prepare more
> sensible set of core libraries (keeping all standard-compliant
> functions + things like RSBAC), most of linux badness would vanish....
> :D
>
> > and yes, things are getting kludgy.
> >
>
>
>
> --
> Paul Lasek
>



-- 
Nietzsche's first step is to accept what he knows. Atheism for him goes
without saying and is "contructive and
radical". Nietzsche's supreme vocation, so he says, is to provoke a kind of
crisis and a final decision about the
problem of atheism. The world continues on its course at random and there is
nothing final about it. Thus God
is useless, since He wants nothing in particular. If he wanted something --
and here we recognize the traditional
forumlation of the problem of evil -- He would have to assume responsiblity
for "a sum total of pain and inconsistency
which would debase the entire value of being born."
-- Albert Camus, L'Homme révolté

[-- Attachment #2: Type: text/html, Size: 1948 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2006-05-16 16:59 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-05-12 15:46 [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory usage] Ronald G Minnich
2006-05-12 15:58 ` [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory quanstro
2006-05-16 10:47   ` Paweł Lasek
2006-05-16 16:59     ` LiteStar numnums
2006-05-12 16:23 ` [9fans] [Fwd: [olpc-software] Multi-protection VMAs and memory usage] David Leimbach

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).