git: hammer2 - major simplification of algorithms part 1/many
Matthew Dillon
dillon at crater.dragonflybsd.org
Wed Jul 30 00:29:10 PDT 2014
commit da6f36f44bb9c76612e31b56cdfe4d787e53d61f
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date: Wed Jul 30 00:17:29 2014 -0700
hammer2 - major simplification of algorithms part 1/many
* Huge simplification of in-memory data structures and algorithms.
Remove delete-duplicate, ownerq (shadow copies), dbq, dbtree, and most of
the xid lo/hi sequencing. Remove all the complexities related to
managing the above elements. Net removal of ~1500 lines of code or so.
* Blockmap deletions are now handled by the frontend, so the backend doesn't
need to deal with shadowed deletions. This is still fairly optimal since
insertions are still handled by the backend during flushes. So for quick
create/delete operations the blockmap is never even initialized which means
that deletions don't have to remove anything.
* Cleanup buffer cache on file removal / last-close, but allow file delete
to simply wipe out the inode. Don't bother iterating its indirect blocks
or data blocks on-media but use the flush code to get rid of any chains
still cached.
* Buffer invalidation on permanent chain deletions for modified chains.
* Major items still TODO: flush interlocks and meta-data updates.
Summary of changes:
sys/vfs/hammer2/TODO | 3 +-
sys/vfs/hammer2/hammer2.h | 253 +++---
sys/vfs/hammer2/hammer2_chain.c | 1667 ++++++++++---------------------------
sys/vfs/hammer2/hammer2_cluster.c | 177 ++--
sys/vfs/hammer2/hammer2_flush.c | 1351 ++++++++----------------------
sys/vfs/hammer2/hammer2_freemap.c | 14 +-
sys/vfs/hammer2/hammer2_inode.c | 368 ++++----
sys/vfs/hammer2/hammer2_ioctl.c | 2 +-
sys/vfs/hammer2/hammer2_subr.c | 6 +-
sys/vfs/hammer2/hammer2_vfsops.c | 198 ++---
sys/vfs/hammer2/hammer2_vnops.c | 75 +-
11 files changed, 1270 insertions(+), 2844 deletions(-)
http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/da6f36f44bb9c76612e31b56cdfe4d787e53d61f
--
DragonFly BSD source repository
More information about the Commits
mailing list