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

/macosx-10.5.8/xnu-1228.15.4/libkern/c++/
H A DOSSerialize.cpp68 bzero((void *)data, capacity);
126 // add char, possibly extending our capacity
127 if (length >= capacity && length >=ensureCapacity(capacity+capacityIncrement))
157 capacity = (inCapacity) ? round_page_32(inCapacity) : round_page_32(1);
158 capacityIncrement = capacity;
163 kern_return_t rc = kmem_alloc(kernel_map, (vm_offset_t *)&data, capacity);
169 bzero((void *)data, capacity);
172 ACCUMSIZE(capacity);
190 unsigned int OSSerialize::getCapacity() const { return capacity; }
[all...]
H A DOSData.cpp64 if (data && (!inCapacity || capacity < inCapacity) ) {
66 kfree(data, capacity);
68 ACCUMSIZE(-capacity);
75 capacity = inCapacity;
106 capacity = EXTERNAL;
190 if (capacity != EXTERNAL && data && capacity) {
191 kfree(data, capacity);
192 ACCUMSIZE( -capacity );
198 unsigned int OSData::getCapacity() const { return capacity; }
[all...]
H A DOSDictionary.cpp79 capacity = inCapacity;
90 unsigned int capacity = theCount; local
99 capacity = theCapacity;
102 if (!initWithCapacity(capacity))
120 unsigned int capacity = theCount; local
129 capacity = theCapacity;
132 if (!initWithCapacity(capacity))
156 unsigned int capacity; local
161 capacity = dict->count;
167 capacity
183 withCapacity(unsigned int capacity) argument
195 withObjects(const OSObject *objects[], const OSSymbol *keys[], unsigned int count, unsigned int capacity) argument
210 withObjects(const OSObject *objects[], const OSString *keys[], unsigned int count, unsigned int capacity) argument
225 withDictionary(const OSDictionary *dict, unsigned int capacity) argument
[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))
104 OSSet *OSSet::withCapacity(unsigned int capacity) argument
108 if (me && !me->initWithCapacity(capacity)) {
118 unsigned int capacity)
122 if (me && !me->initWithObjects(objects, count, capacity)) {
131 unsigned int capacity)
135 if (me && !me->initWithArray(array, capacity)) {
144 unsigned int capacity)
116 withObjects(const OSObject *objects[], unsigned int count, unsigned int capacity) argument
130 withArray(const OSArray *array, unsigned int capacity) argument
143 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 DOSMetaClass.cpp86 unsigned int capacity; member in struct:StalledData
271 if (sStalled->count >= sStalled->capacity) {
273 int oldSize = sStalled->capacity * sizeof(OSMetaClass *);
284 sStalled->capacity += kKModCapacityIncrement;
376 sStalled->capacity = kKModCapacityIncrement;
477 ACCUMSIZE(-(sStalled->capacity * sizeof(OSMetaClass *)
480 sStalled->capacity * sizeof(OSMetaClass *));
/macosx-10.5.8/xnu-1228.15.4/libkern/libkern/c++/
H A DOSSet.h68 @abstract A static constructor function to create and initialize an instance of OSSet with a given capacity.
69 @param capacity The initial capacity of the collection. The capacity is the total number of objects that can be stored in the collection.
72 static OSSet *withCapacity(unsigned int capacity);
78 @param capacity The initial storage size of the collection. The capacity is the total number of objects that can be stored in the collection. This value must be equal to or larger than the count parameter.
83 unsigned int capacity = 0);
88 @param capacity The initial storage size of the collection. This value must be equal to or larger than the number of objects provided by the OSArray object passed as the first parameter.
92 unsigned int capacity
[all...]
H A DOSDictionary.h65 unsigned int capacity; member in class:OSDictionary
83 @param capacity The initial storage capacity of the dictionary object.
86 static OSDictionary *withCapacity(unsigned int capacity);
93 @param capacity The initial storage capacity of the dictionary object. If 0, the capacity will be set to the size of 'count', else this value must be greater or equal to 'count'.
99 unsigned int capacity = 0);
106 @param capacity The initial storage capacity o
[all...]
H A DOSArray.h56 unsigned int capacity; member in class:OSArray
75 @abstract A static constructor function to create and initialize a new instance of OSArray with a given capacity.
76 @param capacity The initial capacity (number of refernces) of the OSArray instance.
79 static OSArray *withCapacity(unsigned int capacity);
85 @param capacity The initial storage size of the OSArray instance. If 0, the capacity will be set to the size of count, else the capacity must be greater than or equal to count.
90 unsigned int capacity = 0);
93 @abstract A static constructor function to create and initialize an instance of OSArray of a given capacity an
[all...]
H A DOSOrderedSet.h65 unsigned int capacity; member in class:OSOrderedSet
87 @param capacity The initial storage size in number of objects of the set.
92 static OSOrderedSet *withCapacity(unsigned int capacity,
99 @param capacity The initial storage size in number of objects of the set.
104 virtual bool initWithCapacity(unsigned int capacity,
121 @abstract A member function to return the storage capacity of the collection.
122 @result Returns the total storage capacity of the set.
142 @param newCapacity The new size capacity for the collection.
143 @result Returns new capacity of the set when successful or the old capacity o
[all...]
H A DOSSerialize.h51 unsigned int capacity; // of container member in class:OSSerialize
65 static OSSerialize *withCapacity(unsigned int capacity);
H A DOSData.h49 unsigned int capacity; member in class:OSData
61 @abstract A static constructor function to create and initialize an empty instance of OSData with a given capacity.
62 @param inCapacity The initial capacity of the OSData object in bytes.
102 @abstract A member function to initialize an instance of OSData with a minimum capacity of at least the given size. If this function is called an an object that has been previously used then the length is set down to 0 and a new block of data is allocated if necessary to ensure the given capacity.
103 @param capacity The length of the allocated block of data.
106 virtual bool initWithCapacity(unsigned int capacity);
155 @abstract A member function which returns the capacity of the internal data buffer.
173 @abstract A member function which will expand the size of the collection to a given storage capacity.
174 @param newCapacity The new capacity fo
[all...]
/macosx-10.5.8/xnu-1228.15.4/iokit/Kernel/
H A DIOBufferMemoryDescriptor.cpp102 vm_size_t capacity,
107 return (initWithPhysicalMask(inTask, options, capacity, alignment, physicalMask));
113 mach_vm_size_t capacity,
124 if (!capacity)
128 _capacity = capacity;
210 address = IOMallocPhysical(capacity, physicalMask);
228 _buffer = (void *) IOKernelAllocateContiguous(capacity, alignment);
230 _buffer = IOMallocAligned(capacity, alignment);
232 _buffer = IOMalloc(capacity);
241 vm_size_t size = round_page_32(capacity);
100 initWithOptions( IOOptionBits options, vm_size_t capacity, vm_offset_t alignment, task_t inTask) argument
110 initWithPhysicalMask( task_t inTask, IOOptionBits options, mach_vm_size_t capacity, mach_vm_address_t alignment, mach_vm_address_t physicalMask) argument
347 inTaskWithOptions( task_t inTask, IOOptionBits options, vm_size_t capacity, vm_offset_t alignment) argument
372 inTaskWithPhysicalMask( task_t inTask, IOOptionBits options, mach_vm_size_t capacity, mach_vm_address_t physicalMask) argument
398 initWithOptions( IOOptionBits options, vm_size_t capacity, vm_offset_t alignment) argument
406 withOptions( IOOptionBits options, vm_size_t capacity, vm_offset_t alignment) argument
[all...]
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 DIOInterleavedMemoryDescriptor.cpp93 UInt32 capacity,
105 /* capacity */ capacity,
118 UInt32 capacity,
127 assert(capacity);
139 _descriptors = IONew(IOMemoryDescriptor *, capacity);
140 _descriptorOffsets = IONew(IOByteCount, capacity);
141 _descriptorLengths = IONew(IOByteCount, capacity);
146 _descriptorCapacity = capacity;
92 withCapacity( UInt32 capacity, IODirection direction ) argument
117 initWithCapacity( UInt32 capacity, IODirection direction ) argument
/macosx-10.5.8/xnu-1228.15.4/iokit/IOKit/
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.
97 IORangeScalar defaultAlignment = 0, UInt32 capacity = 0,
113 @discussion This method returns the current capacity of the free fragment list.
114 @result Returns the current capacity of free fragment list.
121 @discussion This method sets the number of extra fragments the free list will expand to when full. It defaults to the initial capacity
[all...]
H A DIOBufferMemoryDescriptor.h81 vm_size_t capacity,
88 mach_vm_size_t capacity,
150 * hold capacity bytes. The descriptor's length is initially set to the
151 * capacity.
154 vm_size_t capacity,
158 vm_size_t capacity,
171 @param capacity The number of bytes to allocate.
178 vm_size_t capacity,
189 @param capacity The number of bytes to allocate.
196 mach_vm_size_t capacity,
[all...]
H A DIOInterleavedMemoryDescriptor.h97 @param capacity The maximum number of IOMemoryDescriptors that may be subsequently added to this IOInterleavedMemoryDescriptor.
101 static IOInterleavedMemoryDescriptor * withCapacity( UInt32 capacity,
107 @param capacity The maximum number of IOMemoryDescriptors that may be subsequently added to this IOInterleavedMemoryDescriptor.
111 virtual bool initWithCapacity( UInt32 capacity,
116 @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.
/macosx-10.5.8/xnu-1228.15.4/libsa/
H A Ddgraph.c67 dgraph->capacity = (5); // pulled from a hat
72 dgraph->capacity * sizeof(dgraph_entry_t *));
596 if (dgraph->length == dgraph->capacity) {
597 unsigned int old_capacity = dgraph->capacity;
600 dgraph->capacity *= 2;
601 newgraph = (dgraph_entry_t **)malloc(dgraph->capacity *
H A Ddgraph.h114 unsigned int capacity; member in struct:__anon623
H A Dkld_patch.c297 static Boolean DataEnsureCapacity(DataRef data, unsigned long capacity) argument
300 if (capacity > data->fCapacity) {
303 capacity += kDataCapacityIncrement - 1;
304 capacity &= ~(kDataCapacityIncrement - 1);
305 newData = (char *) realloc(data->fData, capacity);
309 bzero(newData + data->fCapacity, capacity - data->fCapacity);
311 data->fCapacity = capacity;
349 static DataRef DataCreate(unsigned long capacity) argument
354 if (!capacity)
357 data->fCapacity = capacity
[all...]

Completed in 151 milliseconds