From: Minchan Kim <minchan@kernel.org>
To: Tim Chen <tim.c.chen@linux.intel.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Vladimir Davydov <vdavydov@virtuozzo.com>,
Johannes Weiner <hannes@cmpxchg.org>,
Michal Hocko <mhocko@suse.cz>, Hugh Dickins <hughd@google.com>,
"Kirill A.Shutemov" <kirill.shutemov@linux.intel.com>,
Andi Kleen <andi@firstfloor.org>, Aaron Lu <aaron.lu@intel.com>,
Huang Ying <ying.huang@intel.com>, linux-mm <linux-mm@kvack.org>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] mm: Cleanup - Reorganize the shrink_page_list code into smaller functions
Date: Thu, 9 Jun 2016 13:40:59 +0900 [thread overview]
Message-ID: <20160609044059.GB29779@bbox> (raw)
In-Reply-To: <1465332209.22178.236.camel@linux.intel.com>
On Tue, Jun 07, 2016 at 01:43:29PM -0700, Tim Chen wrote:
> On Tue, 2016-06-07 at 17:21 +0900, Minchan Kim wrote:
> > On Wed, Jun 01, 2016 at 11:23:53AM -0700, Tim Chen wrote:
> > >
> > > On Wed, 2016-06-01 at 16:12 +0900, Minchan Kim wrote:
> > > >
> > > >
> > > > Hi Tim,
> > > >
> > > > To me, this reorganization is too limited and not good for me,
> > > > frankly speaking. It works for only your goal which allocate batch
> > > > swap slot, I guess. :)
> > > >
> > > > My goal is to make them work with batch page_check_references,
> > > > batch try_to_unmap and batch __remove_mapping where we can avoid frequent
> > > > mapping->lock(e.g., anon_vma or i_mmap_lock with hoping such batch locking
> > > > help system performance) if batch pages has same inode or anon.
> > > This is also my goal to group pages that are either under the same
> > > mapping or are anonymous pages together so we can reduce the i_mmap_lock
> > > acquisition. One logic that's yet to be implemented in your patch
> > > is the grouping of similar pages together so we only need one i_mmap_lock
> > > acquisition. Doing this efficiently is non-trivial.
> > Hmm, my assumption is based on same inode pages are likely to order
> > in LRU so no need to group them. If successive page in page_list comes
> > from different inode, we can drop the lock and get new lock from new
> > inode. That sounds strange?
> >
>
> Sounds reasonable. But your process function passed to spl_batch_pages may
> need to be modified to know if the radix tree lock or swap info lock
> has already been held, as it deals with only 1 page. It may be
> tricky as the lock may get acquired and dropped more than once in process
> function.
>
> Are you planning to update the patch with lock batching?
Hi Tim,
Okay, I will give it a shot.
Thanks.
--
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>
prev parent reply other threads:[~2016-06-09 4:47 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-05-20 21:32 [PATCH] mm: Cleanup - Reorganize the shrink_page_list code into smaller functions Tim Chen
2016-05-20 21:32 ` Tim Chen
2016-05-31 9:15 ` Minchan Kim
2016-05-31 17:17 ` Tim Chen
2016-05-31 17:17 ` Tim Chen
2016-06-01 7:12 ` Minchan Kim
2016-06-01 18:23 ` Tim Chen
2016-06-01 18:23 ` Tim Chen
2016-06-07 8:21 ` Minchan Kim
2016-06-07 8:21 ` Minchan Kim
2016-06-07 20:43 ` Tim Chen
2016-06-07 20:43 ` Tim Chen
2016-06-09 4:40 ` Minchan Kim [this message]
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=20160609044059.GB29779@bbox \
--to=minchan@kernel.org \
--cc=aaron.lu@intel.com \
--cc=akpm@linux-foundation.org \
--cc=andi@firstfloor.org \
--cc=hannes@cmpxchg.org \
--cc=hughd@google.com \
--cc=kirill.shutemov@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mhocko@suse.cz \
--cc=tim.c.chen@linux.intel.com \
--cc=vdavydov@virtuozzo.com \
--cc=ying.huang@intel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.