diff options
author | Carsten Otte <[email protected]> | 2008-01-17 15:21:17 -0800 |
---|---|---|
committer | Linus Torvalds <[email protected]> | 2008-01-17 15:38:59 -0800 |
commit | 9723198c219f3546982cb469e5aed26e68399055 (patch) | |
tree | b8e195cb1ca1bdf143e4e564fdb43f09aadfd6f3 /net/unix/sysctl_net_unix.c | |
parent | 6b2d2cec1081a979e0efd6a1e9559e5a01a3c10e (diff) |
#ifdef very expensive debug check in page fault path
This patch puts #ifdef CONFIG_DEBUG_VM around a check in vm_normal_page
that verifies that a pfn is valid. This patch increases performance of the
page fault microbenchmark in lmbench by 13% and overall dbench performance
by 7% on s390x. pfn_valid() is an expensive operation on s390 that needs a
high double digit amount of CPU cycles. Nick Piggin suggested that
pfn_valid() involves an array lookup on systems with sparsemem, and
therefore is an expensive operation there too.
The check looks like a clear debug thing to me, it should never trigger on
regular kernels. And if a pte is created for an invalid pfn, we'll find
out once the memory gets accessed later on anyway. Please consider
inclusion of this patch into mm.
Signed-off-by: Carsten Otte <[email protected]>
Acked-by: Nick Piggin <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'net/unix/sysctl_net_unix.c')
0 files changed, 0 insertions, 0 deletions