public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Ric Wheeler <rwheeler@redhat.com>
To: Andreas Dilger <adilger@sun.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>,
	"Theodore Ts'o" <tytso@mit.edu>,
	linux-ext4@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH, RFC] ext4: Use preallocation when reading from the	inode table
Date: Tue, 23 Sep 2008 08:18:54 -0400	[thread overview]
Message-ID: <48D8DEAE.4080309@redhat.com> (raw)
In-Reply-To: <20080923115045.GI10950@webber.adilger.int>

Andreas Dilger wrote:
> On Sep 23, 2008  10:16 +0100, Alan Cox wrote:
>   
>> On Mon, 22 Sep 2008 20:35:23 -0400
>> "Theodore Ts'o" <tytso@mit.edu> wrote:
>>     
>>> With modern hard drives, reading 64k takes roughly the same time as
>>> reading a 4k block.  So request adjacent inode table blocks to reduce
>>> the time it takes when iterating over directories (especially when doing
>>> this in htree sort order) in a cold cache case.  With this patch, the
>>> time it takes to run "git status" on a kernel tree after flushing the
>>> caches via "echo 3 > /proc/sys/vm/drop_caches", is reduced by 21%.
>>>
>>> Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
>>>       
>> Acked-by: Alan Cox <alan@redhat.com>
>>
>> I'm actually suprised that 16 is the magic tuning number you've used and
>> a bigger one isn't even more of a win
>>     
>
> I was going to suggest making this at least a #defined constant instead
> of hard coding the values there.  Making it a mount option and/or /proc
> value would allow further testing.
>
> Cheers, Andreas
> --
> Andreas Dilger
> Sr. Staff Engineer, Lustre Group
> Sun Microsystems of Canada, Inc.
>
>   

I think that Alan is probably right - the magic number for modern drives 
is probably closer to 256K. Having it be a /sys tunable (with a larger 
default) would be a nice way to verify this.

Ric


  reply	other threads:[~2008-09-23 12:19 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-09-23  0:35 [PATCH, RFC] ext4: Use preallocation when reading from the inode table Theodore Ts'o
2008-09-23  9:16 ` Alan Cox
2008-09-23 11:50   ` Andreas Dilger
2008-09-23 12:18     ` Ric Wheeler [this message]
2008-09-24  1:30       ` Theodore Tso
2008-09-24 13:23         ` Ric Wheeler
2008-09-24 14:20           ` Chris Mason
2008-09-24 20:35           ` Theodore Tso
2008-09-25 23:40             ` 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=48D8DEAE.4080309@redhat.com \
    --to=rwheeler@redhat.com \
    --cc=adilger@sun.com \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=linux-ext4@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tytso@mit.edu \
    /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