/bionic/libm/ |
D | Android.bp | 35 "upstream-freebsd/lib/msun/src/catrig.c", 36 "upstream-freebsd/lib/msun/src/catrigf.c", 37 "upstream-freebsd/lib/msun/src/e_acos.c", 38 "upstream-freebsd/lib/msun/src/e_acosf.c", 39 "upstream-freebsd/lib/msun/src/e_acosh.c", 40 "upstream-freebsd/lib/msun/src/e_acoshf.c", 41 "upstream-freebsd/lib/msun/src/e_asin.c", 42 "upstream-freebsd/lib/msun/src/e_asinf.c", 43 "upstream-freebsd/lib/msun/src/e_atan2.c", 44 "upstream-freebsd/lib/msun/src/e_atan2f.c", [all …]
|
/bionic/libc/include/bits/fortify/ |
D | string.h | 46 void* memcpy(void* const dst __pass_object_size0, const void* src, size_t copy_amount) in memcpy() argument 49 return __builtin___memcpy_chk(dst, src, copy_amount, __bos0(dst)); in memcpy() 54 void* memmove(void* const dst __pass_object_size0, const void* src, size_t len) in memmove() argument 57 return __builtin___memmove_chk(dst, src, len, __bos0(dst)); in memmove() 64 void* mempcpy(void* const dst __pass_object_size0, const void* src, size_t copy_amount) in mempcpy() argument 72 return __builtin___mempcpy_chk(dst, src, copy_amount, bos_dst); in mempcpy() 75 return __builtin_mempcpy(dst, src, copy_amount); in mempcpy() 81 char* stpcpy(char* const dst __pass_object_size, const char* src) in stpcpy() argument 83 __clang_error_if(__bos_unevaluated_le(__bos(dst), __builtin_strlen(src)), in stpcpy() 86 return __builtin___stpcpy_chk(dst, src, __bos(dst)); in stpcpy() [all …]
|
/bionic/libc/arch-arm/bionic/ |
D | __aeabi.c | 62 void __attribute__((weak)) __aeabi_memcpy8_impl(void *dest, const void *src, size_t n) { in __aeabi_memcpy8_impl() argument 63 memcpy(dest, src, n); in __aeabi_memcpy8_impl() 66 void __attribute__((weak)) __aeabi_memcpy4_impl(void *dest, const void *src, size_t n) { in __aeabi_memcpy4_impl() argument 67 memcpy(dest, src, n); in __aeabi_memcpy4_impl() 70 void __attribute__((weak)) __aeabi_memcpy_impl(void *dest, const void *src, size_t n) { in __aeabi_memcpy_impl() argument 71 memcpy(dest, src, n); in __aeabi_memcpy_impl() 74 void __attribute__((weak)) __aeabi_memcpy8_impl2(void *dest, const void *src, size_t n) { in __aeabi_memcpy8_impl2() argument 75 memcpy(dest, src, n); in __aeabi_memcpy8_impl2() 78 void __attribute__((weak)) __aeabi_memcpy4_impl2(void *dest, const void *src, size_t n) { in __aeabi_memcpy4_impl2() argument 79 memcpy(dest, src, n); in __aeabi_memcpy4_impl2() [all …]
|
/bionic/libc/bionic/ |
D | wchar.cpp | 68 size_t mbsnrtowcs(wchar_t* dst, const char** src, size_t nmc, size_t len, mbstate_t* ps) { in mbsnrtowcs() argument 76 if (nmc > 0 && mbstate_bytes_so_far(state) > 0 && static_cast<uint8_t>((*src)[0]) < 0x80) { in mbsnrtowcs() 83 if (static_cast<uint8_t>((*src)[i]) < 0x80) { in mbsnrtowcs() 85 if ((*src)[i] == '\0') { in mbsnrtowcs() 90 r = mbrtowc(nullptr, *src + i, nmc - i, state); in mbsnrtowcs() 107 if (static_cast<uint8_t>((*src)[i]) < 0x80) { in mbsnrtowcs() 109 dst[o] = (*src)[i]; in mbsnrtowcs() 111 if ((*src)[i] == '\0') { in mbsnrtowcs() 112 *src = nullptr; in mbsnrtowcs() 116 r = mbrtowc(dst + o, *src + i, nmc - i, state); in mbsnrtowcs() [all …]
|
D | sys_statvfs.cpp | 20 static __inline void __bionic_statfs_to_statvfs(const struct statfs* src, struct statvfs* dst) { in __bionic_statfs_to_statvfs() argument 21 dst->f_bsize = src->f_bsize; in __bionic_statfs_to_statvfs() 22 dst->f_frsize = src->f_frsize; in __bionic_statfs_to_statvfs() 23 dst->f_blocks = src->f_blocks; in __bionic_statfs_to_statvfs() 24 dst->f_bfree = src->f_bfree; in __bionic_statfs_to_statvfs() 25 dst->f_bavail = src->f_bavail; in __bionic_statfs_to_statvfs() 26 dst->f_files = src->f_files; in __bionic_statfs_to_statvfs() 27 dst->f_ffree = src->f_ffree; in __bionic_statfs_to_statvfs() 28 dst->f_favail = src->f_ffree; in __bionic_statfs_to_statvfs() 29 dst->f_fsid = src->f_fsid.__val[0] | static_cast<uint64_t>(src->f_fsid.__val[1]) << 32; in __bionic_statfs_to_statvfs() [all …]
|
D | fortify.cpp | 132 extern "C" void* __memmove_chk(void* dst, const void* src, size_t len, size_t dst_len) { in __memmove_chk() argument 134 return memmove(dst, src, len); in __memmove_chk() 233 extern "C" char* __stpcpy_chk(char* dst, const char* src, size_t dst_len) { in __stpcpy_chk() argument 235 size_t src_len = strlen(src) + 1; in __stpcpy_chk() 237 return stpcpy(dst, src); in __stpcpy_chk() 241 extern "C" char* __stpncpy_chk(char* dst, const char* src, size_t len, size_t dst_len) { in __stpncpy_chk() argument 243 return stpncpy(dst, src, len); in __stpncpy_chk() 250 char* __stpncpy_chk2(char* dst, const char* src, size_t n, size_t dst_len, size_t src_len) { in __stpncpy_chk2() argument 254 const char* s = src; in __stpncpy_chk2() 257 size_t s_copy_len = static_cast<size_t>(s - src); in __stpncpy_chk2() [all …]
|
D | time64.c | 362 static void copy_tm_to_TM(const struct tm *src, struct TM *dest) { in copy_tm_to_TM() argument 363 if( src == NULL ) { in copy_tm_to_TM() 368 dest->tm_sec = src->tm_sec; in copy_tm_to_TM() 369 dest->tm_min = src->tm_min; in copy_tm_to_TM() 370 dest->tm_hour = src->tm_hour; in copy_tm_to_TM() 371 dest->tm_mday = src->tm_mday; in copy_tm_to_TM() 372 dest->tm_mon = src->tm_mon; in copy_tm_to_TM() 373 dest->tm_year = (Year)src->tm_year; in copy_tm_to_TM() 374 dest->tm_wday = src->tm_wday; in copy_tm_to_TM() 375 dest->tm_yday = src->tm_yday; in copy_tm_to_TM() [all …]
|
/bionic/libc/upstream-freebsd/lib/libc/string/ |
D | bcopy.c | 71 const char *src = src0; in memcpy() local 74 if (length == 0 || dst == src) /* nothing to do */ in memcpy() 83 if ((unsigned long)dst < (unsigned long)src) { in memcpy() 87 t = (uintptr_t)src; /* only need low bits */ in memcpy() 98 TLOOP1(*dst++ = *src++); in memcpy() 104 TLOOP(*(word *)(void *)dst = *(const word *)(const void *)src; in memcpy() 105 src += wsize; dst += wsize); in memcpy() 107 TLOOP(*dst++ = *src++); in memcpy() 114 src += length; in memcpy() 116 t = (uintptr_t)src; in memcpy() [all …]
|
/bionic/libc/upstream-openbsd/lib/libc/net/ |
D | inet_pton.c | 32 static int inet_pton4(const char *src, u_char *dst); 33 static int inet_pton6(const char *src, u_char *dst); 47 inet_pton(int af, const char *src, void *dst) in inet_pton() argument 51 return (inet_pton4(src, dst)); in inet_pton() 53 return (inet_pton6(src, dst)); in inet_pton() 73 inet_pton4(const char *src, u_char *dst) in inet_pton4() argument 82 while ((ch = *src++) != '\0') { in inet_pton4() 124 inet_pton6(const char *src, u_char *dst) in inet_pton6() argument 137 if (*src == ':') in inet_pton6() 138 if (*++src != ':') in inet_pton6() [all …]
|
D | inet_ntop.c | 33 static const char *inet_ntop4(const u_char *src, char *dst, size_t size); 34 static const char *inet_ntop6(const u_char *src, char *dst, size_t size); 45 inet_ntop(int af, const void *src, char *dst, socklen_t size) in inet_ntop() argument 49 return (inet_ntop4(src, dst, size)); in inet_ntop() 51 return (inet_ntop6(src, dst, size)); in inet_ntop() 72 inet_ntop4(const u_char *src, char *dst, size_t size) in inet_ntop4() argument 78 src[0], src[1], src[2], src[3]); in inet_ntop4() 94 inet_ntop6(const u_char *src, char *dst, size_t size) in inet_ntop6() argument 117 words[i / 2] |= (src[i] << ((1 - (i % 2)) << 3)); in inet_ntop6() 170 if (!inet_ntop4(src+12, tp, ep - tp)) in inet_ntop6()
|
D | base64.c | 124 b64_ntop(unsigned char const *src, size_t srclength, char *target, in b64_ntop() argument 133 input[0] = *src++; in b64_ntop() 134 input[1] = *src++; in b64_ntop() 135 input[2] = *src++; in b64_ntop() 156 input[i] = *src++; in b64_ntop() 185 b64_pton(char const *src, unsigned char *target, size_t targsize) in b64_pton() argument 194 while ((ch = (unsigned char)*src++) != '\0') { in b64_pton() 260 ch = (unsigned char)*src++; /* Skip it, get next. */ in b64_pton() 268 for (; ch != '\0'; ch = (unsigned char)*src++) in b64_pton() 274 ch = (unsigned char)*src++; /* Skip the = */ in b64_pton() [all …]
|
/bionic/libc/dns/nameser/ |
D | ns_netint.c | 36 ns_get16(const u_char *src) { in ns_get16() argument 39 NS_GET16(dst, src); in ns_get16() 44 ns_get32(const u_char *src) { in ns_get32() argument 47 NS_GET32(dst, src); in ns_get32() 52 ns_put16(uint16_t src, u_char *dst) { in ns_put16() argument 53 NS_PUT16(src, dst); in ns_put16() 57 ns_put32(uint32_t src, u_char *dst) { in ns_put32() argument 58 NS_PUT32(src, dst); in ns_put32()
|
D | ns_ttl.c | 50 ns_format_ttl(u_long src, char *dst, size_t dstlen) { in ns_format_ttl() argument 55 secs = (int)(src % 60); src /= 60; in ns_format_ttl() 56 mins = (int)(src % 60); src /= 60; in ns_format_ttl() 57 hours = (int)(src % 24); src /= 24; in ns_format_ttl() 58 days = (int)(src % 7); src /= 7; in ns_format_ttl() 59 weeks = (int)src; src = 0; in ns_format_ttl() 97 ns_parse_ttl(const char *src, u_long *dst) { in ns_parse_ttl() argument 105 while ((ch = *src++) != '\0') { in ns_parse_ttl()
|
D | ns_name.c | 98 ns_name_ntop(const u_char *src, char *dst, size_t dstsiz) in ns_name_ntop() argument 106 cp = src; in ns_name_ntop() 203 ns_name_pton(const char *src, u_char *dst, size_t dstsiz) { in ns_name_pton() argument 204 return (ns_name_pton2(src, dst, dstsiz, NULL)); in ns_name_pton() 221 ns_name_pton2(const char *src, u_char *dst, size_t dstsiz, size_t *dstlen) { in ns_name_pton2() argument 231 while ((c = *src++) != 0) { in ns_name_pton2() 234 if ((cp = strchr(src, ']')) == NULL) { in ns_name_pton2() 238 if ((e = encode_bitsring(&src, cp + 2, in ns_name_pton2() 246 if ((c = *src++) == 0) in ns_name_pton2() 256 if ((c = *src++) == 0 || in ns_name_pton2() [all …]
|
/bionic/libc/dns/resolv/ |
D | res_comp.c | 104 dn_expand(const u_char *msg, const u_char *eom, const u_char *src, in dn_expand() argument 107 int n = ns_name_uncompress(msg, eom, src, dst, (size_t)dstsiz); in dn_expand() 120 dn_comp(const char *src, u_char *dst, int dstsiz, in dn_comp() argument 123 return (ns_name_compress(src, dst, (size_t)dstsiz, in dn_comp() 260 void __putlong(u_int32_t src, u_char *dst) { ns_put32(src, dst); } in __putlong() argument 261 void __putshort(u_int16_t src, u_char *dst) { ns_put16(src, dst); } in __putshort() argument 263 u_int32_t _getlong(const u_char *src) { return (ns_get32(src)); } in _getlong() argument 264 u_int16_t _getshort(const u_char *src) { return (ns_get16(src)); } in _getshort() argument
|
/bionic/libc/upstream-openbsd/lib/libc/string/ |
D | strlcat.c | 30 strlcat(char *dst, const char *src, size_t dsize) in strlcat() argument 33 const char *osrc = src; in strlcat() 44 return(dlen + strlen(src)); in strlcat() 45 while (*src != '\0') { in strlcat() 47 *dst++ = *src; in strlcat() 50 src++; in strlcat() 54 return(dlen + (src - osrc)); /* count does not include NUL */ in strlcat()
|
D | strlcpy.c | 28 strlcpy(char *dst, const char *src, size_t dsize) in strlcpy() argument 30 const char *osrc = src; in strlcpy() 36 if ((*dst++ = *src++) == '\0') in strlcpy() 45 while (*src++) in strlcpy() 49 return(src - osrc - 1); /* count does not include NUL */ in strlcpy()
|
D | wcslcpy.c | 28 wcslcpy(wchar_t *dst, const wchar_t *src, size_t dsize) in wcslcpy() argument 30 const wchar_t *osrc = src; in wcslcpy() 36 if ((*dst++ = *src++) == L'\0') in wcslcpy() 45 while (*src++) in wcslcpy() 49 return(src - osrc - 1); /* count does not include NUL */ in wcslcpy()
|
D | strxfrm.c | 42 strxfrm(char *dst, const char *src, size_t n) in strxfrm() argument 49 return (strlen(src)); in strxfrm() 50 return (strlcpy(dst, src, n)); in strxfrm()
|
/bionic/tests/ |
D | sys_uio_test.cpp | 115 char src[1024] = "This is the source buffer containing some data"; in TEST() local 117 iovec remote = { src, sizeof src }; in TEST() 119 ASSERT_EQ(ssize_t(sizeof src), process_vm_readv(getpid(), &local, 1, &remote, 1, 0)); in TEST() 122 ASSERT_EQ(0, memcmp(src, dst, sizeof src)); in TEST() 134 char src[1024] = "This is the source buffer containing some data"; in TEST() local 137 iovec local = { src, sizeof src }; in TEST() 138 ASSERT_EQ(ssize_t(sizeof src), process_vm_writev(getpid(), &local, 1, &remote, 1, 0)); in TEST() 141 ASSERT_EQ(0, memcmp(src, dst, sizeof src)); in TEST()
|
D | wchar_test.cpp | 123 const wchar_t* src; in TEST() local 130 src = chars; in TEST() 131 EXPECT_EQ(5U, wcsrtombs(nullptr, &src, 0, nullptr)); in TEST() 132 EXPECT_EQ(&chars[0], src); in TEST() 133 src = chars; in TEST() 134 EXPECT_EQ(5U, wcsrtombs(nullptr, &src, 4, nullptr)); in TEST() 135 EXPECT_EQ(&chars[0], src); in TEST() 136 src = chars; in TEST() 137 EXPECT_EQ(5U, wcsrtombs(nullptr, &src, 256, nullptr)); in TEST() 138 EXPECT_EQ(&chars[0], src); in TEST() [all …]
|
D | fortify_test.cpp | 135 char* src = strdup(""); in TEST_F() local 136 ASSERT_FORTIFY(stpcpy(myfoo.empty, src)); in TEST_F() 137 free(src); in TEST_F() 147 char* src = strdup(""); in TEST_F() local 148 ASSERT_FORTIFY(strcpy(myfoo.empty, src)); in TEST_F() 149 free(src); in TEST_F() 159 char* src = strdup("1"); in TEST_F() local 160 ASSERT_FORTIFY(strcpy(myfoo.empty, src)); in TEST_F() 161 free(src); in TEST_F() 171 char* src = strdup("12"); in TEST_F() local [all …]
|
/bionic/libc/dns/include/ |
D | hostent.h | 77 #define HENT_COPY(dst, src, slen, ptr, len) \ argument 81 memcpy(ptr, src, (size_t)slen); \ 87 #define HENT_SCOPY(dst, src, ptr, len) \ argument 89 size_t _len = strlen(src) + 1; \ 90 HENT_COPY(dst, src, _len, ptr, len); \
|
/bionic/benchmarks/ |
D | string_benchmark.cpp | 29 std::vector<char> src; in BM_string_memcmp() local 31 char* src_aligned = GetAlignedPtrFilled(&src, src_alignment, nbytes, 'x'); in BM_string_memcmp() 47 std::vector<char> src; in BM_string_memcpy() local 49 char* src_aligned = GetAlignedPtrFilled(&src, src_alignment, nbytes, 'x'); in BM_string_memcpy() 65 std::vector<char> src; in BM_string_memmove_non_overlapping() local 67 char* src_aligned = GetAlignedPtrFilled(&src, src_alignment, nbytes, 'x'); in BM_string_memmove_non_overlapping() 144 std::vector<char> src; in BM_string_strcat_copy_only() local 146 char* src_aligned = GetAlignedPtrFilled(&src, src_alignment, nbytes, 'x'); in BM_string_strcat_copy_only() 167 std::vector<char> src; in BM_string_strcat_seek_only() local 169 char* src_aligned = GetAlignedPtrFilled(&src, src_alignment, 3, 'x'); in BM_string_strcat_seek_only() [all …]
|
/bionic/libc/upstream-openbsd/lib/libc/locale/ |
D | wcsxfrm.c | 36 wcsxfrm(wchar_t *dest, const wchar_t *src, size_t n) in wcsxfrm() argument 39 return wcslen(src); in wcsxfrm() 40 return wcslcpy(dest, src, n); in wcsxfrm()
|