git: hammer2 - cleanup data load, unlink optimization
dillon at crater.dragonflybsd.org
Mon May 25 21:47:46 PDT 2015
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date: Mon May 25 21:42:00 2015 -0700
hammer2 - cleanup data load, unlink optimization
* Clean up data loading on chain lock. Use chain flags to interlock data
loading with either a shared or exclusive lock.
* We no longer upgrade a shared lock to exclusive in order to load data,
preventing a potentially unexpected deadlock from occuring.
* Clean up the chain_core (chain->core) structure. Remove flags and
move the main lock from the core to the main chain structure proper.
* Attempt to avoid I/O when unlinking files by not updating the inode
on the final 1->0 transition of nlinks. This greatly reduces the amount
of write I/O occuring during a rm -rf and improves performance by a
factor of 3x.
Summary of changes:
sys/vfs/hammer2/hammer2.h | 20 +++---
sys/vfs/hammer2/hammer2_chain.c | 152 ++++++++++++++++++++++++++++-----------
sys/vfs/hammer2/hammer2_inode.c | 50 ++++++++++---
sys/vfs/hammer2/hammer2_subr.c | 6 +-
sys/vfs/hammer2/hammer2_vfsops.c | 6 +-
sys/vfs/hammer2/hammer2_vnops.c | 7 +-
6 files changed, 168 insertions(+), 73 deletions(-)
DragonFly BSD source repository
More information about the Commits