kernel-ark/include/asm-generic
Zachary Amsden a600388d28 [PATCH] x86: ptep_clear optimization
Add a new accessor for PTEs, which passes the full hint from the mmu_gather
struct; this allows architectures with hardware pagetables to optimize away
atomic PTE operations when destroying an address space.  Removing the
locked operation should allow better pipelining of memory access in this
loop.  I measured an average savings of 30-35 cycles per zap_pte_range on
the first 500 destructions on Pentium-M, but I believe the optimization
would win more on older processors which still assert the bus lock on xchg
for an exclusive cacheline.

Update: I made some new measurements, and this saves exactly 26 cycles over
ptep_get_and_clear on Pentium M.  On P4, with a PAE kernel, this saves 180
cycles per ptep_get_and_clear, for a whopping 92160 cycles savings for a
full address space destruction.

pte_clear_full is not yet used, but is provided for future optimizations
(in particular, when running inside of a hypervisor that queues page table
updates, the full hint allows us to avoid queueing unnecessary page table
update for an address space in the process of being destroyed.

This is not a huge win, but it does help a bit, and sets the stage for
further hypervisor optimization of the mm layer on all architectures.

Signed-off-by: Zachary Amsden <zach@vmware.com>
Cc: Christoph Lameter <christoph@lameter.com>
Cc: <linux-mm@kvack.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-09-05 00:05:48 -07:00
..
4level-fixup.h
bitops.h
bug.h
cputime.h
div64.h
dma-mapping-broken.h
dma-mapping.h
emergency-restart.h [PATCH] Add emergency_restart() 2005-07-26 14:35:41 -07:00
errno-base.h
errno.h
hdreg.h
ide_iops.h
iomap.h
ipc.h
local.h
page.h [PATCH] mm: consolidate get_order 2005-09-05 00:05:39 -07:00
pci-dma-compat.h
pci.h [PATCH] pci and yenta: pcibios_bus_to_resource 2005-08-04 21:32:46 -07:00
percpu.h [PATCH] adjust per_cpu definition in non-SMP case 2005-06-23 09:45:28 -07:00
pgtable-nopmd.h
pgtable-nopud.h
pgtable.h [PATCH] x86: ptep_clear optimization 2005-09-05 00:05:48 -07:00
resource.h
rtc.h
sections.h [PATCH] x86_64: Some cleanup in setup64.c 2005-07-28 21:45:58 -07:00
siginfo.h
signal.h
statfs.h
termios.h
tlb.h
topology.h
uaccess.h
unaligned.h
vmlinux.lds.h [PATCH] kexec: vmlinux: fix physical addresses 2005-06-25 16:24:47 -07:00
xor.h