cvs commit: src/sys/vfs/hammer hammer.h hammer_btree.c hammer_btree.h hammer_cursor.c hammer_disk.h hammer_inode.c hammer_io.c hammer_object.c hammer_ondisk.c hammer_transaction.c hammer_vfsops.c hammer_vnops.c
Matthew Dillon
dillon at crater.dragonflybsd.org
Tue Jun 17 18:14:36 PDT 2008
dillon 2008/06/17 18:13:31 PDT
DragonFly src repository
Modified files:
sys/vfs/hammer hammer.h hammer_btree.c hammer_btree.h
hammer_cursor.c hammer_disk.h
hammer_inode.c hammer_io.c
hammer_object.c hammer_ondisk.c
hammer_transaction.c hammer_vfsops.c
hammer_vnops.c
Log:
HAMMER 56B/Many: Performance tuning - MEDIA STRUCTURES CHANGED!
* MEDIA CHANGE: The atime has been moved back into the inode data proper.
The nlinks field has also been moved.
* PERFORMANCE: The CRC for cached B-Tree nodes was being run on every access
instead of just the first time. This was the cause of HAMMER's poor
directory scanning performance and cpu-intensive write flushes.
Adjusted to only check the CRC on the initial load into the buffer cache.
* PERFORMANCE: The CRC for modified B-Tree nodes was being regenerated every
time the node was modified, so a large number of insertions or deletions
modifying the same B-Tree need needlessly regenerated the CRC each time.
Adjusted to delay generation of the CRC until just before the buffer is
flushed to the physical media.
Just for the record, B-Tree nodes are 4K and it takes ~25uS to run a CRC
on them. Needless to say removing the unnecessary calls solved a lot of
performance issues.
* PERFORMANCE: Removed limitations in the node caching algorithms. Now more
then one inode can cache pointers to the same B-Tree node.
* PERFORMANCE: When calculating the parent B-Tree node we have to scan the
element array to locate the index that points back to the child. Use a
power-of-2 algorithm instead of a linear scan.
* PERFORMANCE: Clean up the selection of ip->cache[0] or ip->cache[1] based
on whether we are trying to cache the location of the inode or the
location of the file object's data.
Revision Changes Path
1.86 +52 -13 src/sys/vfs/hammer/hammer.h
1.55 +1 -4 src/sys/vfs/hammer/hammer_btree.c
1.18 +1 -1 src/sys/vfs/hammer/hammer_btree.h
1.31 +15 -21 src/sys/vfs/hammer/hammer_cursor.c
1.38 +6 -3 src/sys/vfs/hammer/hammer_disk.h
1.77 +40 -15 src/sys/vfs/hammer/hammer_inode.c
1.43 +23 -0 src/sys/vfs/hammer/hammer_io.c
1.70 +11 -9 src/sys/vfs/hammer/hammer_object.c
1.59 +47 -62 src/sys/vfs/hammer/hammer_ondisk.c
1.18 +7 -0 src/sys/vfs/hammer/hammer_transaction.c
1.49 +2 -0 src/sys/vfs/hammer/hammer_vfsops.c
1.72 +29 -27 src/sys/vfs/hammer/hammer_vnops.c
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/hammer/hammer.h.diff?r1=1.85&r2=1.86&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/hammer/hammer_btree.c.diff?r1=1.54&r2=1.55&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/hammer/hammer_btree.h.diff?r1=1.17&r2=1.18&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/hammer/hammer_cursor.c.diff?r1=1.30&r2=1.31&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/hammer/hammer_disk.h.diff?r1=1.37&r2=1.38&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/hammer/hammer_inode.c.diff?r1=1.76&r2=1.77&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/hammer/hammer_io.c.diff?r1=1.42&r2=1.43&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/hammer/hammer_object.c.diff?r1=1.69&r2=1.70&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/hammer/hammer_ondisk.c.diff?r1=1.58&r2=1.59&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/hammer/hammer_transaction.c.diff?r1=1.17&r2=1.18&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/hammer/hammer_vfsops.c.diff?r1=1.48&r2=1.49&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/hammer/hammer_vnops.c.diff?r1=1.71&r2=1.72&f=u
More information about the Commits
mailing list