Re: [PATCH] mm: vmscan: Obey indeed proportional scanning for kswapd and memcg

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Nov 25, 2015 at 12:48:20PM +0800, Yaowei Bai wrote:
> Commit e82e0561dae9f3ae5 ("mm: vmscan: obey proportional scanning
> requirements for kswapd") intended to preserve the proportional scanning
> and reclaim what was requested by get_scan_count() for kswapd and memcg
> by stopping reclaiming one type(anon or file) LRU and reducing the other's
> amount of scanning proportional to the original scan target.
> 
> So the way to determine which LRU should be stopped reclaiming should be
> comparing scanned/unscanned percentages to the original scan target of two
> lru types instead of absolute values what implemented currently, because
> larger absolute value doesn't mean larger percentage, there shall be
> chance that larger absolute value with smaller percentage, for instance:
> 
> 	target_file = 1000
> 	target_anon = 500
> 	nr_file = 500
> 	nr_anon = 400
> 
> in this case, because nr_file > nr_anon, according to current implement,
> we will stop scanning anon lru and shrink file lru. This breaks
> proportional scanning intent and makes more unproportional.
> 
> This patch changes to compare percentage to the original scan target to
> determine which lru should be shrunk.
> 
> Signed-off-by: Yaowei Bai <baiyaowei@xxxxxxxxxxxxxxxxxxxx>

This one has gone back and forth a few times in the past. It really was
deliberate that the scanning was proportional to the scan target. While
I see what your concern is, it's unclear what the actual impact is. Have
you done any testing to check if the proposed new behaviour is actually
better?

-- 
Mel Gorman
SUSE Labs

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]