Re: [PATCH 2/2] huge-memory: Use fast mm counters for transparent huge pages

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

 



(2012/03/31 23:09), Andi Kleen wrote:

> From: Andi Kleen <ak@xxxxxxxxxxxxxxx>
> 
> We found that the mm struct anon page counter cache line is much hotter
> with transparent huge pages compared to small pages.
> 
> Small pages use a special fast counter mechanism in task_struct, but huge pages
> didn't.  The huge pages are larger than the normal 64 entry threshold for the
> fast counter, so it cannot be directly used. Use a new special counter for huge
> pages to handle them efficiently.
> 
> Any users just calculate the correct total.
> 
> The only special case is transferring the large page count to small pages
> when splitting. I put it somewhat arbitarily into the tricky split
> sequence. Some review on this part is appreciated.
> 
> [An alternative would be to not do that, but that could lead to
> negative counters. These should still give the correct result]
> 
> Contains a fix for a problem found by Andrea in review.
> 
> Cc: aarcange@xxxxxxxxxx
> Signed-off-by: Andi Kleen <ak@xxxxxxxxxxxxxxx>


Acked-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@xxxxxxxxxxxxxx>


--
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/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
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]