From: Vlastimil Babka <vbabka@suse.cz>
To: Andrew Morton <akpm@linux-foundation.org>,
David Rientjes <rientjes@google.com>
Cc: linux-kernel@vger.kernel.org, linux-mm@vger.kernel.org,
Vlastimil Babka <vbabka@suse.cz>,
Christoph Lameter <cl@linux.com>,
Joonsoo Kim <iamjoonsoo.kim@lge.com>,
Mel Gorman <mgorman@suse.de>,
Michal Nazarewicz <mina86@mina86.com>,
Minchan Kim <minchan@kernel.org>,
Naoya Horiguchi <n-horiguchi@ah.jp.nec.com>,
Rik van Riel <riel@redhat.com>,
Zhang Yanfei <zhangyanfei@cn.fujitsu.com>
Subject: [PATCH v5 00/14] compaction: balancing overhead and success rates
Date: Mon, 28 Jul 2014 15:11:27 +0200 [thread overview]
Message-ID: <1406553101-29326-1-git-send-email-vbabka@suse.cz> (raw)
Based on next-20140728.
Here's v5 of the series. I declared v4 ready on friday, so obviously I had to
immediately realize there's bug in one of the patches. So here's a new posting
with these changes:
- Patch 14 had two issues in v4. The major issue was leaking captured pages
when called from compact_pgdat() by kswapd. I thought that checking for
cc->order is enough to recognize a direct compaction, but missed that kswapd
also uses an order > 0 and does not consume any page. Fixed by adopting the
approach in original capture commit 1fb3f8ca0e92: cc->capture_page is no
longer a "struct page *", but "struct page **" and only when it's non-NULL
(in direct compaction) it means the caller wants a captured page pointer
filled there.
The minor issue was that during changes from v3 and v4, a rebase snafu lead
to removing the check whether to capture pages, based on matching pageblock
migratetype. So it could e.g. capture a page for UNMOVABLE allocation inside
a MOVABLE pageblock, which is undesired. So in v5 the check is back and
slightly improved by observing that if we want the whole pageblock, it does
not matter what its migratetype is.
- Patch 15 dropped for now (was always RFC), will appear in future series, as
it was negatively affecting extfrag. The (theoretical so far) explanation is
that by aggressively skipping a pageblock as soon as it cannot be completely
compacted, we fail to create lower-than-9-order free pages that could still
be otherwise created. Since page stealing works by stealing the
highest-order-available page and then satisfying potentially many allocations
from that, lack of high-order pages means more stealing events in potentially
more different pageblocks, so that many MOVABLE pageblocks are polluted, each
by only a few UNMOVABLE pages, which is still enough to kill the pageblocks
for the purposes of THP(-like) allocation.
- Patch 7 has benchmark data included.
- Checkpatch fixes applied, Acked-by's from Mel added.
David Rientjes (2):
mm: rename allocflags_to_migratetype for clarity
mm, compaction: pass gfp mask to compact_control
Vlastimil Babka (12):
mm, THP: don't hold mmap_sem in khugepaged when allocating THP
mm, compaction: defer each zone individually instead of preferred zone
mm, compaction: do not count compact_stall if all zones skipped
compaction
mm, compaction: do not recheck suitable_migration_target under lock
mm, compaction: move pageblock checks up from
isolate_migratepages_range()
mm, compaction: reduce zone checking frequency in the migration
scanner
mm, compaction: khugepaged should not give up due to need_resched()
mm, compaction: periodically drop lock and restore IRQs in scanners
mm, compaction: skip rechecks when lock was already held
mm, compaction: remember position within pageblock in free pages
scanner
mm, compaction: skip buddy pages by their order in the migrate scanner
mm, compaction: try to capture the just-created high-order freepage
include/linux/compaction.h | 28 +-
include/linux/gfp.h | 2 +-
mm/compaction.c | 757 ++++++++++++++++++++++++++++++++-------------
mm/huge_memory.c | 20 +-
mm/internal.h | 28 +-
mm/page_alloc.c | 189 ++++++++---
6 files changed, 733 insertions(+), 291 deletions(-)
--
1.8.4.5
next reply other threads:[~2014-07-28 13:15 UTC|newest]
Thread overview: 51+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-28 13:11 Vlastimil Babka [this message]
2014-07-28 13:11 ` [PATCH v5 01/14] mm, THP: don't hold mmap_sem in khugepaged when allocating THP Vlastimil Babka
2014-07-28 23:39 ` David Rientjes
2014-07-28 13:11 ` [PATCH v5 02/14] mm, compaction: defer each zone individually instead of preferred zone Vlastimil Babka
2014-07-28 23:59 ` David Rientjes
2014-07-29 9:02 ` Vlastimil Babka
2014-07-29 6:38 ` Joonsoo Kim
2014-07-29 9:12 ` Vlastimil Babka
2014-07-30 16:22 ` Vlastimil Babka
2014-08-01 8:51 ` Vlastimil Babka
2014-08-04 6:45 ` Joonsoo Kim
2014-07-28 13:11 ` [PATCH v5 03/14] mm, compaction: do not count compact_stall if all zones skipped compaction Vlastimil Babka
2014-07-29 0:04 ` David Rientjes
2014-07-28 13:11 ` [PATCH v5 04/14] mm, compaction: do not recheck suitable_migration_target under lock Vlastimil Babka
2014-07-28 13:11 ` [PATCH v5 05/14] mm, compaction: move pageblock checks up from isolate_migratepages_range() Vlastimil Babka
2014-07-29 0:29 ` David Rientjes
2014-07-29 9:27 ` Vlastimil Babka
2014-07-29 23:02 ` David Rientjes
2014-07-29 23:21 ` Kirill A. Shutemov
2014-07-29 23:51 ` David Rientjes
2014-07-30 9:27 ` Vlastimil Babka
2014-07-30 9:39 ` Vlastimil Babka
2014-07-28 13:11 ` [PATCH v5 06/14] mm, compaction: reduce zone checking frequency in the migration scanner Vlastimil Babka
2014-07-29 0:44 ` David Rientjes
2014-07-29 9:31 ` Vlastimil Babka
2014-07-28 13:11 ` [PATCH v5 07/14] mm, compaction: khugepaged should not give up due to need_resched() Vlastimil Babka
2014-07-29 0:59 ` David Rientjes
2014-07-29 9:45 ` Vlastimil Babka
2014-07-29 22:57 ` David Rientjes
2014-07-29 6:53 ` Joonsoo Kim
2014-07-29 7:31 ` David Rientjes
2014-07-29 8:27 ` Joonsoo Kim
2014-07-29 9:16 ` David Rientjes
2014-07-29 9:49 ` Vlastimil Babka
2014-07-29 22:53 ` David Rientjes
2014-07-30 9:08 ` Vlastimil Babka
2014-07-28 13:11 ` [PATCH v5 08/14] mm, compaction: periodically drop lock and restore IRQs in scanners Vlastimil Babka
2014-07-29 1:03 ` David Rientjes
2014-07-28 13:11 ` [PATCH v5 09/14] mm, compaction: skip rechecks when lock was already held Vlastimil Babka
2014-07-28 13:11 ` [PATCH v5 10/14] mm, compaction: remember position within pageblock in free pages scanner Vlastimil Babka
2014-07-28 13:11 ` [PATCH v5 11/14] mm, compaction: skip buddy pages by their order in the migrate scanner Vlastimil Babka
2014-07-29 1:05 ` David Rientjes
2014-07-28 13:11 ` [PATCH v5 12/14] mm: rename allocflags_to_migratetype for clarity Vlastimil Babka
2014-07-28 13:11 ` [PATCH v5 13/14] mm, compaction: pass gfp mask to compact_control Vlastimil Babka
2014-07-28 13:11 ` [PATCH v5 14/14] mm, compaction: try to capture the just-created high-order freepage Vlastimil Babka
2014-07-29 7:34 ` Joonsoo Kim
2014-07-29 15:34 ` Vlastimil Babka
2014-07-30 8:39 ` Joonsoo Kim
2014-07-30 9:56 ` Vlastimil Babka
2014-07-30 14:19 ` Joonsoo Kim
2014-07-30 15:05 ` Vlastimil Babka
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=1406553101-29326-1-git-send-email-vbabka@suse.cz \
--to=vbabka@suse.cz \
--cc=akpm@linux-foundation.org \
--cc=cl@linux.com \
--cc=iamjoonsoo.kim@lge.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@vger.kernel.org \
--cc=mgorman@suse.de \
--cc=mina86@mina86.com \
--cc=minchan@kernel.org \
--cc=n-horiguchi@ah.jp.nec.com \
--cc=riel@redhat.com \
--cc=rientjes@google.com \
--cc=zhangyanfei@cn.fujitsu.com \
/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
all inboxes | Powered by JetHome®