[U-Boot] [PATCH v3] Avoid use of divides in print_size
Timur Tabi
timur.tabi at gmail.com
Tue May 11 16:41:25 CEST 2010
On Tue, May 11, 2010 at 5:29 AM, Nick Thompson <nick.thompson at ge.com> wrote:
> Modification of print_size to avoid use of divides and especially
> long long divides. Keep the binary scale factor in terms of bit
> shifts instead. This should be faster, since the previous code
> gave the compiler no clues that the divides where always powers
> of two, preventing optimisation.
>
> Signed-off-by: Nick Thompson <nick.thompson at ge.com>
> ---
Acked-by: Timur Tabi <timur at freescale.com>
I don't know if this solves the problem on ARM, but it works on PowerPC.
--
Timur Tabi
Linux kernel developer at Freescale
More information about the U-Boot
mailing list