linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: "William J. Earl" <wje@cthulhu.engr.sgi.com>
To: Ingo Molnar <mingo@chiara.csoma.elte.hu>
Cc: "Benjamin C.R. LaHaise" <blah@kvack.org>,
	Rik van Riel <riel@nl.linux.org>,
	Kanoj Sarcar <kanoj@google.engr.sgi.com>,
	Jeff Garzik <jgarzik@mandrakesoft.com>,
	alan@lxorguk.ukuu.org.uk, linux-kernel@vger.rutgers.edu,
	linux-mm@kvack.org
Subject: Re: Getting big areas of memory, in 2.3.x?
Date: Thu, 9 Dec 1999 16:18:28 -0800 (PST)	[thread overview]
Message-ID: <14416.18132.295161.653334@liveoak.engr.sgi.com> (raw)
In-Reply-To: <Pine.LNX.4.10.9912100139370.12148-100000@chiara.csoma.elte.hu>

Ingo Molnar writes:
 > On Thu, 9 Dec 1999, Benjamin C.R. LaHaise wrote:
 > 
 > > The type of allocation determines what pool memory is allocated from.  
 > > Ie nonpagable kernel allocations come from one zone, atomic
 > > allocations from another and user from yet another.  It's basically
 > > the same thing that the slab does, except for pages.  The key
 > > advantage is that allocations of different types are not mixed, so the
 > > lifetime of allocations in the same zone tends to be similar and
 > > fragmentation tends to be lower.
 > 
 > well, this is perfectly possible with the current zone allocator (check
 > out how build_zonelists() builds dynamic allocation paths). I dont see
 > much point in it though, it might prevent fragmentation to a certain
 > degree, but i dont think it is a fair use of memory resources. (i'm pretty
 > sure the atomic zone would stay unused most of the time) But you might
 > want to try it out - just pass many small zones in free_area_init_core()
 > and modify build_zonelists() to have private and isolated zones for
 > GFP_ATOMIC, etc.
 > 
 > the SLAB is completely different as it has micro-units of a few pages. A
 > zoned allocator must work on a larger scale, and cannot afford wasting
 > memory on the order of those larger units.
...

     For a production implementation of large pages, the zones have to
be more dynamic.  That is, there has to be a way to move a large page
from the "moveable" zone to the "unmoveable" zone (when we run out of
"unmoveable" space and the kernel wants more), and to temporarily
put moveable (small) pages in the "unmoveable" zone, to avoid just
this inefficient use of memory.  (This assumes that an allocation
of an "unmoveable" page will evict a "moveable" page from the "unmoveable"
zone before expanding the "unmoveable" zone, if there are no free
pages left in the "unmoveable" zone.)

    Even this scheme is, of course, not a perfect solution, if there
are multiple large page sizes, and "unmoveable" allocations can
request a page of any size, since one could then wind up with
fragmentation of unmoveable memory.  A reasonable compromise might be
to force "ummoveable" allocations larger than a basic page to some
particular large page size, make that page size the unit of additions
to the "unmoveable" zone, and delete from the "unmoveable" zone any
large pages which hecome entirely free (or composed only of free and
"moveable" pages).  This last is what I did on the SGI O2.  It still
allows for "moveable" large pages of any size, which gains the
efficiency benefits of large pages for applications, at the cost
of limiting driver and other kernel allocations to the specific large
page size.

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://humbolt.geo.uu.nl/Linux-MM/

  reply	other threads:[~1999-12-10  0:18 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-12-09  1:03 Jeff Garzik
1999-12-09  2:28 ` Alan Cox
1999-12-09  2:45   ` Jeff Garzik
1999-12-09  5:22     ` Oliver Xymoron
1999-12-09 12:25     ` Ingo Molnar
1999-12-09 20:24       ` Jeff Garzik
1999-12-09 20:31         ` Kanoj Sarcar
1999-12-09 20:39           ` Rik van Riel
1999-12-09 20:54             ` Kanoj Sarcar
1999-12-09 23:21               ` Ingo Molnar
1999-12-09 22:27                 ` Kanoj Sarcar
1999-12-09 23:16             ` Ingo Molnar
1999-12-09 23:09               ` Benjamin C.R. LaHaise
1999-12-10  0:44                 ` Ingo Molnar
1999-12-10  0:18                   ` William J. Earl [this message]
1999-12-11 19:56                   ` Stephen C. Tweedie
1999-12-10 12:21               ` Rik van Riel
1999-12-10 13:42                 ` Ingo Molnar
1999-12-10 18:04                   ` William J. Earl
1999-12-09 20:50           ` William J. Earl
1999-12-09 23:15         ` Ingo Molnar
1999-12-09 22:13           ` William J. Earl
1999-12-09 22:26             ` Alan Cox
1999-12-09 23:42               ` William J. Earl
1999-12-09 23:50                 ` Alan Cox
1999-12-10  0:30                   ` William J. Earl
1999-12-10  0:37                     ` Alan Cox
1999-12-10  4:19                   ` Oliver Xymoron
1999-12-10 10:14                   ` Thomas Sailer
1999-12-09 23:24             ` Ingo Molnar
1999-12-09 22:33               ` Jeff Garzik
1999-12-09 23:32               ` Rogier Wolff
1999-12-09 23:44                 ` JF Martinez
1999-12-10  0:52                   ` Ingo Molnar
1999-12-09 23:46                 ` Andi Kleen
1999-12-10 13:52       ` Stephen C. Tweedie

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=14416.18132.295161.653334@liveoak.engr.sgi.com \
    --to=wje@cthulhu.engr.sgi.com \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=blah@kvack.org \
    --cc=jgarzik@mandrakesoft.com \
    --cc=kanoj@google.engr.sgi.com \
    --cc=linux-kernel@vger.rutgers.edu \
    --cc=linux-mm@kvack.org \
    --cc=mingo@chiara.csoma.elte.hu \
    --cc=riel@nl.linux.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox