/bionic/libm/upstream-freebsd/lib/msun/src/ |
D | e_asin.c | 73 double t=0.0,w,p,q,c,r,s; in asin() local 88 t = x*x; in asin() 89 p = t*(pS0+t*(pS1+t*(pS2+t*(pS3+t*(pS4+t*pS5))))); in asin() 90 q = one+t*(qS1+t*(qS2+t*(qS3+t*qS4))); in asin() 96 t = w*0.5; in asin() 97 p = t*(pS0+t*(pS1+t*(pS2+t*(pS3+t*(pS4+t*pS5))))); in asin() 98 q = one+t*(qS1+t*(qS2+t*(qS3+t*qS4))); in asin() 99 s = sqrt(t); in asin() 102 t = pio2_hi-(2.0*(s+s*w)-pio2_lo); in asin() 106 c = (t-w*w)/(s+w); in asin() [all …]
|
D | s_cbrt.c | 45 double r,s,t=0.0,w; in cbrt() local 72 SET_HIGH_WORD(t,0x43500000); /* set t= 2**54 */ in cbrt() 73 t*=x; in cbrt() 74 GET_HIGH_WORD(high,t); in cbrt() 75 INSERT_WORDS(t,sign|((high&0x7fffffff)/3+B2),0); in cbrt() 77 INSERT_WORDS(t,sign|(hx/3+B1),0); in cbrt() 89 r=(t*t)*(t/x); in cbrt() 90 t=t*((P0+r*(P1+r*P2))+((r*r)*r)*(P3+r*P4)); in cbrt() 102 u.value=t; in cbrt() 104 t=u.value; in cbrt() [all …]
|
D | e_asinf.c | 38 float t,w,p,q; in asinf() local 50 t = x*x; in asinf() 51 p = t*(pS0+t*(pS1+t*pS2)); in asinf() 52 q = one+t*qS1; in asinf() 58 t = w*(float)0.5; in asinf() 59 p = t*(pS0+t*(pS1+t*pS2)); in asinf() 60 q = one+t*qS1; in asinf() 61 s = sqrt(t); in asinf() 63 t = pio2-2.0*(s+s*w); in asinf() 64 if(hx>0) return t; else return -t; in asinf()
|
D | s_csqrtf.c | 40 double t; in csqrtf() local 52 t = (b - b) / (b - b); /* raise invalid if b is not a NaN */ in csqrtf() 53 return (CMPLXF(a + 0.0L + t, a + 0.0L + t)); /* NaN + NaN i */ in csqrtf() 68 t = (a - a) / (a - a); /* raise invalid */ in csqrtf() 69 return (CMPLXF(b + 0.0L + t, b + 0.0L + t)); /* NaN + NaN i */ in csqrtf() 78 t = sqrt((a + hypot(a, b)) * 0.5); in csqrtf() 79 return (CMPLXF(t, b / (2 * t))); in csqrtf() 81 t = sqrt((-a + hypot(a, b)) * 0.5); in csqrtf() 82 return (CMPLXF(fabsf(b) / (2 * t), copysignf(t, b))); in csqrtf()
|
D | s_roundf.c | 38 float t; in roundf() local 46 t = floorf(x); in roundf() 47 if (t - x <= -0.5F) in roundf() 48 t += 1; in roundf() 49 return (t); in roundf() 51 t = floorf(-x); in roundf() 52 if (t + x <= -0.5F) in roundf() 53 t += 1; in roundf() 54 return (-t); in roundf()
|
D | s_roundl.c | 44 long double t; in roundl() local 54 t = floorl(x); in roundl() 55 if (t - x <= -0.5L) in roundl() 56 t += 1; in roundl() 57 RETURNI(t); in roundl() 59 t = floorl(-x); in roundl() 60 if (t + x <= -0.5L) in roundl() 61 t += 1; in roundl() 62 RETURNI(-t); in roundl()
|
D | s_round.c | 40 double t; in round() local 48 t = floor(x); in round() 49 if (t - x <= -0.5) in round() 50 t += 1; in round() 51 return (t); in round() 53 t = floor(-x); in round() 54 if (t + x <= -0.5) in round() 55 t += 1; in round() 56 return (-t); in round()
|
D | s_csqrtl.c | 60 long double a, b, rx, ry, scale, t; in csqrtl() local 71 t = (b - b) / (b - b); /* raise invalid if b is not a NaN */ in csqrtl() 72 return (CMPLXL(a + 0.0L + t, a + 0.0L + t)); /* NaN + NaN i */ in csqrtl() 87 t = (a - a) / (a - a); /* raise invalid */ in csqrtl() 88 return (CMPLXL(b + 0.0L + t, b + 0.0L + t)); /* NaN + NaN i */ in csqrtl() 116 t = sqrtl((a + hypotl(a, b)) * 0.5); in csqrtl() 117 rx = scale * t; in csqrtl() 118 ry = scale * b / (2 * t); in csqrtl() 120 t = sqrtl((-a + hypotl(a, b)) * 0.5); in csqrtl() 121 rx = scale * fabsl(b) / (2 * t); in csqrtl() [all …]
|
D | s_csqrt.c | 45 double a, b, rx, ry, scale, t; in csqrt() local 56 t = (b - b) / (b - b); /* raise invalid if b is not a NaN */ in csqrt() 57 return (CMPLX(a + 0.0L + t, a + 0.0L + t)); /* NaN + NaN i */ in csqrt() 72 t = (a - a) / (a - a); /* raise invalid */ in csqrt() 73 return (CMPLX(b + 0.0L + t, b + 0.0L + t)); /* NaN + NaN i */ in csqrt() 101 t = sqrt((a + hypot(a, b)) * 0.5); in csqrt() 102 rx = scale * t; in csqrt() 103 ry = scale * b / (2 * t); in csqrt() 105 t = sqrt((-a + hypot(a, b)) * 0.5); in csqrt() 106 rx = scale * fabs(b) / (2 * t); in csqrt() [all …]
|
D | e_asinl.c | 37 long double t=0.0,w,p,q,c,r,s; in asinl() local 51 t = x*x; in asinl() 52 p = P(t); in asinl() 53 q = Q(t); in asinl() 59 t = w*0.5; in asinl() 60 p = P(t); in asinl() 61 q = Q(t); in asinl() 62 s = sqrtl(t); in asinl() 65 t = pio2_hi-(2.0*(s+s*w)-pio2_lo); in asinl() 70 c = (t-w*w)/(s+w); in asinl() [all …]
|
D | e_sinhf.c | 27 float t,h; in sinhf() local 42 t = expm1f(fabsf(x)); in sinhf() 43 if(ix<0x3f800000) return h*((float)2.0*t-t*t/(t+one)); in sinhf() 44 return h*(t+t/(t+one)); in sinhf()
|
D | e_sinh.c | 45 double t,h; in sinh() local 61 t = expm1(fabs(x)); in sinh() 62 if(ix<0x3ff00000) return h*(2.0*t-t*t/(t+one)); in sinh() 63 return h*(t+t/(t+one)); in sinh()
|
D | s_expm1f.c | 44 float y,hi,lo,c,t,e,hxs,hfx,r1,twopk; in expm1f() local 76 t = k; in expm1f() 77 hi = x - t*ln2_hi; /* t*ln2_hi is exact here */ in expm1f() 78 lo = t*ln2_lo; in expm1f() 84 t = huge+x; /* return x with inexact flags when x!=0 */ in expm1f() 85 return x - (t-(huge+x)); in expm1f() 93 t = (float)3.0-r1*hfx; in expm1f() 94 e = hxs*((r1-t)/((float)6.0 - x*t)); in expm1f() 111 t = one; in expm1f() 113 SET_FLOAT_WORD(t,0x3f800000 - (0x1000000>>k)); /* t=1-2^-k */ in expm1f() [all …]
|
D | s_cbrtl.c | 38 long double r, s, t, w; in cbrtl() local 116 t = dt + vd - 0x1.0p32; in cbrtl() 126 t = dt + 0x2.0p-46 + 0x1.0p60L - 0x1.0p60; in cbrtl() 135 s=t*t; /* t*t is exact */ in cbrtl() 137 w=t+t; /* t+t is exact */ in cbrtl() 138 r=(r-t)/(w+r); /* r-t is exact; w+r ~= 3*t */ in cbrtl() 139 t=t+t*r; /* error <= (0.5 + 0.5/3) * ulp */ in cbrtl() 141 t *= v.e; in cbrtl() 142 RETURNI(t); in cbrtl()
|
D | e_acoshf.c | 29 float t; in acoshf() local 42 t=x*x; in acoshf() 43 return logf((float)2.0*x-one/(x+sqrtf(t-one))); in acoshf() 45 t = x-one; in acoshf() 46 return log1pf(t+sqrtf((float)2.0*t+t*t)); in acoshf()
|
/bionic/benchmarks/ |
D | time_benchmark.cpp | 42 timespec t; in BM_time_clock_gettime() local 44 clock_gettime(CLOCK_MONOTONIC, &t); in BM_time_clock_gettime() 51 timespec t; in BM_time_clock_gettime_syscall() local 53 syscall(__NR_clock_gettime, CLOCK_MONOTONIC, &t); in BM_time_clock_gettime_syscall() 60 timespec t; in BM_time_clock_gettime_MONOTONIC_COARSE() local 62 clock_gettime(CLOCK_MONOTONIC_COARSE, &t); in BM_time_clock_gettime_MONOTONIC_COARSE() 69 timespec t; in BM_time_clock_gettime_MONOTONIC_RAW() local 71 clock_gettime(CLOCK_MONOTONIC_RAW, &t); in BM_time_clock_gettime_MONOTONIC_RAW() 78 timespec t; in BM_time_clock_gettime_REALTIME() local 80 clock_gettime(CLOCK_REALTIME, &t); in BM_time_clock_gettime_REALTIME() [all …]
|
/bionic/libc/arch-riscv64/string/ |
D | bcopy.c | 57 size_t t; in memcpy_gc() local 65 #define TLOOP(s) if (t) TLOOP1(s) in memcpy_gc() 66 #define TLOOP1(s) do { s; } while (--t) in memcpy_gc() 72 t = (uintptr_t)src; /* only need low bits */ in memcpy_gc() 73 if ((t | (uintptr_t)dst) & wmask) { in memcpy_gc() 78 if ((t ^ (uintptr_t)dst) & wmask || length < wsize) in memcpy_gc() 79 t = length; in memcpy_gc() 81 t = wsize - (t & wmask); in memcpy_gc() 82 length -= t; in memcpy_gc() 88 t = length / wsize; in memcpy_gc() [all …]
|
D | memset.c | 51 size_t t; in memset_gc() local 86 if ((t = (long)dst & wmask) != 0) { in memset_gc() 87 t = wsize - t; in memset_gc() 88 length -= t; in memset_gc() 91 } while (--t != 0); in memset_gc() 95 t = length / wsize; in memset_gc() 99 } while (--t != 0); in memset_gc() 102 t = length & wmask; in memset_gc() 103 if (t != 0) in memset_gc() 106 } while (--t != 0); in memset_gc()
|
/bionic/tests/ |
D | termios_test.cpp | 49 termios t = {}; in TEST() local 50 ASSERT_EQ(0, cfsetispeed(&t, B1200)); in TEST() 51 ASSERT_EQ(static_cast<speed_t>(B1200), cfgetispeed(&t)); in TEST() 55 termios t = {}; in TEST() local 57 ASSERT_EQ(-1, cfsetispeed(&t, 1200)); in TEST() 62 termios t = {}; in TEST() local 63 ASSERT_EQ(0, cfsetospeed(&t, B1200)); in TEST() 64 ASSERT_EQ(static_cast<speed_t>(B1200), cfgetospeed(&t)); in TEST() 68 termios t = {}; in TEST() local 70 ASSERT_EQ(-1, cfsetospeed(&t, 1200)); in TEST() [all …]
|
D | sys_timex_test.cpp | 24 timex t; in TEST() local 25 memset(&t, 0, sizeof(t)); in TEST() 27 ASSERT_NE(-1, adjtimex(&t)); in TEST() 31 timex t; in TEST() local 32 memset(&t, 0, sizeof(t)); in TEST() 34 ASSERT_NE(-1, clock_adjtime(CLOCK_REALTIME, &t)); in TEST()
|
D | time_test.cpp | 66 time_t t = 0; in TEST() local 67 tm* broken_down = gmtime(&t); in TEST() 79 time_t t = 0; in TEST() local 80 struct tm* broken_down = gmtime_r(&t, &tm); in TEST() 120 pthread_t t; in TEST() local 121 ASSERT_EQ(0, pthread_create(&t, &a, gmtime_no_stack_overflow_14313703_fn, nullptr)); in TEST() 122 ASSERT_EQ(0, pthread_join(t, nullptr)); in TEST() 129 struct tm t; in TEST() local 130 memset(&t, 0, sizeof(tm)); in TEST() 131 t.tm_year = 1980 - 1900; in TEST() [all …]
|
/bionic/libm/upstream-netbsd/lib/libm/complex/ |
D | cephes_subrl.c | 72 long double t; in _redupil() local 75 t = x / M_PIL; in _redupil() 76 if (t >= 0.0L) in _redupil() 77 t += 0.5L; in _redupil() 79 t -= 0.5L; in _redupil() 81 i = t; /* the multiple */ in _redupil() 82 t = i; in _redupil() 83 t = ((x - t * DP1) - t * DP2) - t * DP3; in _redupil() 84 return t; in _redupil() 92 long double f, x, x2, y, y2, rn, t; in _ctansl() local [all …]
|
/bionic/libc/tzcode/ |
D | strftime.c | 135 struct tm const *restrict t, in strftime_l() argument 139 return strftime(s, maxsize, format, t); in strftime_l() 147 struct tm const *restrict t) in strftime() argument 154 p = _fmt(format, t, s, s + maxsize, &warn); in strftime() 217 _fmt(const char *format, const struct tm *t, char *pt, in _fmt() argument 231 pt = _add((t->tm_wday < 0 || in _fmt() 232 t->tm_wday >= DAYSPERWEEK) ? in _fmt() 233 "?" : Locale->weekday[t->tm_wday], in _fmt() 237 pt = _add((t->tm_wday < 0 || in _fmt() 238 t->tm_wday >= DAYSPERWEEK) ? in _fmt() [all …]
|
/bionic/libc/dns/resolv/ |
D | herror.c | 100 char *t; in herror() local 103 DE_CONST(s, t); in herror() 104 v->iov_base = t; in herror() 105 v->iov_len = strlen(t); in herror() 107 DE_CONST(": ", t); in herror() 108 v->iov_base = t; in herror() 112 DE_CONST(hstrerror(h_errno), t); in herror() 113 v->iov_base = t; in herror() 116 DE_CONST("\n", t); in herror() 117 v->iov_base = t; in herror()
|
/bionic/libc/bionic/ |
D | pthread_internal.cpp | 102 for (pthread_internal_t* t = g_thread_list; t != nullptr; t = t->next) { in __pthread_internal_find() local 103 if (t == thread) return thread; in __pthread_internal_find() 194 for (pthread_internal_t* t = g_thread_list; t != nullptr; t = t->next) { in __pthread_internal_remap_stack_with_mte() local 195 if (t->terminating || t->is_main()) continue; in __pthread_internal_remap_stack_with_mte() 196 if (mprotect(t->mmap_base_unguarded, t->mmap_size_unguarded, in __pthread_internal_remap_stack_with_mte() 198 async_safe_fatal("error: failed to set PROT_MTE on thread: %d", t->tid); in __pthread_internal_remap_stack_with_mte() 248 for (pthread_internal_t* t = g_thread_list; t != nullptr; t = t->next) { in android_run_on_all_threads() local 251 if (t == __get_thread()) continue; in android_run_on_all_threads() 256 if (atomic_load(&t->terminating)) continue; in android_run_on_all_threads() 258 if (tgkill(my_pid, t->tid, BIONIC_SIGNAL_RUN_ON_ALL_THREADS) == 0) { in android_run_on_all_threads()
|