[U-Boot] initcall: Move to inline function

Tom Rini trini at konsulko.com
Sun Feb 10 13:09:49 UTC 2019


On Thu, Jan 31, 2019 at 04:06:23PM +0100, Alexander Graf wrote:

> The board_r init function was complaining that we are looping through
> an array, calling all our tiny init stubs sequentially via indirect
> function calls (which can't be speculated, so they are slow).
> 
> The solution to that is pretty easy though. All we need to do is inline
> the function that loops through the functions and the compiler will
> automatically convert almost all indirect calls into direct inlined code.
> 
> With this patch, the overall code size drops (by 40 bytes on riscv64)
> and boot time should become measurably faster for every target.
> 
> Signed-off-by: Alexander Graf <agraf at suse.de>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20190210/f58e28a3/attachment.sig>


More information about the U-Boot mailing list