From: "liuyuntao (F)" <liuyuntao12@huawei.com>
To: Russell King <linux@armlinux.org.uk>,
Ard Biesheuvel <ardb@kernel.org>, Arnd Bergmann <arnd@arndb.de>,
Fangrui Song <maskray@google.com>,
Linus Walleij <linus.walleij@linaro.org>, <geert@linux-m68k.org>,
<linux@armlinux.org.uk>, <afd@ti.com>,
<akpm@linux-foundation.org>, <kirill.shutemov@linux.intel.com>,
<geert+renesas@glider.be>, <corbet@lwn.net>, <rppt@kernel.org>,
<robh@kernel.org>, <tglx@linutronix.de>,
<linux-arm-kernel@lists.infradead.org>,
<linux-kernel@vger.kernel.org>
Cc: <liuyuntao12@huawei.com>
Subject: Re: [PATCH-next v4] arm32: enable HAVE_LD_DEAD_CODE_DATA_ELIMINATION
Date: Mon, 3 Jun 2024 20:55:09 +0800 [thread overview]
Message-ID: <a800254e-f305-4adc-9d8b-fea8c5926539@huawei.com> (raw)
In-Reply-To: <CAMj1kXH5bpbagOO+WFwxp4=U=Kbu9RVbPrEemt80S7My1jTEdw@mail.gmail.com>
Gentle ping
On 2024/3/20 1:12, Ard Biesheuvel wrote:
> On Sat, 16 Mar 2024 at 03:44, Yuntao Liu <liuyuntao12@huawei.com> wrote:
>>
>> The current arm32 architecture does not yet support the
>> HAVE_LD_DEAD_CODE_DATA_ELIMINATION feature. arm32 is widely used in
>> embedded scenarios, and enabling this feature would be beneficial for
>> reducing the size of the kernel image.
>>
>> In order to make this work, we keep the necessary tables by annotating
>> them with KEEP, also it requires further changes to linker script to KEEP
>> some tables and wildcard compiler generated sections into the right place.
>> When using ld.lld for linking, KEEP is not recognized within the OVERLAY
>> command, and Ard proposed a concise method to solve this problem.
>>
>> It boots normally with defconfig, vexpress_defconfig and tinyconfig.
>>
>> The size comparison of zImage is as follows:
>> defconfig vexpress_defconfig tinyconfig
>> 5137712 5138024 424192 no dce
>> 5032560 4997824 298384 dce
>> 2.0% 2.7% 29.7% shrink
>>
>> When using smaller config file, there is a significant reduction in the
>> size of the zImage.
>>
>> We also tested this patch on a commercially available single-board
>> computer, and the comparison is as follows:
>> a15eb_config
>> 2161384 no dce
>> 2092240 dce
>> 3.2% shrink
>>
>> The zImage size has been reduced by approximately 3.2%, which is 70KB on
>> 2.1M.
>>
>> Signed-off-by: Yuntao Liu <liuyuntao12@huawei.com>
>> Tested-by: Arnd Bergmann <arnd@arndb.de>
>> Reviewed-by: Arnd Bergmann <arnd@arndb.de>
>
> Reviewed-by: Ard Biesheuvel <ardb@kernel.org>
next prev parent reply other threads:[~2024-06-03 12:55 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-16 2:39 Yuntao Liu
2024-03-19 17:12 ` Ard Biesheuvel
2024-06-03 12:55 ` liuyuntao (F) [this message]
2024-06-03 13:47 ` Linus Walleij
2024-06-03 14:15 ` liuyuntao (F)
2024-06-11 12:45 ` Geert Uytterhoeven
2024-06-12 1:54 ` liuyuntao (F)
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=a800254e-f305-4adc-9d8b-fea8c5926539@huawei.com \
--to=liuyuntao12@huawei.com \
--cc=afd@ti.com \
--cc=akpm@linux-foundation.org \
--cc=ardb@kernel.org \
--cc=arnd@arndb.de \
--cc=corbet@lwn.net \
--cc=geert+renesas@glider.be \
--cc=geert@linux-m68k.org \
--cc=kirill.shutemov@linux.intel.com \
--cc=linus.walleij@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=maskray@google.com \
--cc=robh@kernel.org \
--cc=rppt@kernel.org \
--cc=tglx@linutronix.de \
/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
all inboxes | Powered by JetHome®