Searched refs:array (Results 1 - 25 of 60) sorted by relevance

123

/xnu-2422.115.4/libkern/kxld/
H A Dkxld_array.c42 static kern_return_t array_init(KXLDArray *array, size_t itemsize, u_int nitems);
45 static u_int reinit_pools(KXLDArray *array, u_int nitems);
50 kxld_array_init(KXLDArray *array, size_t itemsize, u_int nitems) argument
58 check(array);
61 kxld_array_reset(array);
68 /* If the array has some pools, we need to see if there is enough space in
69 * those pools to accomodate the requested size array. If there isn't
71 * out the array structure. This will cause a new pool of sufficient size
75 if (array->npools) {
76 /* Update the array'
138 array_init(KXLDArray *array, size_t itemsize, u_int nitems) argument
252 kxld_array_reset(KXLDArray *array) argument
267 kxld_array_clear(KXLDArray *array) argument
282 kxld_array_deinit(KXLDArray *array) argument
298 kxld_array_get_item(const KXLDArray *array, u_int idx) argument
323 kxld_array_get_slot(const KXLDArray *array, u_int idx) argument
348 kxld_array_get_index(const KXLDArray *array, const void *item, u_int *_idx) argument
386 kxld_array_resize(KXLDArray *array, u_int nitems) argument
417 reinit_pools(KXLDArray *array, u_int nitems) argument
442 kxld_array_remove(KXLDArray *array, u_int idx) argument
[all...]
H A Dkxld_array.h40 * This is a resizeable array implementation designed primarily to maximize
41 * memory reuse. The array should only be allocated once, but it can be
43 * reallocates only if it needs to grow the internal array, such that memory
46 * one large array in the init function.
48 * A technique commonly used in kxld is to make an array of objects that
50 * the individual objects contained in an array should be cleared at the end of
52 * memory they have already allocated. The array that contains them should not
55 * allocated space of the array and clean up all potential instances contained
57 * requirements that must be met, and guarantees that the array implementation
61 * - A newly allocated, uninitialized array objec
[all...]
H A Dkxld_util.h79 #define const_array_len(array) sizeof(array) / sizeof(*array)
/xnu-2422.115.4/libkern/kxld/tests/
H A Dkxld_array_test.c45 KXLDArray array; local
53 bzero(&array, sizeof(array));
61 rval = kxld_array_init(&array, sizeof(u_int), titems);
63 assert(array.nitems == titems);
67 item = kxld_array_get_item(&array, idx);
69 assert(item == kxld_array_get_slot(&array, idx));
72 item = kxld_array_get_item(&array, idx);
74 assert(item == kxld_array_get_slot(&array, idx));
77 item = kxld_array_get_item(&array, id
[all...]
/xnu-2422.115.4/osfmk/mach_debug/
H A Dmach_debug_types.defs68 type zone_name_array_t = array[] of zone_name_t; /* deprecated */
71 type zone_info_array_t = array[] of zone_info_t; /* deprecated */
74 type mach_zone_name_array_t = array[] of mach_zone_name_t;
77 type mach_zone_info_array_t = array[] of mach_zone_info_t;
80 type task_zone_info_array_t = array[] of task_zone_info_t;
83 type hash_info_bucket_array_t = array[] of hash_info_bucket_t;
88 type ipc_info_name_array_t = array[] of ipc_info_name_t;
91 type ipc_info_tree_name_array_t = array[] of ipc_info_tree_name_t;
98 type vm_info_object_array_t = ^array[] of vm_info_object_t;
100 type page_address_array_t = ^array[] o
[all...]
/xnu-2422.115.4/iokit/Kernel/
H A DIODeviceMemory.cpp57 OSArray * array; local
61 array = OSArray::withCapacity( count );
62 if( 0 == array )
69 array->setObject( range);
72 array->release();
73 array = 0;
78 return( array );
H A DIOCatalogue.cpp90 OSArray * array; local
96 array = OSDynamicCast(OSArray, OSUnserialize(gIOKernelConfigTables, &errorString));
97 if (!array && errorString) {
107 assert( array && gIOClassKey && gIOProbeScoreKey
112 rc = gIOCatalogue->init(array);
114 array->release();
201 OSArray * array; local
215 array = (OSArray *) personalities->getObject(meta->getClassNameSymbol());
216 if (array) for (idx = 0; (nextTable = (OSDictionary *) array
242 OSArray * array; local
339 OSArray * array = arrayForPersonality(personality); local
398 OSArray * array; local
581 OSArray * array; local
706 OSArray * array; local
769 OSArray * array; local
[all...]
H A DIORangeAllocator.cpp334 OSArray * array = OSArray::withCapacity( numElements * 2 ); local
339 if( !array)
347 array->setObject(num);
352 array->setObject(num);
359 ret = array->serialize(s);
360 array->release();
/xnu-2422.115.4/osfmk/default_pager/
H A Ddefault_pager_types.defs42 type default_pager_object_array_t = array[] of default_pager_object_t;
45 type default_pager_page_array_t = array[] of default_pager_page_t;
48 type backing_store_info_t = array[*:20] of integer_t;
H A Ddefault_pager_object.defs76 type vnode_ptr_t = array[1] of int;
92 array[] of mach_port_move_send_t,
/xnu-2422.115.4/libkern/c++/
H A DOSArray.cpp69 array = (const OSMetaClassBase **) kalloc(size);
70 if (!array)
77 bzero(array, size);
105 array[count++] = newObject;
118 return initWithObjects((const OSObject **) anArray->array,
148 OSArray *OSArray::withArray(const OSArray *array, argument
153 if (me && !me->initWithArray(array, capacity)) {
168 if (array) {
169 kfree(array, sizeof(const OSMetaClassBase *) * capacity);
206 bcopy(array, newArra
[all...]
H A DOSOrderedSet.cpp72 array = (_Element *) kalloc(size);
73 if (!array)
82 bzero(array, size);
107 if (array) {
108 kfree(array, sizeof(_Element) * capacity);
144 bcopy(array, newArray, oldSize);
146 kfree(array, oldSize);
147 array = newArray;
161 array[i].obj->taggedRelease(OSTypeID(OSCollection));
185 array[
[all...]
H A DOSSet.cpp95 return initWithObjects((const OSObject **) inArray->array,
131 OSSet *OSSet::withArray(const OSArray *array, argument
136 if (me && !me->initWithArray(array, capacity)) {
207 bool OSSet::merge(const OSArray * array) argument
212 for (int i = 0; (anObject = array->getObject(i)); i++) {
387 OSObject *obj = EXT_CAST(members->array[i]);
/xnu-2422.115.4/osfmk/mach/
H A Dmach_types.defs77 type memory_object_fault_info_t = array[16] of integer_t;
85 type upl_page_info_array_t = array[*:256] of upl_page_info_t;
103 * this array may have to be increased. (See mach/port.h)
106 type mach_port_info_t = array[*:17] of integer_t;
120 type mach_msg_trailer_info_t = array[*:68] of char;
162 /* thread_state_t: This inline array can hold
169 type thread_state_t = array[*:THREAD_STATE_MAX] of natural_t;
171 type task_array_t = ^array[] of task_t;
172 type thread_array_t = ^array[] of thread_t;
173 type thread_act_array_t = ^array[] o
[all...]
H A Dprof.defs124 type sample_array_t = array[*:1024] of unsigned;
H A Dstd_types.defs96 type pointer_t = ^array[] of MACH_MSG_TYPE_BYTE
101 type mach_port_array_t = array[] of mach_port_t;
104 type mach_port_name_array_t = array[] of mach_port_name_t;
109 type mach_port_type_array_t = array[] of mach_port_type_t;
H A Dclock_types.defs61 type clock_attr_t = array[*:1] of int;
H A Dexc.defs74 type exception_data_t = array[*:2] of integer_t;
/xnu-2422.115.4/osfmk/lockd/
H A Dlockd_mach.defs39 type sock_storage = array [32] of uint32_t;
40 type xcred = array [19] of uint32_t;
41 type nfs_handle = array [64] of uint8_t;
/xnu-2422.115.4/osfmk/device/
H A Ddevice_types.defs79 type dev_status_t = array[*:1024] of int;
81 type io_buf_ptr_t = ^array[] of MACH_MSG_TYPE_INTEGER_8;
82 type io_buf_ptr_inband_t= array[*:128] of char;
84 type filter_array_t = array[*:64] of filter_t;
H A Ddevice.defs95 type io_struct_inband_t = array[*:4096] of char;
96 type io_buf_ptr_t = ^array[] of MACH_MSG_TYPE_INTEGER_8;
102 type io_scalar_inband_t = array[*:16] of int;
104 type io_async_ref_t = array[*:8] of natural_t;
105 type io_scalar_inband64_t = array[*:16] of io_user_scalar_t;
106 type io_async_ref64_t = array[*:8] of io_user_reference_t;
110 type io_scalar_inband_t = array[*:16] of io_user_scalar_t;
111 type io_async_ref_t = array[*:8] of io_user_reference_t;
112 type io_scalar_inband64_t = array[*:16] of io_user_scalar_t;
113 type io_async_ref64_t = array[*
[all...]
/xnu-2422.115.4/bsd/netinet/
H A Ddhcp_options.c87 * A dynamically growable array of pointers.
102 if (list->array)
103 my_free(list->array);
111 if (list == NULL || list->array == NULL)
120 if (list->array == NULL)
123 return (list->array[i]);
131 if (list->array == NULL) {
135 list->array = my_malloc(sizeof(*list->array) * list->size);
139 list->array
[all...]
/xnu-2422.115.4/libkern/libkern/c++/
H A DOSSet.h137 * @param objects A C array of OSMetaClassBase-derived objects.
174 * @param array An array whose objects will be stored in the new OSSet.
177 * in <code>array</code>;
179 * the number of objects in <code>array</code>.
182 * the objects of <code>array</code>,
187 * Each distinct object in <code>array</code> is added to the new set.
189 * <code>array</code> must be non-<code>NULL</code>.
196 * The objects in <code>array</code> are retained for storage in the new set,
200 const OSArray * array,
[all...]
H A DOSArray.h58 * Storage and access are by array index.
95 const OSMetaClassBase ** array; member in class:OSArray
118 * @param capacity The initial storage capacity of the array object.
126 * The new array will grow as needed to accommodate more objects
139 * @param objects A C array of OSObject-derived instances.
140 * @param count The number of objects to be placed into the array.
141 * @param capacity The initial storage capacity of the array object.
154 * The new array will grow as needed to accommodate more objects
168 * Creates and initializes an OSArray populated with the contents of another array.
170 * @param array A
[all...]
/xnu-2422.115.4/osfmk/UserNotification/
H A DUNDTypes.defs49 type xmlData = ^ array [] of MACH_MSG_TYPE_BYTE

Completed in 179 milliseconds

123