|
|
Log in / Subscribe / Register

better block swap batching and a different take on swap_ops

From:  Christoph Hellwig <hch-AT-lst.de>
To:  
Subject:  better block swap batching and a different take on swap_ops
Date:  Thu, 28 May 2026 14:45:16 +0200
Message-ID:  <20260528124559.2566481-1-hch@lst.de>
Cc:  baoquan.he-AT-linux.dev, akpm-AT-linux-foundation.org, chrisl-AT-kernel.org, usama.arif-AT-linux.dev, kasong-AT-tencent.com, nphamcs-AT-gmail.com, shikemeng-AT-huaweicloud.com, youngjun.park-AT-lge.com, linux-mm-AT-kvack.org
Archive-link:  Article

Hi all,

this series makes use of the swap_iocb for block as well so that it
doesn't do inefficient single-bio I/O, and then rebases the swap_ops
from Baoquan on top of the now very different method structure.

When running doing kernels builds, which is a workload that doesn't
really do much THP anonymous memory it still gets 2x clustering for
writeout and 1.2x for reading back swap in.  The overall times do
not actually change, though.

Note that the buildbot is slow at the moment, so while I fixed all
issues from the previous round, that run did take multiple days and
the new one is still pending, so I'd rather get a v1 out now as
we're most likely to have additional roundtrips anyway.

Diffstat:
 Documentation/filesystems/locking.rst     |    5 
 Documentation/filesystems/vfs.rst         |    4 
 drivers/gpu/drm/i915/gem/i915_gem_shmem.c |    2 
 drivers/gpu/drm/ttm/ttm_backup.c          |    2 
 fs/nfs/file.c                             |    4 
 fs/smb/client/file.c                      |    4 
 include/linux/memcontrol.h                |   10 
 include/linux/shmem_fs.h                  |    5 
 include/linux/swap.h                      |    7 
 include/linux/vm_event_item.h             |    4 
 mm/madvise.c                              |   16 
 mm/page_io.c                              |  568 ++++++++++++++----------------
 mm/shmem.c                                |   18 
 mm/swap.h                                 |   52 +-
 mm/swap_state.c                           |   53 +-
 mm/swapfile.c                             |   11 
 mm/vmscan.c                               |   88 ++--
 mm/vmstat.c                               |    6 
 mm/zswap.c                                |    4 
 19 files changed, 444 insertions(+), 419 deletions(-)



Copyright © 2026, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds