On 13.08.21 11:38, Rasmus Villemoes wrote:
On 12/08/2021 16.47, Stefan Roese wrote:
This patch enables the use of the optimized memset(), memmove() &
memcpy() versions recently added on ARM64.
Signed-off-by: Stefan Roese <s...@denx.de>
+config USE_ARCH_MEMMOVE
+ bool "Use an assembly optimized implementation of memmove"
+ default y
+ depends on ARM64
+ help
+ Enable the generation of an optimized version of memmove.
+ Such an implementation may be faster under some conditions
+ but may increase the binary size.
Hm. I don't think you can allow making this separately (de)selectable,
since if the optimized memcpy is selected, the memmove comes
unconditionally for free [and it would be a bit silly to guard the
ENTRY_ALIAS() by a CONFIG check IMO]. So with USE_ARCH_MEMCPY=y,
USE_ARCH_MEMMOVE=n, I think you'd get a "multiple definitions of
memmove" error. So on arm64, I think USE_ARCH_MEMMOVE should simply be
an unchangeable alias for USE_ARCH_MEMCPY (and similarly for the SPL/TPL
variants).
In Kconfig, I think one could spell this
bool "Use an ..." if !ARM64
default USE_ARCH_MEMCPY if ARM64
depends on ARM64
Thanks, I've incorporated this into v5 of this patchset.
Thanks,
Stefan