From: Mel Gorman <mgorman@techsingularity.net>
To: Minchan Kim <minchan@kernel.org>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Johannes Weiner <hannes@cmpxchg.org>,
Michal Hocko <mhocko@suse.cz>, Vlastimil Babka <vbabka@suse.cz>,
Linux-MM <linux-mm@kvack.org>,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 5/5] mm, vmscan: Account for skipped pages as a partial scan
Date: Mon, 25 Jul 2016 10:52:51 +0100 [thread overview]
Message-ID: <20160725095251.GN10438@techsingularity.net> (raw)
In-Reply-To: <20160725083913.GE1660@bbox>
On Mon, Jul 25, 2016 at 05:39:13PM +0900, Minchan Kim wrote:
> > @@ -1465,14 +1471,24 @@ static unsigned long isolate_lru_pages(unsigned long nr_to_scan,
> > */
> > if (!list_empty(&pages_skipped)) {
> > int zid;
> > + unsigned long total_skipped = 0;
> >
> > - list_splice(&pages_skipped, src);
> > for (zid = 0; zid < MAX_NR_ZONES; zid++) {
> > if (!nr_skipped[zid])
> > continue;
> >
> > __count_zid_vm_events(PGSCAN_SKIP, zid, nr_skipped[zid]);
> > + total_skipped += nr_skipped[zid];
> > }
> > +
> > + /*
> > + * Account skipped pages as a partial scan as the pgdat may be
> > + * close to unreclaimable. If the LRU list is empty, account
> > + * skipped pages as a full scan.
> > + */
>
> node-lru made OOM detection lengthy because a freeing of any zone will
> reset NR_PAGES_SCANNED easily so that it's hard to meet a situation
> pgdat_reclaimable returns *false*.
>
Your patch should go a long way to addressing that as it checks the zone
counters first before conducting the scan. Remember as well that the longer
detection of OOM only applies to zone-constrained allocations and there
is always the possibility that highmem shrinking of pages frees lowmem
memory if buffers are used.
--
Mel Gorman
SUSE Labs
--
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>
next prev parent reply other threads:[~2016-07-25 9:52 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-21 14:10 [PATCH 0/5] Candidate fixes for premature OOM kills with node-lru v2 Mel Gorman
2016-07-21 14:10 ` [PATCH 1/5] mm: add per-zone lru list stat Mel Gorman
2016-07-22 15:51 ` Johannes Weiner
2016-07-21 14:10 ` [PATCH 2/5] mm, vmscan: Remove highmem_file_pages Mel Gorman
2016-07-22 15:53 ` Johannes Weiner
2016-07-25 8:09 ` Minchan Kim
2016-07-25 9:23 ` [PATCH] mm, vmscan: remove highmem_file_pages -fix Mel Gorman
2016-07-21 14:10 ` [PATCH 3/5] mm: Remove reclaim and compaction retry approximations Mel Gorman
2016-07-22 15:57 ` Johannes Weiner
2016-07-25 8:18 ` Minchan Kim
2016-07-21 14:11 ` [PATCH 4/5] mm: consider per-zone inactive ratio to deactivate Mel Gorman
2016-07-21 15:52 ` Johannes Weiner
2016-07-21 14:11 ` [PATCH 5/5] mm, vmscan: Account for skipped pages as a partial scan Mel Gorman
2016-07-22 16:02 ` Johannes Weiner
2016-07-25 8:39 ` Minchan Kim
2016-07-25 9:52 ` Mel Gorman [this message]
2016-07-26 8:16 ` Joonsoo Kim
2016-07-26 8:26 ` Joonsoo Kim
2016-07-26 8:11 ` [PATCH 0/5] Candidate fixes for premature OOM kills with node-lru v2 Joonsoo Kim
2016-07-26 12:50 ` Mel Gorman
2016-07-28 6:44 ` Joonsoo Kim
2016-07-28 10:27 ` 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=20160725095251.GN10438@techsingularity.net \
--to=mgorman@techsingularity.net \
--cc=akpm@linux-foundation.org \
--cc=hannes@cmpxchg.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mhocko@suse.cz \
--cc=minchan@kernel.org \
--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 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).