Searched refs:capacity (Results 1 - 21 of 21) sorted by relevance

/xnu-2422.115.4/libkern/c++/
H A DOSSerialize.cpp68 bzero((void *)data, capacity);
127 // add char, possibly extending our capacity
128 if (length >= capacity && length >=ensureCapacity(capacity+capacityIncrement))
158 capacity = (inCapacity) ? round_page_32(inCapacity) : round_page_32(1);
159 capacityIncrement = capacity;
164 kern_return_t rc = kmem_alloc(kernel_map, (vm_offset_t *)&data, capacity);
170 bzero((void *)data, capacity);
173 ACCUMSIZE(capacity);
191 unsigned int OSSerialize::getCapacity() const { return capacity; }
[all...]
H A DOSData.cpp70 if (data && (!inCapacity || capacity < inCapacity) ) {
72 kfree(data, capacity);
74 ACCUMSIZE(-capacity);
81 capacity = inCapacity;
112 capacity = EXTERNAL;
196 if (capacity != EXTERNAL && data && capacity) {
197 kfree(data, capacity);
198 ACCUMSIZE( -capacity );
199 } else if (capacity
[all...]
H A DOSArray.cpp74 capacity = inCapacity;
122 OSArray *OSArray::withCapacity(unsigned int capacity) argument
126 if (me && !me->initWithCapacity(capacity)) {
136 unsigned int capacity)
140 if (me && !me->initWithObjects(objects, count, capacity)) {
149 unsigned int capacity)
153 if (me && !me->initWithArray(array, capacity)) {
169 kfree(array, sizeof(const OSMetaClassBase *) * capacity);
170 ACCUMSIZE( -(sizeof(const OSMetaClassBase *) * capacity) );
178 unsigned int OSArray::getCapacity() const { return capacity; }
134 withObjects(const OSObject *objects[], unsigned int count, unsigned int capacity) argument
148 withArray(const OSArray *array, unsigned int capacity) argument
[all...]
H A DOSSet.cpp66 unsigned int capacity = inCount; local
72 capacity = inCapacity;
75 if (!inObjects || !initWithCapacity(capacity))
105 OSSet *OSSet::withCapacity(unsigned int capacity) argument
109 if (me && !me->initWithCapacity(capacity)) {
119 unsigned int capacity)
123 if (me && !me->initWithObjects(objects, count, capacity)) {
132 unsigned int capacity)
136 if (me && !me->initWithArray(array, capacity)) {
145 unsigned int capacity)
117 withObjects(const OSObject *objects[], unsigned int count, unsigned int capacity) argument
131 withArray(const OSArray *array, unsigned int capacity) argument
144 withSet(const OSSet *set, unsigned int capacity) argument
[all...]
H A DOSOrderedSet.cpp77 capacity = inCapacity;
89 withCapacity(unsigned int capacity, argument
94 if (me && !me->initWithCapacity(capacity, ordering, orderingRef)) {
108 kfree(array, sizeof(_Element) * capacity);
109 ACCUMSIZE( -(sizeof(_Element) * capacity) );
116 unsigned int OSOrderedSet::getCapacity() const { return capacity; }
130 if (newCapacity <= capacity)
131 return capacity;
140 oldSize = sizeof(_Element) * capacity;
145 bzero(&newArray[capacity], newSiz
[all...]
H A DOSDictionary.cpp81 capacity = inCapacity;
194 OSDictionary *OSDictionary::withCapacity(unsigned int capacity) argument
198 if (me && !me->initWithCapacity(capacity)) {
209 unsigned int capacity)
213 if (me && !me->initWithObjects(objects, keys, count, capacity)) {
224 unsigned int capacity)
228 if (me && !me->initWithObjects(objects, keys, count, capacity)) {
237 unsigned int capacity)
241 if (me && !me->initWithDictionary(dict, capacity)) {
254 kfree(dictionary, capacity * sizeo
206 withObjects(const OSObject *objects[], const OSSymbol *keys[], unsigned int count, unsigned int capacity) argument
221 withObjects(const OSObject *objects[], const OSString *keys[], unsigned int count, unsigned int capacity) argument
236 withDictionary(const OSDictionary *dict, unsigned int capacity) argument
[all...]
H A DOSMetaClass.cpp108 unsigned int capacity; member in struct:StalledData
413 if (sStalled->count >= sStalled->capacity) {
415 int oldSize = sStalled->capacity * sizeof(OSMetaClass *);
426 sStalled->capacity += kKModCapacityIncrement;
549 sStalled->capacity = kKModCapacityIncrement;
714 ACCUMSIZE(-(sStalled->capacity * sizeof(OSMetaClass *) +
716 kfree(sStalled->classes, sStalled->capacity * sizeof(OSMetaClass *));
/xnu-2422.115.4/libkern/libkern/c++/
H A DOSSet.h114 * @param capacity The initial storage capacity of the new set object.
122 * <code>capacity</code> must be nonzero.
125 * for which the initial capacity is a hard limit).
127 static OSSet * withCapacity(unsigned int capacity);
139 * @param capacity The initial storage capacity of the new set object.
152 * If <code>capacity</code> is nonzero,
156 * for which the initial capacity is a hard limit).
164 unsigned int capacity
[all...]
H A DOSArray.h97 unsigned int capacity; member in class:OSArray
118 * @param capacity The initial storage capacity of the array object.
125 * <code>capacity</code> must be nonzero.
128 * for which the initial capacity is a hard limit).
130 static OSArray * withCapacity(unsigned int capacity);
141 * @param capacity The initial storage capacity of the array object.
152 * If <code>capacity</code> is nonzero,
156 * for which the initial capacity i
[all...]
H A DOSDictionary.h124 unsigned int capacity; member in class:OSDictionary
145 * @param capacity The initial storage capacity of the new dictionary object.
153 * <code>capacity</code> must be nonzero.
156 * for which the initial capacity is a hard limit).
158 static OSDictionary * withCapacity(unsigned int capacity);
172 * @param capacity The initial storage capacity of the new dictionary object.
185 * If <code>capacity</code> is nonzero,
191 * for which the initial capacity i
[all...]
H A DOSData.h81 unsigned int capacity; member in class:OSData
97 * @param capacity The initial capacity of the OSData object in bytes.
104 * <code>capacity</code> may be zero.
108 * for which a nonzero initial capacity is a hard limit).
110 static OSData * withCapacity(unsigned int capacity);
131 * for which a nonzero initial capacity is a hard limit).
188 * for which a nonzero initial capacity is a hard limit).
213 * for which a nonzero initial capacity is a hard limit).
227 * @param capacity Th
[all...]
H A DOSOrderedSet.h128 unsigned int capacity; member in class:OSOrderedSet
150 * @param capacity The initial storage capacity
162 * <code>capacity</code> must be nonzero.
166 * for which the initial capacity is a hard limit).
184 unsigned int capacity,
195 * @param capacity The initial storage capacity
212 * <code>capacity</code> must be nonzero.
215 * for which the initial capacity i
[all...]
H A DOSSerialize.h86 unsigned int capacity; // of container member in class:OSSerialize
106 * @param capacity The initial size of the XML buffer.
116 static OSSerialize * withCapacity(unsigned int capacity);
/xnu-2422.115.4/iokit/IOKit/
H A DIOBufferMemoryDescriptor.h87 vm_size_t capacity,
96 mach_vm_size_t capacity,
131 * hold capacity bytes. The descriptor's length is initially set to the
132 * capacity.
136 vm_size_t capacity,
141 vm_size_t capacity,
158 @param capacity The number of bytes to allocate.
165 vm_size_t capacity,
180 @param capacity The number of bytes to allocate.
187 mach_vm_size_t capacity,
[all...]
H A DIOInterleavedMemoryDescriptor.h58 @param capacity The maximum number of IOMemoryDescriptors that may be subsequently added to this IOInterleavedMemoryDescriptor.
62 static IOInterleavedMemoryDescriptor * withCapacity( IOByteCount capacity,
68 @param capacity The maximum number of IOMemoryDescriptors that may be subsequently added to this IOInterleavedMemoryDescriptor.
72 virtual bool initWithCapacity( IOByteCount capacity,
77 @discussion Clears each IOMemoryDescriptor by completing (if needed) and releasing. The IOInterleavedMemoryDescriptor is then reset and may accept new descriptors up to the capacity specified when it was created.
H A DIORangeAllocator.h56 UInt32 capacity; member in class:IORangeAllocator
75 @discussion This method initializes an IORangeAllocator and optionally sets the free list to contain one fragment, from zero to an endOfRange parameter. The capacity in terms of free fragments and locking options are set for the instance.
78 @param capacity Sets the initial size of the free list in number of noncontiguous fragments. This value is also used for the capacityIncrement.
84 UInt32 capacity,
89 @discussion This method allocates and initializes an IORangeAllocator and optionally sets the free list to contain one fragment, from zero to an endOfRange parameter. The capacity in terms of free fragments and locking options are set for the instance.
92 @param capacity Sets the initial size of the free list in number of non-contiguous fragments. This value is also used for the capacityIncrement.
98 UInt32 capacity = 0,
114 @discussion This method returns the current capacity of the free fragment list.
115 @result Returns the current capacity of free fragment list.
122 @discussion This method sets the number of extra fragments the free list will expand to when full. It defaults to the initial capacity
[all...]
/xnu-2422.115.4/iokit/Kernel/
H A DIOBufferMemoryDescriptor.cpp100 vm_size_t capacity,
105 return (initWithPhysicalMask(inTask, options, capacity, alignment, physicalMask));
112 mach_vm_size_t capacity,
125 if (!capacity)
129 _capacity = capacity;
165 capacity = round_page(capacity);
260 capacity = round_page(capacity);
263 capacity, highestMas
98 initWithOptions( IOOptionBits options, vm_size_t capacity, vm_offset_t alignment, task_t inTask) argument
109 initWithPhysicalMask( task_t inTask, IOOptionBits options, mach_vm_size_t capacity, mach_vm_address_t alignment, mach_vm_address_t physicalMask) argument
375 inTaskWithOptions( task_t inTask, IOOptionBits options, vm_size_t capacity, vm_offset_t alignment) argument
390 inTaskWithPhysicalMask( task_t inTask, IOOptionBits options, mach_vm_size_t capacity, mach_vm_address_t physicalMask) argument
407 initWithOptions( IOOptionBits options, vm_size_t capacity, vm_offset_t alignment) argument
416 withOptions( IOOptionBits options, vm_size_t capacity, vm_offset_t alignment) argument
[all...]
H A DIOInterleavedMemoryDescriptor.cpp36 IOByteCount capacity,
48 /* capacity */ capacity,
59 IOByteCount capacity,
68 assert(capacity);
83 _descriptors = IONew(IOMemoryDescriptor *, capacity);
84 _descriptorOffsets = IONew(IOByteCount, capacity);
85 _descriptorLengths = IONew(IOByteCount, capacity);
90 _descriptorCapacity = capacity;
35 withCapacity( IOByteCount capacity, IODirection direction ) argument
58 initWithCapacity( IOByteCount capacity, IODirection direction ) argument
H A DIORangeAllocator.cpp78 capacity = 0;
97 UInt32 capacity,
104 capacity, options )) {
115 IODelete( elements, IORangeAllocatorElement, capacity );
127 return( capacity );
142 if( ((numElements == capacity) && capacityIncrement)
145 newCapacity = capacity + capacityIncrement;
158 IODelete( elements, IORangeAllocatorElement, capacity );
162 capacity = newCapacity;
94 withRange( IORangeScalar endOfRange, IORangeScalar defaultAlignment, UInt32 capacity, IOOptionBits options ) argument
H A DIOPMrootDomain.cpp3455 int i, j, count, capacity; local
3467 if (!array || ((capacity = array->getCount()) == 0))
3471 chosen = OSArray::withCapacity(capacity);
3475 entries = IONew(PMSettingCallEntry, capacity);
3478 memset(entries, 0, sizeof(PMSettingCallEntry) * capacity);
3482 for (i = 0, j = 0; i<capacity; i++)
3519 if (entries) IODelete(entries, PMSettingCallEntry, capacity);
/xnu-2422.115.4/libkern/kxld/
H A Dkxld_array.c43 static KXLDArrayPool * pool_create(size_t capacity);
44 static void pool_destroy(KXLDArrayPool *pool, size_t capacity);
176 pool_create(size_t capacity) argument
183 pool->buffer = kxld_page_alloc(capacity);
185 bzero(pool->buffer, capacity);
191 if (pool) pool_destroy(pool, capacity);
198 pool_destroy(KXLDArrayPool *pool, size_t capacity) argument
201 if (pool->buffer) kxld_page_free(pool->buffer, capacity);

Completed in 75 milliseconds