linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/3] btrfs: find_free_extent cleanups
@ 2025-10-03 23:41 Leo Martins
  2025-10-03 23:41 ` [PATCH v2 1/3] btrfs: remove ffe RAID loop Leo Martins
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Leo Martins @ 2025-10-03 23:41 UTC (permalink / raw)
  To: linux-btrfs, kernel-team, fstests

The first patch removes redundant RAID loop logic that became obsolete
after previous changes ensured allocations only occur from block groups
with matching RAID level.

The second patch adds comprehensive tracing to find_free_extent() to
improve debugging and performance analysis capabilities.

Here is a bpftrace script I put together to analyze the allocation
behavior, along with output.
Link: https://github.com/loemraw/btrfs-scripts/blob/main/ffe_analyzer.bt
Link: https://github.com/loemraw/btrfs-scripts/blob/main/ffe_analyzer.out

Testing:
- ran xfstests btrfs/auto
- verified trace events output correctly
- new fstest that tests RAID conversions under stress

Change log:
v1 -> v2:
PATCH 1
- re-add full_search
PATCH 2
- standardize naming of skip reasons
- remove preapare_allocation_failure reason as it's not a skip
- add more error_or_values for skip reasons
PATCH 3
- new fstests for raid conversions under stress


Leo Martins (2):
  btrfs: remove ffe RAID loop
  btrfs: add tracing for find_free_extent skip conditions

 fs/btrfs/extent-tree.c       | 70 ++++++++++++++++++------------------
 fs/btrfs/extent-tree.h       | 17 +++++++++
 include/trace/events/btrfs.h | 66 ++++++++++++++++++++++++++++++++++
 3 files changed, 119 insertions(+), 34 deletions(-)

-- 
2.47.3


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2025-10-15  3:31 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-03 23:41 [PATCH v2 0/3] btrfs: find_free_extent cleanups Leo Martins
2025-10-03 23:41 ` [PATCH v2 1/3] btrfs: remove ffe RAID loop Leo Martins
2025-10-15  3:29   ` Boris Burkov
2025-10-03 23:41 ` [PATCH v2 2/3] btrfs: add tracing for find_free_extent skip conditions Leo Martins
2025-10-15  3:28   ` Boris Burkov
2025-10-03 23:41 ` [PATCH v2 3/3] fstests: btrfs: test RAID conversions under stress Leo Martins
2025-10-04  1:54   ` Qu Wenruo
2025-10-06 17:37     ` Leo Martins
2025-10-06 18:16       ` David Sterba
2025-10-15  3:31   ` Boris Burkov

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).