mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Carl Henrik Lunde" <chlunde@ping.uio.no>
To: "Soeren Sandmann" <sandmann@daimi.au.dk>
Cc: "Theodore Tso" <tytso@mit.edu>,
	linux-kernel@vger.kernel.org, alexl@redhat.com
Subject: Re: stat benchmark
Date: Mon, 28 Apr 2008 02:13:55 +0200	[thread overview]
Message-ID: <ed038eb20804271713n79ff9b0cxa6906867d7a20f9@mail.gmail.com> (raw)
In-Reply-To: <ye8iqy23mhb.fsf@camel27.daimi.au.dk>

On Mon, Apr 28, 2008 at 1:29 AM, Soeren Sandmann <sandmann@daimi.au.dk> wrote:
[...]
>  For a directory of ~2360 files, chunks of a 1000 files is actually
>  surprisingly worse than statting all of the files at once:
>
>     Time to stat 1000 files: 1.008735 s
>     Time to stat 1000 files: 0.738936 s
>     Time to stat 366 files: 0.217002 s
>
>  I guess this just shows that seeks really is pretty much all that
>  matters. Glib should maybe use a larger chunk size.

I agree, if I remember correctly I did not find a directory on my local
disk where the best result was to sort a chunk instead of the complete
directory.

>  I don't know if a general library outside glib would be useful. It
>  seems that just telling people to "sort by inode before statting"
>  would be just as effective as telling them "use this optimized
>  library".

A library (like glib) could disable the feature for solid-state drives
and perhaps implement an alternative strategy for filesystems without
any inode/sector correlation.

So I think we should tell people to use glib. :-)

-- 
Carl Henrik

  reply	other threads:[~2008-04-28  0:14 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-04-24 20:59 Soeren Sandmann
2008-04-24 21:42 ` Carl Henrik Lunde
2008-04-24 21:44 ` Jan Engelhardt
2008-04-25  2:27   ` Justin Banks
2008-04-25  7:01   ` Christoph Hellwig
2008-04-25 19:48 ` Theodore Tso
2008-04-27 23:29   ` Soeren Sandmann
2008-04-28  0:13     ` Carl Henrik Lunde [this message]
2008-04-28 19:41       ` Alexander Larsson
2008-04-28  2:10     ` Theodore Tso
2008-04-27 22:40 ` Carl Henrik Lunde
2008-04-28 17:46   ` Zach Brown
2008-04-28  4:43 ` Ulrich Drepper
2008-04-28 11:53   ` Theodore Tso
2008-04-28 11:59     ` Avi Kivity
2008-04-28 13:31       ` Theodore Tso
2008-04-28 16:18     ` J. Bruce Fields

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=ed038eb20804271713n79ff9b0cxa6906867d7a20f9@mail.gmail.com \
    --to=chlunde@ping.uio.no \
    --cc=alexl@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sandmann@daimi.au.dk \
    --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

all inboxes | Powered by JetHome®