All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ric Wheeler <ric@emc.com>
To: Benjamin LaHaise <bcrl@kvack.org>
Cc: akpm@osdl.org, sct@redhat.com, linux-fsdevel@vger.kernel.org,
	Jens Axboe <axboe@suse.de>, Chris Mason <mason@suse.com>
Subject: Re: [JBD] change batching logic to improve O_SYNC performance
Date: Thu, 15 Dec 2005 09:22:23 -0500	[thread overview]
Message-ID: <43A17C1F.6070906@emc.com> (raw)
In-Reply-To: <20051215145951.GB2444@kvack.org>

Benjamin LaHaise wrote:
> Hello folks,
> 
> When writing files out using O_SYNC, jbd's 1 jiffy delay results in a 
> significant drop in throughput as the disk sits idle.  The patch below 
> results in a 4-5x performance improvement (from 6.5MB/s to ~24-30MB/s on 
> my IDE test box) when writing out files using O_SYNC.  Instead of always 
> delaying for 1 jiffy when trying to batch, merely do a yield() to allow 
> other processes to execute and potentially batch requests.  Additionally, 
> limit the delay to an absolute max of 1/50th of a second.  
> 
> 		-ben
> 

I was playing with similar code in reiserfs last year, trying to tune 
for fsync() performance.

The challenge is that when the rate of fsync() arrivals is low, you 
don't want to introduce extra latency for these "lonely" requests while 
you wait for a request to combine which is not going to come any time soon.

On the other hand, if the rate of fsync() requests is high enough, you 
gain a huge performance win by combining multiple fsync()'s into one 
transaction.

This feels a bit like the IO combining logic in the io scheduler layer.

It would seem to be begging for some dynamic logic based on the arrival 
rate for both the fsync & synchronous write combining...

ric



  reply	other threads:[~2005-12-15 17:26 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-12-15 14:59 [JBD] change batching logic to improve O_SYNC performance Benjamin LaHaise
2005-12-15 14:22 ` Ric Wheeler [this message]
2005-12-15 23:55 ` Andrew Morton
2005-12-15 21:39   ` Ric Wheeler
2005-12-16  0:48   ` Andreas Dilger

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=43A17C1F.6070906@emc.com \
    --to=ric@emc.com \
    --cc=akpm@osdl.org \
    --cc=axboe@suse.de \
    --cc=bcrl@kvack.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=mason@suse.com \
    --cc=sct@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.