[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <a08e1cee-05e0-447a-b25b-6c2ebb116e8d@app.fastmail.com>
Date: Tue, 26 Sep 2023 13:24:21 +0200
From: "Arnd Bergmann" <arnd@...db.de>
To: "Zhangjin Wu" <falcon@...ylab.org>, linux-kernel@...r.kernel.org,
linux-mips@...r.kernel.org, linux-riscv@...ts.infradead.org
Cc: "Palmer Dabbelt" <palmer@...osinc.com>,
"Paul Walmsley" <paul.walmsley@...ive.com>, paulburton@...nel.org,
"Paul E. McKenney" <paulmck@...nel.org>,
"Thomas Bogendoerfer" <tsbogend@...ha.franken.de>,
"Willy Tarreau" <w@....eu>,
Thomas Weißschuh <linux@...ssschuh.net>,
"Tim Bird" <tim.bird@...y.com>,
"Geert Uytterhoeven" <geert@...ux-m68k.org>,
"Nicolas Pitre" <nico@...xnic.net>
Subject: Re: [PATCH v1 0/7] DCE/DSE: Add Dead Syscalls Elimination support, part1
On Tue, Sep 26, 2023, at 09:14, Arnd Bergmann wrote:
> On Tue, Sep 26, 2023, at 00:33, Zhangjin Wu wrote:
>
> It would be nice to include some size numbers here for at least
> one practical use case. If you have a defconfig for a shipping
> product with a small kernel, what is the 'size -B' output you
> see comparing with and without DCE and, and with DCE+DSE?
To follow up on this myself, for a very rough baseline,
I tried a riscv tinyconfig build with and without
CONFIG_LD_DEAD_CODE_DATA_ELIMINATION (this is currently
not supported on arm, so I did not try it there), and
then another build with simply *all* system calls stubbed
out by hacking asm/syscall-wrapper.h:
$ size build/tmp/vmlinux-*
text data bss dec hex filename
754772 220016 71841 1046629 ff865 vmlinux-tinyconfig
717500 223368 71841 1012709 f73e5 vmlinux-tiny+nosyscalls
567310 176200 71473 814983 c6f87 vmlinux-tiny+gc-sections
493278 170752 71433 735463 b38e7 vmlinux-tiny+gc-sections+nosyscalls
10120058 3572756 493701 14186515 d87813 vmlinux-defconfig
9953934 3529004 491525 13974463 d53bbf vmlinux-defconfig+gc
9709856 3500600 489221 13699677 d10a5d vmlinux-defconfig+gc+nosyscalls
This would put us at an upper bound of 10% size savings (80kb) for
tinyconfig, which is clearly significant. For defconfig, it's
still 2.0% or 275kb size reduction when all syscalls are dropped.
Arnd
Powered by blists - more mailing lists