From: Joonsoo Kim <iamjoonsoo.kim@lge.com>
To: Vlastimil Babka <vbabka@suse.cz>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Mel Gorman <mgorman@suse.de>, Rik van Riel <riel@redhat.com>,
linux-mm@kvack.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 4/5] mm/compaction: check pageblock suitability once per pageblock
Date: Mon, 10 Feb 2014 09:46:26 +0900 [thread overview]
Message-ID: <20140210004626.GC12049@lge.com> (raw)
In-Reply-To: <52F4B5AA.2040006@suse.cz>
On Fri, Feb 07, 2014 at 11:30:02AM +0100, Vlastimil Babka wrote:
> On 02/07/2014 06:08 AM, Joonsoo Kim wrote:
> > isolation_suitable() and migrate_async_suitable() is used to be sure
> > that this pageblock range is fine to be migragted. It isn't needed to
> > call it on every page. Current code do well if not suitable, but, don't
> > do well when suitable. It re-check it on every valid pageblock.
> > This patch fix this situation by updating last_pageblock_nr.
>
> It took me a while to understand that the problem with migrate_async_suitable() was the
> lack of last_pageblock_nr updates (when the code doesn't go through next_pageblock:
> label), while the problem with isolation_suitable() was the lack of doing the test only
> when last_pageblock_nr != pageblock_nr (so two different things). How bout making it
> clearer in the changelog by replacing the paragraph above with something like:
Really nice!!
Sorry for bad description and thanks for taking time to understand it.
>
> <snip>
> isolation_suitable() and migrate_async_suitable() is used to be sure
> that this pageblock range is fine to be migragted. It isn't needed to
> call it on every page. Current code do well if not suitable, but, don't
> do well when suitable.
>
> 1) It re-checks isolation_suitable() on each page of a pageblock that was already
> estabilished as suitable.
> 2) It re-checks migrate_async_suitable() on each page of a pageblock that was not entered
> through the next_pageblock: label, because last_pageblock_nr is not otherwise updated.
>
> This patch fixes situation by 1) calling isolation_suitable() only once per pageblock and
> 2) always updating last_pageblock_nr to the pageblock that was just checked.
> </snip>
>
> > Additionally, move PageBuddy() check after pageblock unit check,
> > since pageblock check is the first thing we should do and makes things
> > more simple.
>
> You should also do this, since it becomes redundant and might only confuse people:
>
> next_pageblock:
> low_pfn = ALIGN(low_pfn + 1, pageblock_nr_pages) - 1;
> - last_pageblock_nr = pageblock_nr;
>
Okay.
> > Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com>
>
> With the above resolved, consider the patch to be
>
> Acked-by: Vlastimil Babka <vbabka@suse.cz>
I will do it.
Thanks!
--
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:"dont@kvack.org"> email@kvack.org </a>
WARNING: multiple messages have this Message-ID (diff)
From: Joonsoo Kim <iamjoonsoo.kim@lge.com>
To: Vlastimil Babka <vbabka@suse.cz>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Mel Gorman <mgorman@suse.de>, Rik van Riel <riel@redhat.com>,
linux-mm@kvack.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 4/5] mm/compaction: check pageblock suitability once per pageblock
Date: Mon, 10 Feb 2014 09:46:26 +0900 [thread overview]
Message-ID: <20140210004626.GC12049@lge.com> (raw)
In-Reply-To: <52F4B5AA.2040006@suse.cz>
On Fri, Feb 07, 2014 at 11:30:02AM +0100, Vlastimil Babka wrote:
> On 02/07/2014 06:08 AM, Joonsoo Kim wrote:
> > isolation_suitable() and migrate_async_suitable() is used to be sure
> > that this pageblock range is fine to be migragted. It isn't needed to
> > call it on every page. Current code do well if not suitable, but, don't
> > do well when suitable. It re-check it on every valid pageblock.
> > This patch fix this situation by updating last_pageblock_nr.
>
> It took me a while to understand that the problem with migrate_async_suitable() was the
> lack of last_pageblock_nr updates (when the code doesn't go through next_pageblock:
> label), while the problem with isolation_suitable() was the lack of doing the test only
> when last_pageblock_nr != pageblock_nr (so two different things). How bout making it
> clearer in the changelog by replacing the paragraph above with something like:
Really nice!!
Sorry for bad description and thanks for taking time to understand it.
>
> <snip>
> isolation_suitable() and migrate_async_suitable() is used to be sure
> that this pageblock range is fine to be migragted. It isn't needed to
> call it on every page. Current code do well if not suitable, but, don't
> do well when suitable.
>
> 1) It re-checks isolation_suitable() on each page of a pageblock that was already
> estabilished as suitable.
> 2) It re-checks migrate_async_suitable() on each page of a pageblock that was not entered
> through the next_pageblock: label, because last_pageblock_nr is not otherwise updated.
>
> This patch fixes situation by 1) calling isolation_suitable() only once per pageblock and
> 2) always updating last_pageblock_nr to the pageblock that was just checked.
> </snip>
>
> > Additionally, move PageBuddy() check after pageblock unit check,
> > since pageblock check is the first thing we should do and makes things
> > more simple.
>
> You should also do this, since it becomes redundant and might only confuse people:
>
> next_pageblock:
> low_pfn = ALIGN(low_pfn + 1, pageblock_nr_pages) - 1;
> - last_pageblock_nr = pageblock_nr;
>
Okay.
> > Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com>
>
> With the above resolved, consider the patch to be
>
> Acked-by: Vlastimil Babka <vbabka@suse.cz>
I will do it.
Thanks!
next prev parent reply other threads:[~2014-02-10 0:46 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-07 5:08 [PATCH 0/5] compaction related commits Joonsoo Kim
2014-02-07 5:08 ` Joonsoo Kim
2014-02-07 5:08 ` [PATCH 1/5] mm/compaction: disallow high-order page for migration target Joonsoo Kim
2014-02-07 5:08 ` Joonsoo Kim
2014-02-07 9:20 ` Vlastimil Babka
2014-02-07 9:20 ` Vlastimil Babka
2014-02-10 13:26 ` Mel Gorman
2014-02-10 13:26 ` Mel Gorman
2014-02-11 7:12 ` Joonsoo Kim
2014-02-11 7:12 ` Joonsoo Kim
2014-02-07 5:08 ` [PATCH 2/5] mm/compaction: do not call suitable_migration_target() on every page Joonsoo Kim
2014-02-07 5:08 ` Joonsoo Kim
2014-02-07 9:36 ` Vlastimil Babka
2014-02-07 9:36 ` Vlastimil Babka
2014-02-10 0:41 ` Joonsoo Kim
2014-02-10 0:41 ` Joonsoo Kim
2014-02-07 5:08 ` [PATCH 3/5] mm/compaction: change the timing to check to drop the spinlock Joonsoo Kim
2014-02-07 5:08 ` Joonsoo Kim
2014-02-07 9:50 ` Vlastimil Babka
2014-02-07 9:50 ` Vlastimil Babka
2014-02-07 5:08 ` [PATCH 4/5] mm/compaction: check pageblock suitability once per pageblock Joonsoo Kim
2014-02-07 5:08 ` Joonsoo Kim
2014-02-07 10:30 ` Vlastimil Babka
2014-02-07 10:30 ` Vlastimil Babka
2014-02-10 0:46 ` Joonsoo Kim [this message]
2014-02-10 0:46 ` Joonsoo Kim
2014-02-07 5:08 ` [PATCH 5/5] mm/compaction: clean-up code on success of ballon isolation Joonsoo Kim
2014-02-07 5:08 ` Joonsoo Kim
2014-02-07 10:33 ` Vlastimil Babka
2014-02-07 10:33 ` Vlastimil Babka
2014-02-07 9:14 ` [PATCH 0/5] compaction related commits Vlastimil Babka
2014-02-07 9:14 ` Vlastimil Babka
2014-02-10 0:24 ` Joonsoo Kim
2014-02-10 0:24 ` Joonsoo Kim
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=20140210004626.GC12049@lge.com \
--to=iamjoonsoo.kim@lge.com \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mgorman@suse.de \
--cc=riel@redhat.com \
--cc=vbabka@suse.cz \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.