diff options
author | alc <alc@FreeBSD.org> | 2004-08-16 06:16:12 +0000 |
---|---|---|
committer | alc <alc@FreeBSD.org> | 2004-08-16 06:16:12 +0000 |
commit | 336d354baa1e8f33fe0828ce3addde3e40353ac3 (patch) | |
tree | bf9cf631718b8e20d5ca0e01cf511e82d9b9242f /sys/vm/vm_map.c | |
parent | a14d72d4260dd5b04f8a6072b760c4fba679688b (diff) | |
download | FreeBSD-src-336d354baa1e8f33fe0828ce3addde3e40353ac3.zip FreeBSD-src-336d354baa1e8f33fe0828ce3addde3e40353ac3.tar.gz |
- Introduce and use a new tunable "debug.mpsafevm". At present, setting
"debug.mpsafevm" results in (almost) Giant-free execution of zero-fill
page faults. (Giant is held only briefly, just long enough to determine
if there is a vnode backing the faulting address.)
Also, condition the acquisition and release of Giant around calls to
pmap_remove() on "debug.mpsafevm".
The effect on performance is significant. On my dual Opteron, I see a
3.6% reduction in "buildworld" time.
- Use atomic operations to update several counters in vm_fault().
Diffstat (limited to 'sys/vm/vm_map.c')
-rw-r--r-- | sys/vm/vm_map.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/vm/vm_map.c b/sys/vm/vm_map.c index 765126c..2a486e8 100644 --- a/sys/vm/vm_map.c +++ b/sys/vm/vm_map.c @@ -2114,9 +2114,9 @@ vm_map_sync( } if (invalidate) { - mtx_lock(&Giant); + VM_LOCK_GIANT(); pmap_remove(map->pmap, start, end); - mtx_unlock(&Giant); + VM_UNLOCK_GIANT(); } /* * Make a second pass, cleaning/uncaching pages from the indicated @@ -2282,10 +2282,10 @@ vm_map_delete(vm_map_t map, vm_offset_t start, vm_offset_t end) } if (!map->system_map) - mtx_lock(&Giant); + VM_LOCK_GIANT(); pmap_remove(map->pmap, entry->start, entry->end); if (!map->system_map) - mtx_unlock(&Giant); + VM_UNLOCK_GIANT(); /* * Delete the entry (which may delete the object) only after |