From: Bob Liu <bob.liu@oracle.com>
To: Pekka Enberg <penberg@iki.fi>
Cc: Bob Liu <lliubbo@gmail.com>,
linux-mm@kvack.org, gregkh@linuxfoundation.org,
ngupta@vflare.org, akpm@linux-foundation.org,
konrad.wilk@oracle.com, sjenning@linux.vnet.ibm.com,
riel@redhat.com, mgorman@suse.de, kyungmin.park@samsung.com,
p.sarna@partner.samsung.com, barry.song@csr.com,
penberg@kernel.org
Subject: Re: [PATCH v2 4/4] mm: add WasActive page flag
Date: Tue, 13 Aug 2013 21:50:28 +0800 [thread overview]
Message-ID: <520A39A4.6090407@oracle.com> (raw)
In-Reply-To: <5209CBA1.2080009@iki.fi>
Hi Pekka,
On 08/13/2013 02:01 PM, Pekka Enberg wrote:
> On 8/6/13 2:36 PM, Bob Liu wrote:
>> Zcache could be ineffective if the compressed memory pool is full with
>> compressed inactive file pages and most of them will be never used again.
>>
>> So we pick up pages from active file list only, those pages would
>> probably be
>> accessed again. Compress them in memory can reduce the latency
>> significantly
>> compared with rereading from disk.
>>
>> When a file page is shrinked from active file list to inactive file list,
>> PageActive flag is also cleared.
>> So adding an extra WasActive page flag for zcache to know whether the
>> file page
>> was shrinked from the active list.
>>
>> Signed-off-by: Bob Liu <bob.liu@oracle.com>
>
Thank you so much for your review!
> Using a page flag for this seems like an ugly hack to me.
> Can we rearrange the code so that vmscan notifies zcache
> *before* the active page flag is cleared...?
Yep, adding a page flag is not a good idea.
I'm looking at whether there is other way to notify zcache.
BTW: Could you please give some feedback too about other zcache patches?
>
> Pekka
--
Regards,
-Bob
--
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:[~2013-08-13 13:51 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-08-06 11:36 [PATCH v2 0/4] zcache: a compressed file page cache Bob Liu
2013-08-06 11:36 ` [PATCH v2 1/4] mm: zcache: add core files Bob Liu
2013-08-06 11:36 ` [PATCH v2 2/4] zcache: staging: %s/ZCACHE/ZCACHE_OLD Bob Liu
2013-08-06 11:36 ` [PATCH v2 3/4] mm: zcache: add evict zpages supporting Bob Liu
2013-08-06 11:36 ` [PATCH v2 4/4] mm: add WasActive page flag Bob Liu
2013-08-13 6:01 ` Pekka Enberg
2013-08-13 13:50 ` Bob Liu [this message]
2013-08-06 13:58 ` [PATCH v2 0/4] zcache: a compressed file page cache Greg KH
2013-08-06 14:24 ` Bob Liu
2013-08-12 12:19 ` Konrad Rzeszutek Wilk
2013-08-12 12:25 ` Kyungmin Park
2013-08-12 12:30 ` Wanpeng Li
2013-08-12 12:30 ` Wanpeng Li
2013-08-12 13:23 ` Konrad Rzeszutek Wilk
2013-08-12 22:10 ` Greg KH
2013-08-09 8:03 ` Bob Liu
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=520A39A4.6090407@oracle.com \
--to=bob.liu@oracle.com \
--cc=akpm@linux-foundation.org \
--cc=barry.song@csr.com \
--cc=gregkh@linuxfoundation.org \
--cc=konrad.wilk@oracle.com \
--cc=kyungmin.park@samsung.com \
--cc=linux-mm@kvack.org \
--cc=lliubbo@gmail.com \
--cc=mgorman@suse.de \
--cc=ngupta@vflare.org \
--cc=p.sarna@partner.samsung.com \
--cc=penberg@iki.fi \
--cc=penberg@kernel.org \
--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).