mbox series

[v2,00/19] btrfs: fixes, cleanups and optimizations around fiemap

Message ID cover.1665490018.git.fdmanana@suse.com (mailing list archive)
Headers show
Series btrfs: fixes, cleanups and optimizations around fiemap | expand

Message

Filipe Manana Oct. 11, 2022, 12:16 p.m. UTC
From: Filipe Manana <fdmanana@suse.com>

The first 3 patches are bug fixes, the first two fixing bugs in backref
walking that have been around since 2013 and 2017, respectively, while the
third one fixes a bug introduced in this merge window.

The remaining are performance optimizations in the fiemap code path, as
well as some cleanups and refactorings to support them. Results and tests
are found in the changelogs of individual patches (06/19, 16/19, 18/19
and 19/19).

V2: Add one more patch to fix a long standing bug (since 2013) regarding
    delayed data references during backref walking. Made it first patch
    in the series since later patches touched the surrounding code and
    it should backported to stable releases.

Filipe Manana (19):
  btrfs: fix processing of delayed data refs during backref walking
  btrfs: fix processing of delayed tree block refs during backref walking
  btrfs: ignore fiemap path cache if we have multiple leaves for a data extent
  btrfs: get the next extent map during fiemap/lseek more efficiently
  btrfs: skip unnecessary extent map searches during fiemap and lseek
  btrfs: skip unnecessary delalloc search during fiemap and lseek
  btrfs: drop pointless memset when cloning extent buffer
  btrfs: drop redundant bflags initialization when allocating extent buffer
  btrfs: remove checks for a root with id 0 during backref walking
  btrfs: remove checks for a 0 inode number during backref walking
  btrfs: directly pass the inode to btrfs_is_data_extent_shared()
  btrfs: turn the backref sharedness check cache into a context object
  btrfs: move ulists to data extent sharedness check context
  btrfs: remove roots ulist when checking data extent sharedness
  btrfs: remove useless logic when finding parent nodes
  btrfs: cache sharedness of the last few data extents during fiemap
  btrfs: move up backref sharedness cache store and lookup functions
  btrfs: avoid duplicated resolution of indirect backrefs during fiemap
  btrfs: avoid unnecessary resolution of indirect backrefs during fiemap

 fs/btrfs/backref.c    | 489 ++++++++++++++++++++++++++++--------------
 fs/btrfs/backref.h    |  55 ++++-
 fs/btrfs/extent_io.c  |  68 +++---
 fs/btrfs/extent_map.c |  31 ++-
 fs/btrfs/extent_map.h |   2 +
 fs/btrfs/file.c       |  69 ++++--
 6 files changed, 483 insertions(+), 231 deletions(-)

Comments

David Sterba Oct. 11, 2022, 12:54 p.m. UTC | #1
On Tue, Oct 11, 2022 at 01:16:50PM +0100, fdmanana@kernel.org wrote:
> From: Filipe Manana <fdmanana@suse.com>
> 
> The first 3 patches are bug fixes, the first two fixing bugs in backref
> walking that have been around since 2013 and 2017, respectively, while the
> third one fixes a bug introduced in this merge window.
> 
> The remaining are performance optimizations in the fiemap code path, as
> well as some cleanups and refactorings to support them. Results and tests
> are found in the changelogs of individual patches (06/19, 16/19, 18/19
> and 19/19).
> 
> V2: Add one more patch to fix a long standing bug (since 2013) regarding
>     delayed data references during backref walking. Made it first patch
>     in the series since later patches touched the surrounding code and
>     it should backported to stable releases.

Thanks, meanwhile v1 was in misc-next and got lightly tested so now
replaced by v2 and first three patches queued for 6.1.