/bionic/tools/relocation_packer/test_data/ |
D | elf_file_unittest_relocs.cc | 11 const int i = 0; variable 15 const void* pointer_0 = &i; 16 const void* pointer_1 = &i; 17 const void* pointer_2 = &i; 18 const void* pointer_3 = &i; 19 const void* pointer_4 = &i; 20 const void* pointer_5 = &i; 21 const void* pointer_6 = &i; 22 const void* pointer_7 = &i; 23 const void* pointer_8 = &i; [all …]
|
/bionic/libm/upstream-freebsd/lib/msun/src/ |
D | k_rem_pio2.c | 296 int32_t jz,jx,jv,jp,jk,carry,n,iq[20],i,j,k,m,q0,ih; in __kernel_rem_pio2() local 310 for(i=0;i<=m;i++,j++) f[i] = (j<0)? zero : (double) ipio2[j]; in __kernel_rem_pio2() 313 for (i=0;i<=jk;i++) { in __kernel_rem_pio2() 314 for(j=0,fw=0.0;j<=jx;j++) fw += x[j]*f[jx+i-j]; q[i] = fw; in __kernel_rem_pio2() 320 for(i=0,j=jz,z=q[jz];j>0;i++,j--) { in __kernel_rem_pio2() 322 iq[i] = (int32_t)(z-two24*fw); in __kernel_rem_pio2() 333 i = (iq[jz-1]>>(24-q0)); n += i; in __kernel_rem_pio2() 334 iq[jz-1] -= i<<(24-q0); in __kernel_rem_pio2() 342 for(i=0;i<jz ;i++) { /* compute 1-q */ in __kernel_rem_pio2() 343 j = iq[i]; in __kernel_rem_pio2() [all …]
|
D | e_jnf.c | 31 int32_t i,hx,ix, sgn; in __ieee754_jnf() local 57 for(i=1;i<n;i++){ in __ieee754_jnf() 59 b = b*((float)(i+i)/x) - a; /* avoid underflow */ in __ieee754_jnf() 71 for (a=one,i=2;i<=n;i++) { in __ieee754_jnf() 72 a *= (float)i; /* a = n! */ in __ieee754_jnf() 118 for(t=zero, i = 2*(n+k); i>=m; i -= 2) t = one/(i/x-t); in __ieee754_jnf() 133 for(i=n-1,di=(float)(i+i);i>0;i--){ in __ieee754_jnf() 141 for(i=n-1,di=(float)(i+i);i>0;i--){ in __ieee754_jnf() 169 int32_t i,hx,ix,ib; in __ieee754_ynf() local 192 for(i=1;i<n&&ib!=0xff800000;i++){ in __ieee754_ynf() [all …]
|
D | e_jn.c | 56 int32_t i,hx,ix,lx, sgn; in __ieee754_jn() local 104 for(i=1;i<n;i++){ in __ieee754_jn() 106 b = b*((double)(i+i)/x) - a; /* avoid underflow */ in __ieee754_jn() 119 for (a=one,i=2;i<=n;i++) { in __ieee754_jn() 120 a *= (double)i; /* a = n! */ in __ieee754_jn() 166 for(t=zero, i = 2*(n+k); i>=m; i -= 2) t = one/(i/x-t); in __ieee754_jn() 181 for(i=n-1,di=(double)(i+i);i>0;i--){ in __ieee754_jn() 189 for(i=n-1,di=(double)(i+i);i>0;i--){ in __ieee754_jn() 217 int32_t i,hx,ix,lx; in __ieee754_yn() local 262 for(i=1;i<n&&high!=0xfff00000;i++){ in __ieee754_yn() [all …]
|
D | s_rint.c | 41 u_int32_t i,i1; in rint() local 59 i = (0x000fffff)>>j0; in rint() 60 if(((i0&i)|i1)==0) return x; /* x is integral */ in rint() 61 i>>=1; in rint() 62 if(((i0&i)|i1)!=0) { in rint() 73 i0 = (i0&(~i))|((0x20000)>>j0); in rint() 80 i = ((u_int32_t)(0xffffffff))>>(j0-20); in rint() 81 if((i1&i)==0) return x; /* x is integral */ in rint() 82 i>>=1; in rint() 83 if((i1&i)!=0) i1 = (i1&(~i))|((0x40000000)>>(j0-20)); in rint()
|
/bionic/benchmarks/ |
D | property_benchmark.cpp | 72 for (int i = 0; i < nprops; i++) { in LocalPropertyTestState() local 75 name_lens[i] = (random() % (PROP_NAME_MAX - 10)) + 10; in LocalPropertyTestState() 76 names[i] = new char[PROP_NAME_MAX + 1]; in LocalPropertyTestState() 78 for (int j = 0; j < name_lens[i]; j++) { in LocalPropertyTestState() 79 if (j == 0 || names[i][j-1] == '.' || j == name_lens[i] - 1) { in LocalPropertyTestState() 89 names[i][j] = prop_name_chars[random() % prop_name_len]; in LocalPropertyTestState() 91 names[i][name_lens[i]] = 0; in LocalPropertyTestState() 94 value_lens[i] = (random() % (PROP_VALUE_MAX - 1)) + 1; in LocalPropertyTestState() 95 values[i] = new char[PROP_VALUE_MAX]; in LocalPropertyTestState() 96 for (int j = 0; j < value_lens[i]; j++) { in LocalPropertyTestState() [all …]
|
D | pthread_benchmark.cpp | 28 for (int i = 0; i < iters; ++i) { in Run() local 42 for (int i = 0; i < iters; ++i) { in Run() local 57 for (int i = 0; i < iters; ++i) { in Run() local 75 for (int i = 0; i < iters; ++i) { in Run() local 88 for (int i = 0; i < iters; ++i) { in Run() local 102 for (int i = 0; i < iters; ++i) { in Run() local 116 for (int i = 0; i < iters; ++i) { in Run() local 131 for (int i = 0; i < iters; ++i) { in Run() local 147 for (int i = 0; i < iters; ++i) { in Run() local 165 for (int i = 0; i < iters; ++i) { in Run() local [all …]
|
D | time_benchmark.cpp | 28 for (int i = 0; i < iters; ++i) { in Run() local 40 for (int i = 0; i < iters; ++i) { in Run() local 52 for (int i = 0; i < iters; ++i) { in Run() local 64 for (int i = 0; i < iters; ++i) { in Run() local 75 for (int i = 0; i < iters; ++i) { in Run() local
|
D | math_benchmark.cpp | 35 for (int i = 0; i < iters; ++i) { in Run() local 48 for (int i = 0; i < iters; ++i) { in Run() local 61 for (int i = 0; i < iters; ++i) { in Run() local 74 for (int i = 0; i < iters; ++i) { in Run() local 86 for (int i = 0; i < iters; ++i) { in Run() local 98 for (int i = 0; i < iters; ++i) { in Run() local 114 for (int i = 0; i < iters; ++i) { in Run() local 131 for (int i = 0; i < iters; ++i) { in Run() local
|
D | unistd_benchmark.cpp | 26 for (int i = 0; i < iters; ++i) { in Run() local 37 for (int i = 0; i < iters; ++i) { in Run() local 53 for (int i = 0; i < iters; ++i) { in Run() local 66 for (int i = 0; i < iters; ++i) { in Run() local
|
D | string_benchmark.cpp | 39 for (int i = 0; i < iters; ++i) { in Run() local 56 for (int i = 0; i < iters; ++i) { in Run() local 73 for (int i = 0; i < iters; ++i) { in Run() local 88 for (int i = 0; i < iters; ++i) { in Run() local 106 for (int i = 0; i < iters; ++i) { in Run() local
|
/bionic/tests/ |
D | sched_test.cpp | 33 int i = 0; in TEST() local 34 pid_t tid = clone(child_fn, &child_stack[1024], CLONE_VM, &i); in TEST() 39 ASSERT_EQ(42, i); in TEST() 68 for (int i = 0; i < CPU_SETSIZE; i++) { in TEST() local 69 ASSERT_EQ(i == 0 || i == 17, CPU_ISSET(i, &set)); in TEST() 94 for (int i = 0; i < CPU_SETSIZE; i++) { in TEST() local 95 ASSERT_FALSE(CPU_ISSET(i, &set)); in TEST() 105 for (int i = 0; i < CPU_SETSIZE; i++) { in TEST() local 106 ASSERT_EQ(i == 0 || i == 1, CPU_ISSET(i, &set)); in TEST() 109 for (int i = 0; i < CPU_SETSIZE; i++) { in TEST() local [all …]
|
D | stdatomic_test.cpp | 96 atomic_int i; in TEST() local 97 atomic_store(&i, 123); in TEST() 98 ASSERT_EQ(123, atomic_load(&i)); in TEST() 99 atomic_store_explicit(&i, 123, memory_order_relaxed); in TEST() 100 ASSERT_EQ(123, atomic_load_explicit(&i, memory_order_relaxed)); in TEST() 104 atomic_int i; in TEST() local 105 atomic_store(&i, 123); in TEST() 106 ASSERT_EQ(123, atomic_exchange(&i, 456)); in TEST() 107 ASSERT_EQ(456, atomic_exchange_explicit(&i, 123, memory_order_relaxed)); in TEST() 111 atomic_int i; in TEST() local [all …]
|
D | math_data_test.h | 143 for (size_t i = 0; i < N; ++i) { 145 data[i].expected, f(data[i].input)) << "Failed on element " << i; 155 for (size_t i = 0; i < N; ++i) { 156 EXPECT_EQ(data[i].expected, f(data[i].input)) << "Failed on element " << i; 167 for (size_t i = 0; i < N; ++i) { 169 … data[i].expected, f(data[i].input1, data[i].input2)) << "Failed on element " << i; 181 for (size_t i = 0; i < N; ++i) { 184 f(data[i].input, &out1, &out2); 185 EXPECT_PRED_FORMAT2(predicate1, data[i].expected1, out1) << "Failed on element " << i; 186 EXPECT_PRED_FORMAT2(predicate2, data[i].expected2, out2) << "Failed on element " << i; [all …]
|
D | buffer_tests.cpp | 209 for (int i = 0; i < FENCEPOST_LENGTH; i += 2) { in SetFencepost() local 210 buffer[i] = 0xde; in SetFencepost() 211 buffer[i+1] = 0xad; in SetFencepost() 216 for (int i = 0; i < FENCEPOST_LENGTH; i += 2) { in VerifyFencepost() local 217 if (buffer[i] != 0xde || buffer[i+1] != 0xad) { in VerifyFencepost() 219 if (buffer[i] == 0xde) { in VerifyFencepost() 220 i++; in VerifyFencepost() 225 ASSERT_EQ(expected_value, buffer[i]); in VerifyFencepost() 242 for (size_t i = 0; i < g_single_aligns_len; i++) { in RunSingleBufferAlignTest() local 248 buf+FENCEPOST_LENGTH, g_single_aligns[i][0], g_single_aligns[i][1])); in RunSingleBufferAlignTest() [all …]
|
D | malloc_test.cpp | 49 for (size_t i = 0; i < alloc_len; i++) { in TEST() local 50 ASSERT_EQ(0, ptr[i]); in TEST() 78 for (size_t i = 0; i <= 12; i++) { in TEST() local 79 for (size_t alignment = 1 << i; alignment < (1U << (i+1)); alignment++) { in TEST() 83 ASSERT_EQ(0U, reinterpret_cast<uintptr_t>(ptr) % ((1U << i))) in TEST() 126 for (size_t i = 0; i < 100; i++) { in TEST() local 127 ASSERT_EQ(0x23, ptr[i]); in TEST() 134 for (size_t i = 0; i < 200; i++) { in TEST() local 135 ASSERT_EQ(0x45, ptr[i]); in TEST() 142 for (size_t i = 0; i < 250; i++) { in TEST() local [all …]
|
D | sys_socket_test.cpp | 127 for (size_t i = 0; i < NUM_RECV_MSGS; i++) { in SendMultiple() local 128 if (send(fd, g_RecvMsgs[i], strlen(g_RecvMsgs[i]) + 1, 0) < 0) { in SendMultiple() 147 for (size_t i = 0; i < NUM_RECV_MSGS; i++) { in TestRecvMMsg() local 148 io[i].iov_base = reinterpret_cast<void*>(bufs[i]); in TestRecvMMsg() 149 io[i].iov_len = strlen(g_RecvMsgs[i]) + 1; in TestRecvMMsg() 151 msgs[i].msg_hdr.msg_iov = &io[i]; in TestRecvMMsg() 152 msgs[i].msg_hdr.msg_iovlen = 1; in TestRecvMMsg() 153 msgs[i].msg_len = sizeof(struct msghdr); in TestRecvMMsg() 163 for (size_t i = 0; i < NUM_RECV_MSGS; i++) { in TestRecvMMsg() local 164 ASSERT_STREQ(g_RecvMsgs[i], bufs[i]); in TestRecvMMsg() [all …]
|
/bionic/libc/tools/ |
D | generate-NOTICE.py | 36 def ExtractCopyrightAt(lines, i): argument 37 hash = lines[i].startswith("#") 40 start = i 49 while i < len(lines): 50 if "*/" in lines[i]: 52 if hash and len(lines[i]) == 0: 54 …if "\t@(#)" in lines[i] or "\tfrom: @(#)" in lines[i] or "From: @(#)" in lines[i] or "from OpenBSD… 56 if "\tcitrus Id: " in lines[i]: 58 …if "\t$Citrus: " in lines[i] or "\t$OpenBSD: " in lines[i] or " $FreeBSD: " in lines[i] or "\t$Net… 60 if "$FreeBSD$" in lines[i] or "$Citrus$" in lines[i]: [all …]
|
/bionic/libc/upstream-openbsd/lib/libc/gdtoa/ |
D | hexnan.c | 36 L_shift(x, x1, i) ULong *x; ULong *x1; int i; in L_shift() argument 38 L_shift(ULong *x, ULong *x1, int i) 43 i = 8 - i; 44 i <<= 2; 45 j = ULbits - i; 48 x[1] >>= i; 62 int havedig, hd0, i, nbits; local 72 havedig = hd0 = i = 0; 84 if (x < x1 && i < 8) 85 L_shift(x, x1, i); [all …]
|
/bionic/libc/upstream-openbsd/lib/libc/net/ |
D | inet_lnaof.c | 43 in_addr_t i = ntohl(in.s_addr); in inet_lnaof() local 45 if (IN_CLASSA(i)) in inet_lnaof() 46 return ((i)&IN_CLASSA_HOST); in inet_lnaof() 47 else if (IN_CLASSB(i)) in inet_lnaof() 48 return ((i)&IN_CLASSB_HOST); in inet_lnaof() 50 return ((i)&IN_CLASSC_HOST); in inet_lnaof()
|
D | inet_netof.c | 42 in_addr_t i = ntohl(in.s_addr); in inet_netof() local 44 if (IN_CLASSA(i)) in inet_netof() 45 return (((i)&IN_CLASSA_NET) >> IN_CLASSA_NSHIFT); in inet_netof() 46 else if (IN_CLASSB(i)) in inet_netof() 47 return (((i)&IN_CLASSB_NET) >> IN_CLASSB_NSHIFT); in inet_netof() 49 return (((i)&IN_CLASSC_NET) >> IN_CLASSC_NSHIFT); in inet_netof()
|
D | inet_ntop.c | 107 int i; in inet_ntop6() local 116 for (i = 0; i < IN6ADDRSZ; i++) in inet_ntop6() 117 words[i / 2] |= (src[i] << ((1 - (i % 2)) << 3)); in inet_ntop6() 120 for (i = 0; i < (IN6ADDRSZ / INT16SZ); i++) { in inet_ntop6() 121 if (words[i] == 0) { in inet_ntop6() 123 cur.base = i, cur.len = 1; in inet_ntop6() 146 for (i = 0; i < (IN6ADDRSZ / INT16SZ) && tp < ep; i++) { in inet_ntop6() 148 if (best.base != -1 && i >= best.base && in inet_ntop6() 149 i < (best.base + best.len)) { in inet_ntop6() 150 if (i == best.base) { in inet_ntop6() [all …]
|
/bionic/libc/bionic/ |
D | wchar.cpp | 71 size_t i, o, r; in mbsnrtowcs() local 83 for (i = o = 0; i < nmc; i += r, o++) { in mbsnrtowcs() 84 if (static_cast<uint8_t>((*src)[i]) < 0x80) { in mbsnrtowcs() 86 if ((*src)[i] == '\0') { in mbsnrtowcs() 92 r = mbrtowc(NULL, *src + i, nmc - i, state); in mbsnrtowcs() 117 for (i = o = 0; i < nmc && o < len; i += r, o++) { in mbsnrtowcs() 118 if (static_cast<uint8_t>((*src)[i]) < 0x80) { in mbsnrtowcs() 120 dst[o] = (*src)[i]; in mbsnrtowcs() 122 if ((*src)[i] == '\0') { in mbsnrtowcs() 127 r = mbrtowc(dst + o, *src + i, nmc - i, state); in mbsnrtowcs() [all …]
|
D | vdso.cpp | 77 for (size_t i = 0; i < vdso_ehdr->e_shnum; ++i) { in __libc_init_vdso() local 78 if (vdso_shdr[i].sh_type == SHT_DYNSYM) { in __libc_init_vdso() 79 symbol_count = vdso_shdr[i].sh_size / sizeof(ElfW(Sym)); in __libc_init_vdso() 90 for (size_t i = 0; i < vdso_ehdr->e_phnum; ++i) { in __libc_init_vdso() local 91 if (vdso_phdr[i].p_type == PT_DYNAMIC) { in __libc_init_vdso() 92 vdso_dyn = reinterpret_cast<ElfW(Dyn)*>(vdso_ehdr_addr + vdso_phdr[i].p_offset); in __libc_init_vdso() 93 } else if (vdso_phdr[i].p_type == PT_LOAD) { in __libc_init_vdso() 94 vdso_addr = vdso_ehdr_addr + vdso_phdr[i].p_offset - vdso_phdr[i].p_vaddr; in __libc_init_vdso() 116 for (size_t i = 0; i < symbol_count; ++i) { in __libc_init_vdso() local 118 if (strcmp(vdso_entries[j].name, strtab + symtab[i].st_name) == 0) { in __libc_init_vdso() [all …]
|
/bionic/libc/dns/nameser/ |
D | ns_samedomain.c | 56 size_t la, lb, i; in ns_samedomain() local 67 for (i = la - 1; i > 0; i--) in ns_samedomain() 68 if (a[i - 1] == '\\') { in ns_samedomain() 83 for (i = lb - 1; i > 0; i--) in ns_samedomain() 84 if (b[i - 1] == '\\') { in ns_samedomain() 132 for (i = diff - 1; i > 0; i--) in ns_samedomain() 133 if (a[i - 1] == '\\') { in ns_samedomain()
|