projects
/
GitHub
/
LineageOS
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5b74e3a
)
x86_64: Always use builtin memcpy on gcc 4.3
author
Andi Kleen
<ak@suse.de>
Sat, 21 Jul 2007 15:09:58 +0000
(17:09 +0200)
committer
Linus Torvalds
<torvalds@woody.linux-foundation.org>
Sun, 22 Jul 2007 01:37:08 +0000
(18:37 -0700)
Jan asked to always use the builtin memcpy on gcc 4.3 mainline because
it should generate better code than the old macro. Let's try it.
Cc: Jan Hubicka <jh@suse.cz>
Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
include/asm-x86_64/string.h
patch
|
blob
|
blame
|
history
diff --git
a/include/asm-x86_64/string.h
b/include/asm-x86_64/string.h
index 9505d9f4bead96807357ffee406e2d42aaa41a88..e583da7918fb314b34fe8156dd1b7626fbeadf4d 100644
(file)
--- a/
include/asm-x86_64/string.h
+++ b/
include/asm-x86_64/string.h
@@
-29,6
+29,9
@@
return (to);
function. */
#define __HAVE_ARCH_MEMCPY 1
+#if (__GNUC__ == 4 && __GNUC_MINOR__ >= 3) || __GNUC__ > 4
+extern void *memcpy(void *to, const void *from, size_t len);
+#else
extern void *__memcpy(void *to, const void *from, size_t len);
#define memcpy(dst,src,len) \
({ size_t __len = (len); \
@@
-38,7
+41,7
@@
extern void *__memcpy(void *to, const void *from, size_t len);
else \
__ret = __builtin_memcpy((dst),(src),__len); \
__ret; })
-
+#endif
#define __HAVE_ARCH_MEMSET
void *memset(void *s, int c, size_t n);