From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753204AbbCIBFd (ORCPT ); Sun, 8 Mar 2015 21:05:33 -0400 Received: from mail-pa0-f45.google.com ([209.85.220.45]:46834 "EHLO mail-pa0-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752832AbbCIBFb (ORCPT ); Sun, 8 Mar 2015 21:05:31 -0400 Date: Mon, 9 Mar 2015 10:05:22 +0900 From: Minchan Kim To: Sergey Senozhatsky Cc: akpm@linux-foundation.org, ddstreet@ieee.org, gunho.lee@lge.com, iamjoonsoo.kim@lge.com, jmarchan@redhat.com, juno.choi@lge.com, mel@csn.ul.ie, ngupta@vflare.org, semenzato@google.com, sergey.senozhatsky@gmail.com, sjennings@variantweb.net, mm-commits@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: + zram-support-compaction.patch added to -mm tree Message-ID: <20150309010522.GD15184@blaptop> References: <54f780fc.3sOWZKr7rufmI85r%akpm@linux-foundation.org> <20150305052941.GK14927@swordfish> <20150309004859.GB15184@blaptop> <20150309005718.GA794@swordfish> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20150309005718.GA794@swordfish> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 09, 2015 at 09:57:18AM +0900, Sergey Senozhatsky wrote: > On (03/09/15 09:49), Minchan Kim wrote: > > > rather a discussion question. > > > > > > Minchan, do you want to provide num_migrated as part of zsmalloc stats rather > > > than having yet another zram attr? we already provide zsmalloc stats and this > > > type of information seems to belong there. just idea. > > > > Hmm, CONFIG_ZSMALLOC_STAT is actually to show zsmalloc internals. > > well, to be fair, compaction is a zsmalloc internal. zram has nothing to do with > it. > > but do we we even need this stat? it seems that > > mem_total_used (before compaction) - mem_total_user (after comapction) > > will give user an idea on how much memory was compacted. It's not enough. What I want to know is compaction efficiency per client of zsmalloc(ie, zram). IOW, (how many of freed pages / how many of objects) per zs_compact. > > -ss > > > That's why it is on debugfs. If we add the stat into zsmalloc, we should turn on debugfs > > and CONFIG_ZSMALLOC_STAT to see *a* stat. Even, CONFIG_ZSMALLOC_STAT will add > > unncessary overheads to account another stats fo zsmalloc internals. > > > > As well, if we add auto-compacion like stuff in zsmalloc(ie, it will trigger > > by itself if fragmention is over to predefined theshold), the stat will > > accumulate stat while someone want to see snapshot compaction effiecieny > > of the moment. > > > > So, I want to keep it in zram now. > > > > -- > > Kind regards, > > Minchan Kim > > -- Kind regards, Minchan Kim