lkml.org 
[lkml]   [2015]   [Mar]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: + zram-support-compaction.patch added to -mm tree
On (03/05/15 14:29), Sergey Senozhatsky wrote:
> On (03/04/15 14:02), akpm@linux-foundation.org wrote:
> > +What: /sys/block/zram<id>/compact
> > +Date: August 2015
> > +Contact: Minchan Kim <minchan@kernel.org>
> > +Description:
> > + The compact file is write-only and trigger compaction for
> > + allocator zrm uses. The allocator moves some objects so that
> > + it could free fragment space.
> > +
> > +What: /sys/block/zram<id>/num_migrated
> > +Date: August 2015
> > +Contact: Minchan Kim <minchan@kernel.org>
> > +Description:
> > + The compact file is read-only and shows how many object
> > + migrated by compaction.
> 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.
>

can compaction memory gain be calculated as, for example,

mem_used_total #before_compaction - mem_used_total #after_compaction ?


if yes, then do we need this attr at all?

the other thing is - why does this attr return the sum of all compactions?
wouldn't it be more informative to return the number of bytes gained after
the most recent compaction? but, once again, is this attr worth having?

-ss


\
 
 \ /
  Last update: 2015-03-05 13:01    [W:0.121 / U:0.016 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site