From: "Darrick J. Wong" <djwong@kernel.org>
To: Christoph Hellwig <hch@infradead.org>
Cc: Dave Chinner <dchinner@redhat.com>,
linux-xfs@vger.kernel.org, david@fromorbit.com,
allison.henderson@oracle.com
Subject: Re: [PATCHSET v2 0/5] xfs: make attr forks permanent
Date: Mon, 11 Jul 2022 18:53:52 -0700 [thread overview]
Message-ID: <YszUMHbqe+vCAdYx@magnolia> (raw)
In-Reply-To: <Ysu0V1mQovrXQiEo@infradead.org>
On Sun, Jul 10, 2022 at 10:25:43PM -0700, Christoph Hellwig wrote:
> On Sat, Jul 09, 2022 at 03:48:36PM -0700, Darrick J. Wong wrote:
> > Although the race condition itself can be fixed through clever use of a
> > memory barrier, further consideration of the use cases of extended
> > attributes shows that most files always have at least one attribute, so
> > we might as well make them permanent.
>
> I kinda hat increase the size of the inode even more, but there is no
> arguing about keeping nasty rarely used code simple vs micro-optimizing
> it. Do you have numbers on hand on how many inodes we can cache in
> an order 0 or 1 cache before and after this?
Hm. On my laptop running 5.18, xfs_inode before the change was 928 bytes,
and here's what it looks like:
928 bytes
Order Pagebytes Slack Objs Slack/Objs
0 4096 384 4 96
1 8192 768 8 96
2 16384 608 17 36
3 32768 288 35 9
4 65536 576 70 9
So I guess that's why it picks order-3 slabs.
On a freshly built djwong-dev kernel, it's now 976 bytes:
976 bytes
Order Pagebytes Slack Objs Slack/Objs
0 4096 192 4 48
1 8192 384 8 48
2 16384 768 16 48
3 32768 560 33 17
4 65536 144 67 2
Here it seems to pick order-2 slabs, which admittedly isn't great.
--D
next prev parent reply other threads:[~2022-07-12 1:53 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-09 22:48 [PATCHSET v2 0/5] xfs: make attr forks permanent Darrick J. Wong
2022-07-09 22:48 ` [PATCH 1/5] xfs: convert XFS_IFORK_PTR to a static inline helper Darrick J. Wong
2022-07-11 5:26 ` Christoph Hellwig
2022-07-12 1:20 ` Darrick J. Wong
2022-07-12 4:53 ` Christoph Hellwig
2022-07-12 6:25 ` Dave Chinner
2022-07-09 22:48 ` [PATCH 2/5] xfs: make inode attribute forks a permanent part of struct xfs_inode Darrick J. Wong
2022-07-09 22:48 ` [PATCH 3/5] xfs: use XFS_IFORK_Q to determine the presence of an xattr fork Darrick J. Wong
2022-07-11 1:29 ` Dave Chinner
2022-07-09 22:48 ` [PATCH 4/5] xfs: replace XFS_IFORK_Q with a proper predicate function Darrick J. Wong
2022-07-09 22:49 ` [PATCH 5/5] xfs: replace inode fork size macros with functions Darrick J. Wong
2022-07-11 5:25 ` [PATCHSET v2 0/5] xfs: make attr forks permanent Christoph Hellwig
2022-07-12 1:53 ` Darrick J. Wong [this message]
2022-07-12 4:50 ` Christoph Hellwig
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=YszUMHbqe+vCAdYx@magnolia \
--to=djwong@kernel.org \
--cc=allison.henderson@oracle.com \
--cc=david@fromorbit.com \
--cc=dchinner@redhat.com \
--cc=hch@infradead.org \
--cc=linux-xfs@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