From: Dave Chinner <david@fromorbit.com>
To: xfs@oss.sgi.com
Subject: [PATCH 02/17] xfs: add pluging for bulkstat readahead
Date: Fri, 7 Jun 2013 15:45:14 +1000 [thread overview]
Message-ID: <1370583929-14276-3-git-send-email-david@fromorbit.com> (raw)
In-Reply-To: <1370583929-14276-1-git-send-email-david@fromorbit.com>
From: Dave Chinner <dchinner@redhat.com>
I was running some tests on bulkstat on CRC enabled filesystems when
I noticed that all the IO being issued was 8k in size, regardless of
the fact taht we are issuing sequential 8k buffers for inodes
clusters. The IO size shoul dbe 16k for 256 byte inodes, and 32k for
512 byte inodes, but this wasn't happening.
blktrace showed that there was an explict plug and unplug happening
around each readahead IO from _xfs_buf_ioapply, and the unplug was
causing the IO to be issued immediately. Hence no opportunity was
being given to the elevator to merge adjacent readahead requests and
dispatch them as a single IO.
Add plugging around the inode chunk readahead dispatch loop tin
bulkstat to ensure that we don't unplug the queue between adjacent
inode buffer readahead IOs and so we get fewer, larger IO requests
hitting the storage subsystemi for bulkstat.
Signed-off-by: Dave Chinner <dchinner@redhat.com>
---
fs/xfs/xfs_itable.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/fs/xfs/xfs_itable.c b/fs/xfs/xfs_itable.c
index 2ea7d40..06d004d 100644
--- a/fs/xfs/xfs_itable.c
+++ b/fs/xfs/xfs_itable.c
@@ -383,11 +383,13 @@ xfs_bulkstat(
* Also start read-ahead now for this chunk.
*/
if (r.ir_freecount < XFS_INODES_PER_CHUNK) {
+ struct blk_plug plug;
/*
* Loop over all clusters in the next chunk.
* Do a readahead if there are any allocated
* inodes in that cluster.
*/
+ blk_start_plug(&plug);
agbno = XFS_AGINO_TO_AGBNO(mp, r.ir_startino);
for (chunkidx = 0;
chunkidx < XFS_INODES_PER_CHUNK;
@@ -399,6 +401,7 @@ xfs_bulkstat(
agbno, nbcluster,
&xfs_inode_buf_ops);
}
+ blk_finish_plug(&plug);
irbp->ir_startino = r.ir_startino;
irbp->ir_freecount = r.ir_freecount;
irbp->ir_free = r.ir_free;
--
1.7.10.4
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
next prev parent reply other threads:[~2013-06-07 5:46 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-07 5:45 [PATCH 00/17] xfs: current patch queue for 3.11 Dave Chinner
2013-06-07 5:45 ` [PATCH 01/17] xfs: update mount options documentation Dave Chinner
2013-06-07 5:45 ` Dave Chinner [this message]
2013-06-07 5:45 ` [PATCH 03/17] xfs: plug directory buffer readahead Dave Chinner
2013-06-07 5:45 ` [PATCH 04/17] xfs: don't use speculative prealloc for small files Dave Chinner
2013-06-07 5:45 ` [PATCH 05/17] xfs: don't do IO when creating an new inode Dave Chinner
2013-06-07 5:45 ` [PATCH 06/17] xfs: xfs_ifree doesn't need to modify the inode buffer Dave Chinner
2013-06-07 5:45 ` [PATCH 07/17] xfs: Introduce ordered log vector support Dave Chinner
2013-06-07 5:45 ` [PATCH 08/17] xfs: Introduce an ordered buffer item Dave Chinner
2013-06-07 5:45 ` [PATCH 09/17] xfs: Inode create log items Dave Chinner
2013-06-07 5:45 ` [PATCH 10/17] xfs: Inode create transaction reservations Dave Chinner
2013-06-07 5:45 ` [PATCH 11/17] xfs: Inode create item recovery Dave Chinner
2013-06-07 5:45 ` [PATCH 12/17] xfs: Use inode create transaction Dave Chinner
2013-06-07 5:45 ` [PATCH 13/17] xfs: remove local fork format handling from xfs_bmapi_write() Dave Chinner
2013-06-07 5:45 ` [PATCH 14/17] xfs: move getdents code into it's own file Dave Chinner
2013-06-07 5:45 ` [PATCH 15/17] xfs: reshuffle dir2 definitions around for userspace Dave Chinner
2013-06-07 5:45 ` [PATCH 16/17] xfs: split out attribute listing code into separate file Dave Chinner
2013-06-07 5:45 ` [PATCH 17/17] xfs: split out attribute fork truncation " Dave Chinner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1370583929-14276-3-git-send-email-david@fromorbit.com \
--to=david@fromorbit.com \
--cc=xfs@oss.sgi.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox