From: Jaegeuk Kim <jaegeuk@kernel.org>
To: Christoph Hellwig <hch@infradead.org>
Cc: Daniel Lee <chullee@google.com>, Chao Yu <chao@kernel.org>,
linux-f2fs-devel@lists.sourceforge.net,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] f2fs: Introduce linear search for dentries
Date: Mon, 23 Dec 2024 16:57:35 +0000 [thread overview]
Message-ID: <Z2mWf-pghAlHYJ8o@google.com> (raw)
In-Reply-To: <Z2ketmZiWmUVddpt@infradead.org>
On 12/23, Christoph Hellwig wrote:
> On Fri, Dec 20, 2024 at 09:21:36AM -0800, Daniel Lee wrote:
> > This patch addresses an issue where some files in case-insensitive
> > directories become inaccessible due to changes in how the kernel function,
> > utf8_casefold(), generates case-folded strings from the commit 5c26d2f1d3f5
> > ("unicode: Don't special case ignorable code points").
>
> That also breaks all other direct hashed and needs to be fixed.
>
> >
> > F2FS uses these case-folded names to calculate hash values for locating
> > dentries and stores them on disk. Since utf8_casefold() can produce
> > different output across kernel versions, stored hash values and newly
> > calculated hash values may differ. This results in affected files no
> > longer being found via the hash-based lookup.
> >
> > To resolve this, the patch introduces a linear search fallback.
> > If the initial hash-based search fails, F2FS will sequentially scan the
> > directory entries.
>
> That means you have really bad worst case behavior for negative lookups.
> I don' think this is in any way a good idea.
No surprise. Please check:
https://lore.kernel.org/lkml/Z1mzu4Eg6CPURra3@google.com/
next prev parent reply other threads:[~2024-12-23 16:57 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-20 17:21 [PATCH v2] f2fs: Introduce linear search for dentries Daniel Lee
2024-12-20 21:00 ` Jaegeuk Kim
2024-12-23 8:26 ` Christoph Hellwig
2024-12-23 16:57 ` Jaegeuk Kim [this message]
2025-01-03 9:24 ` Christoph Hellwig
2025-01-06 21:18 ` Jaegeuk Kim
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=Z2mWf-pghAlHYJ8o@google.com \
--to=jaegeuk@kernel.org \
--cc=chao@kernel.org \
--cc=chullee@google.com \
--cc=hch@infradead.org \
--cc=linux-f2fs-devel@lists.sourceforge.net \
--cc=linux-kernel@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).