linux/fs/xfs
Dave Chinner 74f75a0cb7 xfs: convert buffer cache hash to rbtree
The buffer cache hash is showing typical hash scalability problems.
In large scale testing the number of cached items growing far larger
than the hash can efficiently handle. Hence we need to move to a
self-scaling cache indexing mechanism.

I have selected rbtrees for indexing becuse they can have O(log n)
search scalability, and insert and remove cost is not excessive,
even on large trees. Hence we should be able to cache large numbers
of buffers without incurring the excessive cache miss search
penalties that the hash is imposing on us.

To ensure we still have parallel access to the cache, we need
multiple trees. Rather than hashing the buffers by disk address to
select a tree, it seems more sensible to separate trees by typical
access patterns. Most operations use buffers from within a single AG
at a time, so rather than searching lots of different lists,
separate the buffer indexes out into per-AG rbtrees. This means that
searches during metadata operation have a much higher chance of
hitting cache resident nodes, and that updates of the tree are less
likely to disturb trees being accessed on other CPUs doing
independent operations.

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Alex Elder <aelder@sgi.com>
2010-10-18 15:07:56 -05:00
..
linux-2.6 xfs: convert buffer cache hash to rbtree 2010-10-18 15:07:56 -05:00
quota xfs: split out inode walk inode grabbing 2010-10-18 15:07:52 -05:00
support
Kconfig
Makefile
xfs_acl.h
xfs_ag.h xfs: convert buffer cache hash to rbtree 2010-10-18 15:07:56 -05:00
xfs_alloc_btree.c xfs: remove the ->kill_root btree operation 2010-10-18 15:07:38 -05:00
xfs_alloc_btree.h
xfs_alloc.c xfs: eliminate some newly-reported gcc warnings 2010-10-18 15:07:39 -05:00
xfs_alloc.h
xfs_arch.h
xfs_attr_leaf.c
xfs_attr_leaf.h
xfs_attr_sf.h
xfs_attr.c xfs: don't use vfs writeback for pure metadata modifications 2010-10-18 15:07:45 -05:00
xfs_attr.h
xfs_bit.c
xfs_bit.h
xfs_bmap_btree.c
xfs_bmap_btree.h
xfs_bmap.c xfs: Introduce XFS_IOC_ZERO_RANGE 2010-10-18 15:07:25 -05:00
xfs_bmap.h xfs: Introduce XFS_IOC_ZERO_RANGE 2010-10-18 15:07:25 -05:00
xfs_btree_trace.c
xfs_btree_trace.h
xfs_btree.c xfs: remove the ->kill_root btree operation 2010-10-18 15:07:38 -05:00
xfs_btree.h xfs: remove the ->kill_root btree operation 2010-10-18 15:07:38 -05:00
xfs_buf_item.c xfs: store xfs_mount in the buftarg instead of in the xfs_buf 2010-10-18 15:07:48 -05:00
xfs_buf_item.h
xfs_da_btree.c
xfs_da_btree.h
xfs_dfrag.c
xfs_dfrag.h
xfs_dinode.h
xfs_dir2_block.c
xfs_dir2_block.h
xfs_dir2_data.c
xfs_dir2_data.h
xfs_dir2_leaf.c
xfs_dir2_leaf.h
xfs_dir2_node.c
xfs_dir2_node.h
xfs_dir2_sf.c
xfs_dir2_sf.h
xfs_dir2.c
xfs_dir2.h
xfs_error.c
xfs_error.h
xfs_extfree_item.c
xfs_extfree_item.h
xfs_filestream.c
xfs_filestream.h
xfs_fs.h xfs: Introduce XFS_IOC_ZERO_RANGE 2010-10-18 15:07:25 -05:00
xfs_fsops.c xfs: use unhashed buffers for size checks 2010-10-18 15:07:50 -05:00
xfs_fsops.h xfs: dummy transactions should not dirty VFS state 2010-08-24 11:46:31 +10:00
xfs_ialloc_btree.c xfs: remove the ->kill_root btree operation 2010-10-18 15:07:38 -05:00
xfs_ialloc_btree.h
xfs_ialloc.c xfs: fix untrusted inode number lookup 2010-08-24 11:42:30 +10:00
xfs_ialloc.h
xfs_iget.c
xfs_inode_item.c xfs: don't use vfs writeback for pure metadata modifications 2010-10-18 15:07:45 -05:00
xfs_inode_item.h
xfs_inode.c xfs: ensure we mark all inodes in a freed cluster XFS_ISTALE 2010-08-24 11:42:41 +10:00
xfs_inode.h xfs: don't use vfs writeback for pure metadata modifications 2010-10-18 15:07:45 -05:00
xfs_inum.h
xfs_iomap.c
xfs_iomap.h
xfs_itable.c
xfs_itable.h
xfs_log_cil.c xfs: reduce the number of CIL lock round trips during commit 2010-10-18 15:07:42 -05:00
xfs_log_priv.h xfs: force background CIL push under sustained load 2010-09-29 07:51:03 -05:00
xfs_log_recover.c xfs: store xfs_mount in the buftarg instead of in the xfs_buf 2010-10-18 15:07:48 -05:00
xfs_log_recover.h
xfs_log.c xfs: rename xfs_buf_get_nodaddr to be more appropriate 2010-10-18 15:07:46 -05:00
xfs_log.h
xfs_mount.c xfs: convert buffer cache hash to rbtree 2010-10-18 15:07:56 -05:00
xfs_mount.h xfs: split inode AG walking into separate code for reclaim 2010-10-18 15:07:52 -05:00
xfs_mru_cache.c
xfs_mru_cache.h
xfs_quota.h
xfs_refcache.h
xfs_rename.c xfs: don't use vfs writeback for pure metadata modifications 2010-10-18 15:07:45 -05:00
xfs_rtalloc.c xfs: use unhashed buffers for size checks 2010-10-18 15:07:50 -05:00
xfs_rtalloc.h
xfs_rw.c
xfs_rw.h
xfs_sb.h
xfs_trans_ail.c
xfs_trans_buf.c
xfs_trans_extfree.c
xfs_trans_inode.c xfs: don't use vfs writeback for pure metadata modifications 2010-10-18 15:07:45 -05:00
xfs_trans_priv.h xfs: unlock items before allowing the CIL to commit 2010-08-24 11:42:52 +10:00
xfs_trans_space.h
xfs_trans.c xfs: unlock items before allowing the CIL to commit 2010-08-24 11:42:52 +10:00
xfs_trans.h xfs: don't use vfs writeback for pure metadata modifications 2010-10-18 15:07:45 -05:00
xfs_types.h
xfs_utils.c xfs: don't use vfs writeback for pure metadata modifications 2010-10-18 15:07:45 -05:00
xfs_utils.h
xfs_vnodeops.c xfs: rename xfs_buf_get_nodaddr to be more appropriate 2010-10-18 15:07:46 -05:00
xfs_vnodeops.h
xfs.h