From: yuezhang.mo@foxmail.com
To: linkinjeon@kernel.org, sj1557.seo@samsung.com
Cc: linux-fsdevel@vger.kernel.org, Andy.Wu@sony.com,
wataru.aoyama@sony.com, Yuezhang Mo <Yuezhang.Mo@sony.com>
Subject: [PATCH v1 00/11] exfat: improve sync dentry
Date: Fri, 8 Dec 2023 19:23:08 +0800 [thread overview]
Message-ID: <tencent_0E5AE3EC14C4E534F5D1CF23DD4D7C4CE005@qq.com> (raw)
From: Yuezhang Mo <Yuezhang.Mo@sony.com>
This patch set changes sync dentry-by-dentry to sync
dentrySet-by-dentrySet, and remove some syncs that do not cause
data loss. It not only improves the performance of sync dentry,
but also reduces the consumption of storage device life.
I used the following commands and blktrace to measure the improvements
on a class 10 SDXC card.
rm -fr $mnt/dir; mkdir $mnt/dir; sync
time (for ((i=0;i<1000;i++));do touch $mnt/dir/${prefix}$i;done;sync $mnt)
time (for ((i=0;i<1000;i++));do rm $mnt/dir/${prefix}$i;done;sync $mnt)
| case | name len | create | unlink |
| | | time | write size | time | write size |
|------+----------+----------+------------+-----------+------------|
| 1 | 15 | 10.260s | 191KiB | 9.829s | 96KiB |
| 2 | 15 | 11.456s | 562KiB | 11.032s | 562KiB |
| 3 | 15 | 30.637s | 3500KiB | 21.740s | 2000KiB |
| 1 | 120 | 10.840s | 644KiB | 9.961s | 315KiB |
| 2 | 120 | 13.282s | 1092KiB | 12.432s | 752KiB |
| 3 | 120 | 45.393s | 7573KiB | 37.395s | 5500KiB |
| 1 | 255 | 11.549s | 1028KiB | 9.994s | 594KiB |
| 2 | 255 | 15.826s | 2170KiB | 13.387s | 1063KiB |
| 3 | 255 | 1m7.211s | 12335KiB | 0m58.517s | 10004KiB |
case 1. disable dirsync
case 2. with this patch set and enable dirsync
case 3. without this patch set and enable dirsync
Yuezhang Mo (11):
exfat: add __exfat_get_dentry_set() helper
exfat: add exfat_get_empty_dentry_set() helper
exfat: covert exfat_find_empty_entry() to use dentry cache
exfat: covert exfat_add_entry() to use dentry cache
exfat: covert exfat_remove_entries() to use dentry cache
exfat: move free cluster out of exfat_init_ext_entry()
exfat: covert exfat_init_ext_entry() to use dentry cache
exfat: remove __exfat_find_empty_entry()
exfat: remove unused functions
exfat: do not sync parent dir if just update timestamp
exfat: remove duplicate update parent dir
fs/exfat/dir.c | 286 ++++++++++++++++++-----------------
fs/exfat/exfat_fs.h | 23 ++-
fs/exfat/inode.c | 2 +-
fs/exfat/namei.c | 352 +++++++++++++++++---------------------------
4 files changed, 288 insertions(+), 375 deletions(-)
--
2.25.1
reply other threads:[~2023-12-08 11:27 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=tencent_0E5AE3EC14C4E534F5D1CF23DD4D7C4CE005@qq.com \
--to=yuezhang.mo@foxmail.com \
--cc=Andy.Wu@sony.com \
--cc=Yuezhang.Mo@sony.com \
--cc=linkinjeon@kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=sj1557.seo@samsung.com \
--cc=wataru.aoyama@sony.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 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).