From: Dan Magenheimer <dan.magenheimer@oracle.com>
To: Seth Jennings <sjenning@linux.vnet.ibm.com>,
Minchan Kim <minchan@kernel.org>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Nitin Gupta <ngupta@vflare.org>,
Konrad Wilk <konrad.wilk@oracle.com>,
Robert Jennings <rcj@linux.vnet.ibm.com>,
Jenifer Hopper <jhopper@us.ibm.com>, Mel Gorman <mgorman@suse.de>,
Johannes Weiner <jweiner@redhat.com>,
Rik van Riel <riel@redhat.com>,
Larry Woodman <lwoodman@redhat.com>,
Benjamin Herrenschmidt <benh@kernel.crashing.org>,
Dave Hansen <dave@linux.vnet.ibm.com>,
linux-mm@kvack.org, linux-kernel@vger.kernel.org,
devel@driverdev.osuosl.org
Subject: RE: [PATCHv3 5/6] zswap: add to mm/
Date: Wed, 6 Feb 2013 15:47:29 -0800 (PST) [thread overview]
Message-ID: <a06fbc6b-8731-4bfe-82ff-05e8d14d8595@default> (raw)
In-Reply-To: <51080658.7060709@linux.vnet.ibm.com>
> From: Seth Jennings [mailto:sjenning@linux.vnet.ibm.com]
> Subject: Re: [PATCHv3 5/6] zswap: add to mm/
>
> On 01/29/2013 12:27 AM, Minchan Kim wrote:
> > First feeling is it's simple and nice approach.
> > Although we have some problems to decide policy, it could solve by later patch
> > so I hope we make basic infrasture more solid by lots of comment.
>
> Thanks very much for the review!
> >
> > Another question.
> >
> > What's the benefit of using mempool for zsmalloc?
> > As you know, zsmalloc doesn't use mempool as default.
> > I guess you see some benefit. if so, zram could be changed.
> > If we can change zsmalloc's default scheme to use mempool,
> > all of customer of zsmalloc could be enhanced, too.
>
> In the case of zswap, through experimentation, I found that adding a
> mempool behind the zsmalloc pool added some elasticity to the pool.
> Fewer stores failed if we kept a small reserve of pages around instead
> of having to go back to the buddy allocator who, under memory
> pressure, is more likely to reject our request.
>
> I don't see this situation being applicable to all zsmalloc users
> however. I don't think we want incorporate it directly into zsmalloc
> for now. The ability to register custom page alloc/free functions at
> pool creation time allows users to do something special, like back
> with a mempool, if they want to do that.
(sorry, still catching up on backlog after being gone last week)
IIUC, by using mempool, you are essentially setting aside a
special cache of pageframes that only zswap can use (or other
users of mempool, I don't know what other subsystems use it).
So one would expect that fewer stores would fail if more
pageframes are available to zswap, the same as if you had
increased zswap_max_pool_percent by some small fraction.
But by setting those pageframes aside, you are keeping them from
general use, which may be a use with a higher priority as determined
by the mm system.
This seems wrong to me. Should every subsystem hide a bunch of
pageframes away in case it might need them?
Or am I missing something?
Dan
next prev parent reply other threads:[~2013-02-06 23:48 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-28 21:49 [PATCHv3 0/6] zswap: compressed swap caching Seth Jennings
2013-01-28 21:49 ` [PATCHv3 1/6] debugfs: add get/set for atomic types Seth Jennings
2013-01-29 20:35 ` Konrad Rzeszutek Wilk
2013-01-29 20:49 ` Seth Jennings
2013-01-28 21:49 ` [PATCHv3 2/6] zsmalloc: promote to lib/ Seth Jennings
2013-01-28 23:56 ` Minchan Kim
2013-01-28 21:49 ` [PATCHv3 3/6] mm: break up swap_writepage() for frontswap backends Seth Jennings
2013-01-28 23:58 ` Minchan Kim
2013-01-28 21:49 ` [PATCHv3 4/6] mm: allow for outstanding swap writeback accounting Seth Jennings
2013-01-29 0:01 ` Minchan Kim
2013-01-28 21:49 ` [PATCHv3 5/6] zswap: add to mm/ Seth Jennings
2013-01-29 6:27 ` Minchan Kim
2013-01-29 17:26 ` Seth Jennings
2013-01-30 4:44 ` Minchan Kim
2013-02-06 23:47 ` Dan Magenheimer [this message]
2013-02-07 3:08 ` Seth Jennings
2013-01-29 18:55 ` Seth Jennings
2013-01-28 21:49 ` [PATCHv3 6/6] zswap: add documentation Seth Jennings
2013-01-28 22:08 ` [PATCHv3 0/6] zswap: compressed swap caching Seth Jennings
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=a06fbc6b-8731-4bfe-82ff-05e8d14d8595@default \
--to=dan.magenheimer@oracle.com \
--cc=akpm@linux-foundation.org \
--cc=benh@kernel.crashing.org \
--cc=dave@linux.vnet.ibm.com \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=jhopper@us.ibm.com \
--cc=jweiner@redhat.com \
--cc=konrad.wilk@oracle.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=lwoodman@redhat.com \
--cc=mgorman@suse.de \
--cc=minchan@kernel.org \
--cc=ngupta@vflare.org \
--cc=rcj@linux.vnet.ibm.com \
--cc=riel@redhat.com \
--cc=sjenning@linux.vnet.ibm.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;
as well as URLs for NNTP newsgroup(s).