/bionic/libc/string/ |
D | memchr.c | 33 const unsigned char* p = s; in memchr() local 34 const unsigned char* end = p + n; in memchr() 37 if (p >= end || p[0] == c) break; p++; in memchr() 38 if (p >= end || p[0] == c) break; p++; in memchr() 39 if (p >= end || p[0] == c) break; p++; in memchr() 40 if (p >= end || p[0] == c) break; p++; in memchr() 42 if (p >= end) in memchr() 45 return (void*) p; in memchr()
|
D | strchr.c | 34 strchr(const char *p, int ch) in strchr() argument 36 for (;; ++p) { in strchr() 37 if (*p == (char) ch) in strchr() 38 return((char *)p); in strchr() 39 if (!*p) in strchr()
|
D | index.c | 34 index(const char *p, int ch) in index() argument 36 for (;; ++p) { in index() 37 if (*p == (char) ch) in index() 38 return((char *)p); in index() 39 if (!*p) in index()
|
D | memswap.c | 32 char* p = m1; in memswap() local 33 char* p_end = p + n; in memswap() 36 while (p < p_end) { in memswap() 37 char tmp = *p; in memswap() 38 *p = *q; in memswap() 40 p++; in memswap()
|
D | strrchr.c | 34 strrchr(const char *p, int ch) in strrchr() argument 38 for (save = NULL;; ++p) { in strrchr() 39 if (*p == (char) ch) in strrchr() 40 save = (char *)p; in strrchr() 41 if (!*p) in strrchr()
|
D | memrchr.c | 34 const char* p = (const char*) s; in memrchr() local 35 const char* q = p + n; in memrchr() 38 q--; if (q < p || q[0] == (char) c) break; in memrchr() 39 q--; if (q < p || q[0] == (char) c) break; in memrchr() 40 q--; if (q < p || q[0] == (char) c) break; in memrchr() 41 q--; if (q < p || q[0] == (char) c) break; in memrchr() 43 if (q >= p) in memrchr()
|
D | memccpy.c | 34 const char* p = src; in memccpy() local 35 const char* p_end = p + n; in memccpy() 39 if (ch == c || p >= p_end) break; in memccpy() 40 *q++ = ch = *p++; in memccpy() 43 if (p >= p_end && ch != c) in memccpy()
|
/bionic/libc/stdlib/ |
D | atexit.c | 63 struct atexit *p = __atexit; in __cxa_atexit() local 68 if (pgsize < (int)sizeof(*p)) in __cxa_atexit() 71 p = __atexit; in __cxa_atexit() 72 if (p != NULL) { in __cxa_atexit() 73 if (p->ind + 1 >= p->max) in __cxa_atexit() 74 p = NULL; in __cxa_atexit() 75 else if (mprotect(p, pgsize, PROT_READ | PROT_WRITE)) in __cxa_atexit() 78 if (p == NULL) { in __cxa_atexit() 79 p = mmap(NULL, pgsize, PROT_READ | PROT_WRITE, in __cxa_atexit() 81 if (p == MAP_FAILED) in __cxa_atexit() [all …]
|
D | strntoumax.c | 51 const unsigned char* p = (const unsigned char *)nptr; in strntoumax() local 52 const unsigned char* end = p + n; in strntoumax() 58 while (p < end && isspace(*p)) in strntoumax() 59 p++; in strntoumax() 62 if (p < end) { in strntoumax() 63 char c = p[0]; in strntoumax() 66 p++; in strntoumax() 71 if ( p+2 < end && p[0] == '0' && (p[1] == 'x' || p[1] == 'X') ) { in strntoumax() 72 p += 2; in strntoumax() 74 } else if ( p+1 < end && p[0] == '0' ) { in strntoumax() [all …]
|
D | putenv.c | 37 char *p, *equal; in putenv() local 40 if ((p = strdup(str)) == NULL) in putenv() 42 if ((equal = strchr(p, '=')) == NULL) { in putenv() 43 (void)free(p); in putenv() 47 rval = setenv(p, equal + 1, 1); in putenv() 48 (void)free(p); in putenv()
|
/bionic/libm/src/ |
D | e_remainderf.c | 27 __ieee754_remainderf(float x, float p) in __ieee754_remainderf() argument 34 GET_FLOAT_WORD(hp,p); in __ieee754_remainderf() 40 if(hp==0) return (x*p)/(x*p); /* p = 0 */ in __ieee754_remainderf() 43 return (x*p)/(x*p); in __ieee754_remainderf() 46 if (hp<=0x7effffff) x = __ieee754_fmodf(x,p+p); /* now x < 2p */ in __ieee754_remainderf() 49 p = fabsf(p); in __ieee754_remainderf() 51 if(x+x>p) { in __ieee754_remainderf() 52 x-=p; in __ieee754_remainderf() 53 if(x+x>=p) x -= p; in __ieee754_remainderf() 56 p_half = (float)0.5*p; in __ieee754_remainderf() [all …]
|
D | e_remainder.c | 34 __ieee754_remainder(double x, double p) in __ieee754_remainder() argument 41 EXTRACT_WORDS(hp,lp,p); in __ieee754_remainder() 47 if((hp|lp)==0) return (x*p)/(x*p); /* p = 0 */ in __ieee754_remainder() 51 return (x*p)/(x*p); in __ieee754_remainder() 54 if (hp<=0x7fdfffff) x = __ieee754_fmod(x,p+p); /* now x < 2p */ in __ieee754_remainder() 57 p = fabs(p); in __ieee754_remainder() 59 if(x+x>p) { in __ieee754_remainder() 60 x-=p; in __ieee754_remainder() 61 if(x+x>=p) x -= p; in __ieee754_remainder() 64 p_half = 0.5*p; in __ieee754_remainder() [all …]
|
/bionic/libm/alpha/ |
D | fenv.c | 47 struct mask_args p; in fegetenv() local 55 sysarch(ALPHA_GET_FPMASK, (char *)&p); in fegetenv() 57 *envp = r.__bits | p.mask; in fegetenv() 65 struct mask_args p; in feholdexcept() local 68 sysarch(ALPHA_GET_FPMASK, (char *)&p); in feholdexcept() 70 *envp = r.__bits | p.mask; in feholdexcept() 73 if (p.mask & FE_ALL_EXCEPT) { in feholdexcept() 74 p.mask = 0; in feholdexcept() 75 sysarch(ALPHA_SET_FPMASK, &p); in feholdexcept() 84 struct mask_args p; in fesetenv() local [all …]
|
/bionic/libc/bionic/ |
D | fts.c | 74 FTSENT *p, *root; in fts_open() local 115 if ((p = fts_alloc(sp, *argv, len)) == NULL) in fts_open() 117 p->fts_level = FTS_ROOTLEVEL; in fts_open() 118 p->fts_parent = parent; in fts_open() 119 p->fts_accpath = p->fts_name; in fts_open() 120 p->fts_info = fts_stat(sp, p, ISSET(FTS_COMFOLLOW)); in fts_open() 123 if (p->fts_info == FTS_DOT) in fts_open() 124 p->fts_info = FTS_D; in fts_open() 131 p->fts_link = root; in fts_open() 132 root = p; in fts_open() [all …]
|
/bionic/libc/unistd/ |
D | sysconf.c | 283 line_parser_init( LineParser* p, const char* path ) in line_parser_init() argument 285 p->rpos = 0; in line_parser_init() 286 p->len = (int)sizeof(p->buff); in line_parser_init() 287 p->overflow = 0; in line_parser_init() 289 p->in_len = 0; in line_parser_init() 290 p->in_pos = 0; in line_parser_init() 291 p->fd = open( path, O_RDONLY ); in line_parser_init() 293 return p->fd; in line_parser_init() 298 line_parser_addc( LineParser* p, int c ) in line_parser_addc() argument 300 if (p->overflow) { in line_parser_addc() [all …]
|
D | abort.c | 50 struct atexit *p = __atexit; in __libc_android_abort() local 70 while (p != NULL && p->next != NULL) in __libc_android_abort() 71 p = p->next; in __libc_android_abort() 73 if (p != NULL && p->fns[0].fn_dso == NULL && in __libc_android_abort() 74 p->fns[0].fn_ptr.std_func != NULL) { in __libc_android_abort() 76 (*p->fns[0].fn_ptr.std_func)(); in __libc_android_abort()
|
/bionic/libc/regex/ |
D | regcomp.c | 113 #define PEEK() (*p->next) 114 #define PEEK2() (*(p->next+1)) 115 #define MORE() (p->next < p->end) 116 #define MORE2() (p->next+1 < p->end) 121 #define NEXT() (p->next++) 122 #define NEXT2() (p->next += 2) 123 #define NEXTn(n) (p->next += (n)) 124 #define GETNEXT() (*p->next++) 125 #define SETERROR(e) seterr(p, (e)) 130 #define EMIT(op, sopnd) doemit(p, (sop)(op), (size_t)(sopnd)) [all …]
|
/bionic/libc/inet/ |
D | inet_ntoa.c | 44 char *p; in inet_ntoa() local 46 p = (char *)∈ in inet_ntoa() 49 "%u.%u.%u.%u", UC(p[0]), UC(p[1]), UC(p[2]), UC(p[3])); in inet_ntoa()
|
/bionic/libc/netbsd/net/ |
D | getservent.c | 53 const char* p; in getservent_r() local 61 p = rs->servent_ptr; in getservent_r() 62 if (p == NULL) in getservent_r() 63 p = _services; in getservent_r() 64 else if (p[0] == 0) in getservent_r() 68 namelen = p[0]; in getservent_r() 70 q = p + 1 + namelen + 3; /* skip name + port + proto */ in getservent_r() 94 memcpy( rs->servent.s_name, p+1, namelen ); in getservent_r() 96 p += 1 + namelen; in getservent_r() 99 port = ((((unsigned char*)p)[0] << 8) | in getservent_r() [all …]
|
/bionic/libc/wchar/ |
D | wcspbrk.c | 42 const wchar_t *p; in wcspbrk() local 45 p = s; in wcspbrk() 46 while (*p) { in wcspbrk() 49 if (*p == *q) { in wcspbrk() 51 return (wchar_t *)p; in wcspbrk() 55 p++; in wcspbrk()
|
D | wcslen.c | 42 const wchar_t *p; in wcslen() local 44 p = s; in wcslen() 45 while (*p) in wcslen() 46 p++; in wcslen() 48 return p - s; in wcslen()
|
D | wcscspn.c | 42 const wchar_t *p; in wcscspn() local 45 p = s; in wcscspn() 46 while (*p) { in wcscspn() 49 if (*p == *q) in wcscspn() 53 p++; in wcscspn() 57 return (p - s); in wcscspn()
|
D | wcsspn.c | 42 const wchar_t *p; in wcsspn() local 45 p = s; in wcsspn() 46 while (*p) { in wcsspn() 49 if (*p == *q) in wcsspn() 55 p++; in wcsspn() 59 return (p - s); in wcsspn()
|
/bionic/libc/netbsd/isc/ |
D | eventlib_p.h | 54 #define NEW(p) if (((p) = memget(sizeof *(p))) != NULL) \ argument 55 FILL(p); \ 58 #define OKNEW(p) if (!((p) = memget(sizeof *(p)))) { \ argument 62 FILL(p) 63 #define FREE(p) memput((p), sizeof *(p)) argument 66 #define FILL(p) memset((p), 0xF5, sizeof *(p)) argument 68 #define FILL(p) argument 73 #define NEW(p) p = malloc(sizeof *(p)); argument 74 #define OKNEW(p) if (!((p) = malloc(sizeof *(p)))) { errno = ENOMEM; return (-1); } argument 75 #define FREE(p) free(p) argument [all …]
|
/bionic/libc/kernel/common/linux/ |
D | moduleparam.h | 76 #define __param_check(name, p, type) static inline type *__check_##name(void) { return(p); } argument 77 #define param_check_byte(name, p) __param_check(name, p, unsigned char) argument 79 #define param_check_short(name, p) __param_check(name, p, short) argument 80 #define param_check_ushort(name, p) __param_check(name, p, unsigned short) argument 81 #define param_check_int(name, p) __param_check(name, p, int) argument 82 #define param_check_uint(name, p) __param_check(name, p, unsigned int) argument 84 #define param_check_long(name, p) __param_check(name, p, long) argument 85 #define param_check_ulong(name, p) __param_check(name, p, unsigned long) argument 86 #define param_check_charp(name, p) __param_check(name, p, char *) argument 87 #define param_check_bool(name, p) __param_check(name, p, int) argument [all …]
|