mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v2 0/2] improve buffered write performance with fgf order hint
@ 2024-06-14 16:30 Pankaj Raghav (Samsung)
  2024-06-14 16:30 ` [PATCH v2 1/2] bcachefs: use FGP_WRITEBEGIN instead of combining individual flags Pankaj Raghav (Samsung)
  2024-06-14 16:30 ` [PATCH v2 2/2] bcachefs: set fgf order hint before starting a buffered write Pankaj Raghav (Samsung)
  0 siblings, 2 replies; 3+ messages in thread
From: Pankaj Raghav (Samsung) @ 2024-06-14 16:30 UTC (permalink / raw)
  To: Brian Foster, Kent Overstreet
  Cc: gost.dev, linux-bcachefs, willy, mcgrof, linux-kernel, Pankaj Raghav

From: Pankaj Raghav <p.raghav@samsung.com>

Filesystems that support large folios can set the fgf order before
buffered write(see XFS iomap_write_begin()) that can provide as a hint
to page cache to allocate large folios, if possible.

The first patch is a minor cleanup.
The second patch sets fgf order before starting the buffered write.

I tested the performance on Samsung SSD 990 pro on a system with 64GB
RAM as follows:

$ bcachefs format -f /dev/nvme0n1;
$ mount -t bcachefs /dev/nvme0n1 /mnt
$ fio --name=bcachefs --filename=/mnt/test  --size=100G \
    --ioengine=io_uring --iodepth=16 --rw=write --bs=128k

I measured the BW(MB/s) across three runs on 6.10-rc3:
Before patches: 2730
After patches: 3430 (1.25x boost)

With -o no_data_io mount option:
Before patches: 2920
After patches: 4630 (1.5x boost)

I was not able to test the patches with ktest due to some issue with
debian(some broken package issue). Maybe Kent can run it in his CI while
I try to fix ktest locally?

Changes since v1:
- Avoid changing the indentation in the first patch.

Pankaj Raghav (2):
  bcachefs: use FGP_WRITEBEGIN instead of combining individual flags
  bcachefs: set fgf order hint before starting a buffered write

 fs/bcachefs/fs-io-buffered.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)


base-commit: 03d44168cbd7fc57d5de56a3730427db758fc7f6
-- 
2.44.1


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

end of thread, other threads:[~2024-06-14 16:31 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-06-14 16:30 [PATCH v2 0/2] improve buffered write performance with fgf order hint Pankaj Raghav (Samsung)
2024-06-14 16:30 ` [PATCH v2 1/2] bcachefs: use FGP_WRITEBEGIN instead of combining individual flags Pankaj Raghav (Samsung)
2024-06-14 16:30 ` [PATCH v2 2/2] bcachefs: set fgf order hint before starting a buffered write Pankaj Raghav (Samsung)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®