Home
last modified time | relevance | path

Searched refs:i (Results 1 – 25 of 1010) sorted by relevance

12345678910>>...41

/xnu-11417.121.6/iokit/Tests/
H A DTestCollections.cpp43 int i, j, count, count2; in testArray() local
55 for (i = 0; i < numStrCache; i++) { in testArray()
56 cache[i] = (OSObject *) OSSymbol::withCStringNoCopy(strCache[i]); in testArray()
58 for (i = 0; i < numStrCache; i++) { in testArray()
59 cache[i]->release(); in testArray()
95 for (i = 0; i < numStrCache; i++) { in testArray()
96 cache[i] = OSString::withCStringNoCopy(strCache[i]); in testArray()
100 for (i = 0; i < numStrCache; i++) { in testArray()
101 cache[i]->release(); in testArray()
109 for (i = 0; (str = array1->getObject(i)); i++) { in testArray()
[all …]
H A DTestContainers.cpp125 unsigned int i; in testData() local
136 for (i = 0; i < sizeof(testData) / sizeof(short); i++) { in testData()
137 testData[i] = (unsigned short) i; in testData()
168 for (i = 0; cp && i < (DATA_SIZE_1 / sizeof(short)); i++) { in testData()
169 TEST_ASSERT('d', "2g", *cp++ == testData[i]); in testData()
170 if (*cp != testData[i]) { in testData()
176 for (i = 5; cp && i < (DATA_SIZE_1 / sizeof(short)) - 5; i++) { in testData()
177 TEST_ASSERT('d', "2i", *cp++ == testData[i]); in testData()
178 if (*cp != testData[i]) { in testData()
214 for (i = 0; i < DATA_SIZE_4; i += DATA_SIZE_3) { in testData()
[all …]
/xnu-11417.121.6/osfmk/tests/
H A Dbitmap_test.c46 for (int i = bitmap_first(map, nbits); i >= 0; i = bitmap_next(map, i)) { in dump_bitmap_next() local
47 printf(" %d", i); in dump_bitmap_next()
55 for (int i = bitmap_lsb_first(map, nbits); i >= 0; i = bitmap_lsb_next(map, nbits, i)) { in dump_bitmap_lsb() local
56 printf(" %d", i); in dump_bitmap_lsb()
75 for (uint i = 0; i < nbits; i++) { in test_bitmap() local
76 bitmap_set(map, i); in test_bitmap()
81 for (int i = bitmap_first(map, nbits); i >= 0; i = bitmap_next(map, i)) { in test_bitmap() local
82 assert(i == expected_result); in test_bitmap()
96 for (int i = bitmap_first(map, nbits); i >= 0; i = bitmap_next(map, i)) { in test_bitmap() local
97 assert(i == expected_result); in test_bitmap()
[all …]
/xnu-11417.121.6/tests/
H A Dscanf.c62 for (char i = ' '; i <= '~'; ++i) { variable
63 char buf[] = { i, '\0' };
65 T_ASSERT_EQ_INT(c, i, "character value");
94 for (char i = 0; i <= 9; ++i) { variable
95 char buf[] = { i + '0', '\0' };
97 T_ASSERT_EQ_INT(num, i, "decimal value");
99 for (char i = 10; i <= 99; ++i) { variable
100 char buf[] = { i / 10 + '0', i % 10 + '0', '\0' };
102 T_ASSERT_EQ_INT(num, i, "decimal value");
104 for (char i = 0; i <= 9; ++i) { variable
[all …]
H A Dhost_statistics_rate_limiting.c39 unsigned long i, j; in check_host_info() local
44 …for (i = (HOST_VM_INFO64_REV0_COUNT * sizeof(int)); i < (HOST_VM_INFO64_REV1_COUNT * sizeof(int));… in check_host_info()
45 T_QUIET; T_ASSERT_EQ(datap[i], lett, "HOST_VM_INFO64_REV0 byte %lu iter %lu", i, j); in check_host_info()
49 …for (i = (HOST_VM_INFO_REV0_COUNT * sizeof(int)); i < (HOST_VM_INFO_REV2_COUNT * sizeof(int)); i++… in check_host_info()
50 T_QUIET; T_ASSERT_EQ(datap[i], lett, "HOST_VM_INFO_REV0 byte %lu iter %lu", i, j); in check_host_info()
54 …for (i = (HOST_VM_INFO_REV1_COUNT * sizeof(int)); i < (HOST_VM_INFO_REV2_COUNT * sizeof(int)); i++… in check_host_info()
55 T_QUIET; T_ASSERT_EQ(datap[i], lett, "HOST_VM_INFO_REV1 byte %lu iter %lu", i, j); in check_host_info()
59 …for (i = (TASK_POWER_INFO_COUNT * sizeof(int)); i < (TASK_POWER_INFO_V2_COUNT * sizeof(int)); i++)… in check_host_info()
60 T_QUIET; T_ASSERT_EQ(datap[i], lett, "TASK_POWER_INFO_COUNT byte %lu iter %lu", i, j); in check_host_info()
68 for (i = 0; i < sizeof(struct all_host_info); i++) { in check_host_info()
[all …]
H A Davx.c162 int i = 0; in store_ymm() local
163 __asm__ volatile ("vmovaps %%ymm0, %0" :"=m" (vec256array[i])); in store_ymm()
164 i++; __asm__ volatile ("vmovaps %%ymm1, %0" :"=m" (vec256array[i])); in store_ymm()
165 i++; __asm__ volatile ("vmovaps %%ymm2, %0" :"=m" (vec256array[i])); in store_ymm()
166 i++; __asm__ volatile ("vmovaps %%ymm3, %0" :"=m" (vec256array[i])); in store_ymm()
167 i++; __asm__ volatile ("vmovaps %%ymm4, %0" :"=m" (vec256array[i])); in store_ymm()
168 i++; __asm__ volatile ("vmovaps %%ymm5, %0" :"=m" (vec256array[i])); in store_ymm()
169 i++; __asm__ volatile ("vmovaps %%ymm6, %0" :"=m" (vec256array[i])); in store_ymm()
170 i++; __asm__ volatile ("vmovaps %%ymm7, %0" :"=m" (vec256array[i])); in store_ymm()
172 i++; __asm__ volatile ("vmovaps %%ymm8, %0" :"=m" (vec256array[i])); in store_ymm()
[all …]
H A Dexception_ports_info.c112 for (int i = 0; i < count2; i++) { variable
113 T_LOG("exception port name: 0x%x", ports[i]);
133 for (int i = 0; i < tblcnt; i++) { variable
134 if (table[i].iin_name == exc_port1) {
135 exc_port1_kaddr = table[i].iin_object;
137 if (table[i].iin_name == exc_port2) {
138 exc_port2_kaddr = table[i].iin_object;
140 if (table[i].iin_name == exc_port3) {
141 exc_port3_kaddr = table[i].iin_object;
149 for (int i = 0; i < count; i++) { variable
[all …]
/xnu-11417.121.6/tests/skywalk/
H A Dskt_utunleak.c62 for (int i = 0; i < nchannels; i++) { in skt_utunleak_main() local
63 utuns[i] = -1; in skt_utunleak_main()
66 for (int i = 0; i < nchannels; i++) { in skt_utunleak_main() local
67 utuns[i] = sktu_create_interface(SKTU_IFT_UTUN, SKTU_IFF_ENABLE_NETIF); in skt_utunleak_main()
68 if (utuns[i] == -1) { in skt_utunleak_main()
69 SKT_LOG("Expected: Failed on count %d errno %d\n", i + 1, errno); in skt_utunleak_main()
75 for (int i = 0; i < nchannels; i++) { in skt_utunleak_main() local
76 if (utuns[i] != -1) { in skt_utunleak_main()
77 error = close(utuns[i]); in skt_utunleak_main()
79 utuns[i] = -1; in skt_utunleak_main()
[all …]
/xnu-11417.121.6/osfmk/kern/
H A Dbits.h223 uint i; in bitmap_full() local
225 for (i = 0; i < bitmap_index(nbits - 1); i++) { in bitmap_full()
226 map[i] = ~((uint64_t)0); in bitmap_full()
229 uint nbits_filled = i * 64; in bitmap_full()
232 map[i] = mask(nbits - nbits_filled); in bitmap_full()
241 for (uint i = 0; i < BITMAP_LEN(nbits); i++) { in bitmap_is_empty() local
242 if (map[i]) { in bitmap_is_empty()
253 uint i; in bitmap_is_full() local
255 for (i = 0; i < bitmap_index(nbits - 1); i++) { in bitmap_is_full()
256 if (map[i] != ~((uint64_t)0)) { in bitmap_is_full()
[all …]
H A Dipc_host.c115 int i; in ipc_host_init() local
133 for (i = FIRST_EXCEPTION; i < EXC_TYPES_COUNT; i++) { in ipc_host_init()
134 realhost.exc_actions[i].port = IP_NULL; in ipc_host_init()
138 realhost.exc_actions[i].label = NULL; in ipc_host_init()
140 realhost.exc_actions[i].behavior = 0; in ipc_host_init()
141 realhost.exc_actions[i].flavor = 0; in ipc_host_init()
142 realhost.exc_actions[i].privileged = FALSE; in ipc_host_init()
496 int i; in host_set_exception_ports() local
520 for (i = FIRST_EXCEPTION; i < EXC_TYPES_COUNT; i++) { in host_set_exception_ports()
521 if (mac_exc_label(&host_priv->exc_actions[i]) == NULL) { in host_set_exception_ports()
[all …]
/xnu-11417.121.6/tools/lockstat/
H A Dlockstat.c94 unsigned int i; in main() local
112 for (i = 0; i < count; i++) { in main()
113 printf("%s\n", lockgroup_info[i].lockgroup_name); in main()
137 for (i = 0; i < count; i++) { in main()
138 if (strcmp(argv[1], lockgroup_info[i].lockgroup_name) == 0) { in main()
141 print_spin(i, lockgroup_info); in main()
143 print_mutex(i, lockgroup_info); in main()
145 print_rw(i, lockgroup_info); in main()
196 for (i = 0; i < count; i++) { in main()
197 if (strcmp(argv[1], lockgroup_info[i].lockgroup_name) == 0) { in main()
[all …]
/xnu-11417.121.6/osfmk/kperf/
H A Dkperf_kpc.c95 for (unsigned int i = 0; i < max; i++) { in kperf_kpc_config_log() local
96 uint32_t flag = (i == 0) ? DBG_FUNC_START : ((i == (max - 1)) ? DBG_FUNC_END : DBG_FUNC_NONE); in kperf_kpc_config_log()
98 kpcd->configv[0 + i * 4], kpcd->configv[1 + i * 4], in kperf_kpc_config_log()
99 kpcd->configv[2 + i * 4], kpcd->configv[3 + i * 4]); in kperf_kpc_config_log()
103 for (unsigned int i = 0; i < max; i++) { in kperf_kpc_config_log() local
104 uint32_t flag = (i == 0) ? DBG_FUNC_START : ((i == (max - 1)) ? DBG_FUNC_END : DBG_FUNC_NONE); in kperf_kpc_config_log()
106 kpcd->configv[i * 2] >> 32ULL, in kperf_kpc_config_log()
107 kpcd->configv[i * 2] & 0xffffffffULL, in kperf_kpc_config_log()
108 kpcd->configv[i * 2 + 1] >> 32ULL, in kperf_kpc_config_log()
109 kpcd->configv[i * 2 + 1] & 0xffffffffULL); in kperf_kpc_config_log()
[all …]
/xnu-11417.121.6/libkdd/
H A Dkcdtypes.c73 unsigned int i = 0; in kcdata_get_typedescription() local
76 setup_subtype_description(&subtypes[i++], (t), offsetof(s, f), name); \ in kcdata_get_typedescription()
80 setup_subtype_description(&subtypes[i++], (t), offsetof(s, f), _STR_VALUE(f)); \ in kcdata_get_typedescription()
84 #define _SUBTYPE_ARRAY(t, s, f, c) setup_subtype_array_description(&subtypes[i++], (t), offsetof(s,… in kcdata_get_typedescription()
85 #define _STRINGTYPE(f) setup_subtype_array_description(&subtypes[i++], KC_ST_CHAR, 0, UINT16_MAX, f) in kcdata_get_typedescription()
95 i = 0; in kcdata_get_typedescription()
96 setup_subtype_array_description(&subtypes[i++], KC_ST_CHAR, 0, KCDATA_DESC_MAXLEN, "desc"); in kcdata_get_typedescription()
97 …setup_subtype_array_description(&subtypes[i++], KC_ST_CHAR, KCDATA_DESC_MAXLEN, UINT16_MAX, "data"… in kcdata_get_typedescription()
98 setup_type_definition(retval, type_id, i, "string_desc"); in kcdata_get_typedescription()
103 i = 0; in kcdata_get_typedescription()
[all …]
/xnu-11417.121.6/osfmk/corecrypto/
H A Dccsha256_ltc_compress.c57 #define K(i) ((uint32_t)(ccsha512_K[i] >> 32)) argument
59 #define K(i) ccsha256_K[i] argument
72 #define set_W(i) (W[i] = cc_load32_be(buf + (4 * (i)))) argument
75 #define RND(a, b, c, d, e, f, g, h, i) \ argument
76 t0 = h + Sigma1(e) + Ch(e, f, g) + K(i) + W[i]; \
87 int i; in ccsha256_ltc_compress() local
93 for (i = 0; i < 16; i += 1) { in ccsha256_ltc_compress()
94 set_W(i); in ccsha256_ltc_compress()
98 for (; i < 64; i++) { in ccsha256_ltc_compress()
99 W[i] = Gamma1(W[i - 2]) + W[i - 7] + Gamma0(W[i - 15]) + W[i - 16]; in ccsha256_ltc_compress()
[all …]
H A Dcc_internal.h222 CC_ROL(uint32_t word, int i) in CC_ROL() argument
226 :"0" (word),"c" (i)); in CC_ROL()
231 CC_ROR(uint32_t word, int i) in CC_ROR() argument
235 :"0" (word),"c" (i)); in CC_ROR()
240 #define CC_ROLc(word, i) \ argument
244 :"0" (_word),"I" (i)); \
249 #define CC_RORc(word, i) \ argument
253 :"0" (_word),"I" (i)); \
262 CC_ROL(uint32_t word, int i) in CC_ROL() argument
264 return (word << (i & 31)) | (word >> ((32 - (i & 31)) & 31)); in CC_ROL()
[all …]
/xnu-11417.121.6/osfmk/i386/
H A Dmachine_check.c118 unsigned int i; in mca_cpu_init() local
139 for (i = 1; i < mca_error_bank_count; i++) { in mca_cpu_init()
140 wrmsr64(IA32_MCi_CTL(i), 0xFFFFFFFFFFFFFFFFULL); in mca_cpu_init()
144 for (i = 0; i < mca_error_bank_count; i++) { in mca_cpu_init()
145 wrmsr64(IA32_MCi_STATUS(i), 0ULL); in mca_cpu_init()
150 for (i = 0; i < mca_error_bank_count; i++) { in mca_cpu_init()
151 wrmsr64(IA32_MCi_CTL(i), 0xFFFFFFFFFFFFFFFFULL); in mca_cpu_init()
155 for (i = 0; i < mca_error_bank_count; i++) { in mca_cpu_init()
156 wrmsr64(IA32_MCi_STATUS(i), 0ULL); in mca_cpu_init()
207 unsigned int i; in mca_save_state() local
[all …]
H A Dmtrr.c131 int i; in mtrr_get_var_ranges() local
133 for (i = 0; i < count; i++) { in mtrr_get_var_ranges()
134 range[i].base = rdmsr64(MSR_IA32_MTRR_PHYSBASE(i)); in mtrr_get_var_ranges()
135 range[i].mask = rdmsr64(MSR_IA32_MTRR_PHYSMASK(i)); in mtrr_get_var_ranges()
138 if (range[i].mask & IA32_MTRR_PHYMASK_VALID) { in mtrr_get_var_ranges()
139 range[i].refcnt = 1; in mtrr_get_var_ranges()
141 range[i].refcnt = 0; in mtrr_get_var_ranges()
152 int i; in mtrr_set_var_ranges() local
154 for (i = 0; i < count; i++) { in mtrr_set_var_ranges()
155 wrmsr64(MSR_IA32_MTRR_PHYSBASE(i), range[i].base); in mtrr_set_var_ranges()
[all …]
/xnu-11417.121.6/libkern/c++/
H A DOSDictionary.cpp134 for (unsigned int i = 0; i < theCount; i++) { in initWithObjects() local
137 if (!newObject || !keys[i] || !setObject(keys[i], newObject)) { in initWithObjects()
169 for (unsigned int i = 0; i < theCount; i++) { in initWithObjects() local
210 for (unsigned int i = 0; i < count; i++) { in initWithDictionary() local
211 dictionary[i].key = dict->dictionary[i].key; in initWithDictionary()
212 dictionary[i].value = dict->dictionary[i].value; in initWithDictionary()
350 for (unsigned int i = 0; i < count; i++) { in flushCollection() local
351 dictionary[i].key.reset(); in flushCollection()
352 dictionary[i].value.reset(); in flushCollection()
361 unsigned int i; in setObject() local
[all …]
H A DOSOrderedSet.cpp190 unsigned int i; in flushCollection() local
194 for (i = 0; i < count; i++) { in flushCollection()
195 array[i].obj.reset(); in flushCollection()
205 unsigned int i; in setObject() local
223 for (i = count; i > index; i--) { in setObject()
224 array[i] = os::move(array[i - 1]); in setObject()
270 unsigned int i; in setObject() local
273 for (i = 0; in setObject()
274 (i < count) && (ORDER(array[i].obj.get(), anObject) >= 0); in setObject()
275 i++) { in setObject()
[all …]
H A DOSArray.cpp99 for (unsigned int i = 0; i < theCount; i++) { in initWithObjects() local
237 unsigned int i; in flushCollection() local
240 for (i = 0; i < count; i++) { in flushCollection()
241 array[i].reset(); in flushCollection()
261 unsigned int i; in setObject() local
275 for (i = count; i > index; i--) { in setObject()
276 array[i] = os::move(array[i - 1]); in setObject()
311 for (unsigned int i = 0; i < otherCount; i++) { in merge() local
312 const OSMetaClassBase *newObject = otherArray->getObject(i); in merge()
342 unsigned int i; in removeObject() local
[all …]
/xnu-11417.121.6/pexpert/gen/
H A Dkcformat.c81 kc_index_t i = kc_kind2index(type); in PE_set_kc_header() local
82 assert(!collection_base_pointers[i]); in PE_set_kc_header()
83 assert(!collection_mach_headers[i]); in PE_set_kc_header()
84 collection_mach_headers[i] = header; in PE_set_kc_header()
85 collection_slide[i] = slide; in PE_set_kc_header()
103 collection_base_pointers[i] = (void *)((uintptr_t)lowest_vmaddr + slide); in PE_set_kc_header()
104 assert((uint64_t)(uintptr_t)collection_base_pointers[i] != ~0ULL); in PE_set_kc_header()
114 kc_index_t i = kc_kind2index(type); in PE_reset_kc_header() local
115 collection_mach_headers[i] = 0; in PE_reset_kc_header()
116 collection_base_pointers[i] = 0; in PE_reset_kc_header()
[all …]
/xnu-11417.121.6/tests/counter/
H A Dcounter.c63 int64_t i, num_iterations; in background_scalable_counter_thread() local
65 for (i = 0; i < num_iterations; i++) { in background_scalable_counter_thread()
100 static int64_t kNumIterations = 100, i, expected_value = 0; variable
109 for (i = 0; i < kNumIterations; i++) {
110 scalable_counter_add(i);
111 expected_value += i;
113 for (i = 0; i < kNumIterations / 2; i++) {
114 scalable_counter_add(-i);
115 expected_value -= i;
127 for (size_t i = 0; i < kNumIterations; i++) { variable
[all …]
/xnu-11417.121.6/tools/tests/execperf/
H A Dprintexecinfo.c16 int i; in init() local
19 for (i = 0; argv[i]; i++) { in init()
20 printf("argv[%2d] = %p %.100s%s\n", i, argv[i], argv[i], strlen(argv[i]) > 100 ? "..." : ""); in init()
23 for (i = 0; envp[i]; i++) { in init()
24 printf("envp[%2d] = %p %.100s%s\n", i, envp[i], envp[i], strlen(envp[i]) > 100 ? "..." : ""); in init()
27 for (i = 0; appl[i]; i++) { in init()
28 printf("appl[%2d] = %p %.100s%s\n", i, appl[i], appl[i], strlen(appl[i]) > 100 ? "..." : ""); in init()
/xnu-11417.121.6/osfmk/x86_64/
H A Dmonotonic_x86_64.c153 for (uint32_t i = 0; i < kpc_fixed_count(); i++) { in mt_fixed_counter_set_ctrl_mask() local
154 mask |= ctrlbits << (4 * i); in mt_fixed_counter_set_ctrl_mask()
234 for (uint32_t i = 0; i < kpc_fixed_count(); i++) { in core_up() local
235 mt_core_set_snap(i, mtc->mtc_snaps[i]); in core_up()
260 for (unsigned int i = 0; i < real_ncpus; i++) { in mt_count_pmis() local
261 cpu_data_t *cpu = cpu_data_ptr[i]; in mt_count_pmis()
277 for (uint32_t i = 0; i < kpc_fixed_count(); i++) { in mt_check_for_pmi() local
278 if (status & CTR_FIX_POS(i)) { in mt_check_for_pmi()
279 uint64_t prior = CTR_MAX - mtc->mtc_snaps[i]; in mt_check_for_pmi()
283 uint64_t delta = mt_mtc_update_count(mtc, i); in mt_check_for_pmi()
[all …]
/xnu-11417.121.6/bsd/dev/dtrace/
H A Dblist.c341 int i; local
359 for (i = 1; i <= skip; i += next_skip) {
360 if (scan[i].bm_bighint == (daddr_t)-1) {
364 scan[i].u.bmu_bitmap = (u_daddr_t)-1;
365 scan[i].bm_bighint = BLIST_BMAP_RADIX;
367 scan[i].bm_bighint = radix;
368 scan[i].u.bmu_avail = radix;
375 for (i = 1; i <= skip; i += next_skip) {
376 if (count <= scan[i].bm_bighint) {
382 r = blst_leaf_alloc(&scan[i], blk, count);
[all …]

12345678910>>...41