[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <bc2f3ca9-e49a-4ca1-8b63-cbc7773d23d5@app.fastmail.com>
Date: Tue, 22 Nov 2022 17:33:17 +0100
From: "Arnd Bergmann" <arnd@...db.de>
To: "Vlastimil Babka" <vbabka@...e.cz>,
"Christoph Lameter" <cl@...ux.com>,
"David Rientjes" <rientjes@...gle.com>,
"Joonsoo Kim" <iamjoonsoo.kim@....com>,
"Pekka Enberg" <penberg@...nel.org>
Cc: "Hyeonggon Yoo" <42.hyeyoo@...il.com>,
"Roman Gushchin" <roman.gushchin@...ux.dev>,
"Andrew Morton" <akpm@...ux-foundation.org>,
"Linus Torvalds" <torvalds@...ux-foundation.org>,
"Matthew Wilcox" <willy@...radead.org>, patches@...ts.linux.dev,
linux-mm@...ck.org, linux-kernel@...r.kernel.org,
"Aaro Koskinen" <aaro.koskinen@....fi>,
"Christophe Leroy" <christophe.leroy@...roup.eu>,
"Conor Dooley" <conor@...nel.org>,
"Damien Le Moal" <damien.lemoal@...nsource.wdc.com>,
"Geert Uytterhoeven" <geert@...ux-m68k.org>,
"Janusz Krzysztofik" <jmkrzyszt@...il.com>,
"Jonas Bonn" <jonas@...thpole.se>,
"Josh Triplett" <josh@...htriplett.org>,
"Kees Cook" <keescook@...omium.org>,
linux-arm-kernel@...ts.infradead.org,
Linux-OMAP <linux-omap@...r.kernel.org>,
linux-riscv@...ts.infradead.org, linux-sh@...r.kernel.org,
openrisc@...ts.librecores.org, "Rich Felker" <dalias@...c.org>,
"Russell King" <linux@...linux.org.uk>,
"Stafford Horne" <shorne@...il.com>,
"Stefan Kristiansson" <stefan.kristiansson@...nalahti.fi>,
"Tony Lindgren" <tony@...mide.com>,
"Yoshinori Sato" <ysato@...rs.sourceforge.jp>
Subject: Re: [PATCH 00/12] Introduce CONFIG_SLUB_TINY and deprecate SLOB
On Mon, Nov 21, 2022, at 18:11, Vlastimil Babka wrote:
>
> this continues the discussion from [1]. Reasons to remove SLOB are
> outlined there and no-one has objected so far. The last patch of this
> series therefore deprecates CONFIG_SLOB and updates all the defconfigs
> using CONFIG_SLOB=y in the tree.
>
> There is a k210 board with 8MB RAM where switching to SLUB caused issues
> [2] and the lkp bot wasn't also happy about code bloat [3]. To address
> both, this series introduces CONFIG_SLUB_TINY to perform some rather
> low-hanging fruit modifications to SLUB to reduce its memory overhead.
> This seems to have been successful at least in the k210 case [4]. I
> consider this as an acceptable tradeoff for getting rid of SLOB.
I agree that this is a great success for replacing SLOB on the
smallest machines that have 32MB or less and have to run a
a highly customized kernel, and this is probably enough to
have a drop-in replacement without making any currently working
system worse.
On the other hand, I have the feeling that we may want something
a bit less aggressive than this for machines that are slightly
less constrained, in particular when a single kernel needs to
scale from 64MB to 512MB, which can happen e.g. on OpenWRT.
I have seen a number of reports over the years that suggest
that new kernels handle fragmentation and low memory worse than
old ones, and it would be great to improve that again.
I can imagine those machines wanting to use sysfs in general
but not for the slab caches, so having a separate knob to
configure out the sysfs stuff could be useful without having
to go all the way to SLUB_TINY.
For the options that trade off performance against lower
fragmentation (MIN/MAX_PARTIAL, KMALLOC_RECLAIM, percpu
slabs), I wonder if it's possible to have a boot time
default based on the amount of RAM per CPU to have a better
tuned system on most cases, rather than having to go
to one extreme or the other at compile time.
Arnd
https://openwrt.org/toh/views/toh_standard_all?datasrt=target&dataflt%5B0%5D=availability_%3DAvailable%202021
Powered by blists - more mailing lists