lkml.org 
[lkml]   [2010]   [Aug]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH] vmscan: fix missing place to check nr_swap_pages.
From
On Thu, Aug 26, 2010 at 6:03 PM, Minchan Kim <minchan.kim@gmail.com> wrote:
>
> Hello.
>
> On Fri, Aug 27, 2010 at 9:11 AM, Ying Han <yinghan@google.com> wrote:
> > Fix a missed place where checks nr_swap_pages to do shrink_active_list. Make the
> > change that moves the check to common function inactive_anon_is_low.
> >
>
> Hmm.. AFAIR, we discussed it at that time but we concluded it's not good.
> That's because nr_swap_pages < 0 means both "NO SWAP" and "NOT enough
> swap space now". If we have a swap device or file but not enough space
> now, we need to aging anon pages to make inactive list enough size.
> Otherwise, working set pages would be swapped out more fast before
> promotion.

We found the problem on one of our workloads where more TLB flush
happens without the change. Kswapd seems to be calling
shrink_active_list() which eventually clears access bit of those ptes
and does TLB flush
with ptep_clear_flush_young(). This system does not have swap
configured, and why aging the anon lru in that
case?

> That aging is done by kswapd so I think it's not big harmful in the system.
> But if you want to remove aging completely in non-swap system, we need
> to identify non swap system and not enough swap space. I thought we
> need it for embedded system.

Lots of TLB flush hurts the performance especially on large smp system. So does
it make sense if change it to:

+ if (nr_swap_pages == 0)
+ return 0;

--Ying


> Thanks.
>
>
> --
> Kind regards,
> Minchan Kim
>
> --
> 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>
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2010-08-27 05:33    [W:0.053 / U:2.308 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site