Re: [PATCH, RFC 0/6] Avoid cache trashing on clearing huge/gigantic page

2012-08-09 Thread H. Peter Anvin
On 07/20/2012 05:50 AM, Kirill A. Shutemov wrote: From: "Kirill A. Shutemov" Clearing a 2MB huge page will typically blow away several levels of CPU caches. To avoid this only cache clear the 4K area around the fault address and use a cache avoiding clears for the rest of the 2MB area. It wou

Re: [PATCH, RFC 0/6] Avoid cache trashing on clearing huge/gigantic page

2012-07-25 Thread Christoph Lameter
On Wed, 25 Jul 2012, Andi Kleen wrote: > > why exempt the 4K around the fault address? Is there a regression if that > > is not exempted? > > You would get an immediate cache miss when the faulting instruction > is reexecuted. Nope. You would not get cache misses for all cachelines in the 4k rang

Re: [PATCH, RFC 0/6] Avoid cache trashing on clearing huge/gigantic page

2012-07-25 Thread Andi Kleen
On Wed, Jul 25, 2012 at 01:51:01PM -0500, Christoph Lameter wrote: > On Fri, 20 Jul 2012, Kirill A. Shutemov wrote: > > > From: "Kirill A. Shutemov" > > > > Clearing a 2MB huge page will typically blow away several levels of CPU > > caches. To avoid this only cache clear the 4K area around the f

Re: [PATCH, RFC 0/6] Avoid cache trashing on clearing huge/gigantic page

2012-07-25 Thread Christoph Lameter
On Fri, 20 Jul 2012, Kirill A. Shutemov wrote: > From: "Kirill A. Shutemov" > > Clearing a 2MB huge page will typically blow away several levels of CPU > caches. To avoid this only cache clear the 4K area around the fault > address and use a cache avoiding clears for the rest of the 2MB area. w

Re: [PATCH, RFC 0/6] Avoid cache trashing on clearing huge/gigantic page

2012-07-24 Thread Kirill A. Shutemov
On Mon, Jul 23, 2012 at 04:30:20PM -0700, Andrew Morton wrote: > On Fri, 20 Jul 2012 15:50:16 +0300 > "Kirill A. Shutemov" wrote: > > > Clearing a 2MB huge page will typically blow away several levels of CPU > > caches. To avoid this only cache clear the 4K area around the fault > > address and

Re: [PATCH, RFC 0/6] Avoid cache trashing on clearing huge/gigantic page

2012-07-23 Thread Andrew Morton
On Fri, 20 Jul 2012 15:50:16 +0300 "Kirill A. Shutemov" wrote: > Clearing a 2MB huge page will typically blow away several levels of CPU > caches. To avoid this only cache clear the 4K area around the fault > address and use a cache avoiding clears for the rest of the 2MB area. > > It would be

[PATCH, RFC 0/6] Avoid cache trashing on clearing huge/gigantic page

2012-07-20 Thread Kirill A. Shutemov
From: "Kirill A. Shutemov" Clearing a 2MB huge page will typically blow away several levels of CPU caches. To avoid this only cache clear the 4K area around the fault address and use a cache avoiding clears for the rest of the 2MB area. It would be nice to test the patchset with more workloads.