From: Matthew Wilcox <willy@infradead.org>
To: Hannes Reinecke <hare@suse.de>
Cc: Viacheslav Dubeyko <slava@dubeyko.com>,
Bart Van Assche <bvanassche@acm.org>,
lsf-pc@lists.linuxfoundation.org, linux-mm@kvack.org,
linux-block@vger.kernel.org, linux-scsi@vger.kernel.org,
"linux-nvme@lists.infradead.org" <linux-nvme@lists.infradead.org>
Subject: Re: [LSF/MM/BPF TOPIC] Large block for I/O
Date: Fri, 22 Dec 2023 13:29:17 +0000 [thread overview]
Message-ID: <ZYWPLQdjXzK8D6hT@casper.infradead.org> (raw)
In-Reply-To: <4f03e599-2772-4eb3-afb2-efa788eb08c4@suse.de>
On Fri, Dec 22, 2023 at 01:29:18PM +0100, Hannes Reinecke wrote:
> And that is actually a very valid point; memory fragmentation will become an
> issue with larger block sizes.
>
> Theoretically it should be quite easily solved; just switch the memory
> subsystem to use the largest block size in the system, and run every smaller
> memory allocation via SLUB (or whatever the allocator-of-the-day
> currently is :-). Then trivially the system will never be fragmented,
> and I/O can always use large folios.
>
> However, that means to do away with alloc_page(), which is still in
> widespread use throughout the kernel. I would actually in favour of it,
> but it might be that mm people have a different view.
>
> Matthew, worth a new topic?
> Handling memory fragmentation on large block I/O systems?
I think if we're going to do that as a topic (and I'm not opposed!),
we need data. Various workloads, various block sizes, etc. Right now
people discuss this topic with "feelings" and "intuition" and I think
we need more than vibes to have a productive discussion.
My laptop (rebooted last night due to an unfortunate upgrade that left
anything accessing the sound device hanging ...):
MemTotal: 16006344 kB
MemFree: 2353108 kB
Cached: 7957552 kB
AnonPages: 4271088 kB
Slab: 654896 kB
so ~50% of my 16GB of memory is in the page cache and ~25% is anon memory.
If the page cache is all in 16kB chunks and we need to allocate order-2
folios in order to read from a file, we can find it easily by reclaiming
other order-2 folios from the page cache. We don't need to resort to
heroics like eliminating use of alloc_page().
We should eliminate use of alloc_page() across most of the kernel, but
that's a different topic and one that has not much relevance to LSF/MM
since it's drivers that need to change, not the MM ;-)
Now, other people "feel" differently. And that's cool, but we're not
going to have a productive discussion without data that shows whose
feelings represent reality and for which kinds of workloads.
next prev parent reply other threads:[~2023-12-22 13:29 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <7970ad75-ca6a-34b9-43ea-c6f67fe6eae6@iogearbox.net>
2023-12-20 10:01 ` LSF/MM/BPF: 2024: Call for Proposals Daniel Borkmann
2023-12-20 15:03 ` [LSF/MM/BPF TOPIC] Large block for I/O Hannes Reinecke
2023-12-21 20:33 ` Bart Van Assche
2023-12-21 20:42 ` Matthew Wilcox
2023-12-21 21:00 ` Bart Van Assche
2023-12-22 5:09 ` Christoph Hellwig
2023-12-22 5:13 ` Matthew Wilcox
2023-12-22 5:37 ` Christoph Hellwig
2024-01-08 19:30 ` Bart Van Assche
2024-01-08 19:35 ` Matthew Wilcox
2024-02-22 18:45 ` Luis Chamberlain
2024-02-25 23:09 ` Dave Chinner
2024-02-26 15:25 ` Luis Chamberlain
2024-03-07 1:59 ` Luis Chamberlain
2024-03-07 5:31 ` Dave Chinner
2024-03-07 7:29 ` Luis Chamberlain
2023-12-22 8:23 ` Viacheslav Dubeyko
2023-12-22 12:29 ` Hannes Reinecke
2023-12-22 13:29 ` Matthew Wilcox [this message]
2023-12-22 15:10 ` Keith Busch
2023-12-22 16:06 ` Matthew Wilcox
2023-12-25 8:55 ` Viacheslav Dubeyko
2023-12-25 8:12 ` Viacheslav Dubeyko
2024-02-23 16:41 ` Pankaj Raghav (Samsung)
2024-01-17 13:37 ` LSF/MM/BPF: 2024: Call for Proposals [Reminder] Daniel Borkmann
2024-02-14 13:03 ` LSF/MM/BPF: 2024: Call for Proposals [Final Reminder] Daniel Borkmann
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=ZYWPLQdjXzK8D6hT@casper.infradead.org \
--to=willy@infradead.org \
--cc=bvanassche@acm.org \
--cc=hare@suse.de \
--cc=linux-block@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linux-nvme@lists.infradead.org \
--cc=linux-scsi@vger.kernel.org \
--cc=lsf-pc@lists.linuxfoundation.org \
--cc=slava@dubeyko.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;
as well as URLs for NNTP newsgroup(s).