diff options
author | Aleksey Kuleshov <rndfax@yandex.ru> | 2015-11-25 15:23:22 +0300 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2015-11-26 09:36:34 +0100 |
commit | 114409c73e7d765dd5510b5a945b5e4c15ae4fa8 (patch) | |
tree | 0e4fe7f39f75408842ea0bd9b0638bbffdacf81b /arch/mips/include | |
parent | 6991f6ed5f669f816de9bec1d000fb12cf43687c (diff) | |
download | barebox-114409c73e7d765dd5510b5a945b5e4c15ae4fa8.tar.gz barebox-114409c73e7d765dd5510b5a945b5e4c15ae4fa8.tar.xz |
MIPS: import optimized string functions from Linux
10x performance gain according to simple test on QEMU malta:
barebox:/ time memcpy 0xa0000000 0xa0001000 0x100000
Signed-off-by: Aleksey Kuleshov <rndfax@yandex.ru>
Acked-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/mips/include')
-rw-r--r-- | arch/mips/include/asm/string.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/arch/mips/include/asm/string.h b/arch/mips/include/asm/string.h index 3a32d18159..a797a7459c 100644 --- a/arch/mips/include/asm/string.h +++ b/arch/mips/include/asm/string.h @@ -22,6 +22,13 @@ #ifndef __ASM_MIPS_STRING_H #define __ASM_MIPS_STRING_H -/* nothing special yet */ +#ifdef CONFIG_MIPS_OPTIMIZED_STRING_FUNCTIONS + +#define __HAVE_ARCH_MEMCPY +extern void *memcpy(void *, const void *, __kernel_size_t); +#define __HAVE_ARCH_MEMSET +extern void *memset(void *, int, __kernel_size_t); + +#endif #endif |