From: David Nicol <davidnicol@gmail.com>
To: BTRFS MAILING LIST <linux-btrfs@vger.kernel.org>
Subject: newbie question about struct btrfs_dir_item *btrfs_match_dir_item_name
Date: Mon, 18 Oct 2010 09:14:19 -0500 [thread overview]
Message-ID: <AANLkTikQ94sEbBr8zg7RW5PPRKARFEEhENhXquS=e_Ad@mail.gmail.com> (raw)
reading, in dir-item.c, the code in
struct btrfs_dir_item *btrfs_match_dir_item_name (...)
I am a little surprised to see an O(n) iterative name comparison check
instead of something that would
efficiently support directories with lots of items in them. Is this
function a fall-back if a O(1) table lookup
somewhere else misses, perhaps?
--
"In one instance, a rai being transported by canoe was accidentally
dropped and sunk to the sea floor. Although it was never seen again,
everyone agreed that the rai must still be there, so it continued to
be transacted as genuine currency" -- Wikipedia
reply other threads:[~2010-10-18 14:14 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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='AANLkTikQ94sEbBr8zg7RW5PPRKARFEEhENhXquS=e_Ad@mail.gmail.com' \
--to=davidnicol@gmail.com \
--cc=linux-btrfs@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).