public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Brian Foster <bfoster@redhat.com>
To: Christoph Hellwig <hch@infradead.org>
Cc: Long Li <leo.lilong@huawei.com>,
	brauner@kernel.org, djwong@kernel.org, cem@kernel.org,
	linux-xfs@vger.kernel.org, yi.zhang@huawei.com,
	houtao1@huawei.com, yangerkun@huawei.com
Subject: Re: [PATCH v2 1/2] iomap: fix zero padding data issue in concurrent append writes
Date: Wed, 20 Nov 2024 08:50:45 -0500	[thread overview]
Message-ID: <Zz3pNTDwYImhuAkV@bfoster> (raw)
In-Reply-To: <Zz2mTCq03SEjoUZV@infradead.org>

On Wed, Nov 20, 2024 at 01:05:16AM -0800, Christoph Hellwig wrote:
> On Mon, Nov 18, 2024 at 09:26:45AM -0500, Brian Foster wrote:
> > IOW following the train of thought in the other subthread, would any
> > practical workload be affected if we just trimmed io_size when needed by
> > i_size and left it at that?
> 
> Can you explain what you mean with that? 
> 

I mean what happens if we trimmed io_size just as this patch already
does, but left off the rounding stuff?

The rounding is only used for adding to or attempting to merge ioends. I
don't see when it would ever really make a difference in adding folios
to an ioend, since we don't writeback folios beyond i_size and a size
extending operation is unlikely to write back between the time an ioend
is being constructed/trimmed and submitted.

After discussion, it seems there are some scenarios where the rounding
allows i_size trimmed ioends to merge, but again I'm not seeing how that
can occur frequently enough such that just skipping the rounding and
letting trimmed ioends fail to merge would have any noticeable
performance impact.

But anyways, I think we've reached compromise that pulling the rounding
helper into buffered-io.c and documenting it well preserves logic and
addresses my concerns by making sure it doesn't proliferate for the time
being.

Brian


  reply	other threads:[~2024-11-20 13:49 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-13  9:19 [PATCH v2 1/2] iomap: fix zero padding data issue in concurrent append writes Long Li
2024-11-13  9:19 ` [PATCH v2 2/2] xfs: clean up xfs_end_ioend() to reuse local variables Long Li
2024-11-18  6:57   ` Christoph Hellwig
2024-11-13  9:44 ` [PATCH v2 1/2] iomap: fix zero padding data issue in concurrent append writes Carlos Maiolino
2024-11-13 11:38   ` Long Li
2024-11-13 12:56     ` Carlos Maiolino
2024-11-13 16:13 ` Brian Foster
2024-11-14  2:34   ` Long Li
2024-11-14 18:04     ` Brian Foster
2024-11-14 20:01       ` Dave Chinner
2024-11-15 14:03         ` Brian Foster
2024-11-15 11:53       ` Long Li
2024-11-15 13:46         ` Brian Foster
2024-11-19  1:35           ` Long Li
2024-11-18  6:56   ` Christoph Hellwig
2024-11-18 14:26     ` Brian Foster
2024-11-20  9:05       ` Christoph Hellwig
2024-11-20 13:50         ` Brian Foster [this message]
2024-11-21  5:49           ` Christoph Hellwig
2024-11-19  8:35     ` Long Li
2024-11-19 12:13       ` Brian Foster
2024-11-19 13:46         ` Long Li

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=Zz3pNTDwYImhuAkV@bfoster \
    --to=bfoster@redhat.com \
    --cc=brauner@kernel.org \
    --cc=cem@kernel.org \
    --cc=djwong@kernel.org \
    --cc=hch@infradead.org \
    --cc=houtao1@huawei.com \
    --cc=leo.lilong@huawei.com \
    --cc=linux-xfs@vger.kernel.org \
    --cc=yangerkun@huawei.com \
    --cc=yi.zhang@huawei.com \
    /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