Browse Source

用户态memcpy

fslongjin 2 years ago
parent
commit
f5ae770ffc
1 changed files with 3 additions and 1 deletions
  1. 3 1
      user/libs/libc/string.h

+ 3 - 1
user/libs/libc/string.h

@@ -46,4 +46,6 @@ char* strcpy(char* dst, const char* src);
  * @param src 源串
  * @return char*
  */
-char *strcat(char *dest, const char *src);
+char *strcat(char *dest, const char *src);
+
+#define memcpy(dst, src, n) __builtin_memcpy(dst, src, n)