Miscellanious performance adjustments to the kernel
authorMatthew Dillon <dillon@dragonflybsd.org>
Thu, 19 Jun 2008 23:27:39 +0000 (23:27 +0000)
committerMatthew Dillon <dillon@dragonflybsd.org>
Thu, 19 Jun 2008 23:27:39 +0000 (23:27 +0000)
commite92ca23a23a8a66e917073781ee7729841ad5fe8
tree04abf55586e95aae39cf43fad376ea997788d44a
parentf0bb28557f0d52fa1310e86c1fa0762663f09b2e
Miscellanious performance adjustments to the kernel

* Add an argument to VOP_BMAP so VFSs can discern the type of operation
  the BMAP is being done for.

* Normalize the variable name denoting the blocksize to 'blksize' in
  vfs_cluster.c.

* Fix a bug in the cluster code where a stale bp->b_error could wind up
  getting returned when B_ERROR is not set.

* Do not B_AGE cluster bufs.

* Pass the block size to both cluster_read() and cluster_write() instead
  of those routines getting the block size from
  vp->v_mount->mnt_stat.f_iosize.  This allows different areas of a file
  to use a different block size.

* Properly initialize bp->b_bio2.bio_offset to doffset in cluster_read().
  This fixes an issue where VFSs were making an extra, unnecessary call
  to BMAP.

* Do not recycle vnodes on the free list until numvnodes has reached
  desiredvnodes.  Vnodes were being recycled when their resident page count
  had dropped to zero, but this is actually too early as the VFS may cache
  important information in the vnode that would otherwise require a number
  of I/O's to re-acquire.  This mainly helps HAMMER (whos inode lookups are
  fairly expensive).

* Do not VAGE vnodes.

* Remove the minvnodes test.  There is no reason not to load the vnode cache
  all the way through to its max.

* buf_cmd_t visibility for the new BMAP argument.
16 files changed:
sys/kern/vfs_bio.c
sys/kern/vfs_cluster.c
sys/kern/vfs_lock.c
sys/kern/vfs_vopops.c
sys/sys/buf.h
sys/sys/vfsops.h
sys/vfs/gnu/ext2fs/ext2_readwrite.c
sys/vfs/gnu/ext2fs/ext2_vnops.c
sys/vfs/hpfs/hpfs_vnops.c
sys/vfs/isofs/cd9660/cd9660_lookup.c
sys/vfs/isofs/cd9660/cd9660_vnops.c
sys/vfs/ufs/ffs_rawread.c
sys/vfs/ufs/ffs_softdep.c
sys/vfs/ufs/ufs_readwrite.c
sys/vfs/ufs/ufs_vnops.c
sys/vm/vnode_pager.c