linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Theodore Tso <tytso@mit.edu>
To: Chris Mason <chris.mason@oracle.com>,
	linux-ext4@vger.kernel.org, linux-fsdevel@vger.kernel.org
Subject: Re: ext4 writepages is making tiny bios?
Date: Tue, 1 Sep 2009 16:57:44 -0400	[thread overview]
Message-ID: <20090901205744.GE6996@mit.edu> (raw)
In-Reply-To: <20090901184450.GB7885@think>

On Tue, Sep 01, 2009 at 02:44:50PM -0400, Chris Mason wrote:
> I've been doing some benchmark runs to speed up btrfs and look at Jens'
> new writeback work.  One thing that really surprised me is that ext4
> seems to be making 4k bios pretty much all the time.

Yeah, thanks for pointing that out.  As you pointed out, we're doing
95% of the work to create big bios, so we can allocate blocks
contiguosly for each file.  But then, at the very end, in
fs/ext4/inode.c:mpage_da_submit_io(), we end up calling
ext4_writepage() for each page in the extent.

For the case of data=journal, we need to do that, since all of the I/O
requests need to get chopped up into buffer heads and then submitted
through the jbd layer.  But in the other journal modes, we should be
able to issue a bio directly.  It probably doesn't make that much
difference to the ext4's performance (since the elevator will coalesce
the writes), but all that extra work is burning lot of CPU, and fixing
that would be a Good Thing.  (More CPU for the application to do, you
know, Real Work.  :-)

> This graph shows the difference:
> 
> http://oss.oracle.com/~mason/seekwatcher/trace-buffered.png

Wow, I'm surprised how seeky XFS was in these graphs compared to ext4
and btrfs.  I wonder what was going on.

Thanks for pointing that out.  I'll have to add that to do our "To do"
list for ext4.

							- Ted

  reply	other threads:[~2009-09-01 20:57 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-01 18:44 ext4 writepages is making tiny bios? Chris Mason
2009-09-01 20:57 ` Theodore Tso [this message]
2009-09-01 21:27   ` Christoph Hellwig
2009-09-02  0:17     ` Chris Mason
2009-09-03  5:52     ` Dave Chinner
2009-09-03 16:42       ` Christoph Hellwig
2009-09-04  0:15         ` Theodore Tso
2009-09-04  7:20           ` Jens Axboe

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=20090901205744.GE6996@mit.edu \
    --to=tytso@mit.edu \
    --cc=chris.mason@oracle.com \
    --cc=linux-ext4@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).