From: Krzysztof Kozlowski <krzk@kernel.org>
To: Stephen Boyd <sboyd@kernel.org>,
Colin Ian King <colin.i.king@gmail.com>,
Michael Turquette <mturquette@baylibre.com>,
linux-arm-kernel@lists.infradead.org, linux-clk@vger.kernel.org
Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH][next] clk: moxart: Make read-only array div_idx static const
Date: Thu, 19 Jun 2025 22:18:48 +0200 [thread overview]
Message-ID: <23f5da2f-0da1-449a-ab4e-c62fbfd74d4f@kernel.org> (raw)
In-Reply-To: <175036278075.4372.3898345624525344837@lazor>
On 19/06/2025 21:53, Stephen Boyd wrote:
> Quoting Colin Ian King (2025-06-19 01:30:35)
>> Don't populate the read-only array div_idx on the stack at run time,
>> instead make it static const.
>
> Why? This is in __init code so it can be thrown away if it stays on the
> stack.
Indeed previous code could be discarded, now will be in rodata, but we
save several instructions runtime on copying it. Plus the actual binary
will be slower (really less code), so also loading it will be faster.
Best regards,
Krzysztof
next prev parent reply other threads:[~2025-06-19 20:18 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-19 8:30 [PATCH][next] clk: moxart: Make read-only array div_idx static const Colin Ian King
2025-06-19 17:42 ` Krzysztof Kozlowski
2025-06-19 19:53 ` Stephen Boyd
2025-06-19 20:18 ` Krzysztof Kozlowski [this message]
2025-06-20 5:33 ` Krzysztof Kozlowski
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=23f5da2f-0da1-449a-ab4e-c62fbfd74d4f@kernel.org \
--to=krzk@kernel.org \
--cc=colin.i.king@gmail.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-clk@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mturquette@baylibre.com \
--cc=sboyd@kernel.org \
/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).