From: David Sterba <dsterba@suse.cz>
To: Martin Raiber <martin@urbackup.org>
Cc: fdmanana@kernel.org, linux-btrfs@vger.kernel.org
Subject: Re: [PATCH v2 02/10] btrfs: reduce size of struct btrfs_block_group
Date: Fri, 17 Apr 2026 04:09:12 +0200 [thread overview]
Message-ID: <20260417020912.GV12792@twin.jikos.cz> (raw)
In-Reply-To: <0102019d92c1ee11-d6caef74-9449-4f16-aa67-31c5995f8676-000000@eu-west-1.amazonses.com>
On Wed, Apr 15, 2026 at 08:07:56PM +0000, Martin Raiber wrote:
> I found that putting ro, cached and size_class in the same cache line
> brought performance benefits for |find_free_extent. I cannot say how
> important that is compared to other kinds of users.|
I don't see any obvious use pattern where grouping the class, ro and
cached would be beneficial. What usually works is when a lock and the
members used in the locked section are on the same cacheline. As block
group is a big structure and used in different ways there are
possibilites where the cacheline placement will have good or bad effects
but without a reproducible or described workload it could be just a
random occasion.
Specifically for find_free_extent, there could be some potential for
optimization but this again would need at least a perf profile to find a
starting point.
next prev parent reply other threads:[~2026-04-17 2:09 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-15 14:38 [PATCH 0/9] btrfs: reduce memory consumption for block groups fdmanana
2026-04-15 14:38 ` [PATCH 1/9] btrfs: use a kmem_cache " fdmanana
2026-04-15 14:38 ` [PATCH 2/9] btrfs: reduce size of struct btrfs_block_group fdmanana
2026-04-15 14:38 ` [PATCH 3/9] btrfs: use a kmem_cache for free space control structures fdmanana
2026-04-15 14:38 ` [PATCH 4/9] btrfs: remove start field from struct btrfs_free_space_ctl fdmanana
2026-04-15 14:38 ` [PATCH 5/9] btrfs: remove unit " fdmanana
2026-04-15 14:38 ` [PATCH 6/9] btrfs: reduce size of " fdmanana
2026-04-15 14:38 ` [PATCH 7/9] btrfs: remove block group argument from copy_free_space_cache() fdmanana
2026-04-15 14:38 ` [PATCH 8/9] btrfs: remove unnecessary ctl argument from __btrfs_write_out_cache() fdmanana
2026-04-15 14:38 ` [PATCH 9/9] btrfs: remove unnecessary ctl argument from write_cache_extent_entries() fdmanana
2026-04-15 18:44 ` [PATCH v2 00/10] btrfs: reduce memory consumption for block groups fdmanana
2026-04-15 18:44 ` [PATCH v2 01/10] btrfs: use a kmem_cache " fdmanana
2026-04-17 1:51 ` David Sterba
2026-04-15 18:44 ` [PATCH v2 02/10] btrfs: reduce size of struct btrfs_block_group fdmanana
2026-04-15 20:07 ` Martin Raiber
2026-04-16 10:30 ` Filipe Manana
2026-04-16 10:46 ` Martin Raiber
2026-04-17 2:09 ` David Sterba [this message]
2026-04-15 18:44 ` [PATCH v2 03/10] btrfs: use a kmem_cache for free space control structures fdmanana
2026-04-15 18:44 ` [PATCH v2 04/10] btrfs: remove start field from struct btrfs_free_space_ctl fdmanana
2026-04-15 18:44 ` [PATCH v2 05/10] btrfs: remove unit " fdmanana
2026-04-15 18:44 ` [PATCH v2 06/10] btrfs: reduce size of " fdmanana
2026-04-15 18:44 ` [PATCH v2 07/10] btrfs: remove op field from " fdmanana
2026-04-15 18:44 ` [PATCH v2 08/10] btrfs: remove block group argument from copy_free_space_cache() fdmanana
2026-04-15 18:44 ` [PATCH v2 09/10] btrfs: remove unnecessary ctl argument from __btrfs_write_out_cache() fdmanana
2026-04-15 18:44 ` [PATCH v2 10/10] btrfs: remove unnecessary ctl argument from write_cache_extent_entries() fdmanana
2026-04-17 2:16 ` [PATCH v2 00/10] btrfs: reduce memory consumption for block groups David Sterba
2026-04-17 7:54 ` Filipe Manana
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=20260417020912.GV12792@twin.jikos.cz \
--to=dsterba@suse.cz \
--cc=fdmanana@kernel.org \
--cc=linux-btrfs@vger.kernel.org \
--cc=martin@urbackup.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