Home
last modified time | relevance | path

Searched refs:p (Results 1 – 25 of 142) sorted by relevance

123456

/bionic/libc/upstream-openbsd/lib/libc/stdlib/
Dgetsubopt.c48 char *p; in getsubopt() local
56 for (p = *optionp; *p && (*p == ',' || *p == ' ' || *p == '\t'); ++p); in getsubopt()
58 if (!*p) { in getsubopt()
59 *optionp = p; in getsubopt()
64 for (suboptarg = p; in getsubopt()
65 *++p && *p != ',' && *p != '=' && *p != ' ' && *p != '\t';); in getsubopt()
67 if (*p) { in getsubopt()
73 if (*p == '=') { in getsubopt()
74 *p = '\0'; in getsubopt()
75 for (*valuep = ++p; in getsubopt()
[all …]
Dinsque.c43 struct qelem *p = pred; in insque() local
45 if (p == NULL) in insque()
48 e->q_forw = p->q_forw; in insque()
49 e->q_back = p; in insque()
50 if (p->q_forw != NULL) in insque()
51 p->q_forw->q_back = e; in insque()
52 p->q_forw = e; in insque()
/bionic/libc/stdlib/
Datexit.c82 struct atexit *p = __atexit; in __cxa_atexit() local
87 if (pgsize < sizeof(*p)) in __cxa_atexit()
90 p = __atexit; in __cxa_atexit()
91 if (p != NULL) { in __cxa_atexit()
92 if (p->ind + 1 >= p->max) in __cxa_atexit()
93 p = NULL; in __cxa_atexit()
94 else if (mprotect(p, pgsize, PROT_READ | PROT_WRITE)) in __cxa_atexit()
97 if (p == NULL) { in __cxa_atexit()
98 p = mmap(NULL, pgsize, PROT_READ | PROT_WRITE, in __cxa_atexit()
100 if (p == MAP_FAILED) in __cxa_atexit()
[all …]
/bionic/libc/bionic/
Dfts.c56 #define ALIGN(p) (((uintptr_t)(p) + ALIGNBYTES) &~ ALIGNBYTES) argument
77 FTSENT *p, *root; in fts_open() local
118 if ((p = fts_alloc(sp, *argv, len)) == NULL) in fts_open()
120 p->fts_level = FTS_ROOTLEVEL; in fts_open()
121 p->fts_parent = parent; in fts_open()
122 p->fts_accpath = p->fts_name; in fts_open()
123 p->fts_info = fts_stat(sp, p, ISSET(FTS_COMFOLLOW), -1); in fts_open()
126 if (p->fts_info == FTS_DOT) in fts_open()
127 p->fts_info = FTS_D; in fts_open()
134 p->fts_link = root; in fts_open()
[all …]
Dndk_cruft.cpp79 char* p = reinterpret_cast<char*>(m1); in memswap() local
80 char* p_end = p + n; in memswap()
82 while (p < p_end) { in memswap()
83 char tmp = *p; in memswap()
84 *p = *q; in memswap()
86 p++; in memswap()
148 const unsigned char* p = (const unsigned char *)nptr; in strntoumax() local
149 const unsigned char* end = p + n; in strntoumax()
154 while (p < end && isspace(*p)) { in strntoumax()
155 p++; in strntoumax()
[all …]
/bionic/libm/upstream-freebsd/lib/msun/src/
De_remainderf.c26 __ieee754_remainderf(float x, float p) in __ieee754_remainderf() argument
33 GET_FLOAT_WORD(hp,p); in __ieee754_remainderf()
39 if(hp==0) return (x*p)/(x*p); /* p = 0 */ in __ieee754_remainderf()
42 return ((long double)x*p)/((long double)x*p); in __ieee754_remainderf()
45 if (hp<=0x7effffff) x = __ieee754_fmodf(x,p+p); /* now x < 2p */ in __ieee754_remainderf()
48 p = fabsf(p); in __ieee754_remainderf()
50 if(x+x>p) { in __ieee754_remainderf()
51 x-=p; in __ieee754_remainderf()
52 if(x+x>=p) x -= p; in __ieee754_remainderf()
55 p_half = (float)0.5*p; in __ieee754_remainderf()
[all …]
De_remainder.c35 __ieee754_remainder(double x, double p) in __ieee754_remainder() argument
42 EXTRACT_WORDS(hp,lp,p); in __ieee754_remainder()
48 if((hp|lp)==0) return (x*p)/(x*p); /* p = 0 */ in __ieee754_remainder()
52 return ((long double)x*p)/((long double)x*p); in __ieee754_remainder()
55 if (hp<=0x7fdfffff) x = __ieee754_fmod(x,p+p); /* now x < 2p */ in __ieee754_remainder()
58 p = fabs(p); in __ieee754_remainder()
60 if(x+x>p) { in __ieee754_remainder()
61 x-=p; in __ieee754_remainder()
62 if(x+x>=p) x -= p; in __ieee754_remainder()
65 p_half = 0.5*p; in __ieee754_remainder()
[all …]
/bionic/libc/upstream-netbsd/lib/libc/regex/
Dregcomp.c128 static void p_ere(struct parse *p, int stop, size_t reclimit);
129 static void p_ere_exp(struct parse *p, size_t reclimit);
130 static void p_str(struct parse *p);
131 static void p_bre(struct parse *p, int end1, int end2, size_t reclimit);
132 static int p_simp_re(struct parse *p, int starordinary, size_t reclimit);
133 static int p_count(struct parse *p);
134 static void p_bracket(struct parse *p);
135 static void p_b_term(struct parse *p, cset *cs);
136 static void p_b_cclass(struct parse *p, cset *cs);
137 static void p_b_eclass(struct parse *p, cset *cs);
[all …]
/bionic/libc/upstream-netbsd/lib/libc/stdlib/
Dlcong48.c32 lcong48(unsigned short p[7]) in __weak_alias()
34 _DIAGASSERT(p != NULL); in __weak_alias()
36 __rand48_seed[0] = p[0]; in __weak_alias()
37 __rand48_seed[1] = p[1]; in __weak_alias()
38 __rand48_seed[2] = p[2]; in __weak_alias()
39 __rand48_mult[0] = p[3]; in __weak_alias()
40 __rand48_mult[1] = p[4]; in __weak_alias()
41 __rand48_mult[2] = p[5]; in __weak_alias()
42 __rand48_add = p[6]; in __weak_alias()
/bionic/libc/arch-mips/string/
Dstrnlen.c40 do_bytes (const char *base, const char *p, op_t inval) in do_bytes() argument
58 p += (outval >> 3); in do_bytes()
59 return (size_t) (p - base); in do_bytes()
69 do_bytes (const char *base, const char *p) in do_bytes() argument
71 for (; *p; ++p); in do_bytes()
72 return (size_t) (p - base); in do_bytes()
84 const char *p = (const char *) str; in strnlen() local
88 for (; n > 0 && ((size_t) p % op_size) != 0; --n, ++p) { in strnlen()
89 if (!(*p)) in strnlen()
90 return (p - str); in strnlen()
[all …]
Dstrlen.c40 do_bytes (const char *base, const char *p, op_t inval) in do_bytes() argument
58 p += (outval >> 3); in do_bytes()
59 return (size_t) (p - base); in do_bytes()
69 do_bytes (const char *base, const char *p) in do_bytes() argument
71 for (; *p; ++p); in do_bytes()
72 return (size_t) (p - base); in do_bytes()
85 const char *p = (const char *) str; in strlen() local
89 while ((size_t) p % sizeof (op_t)) { in strlen()
90 if (!(*p)) in strlen()
91 return (p - str); in strlen()
[all …]
Dstrchr.c59 p++; \
61 return (char *)p;
75 unsigned char* p = (unsigned char *) w; in do_bytes() local
92 return (char *)p; in do_bytes()
100 unsigned char* p = (unsigned char *) s; in strchr() local
105 for ( ; *p != ch && ((size_t) p % op_size) != 0; p++) in strchr()
106 if (*p == '\0') in strchr()
109 if (*p != ch) { in strchr()
110 w = (const op_t *) p; in strchr()
137 return (char *)p; in strchr()
Dmemchr.c48 const unsigned char *p = (const unsigned char *) w; in do_bytes() local
65 p += (outval >> 3); in do_bytes()
66 return (void *) p; in do_bytes()
78 const unsigned char *p = (const unsigned char *) w; in do_bytes() local
79 for (; *p != ch; ++p); in do_bytes()
80 return (void *) p; in do_bytes()
106 const unsigned char *p = (const unsigned char *) s; in memchr() local
114 for (; n > 0 && ((size_t) p % op_size) != 0; --n, ++p) { in memchr()
115 if (*p == ch) in memchr()
116 return (void *) p; in memchr()
[all …]
/bionic/libc/dns/net/
Dgetservent.c54 const char* p; in getservent_r() local
62 p = rs->servent_ptr; in getservent_r()
63 if (p == NULL) in getservent_r()
64 p = _services; in getservent_r()
65 else if (p[0] == 0) in getservent_r()
69 namelen = p[0]; in getservent_r()
71 q = p + 1 + namelen + 3; /* skip name + port + proto */ in getservent_r()
95 memcpy( rs->servent.s_name, p+1, namelen ); in getservent_r()
97 p += 1 + namelen; in getservent_r()
100 port = ((((unsigned char*)p)[0] << 8) | in getservent_r()
[all …]
/bionic/libc/upstream-openbsd/lib/libc/net/
Dinet_ntoa.c44 char *p; in inet_ntoa() local
46 p = (char *)&in; 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/upstream-freebsd/lib/libc/string/
Dwcspbrk.c42 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()
Dwcscspn.c42 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()
Dwcsspn.c42 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()
Dwcslen.c42 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()
/bionic/libc/stdio/
Dparsefloat.c42 char *commit, *p; in parsefloat() local
61 for (p = buf; p < end; ) { in parsefloat()
75 commit = p; in parsefloat()
96 commit = p; /* inf or infinity */ in parsefloat()
111 commit = p; in parsefloat()
119 commit = p; in parsefloat()
145 commit = p; in parsefloat()
155 commit = p; in parsefloat()
168 commit = p; in parsefloat()
175 *p++ = c; in parsefloat()
[all …]
/bionic/libc/upstream-openbsd/lib/libc/gdtoa/
Dhdtoa.c127 struct ieee_double *p = (struct ieee_double *)&d; in __hdtoa() local
131 *sign = p->dbl_sign; in __hdtoa()
135 *decpt = p->dbl_exp - DBL_ADJ; in __hdtoa()
142 *decpt = p->dbl_exp - (514 + DBL_ADJ); in __hdtoa()
179 *s = p->dbl_fracl & 0xf; in __hdtoa()
180 p->dbl_fracl >>= 4; in __hdtoa()
183 *s = p->dbl_frach & 0xf; in __hdtoa()
184 p->dbl_frach >>= 4; in __hdtoa()
193 *s = p->dbl_frach | (1U << ((DBL_MANT_DIG - 1) % 4)); in __hdtoa()
202 dorounding(s0, ndigits, p->dbl_sign, decpt); in __hdtoa()
[all …]
/bionic/libc/upstream-openbsd/lib/libc/string/
Dwcsstr.c41 const wchar_t *p; in wcswcs() local
52 p = big; in wcswcs()
54 while (*p) { in wcswcs()
56 r = p; in wcswcs()
65 return (wchar_t *)p; in wcswcs()
67 p++; in wcswcs()
/bionic/libc/upstream-openbsd/lib/libc/stdio/
Dfgetln.c45 void *p; in __slbexpand() local
49 if ((p = realloc(fp->_lb._base, newsize)) == NULL) in __slbexpand()
51 fp->_lb._base = p; in __slbexpand()
66 unsigned char *p; in fgetln() local
79 if ((p = memchr((void *)fp->_p, '\n', fp->_r)) != NULL) { in fgetln()
85 p++; /* advance over it */ in fgetln()
87 *lenp = len = p - fp->_p; in fgetln()
90 fp->_p = p; in fgetln()
120 if ((p = memchr((void *)fp->_p, '\n', fp->_r)) == NULL) in fgetln()
124 p++; in fgetln()
[all …]
/bionic/libc/private/
Dbionic_macros.h51 static constexpr uintptr_t align_down(uintptr_t p, size_t align) { in align_down() argument
52 return p & ~(align - 1); in align_down()
55 static constexpr uintptr_t align_up(uintptr_t p, size_t align) { in align_up() argument
56 return (p + align - 1) & ~(align - 1); in align_up()
60 static inline T* align_down(T* p, size_t align) { in align_down() argument
61 return reinterpret_cast<T*>(align_down(reinterpret_cast<uintptr_t>(p), align)); in align_down()
65 static inline T* align_up(T* p, size_t align) { in align_up() argument
66 return reinterpret_cast<T*>(align_up(reinterpret_cast<uintptr_t>(p), align)); in align_up()
/bionic/libc/upstream-openbsd/android/include/
Darc4random.h77 } *p; in _rs_allocate() local
79 if ((p = mmap(NULL, sizeof(*p), PROT_READ|PROT_WRITE, in _rs_allocate()
83 prctl(PR_SET_VMA, PR_SET_VMA_ANON_NAME, p, sizeof(*p), "arc4random data"); in _rs_allocate()
85 *rsp = &p->rs; in _rs_allocate()
86 *rsxp = &p->rsx; in _rs_allocate()

123456