From: Mel Gorman <mel@csn.ul.ie>
To: Nick Piggin <nickpiggin@yahoo.com.au>
Cc: jschopp@austin.ibm.com, "Martin J. Bligh" <mbligh@mbligh.org>,
linux-mm@kvack.org, lkml <linux-kernel@vger.kernel.org>,
Andrew Morton <akpm@osdl.org>
Subject: Re: Avoiding external fragmentation with a placement policy Version 12
Date: Fri, 3 Jun 2005 14:05:47 +0100 (IST) [thread overview]
Message-ID: <Pine.LNX.4.58.0506031349280.10779@skynet> (raw)
In-Reply-To: <1117770488.5084.25.camel@npiggin-nld.site>
On Fri, 3 Jun 2005, Nick Piggin wrote:
> On Thu, 2005-06-02 at 10:52 -0500, Joel Schopp wrote:
> > > I see your point... Mel's patch has failure cases though.
> > > For example, someone turns swap off, or mlocks some memory
> > > (I guess we then add the page migration defrag patch and
> > > problem is solved?).
> >
> > This reminds me that page migration defrag will be pretty useless
> > without something like this done first. There will be stuff that can't
> > be migrated and it needs to be grouped together somehow.
> >
> > In summary here are the reasons I see to run with Mel's patch:
> >
> > 1. It really helps with medium-large allocations under memory pressure.
> > 2. Page migration defrag will need it.
> > 3. Memory hotplug remove will need it.
> >
>
> I guess I'm now more convinced of its need ;)
>
> add:
> 4. large pages
> 5. (hopefully) helps with smaller allocations (ie. order 3)
>
6. Avoid calls to the page allocator
If a subsystem needs 8 pages to do a job, it should only have to call the
allocator once, not 8 times only to spend more time breaking the work up
into page-sized chunks.
If you look at rmqueue_bulk() in the patch, you'll see that it tries to
fill the per-cpu lists of order-0 pages with one call to the allocator
which saved some time. The additional statistics patch shows how many of
these bulk requests are made and what sizes were actually allocated. It
shows that a sizable number of additional calls to the buddy allocator are
avoided.
> It would really help your cause in the short term if you can
> demonstrate improvements for say order-3 allocations (eg. use
> gige networking, TSO, jumbo frames, etc).
>
I will work on this early next week unless someone else does not beat me
to it. Right now, I need to catch a flight and I'll be offline for a few
days.
Once I start, I'm going to be running tests on network filesystems mounted
on the loopback device to see what sort of results I find.
>
> > On the downside we have:
> >
> > 1. Slightly more complexity in the allocator.
> >
>
> For some definitions of 'slightly', perhaps :(
>
Does it need more documentation? If so, I'll write up a detailed blurb on
how it works and drop it into Documentation/
> Although I can't argue that a buddy allocator is no good without
> being able to satisfy higher order allocations.
>
Unfortunately, it is a fundemental flaw of the buddy allocator that it
fragments badly. The thing is, other allocators that do not fragment are
also slower.
> So in that case, I'm personally OK with it going into -mm. Hopefully
> there will be a bit more review and hopefully some simplification if
> possible.
>
Fingers crossed. I would be very interested to see anything that makes it
simplier.
> Last question: how does it go on systems with really tiny memories?
> (4MB, 8MB, that kind of thing).
>
I tested it with mem=16M (anything lower and my machine doesn't boot the
standard kernel with going OOM, let alone the patched one). There was no
significant change in performance of the aim9 benchmarks. The additional
memory overhead of the patch is insignificant.
However, at low memory, the fragmentation strategy does not work unless
MAX_ORDER is also dropped. As the block reservations are 2^MAX_ORDER in
size, there is no point reserving anything if the system only has 4
MAX_ORDER blocks to being with.
--
Mel Gorman
Part-time Phd Student Java Applications Developer
University of Limerick IBM Dublin Software Lab
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"aart@kvack.org"> aart@kvack.org </a>
next prev parent reply other threads:[~2005-06-03 13:05 UTC|newest]
Thread overview: 42+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-05-31 11:20 Mel Gorman
2005-06-01 20:55 ` Joel Schopp
2005-06-01 23:09 ` Nick Piggin
2005-06-01 23:23 ` David S. Miller, Nick Piggin
2005-06-01 23:28 ` Martin J. Bligh
2005-06-01 23:43 ` Nick Piggin
2005-06-02 0:02 ` Martin J. Bligh
2005-06-02 0:20 ` Nick Piggin
2005-06-02 13:55 ` Mel Gorman
2005-06-02 15:52 ` Joel Schopp
2005-06-02 19:50 ` Ray Bryant
2005-06-02 20:10 ` Joel Schopp
2005-06-04 16:09 ` Marcelo Tosatti
2005-06-03 3:48 ` Nick Piggin
2005-06-03 4:49 ` David S. Miller, Nick Piggin
2005-06-03 5:34 ` Martin J. Bligh
2005-06-03 5:37 ` David S. Miller, Martin J. Bligh
2005-06-03 5:42 ` Martin J. Bligh
2005-06-03 5:51 ` David S. Miller, Martin J. Bligh
2005-06-03 13:13 ` Mel Gorman
2005-06-03 6:43 ` Nick Piggin
2005-06-03 13:57 ` Martin J. Bligh
2005-06-03 16:43 ` Dave Hansen
2005-06-03 18:43 ` David S. Miller, Dave Hansen
2005-06-04 1:44 ` Herbert Xu
2005-06-04 2:15 ` Nick Piggin
2005-06-05 19:52 ` David S. Miller, Nick Piggin
2005-06-03 13:05 ` Mel Gorman [this message]
2005-06-03 14:00 ` Martin J. Bligh
2005-06-08 17:03 ` Mel Gorman
2005-06-08 17:18 ` Martin J. Bligh
2005-06-10 16:20 ` Christoph Lameter
2005-06-10 17:53 ` Steve Lord
2005-06-02 18:28 ` Andi Kleen
2005-06-02 18:42 ` Martin J. Bligh
2005-06-02 13:15 ` Mel Gorman
2005-06-02 14:01 ` Martin J. Bligh
[not found] ` <20050603174706.GA25663@localhost.localdomain>
2005-06-03 17:56 ` Martin J. Bligh
2005-06-01 23:47 ` Mike Kravetz
2005-06-01 23:56 ` Nick Piggin
2005-06-02 0:07 ` Mike Kravetz
2005-06-02 9:49 ` Mel Gorman
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=Pine.LNX.4.58.0506031349280.10779@skynet \
--to=mel@csn.ul.ie \
--cc=akpm@osdl.org \
--cc=jschopp@austin.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mbligh@mbligh.org \
--cc=nickpiggin@yahoo.com.au \
/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