diff options
author | Chris Mason <chris.mason@oracle.com> | 2008-07-31 15:42:53 -0400 |
---|---|---|
committer | Chris Mason <chris.mason@oracle.com> | 2008-09-25 11:04:05 -0400 |
commit | 61b4944018449003ac5f9757f4d125dce519cf51 (patch) | |
tree | 553855996c641a945344db870b6dfd0d2d02086e /fs/btrfs/ctree.h | |
parent | 37d1aeee3990385e9bb436c50c2f7e120a668df6 (diff) |
Btrfs: Fix streaming read performance with checksumming on
Large streaming reads make for large bios, which means each entry on the
list async work queues represents a large amount of data. IO
congestion throttling on the device was kicking in before the async
worker threads decided a single thread was busy and needed some help.
The end result was that a streaming read would result in a single CPU
running at 100% instead of balancing the work off to other CPUs.
This patch also changes the pre-IO checksum lookup done by reads to
work on a per-bio basis instead of a per-page. This results in many
extra btree lookups on large streaming reads. Doing the checksum lookup
right before bio submit allows us to reuse searches while processing
adjacent offsets.
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/ctree.h')
-rw-r--r-- | fs/btrfs/ctree.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h index be16cd49ef69..d788ab0dcd96 100644 --- a/fs/btrfs/ctree.h +++ b/fs/btrfs/ctree.h | |||
@@ -1613,6 +1613,8 @@ int btrfs_lookup_inode(struct btrfs_trans_handle *trans, struct btrfs_root | |||
1613 | struct btrfs_key *location, int mod); | 1613 | struct btrfs_key *location, int mod); |
1614 | 1614 | ||
1615 | /* file-item.c */ | 1615 | /* file-item.c */ |
1616 | int btrfs_lookup_bio_sums(struct btrfs_root *root, struct inode *inode, | ||
1617 | struct bio *bio); | ||
1616 | int btrfs_insert_file_extent(struct btrfs_trans_handle *trans, | 1618 | int btrfs_insert_file_extent(struct btrfs_trans_handle *trans, |
1617 | struct btrfs_root *root, | 1619 | struct btrfs_root *root, |
1618 | u64 objectid, u64 pos, u64 disk_offset, | 1620 | u64 objectid, u64 pos, u64 disk_offset, |