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

/system/core/toolbox/
H A Ddynarray.c8 a->count = a->capacity = 0;
16 int old_cap = a->capacity;
42 a->capacity = new_cap;
48 if (a->count >= a->capacity)
59 a->count = a->capacity = 0;
H A Ddynarray.h9 int capacity; member in struct:__anon234
/system/core/libutils/tests/
H A DBasicHashtable_test.cpp159 ALOGD("hashtable %p, size=%u, capacity=%u, bucketCount=%u",
160 &h, h.size(), h.capacity(), h.bucketCount());
182 EXPECT_EQ(3U, h.capacity());
191 EXPECT_EQ(77U, h.capacity());
200 EXPECT_EQ(46U, h.capacity()); // must be one less than bucketCount because loadFactor == 1.0f
209 EXPECT_EQ(46U, h.capacity()); // must be one less than bucketCount because loadFactor == 1.0f
315 EXPECT_EQ(3U, h.capacity());
327 EXPECT_EQ(3U, h.capacity());
342 EXPECT_EQ(3U, h.capacity());
360 EXPECT_EQ(3U, h.capacity());
[all...]
/system/extras/tests/sdcard/
H A Dstopwatch.h84 // Create a stop watch. Default capacity == 2 * interval_nb
87 // @param capacity Hint about the number of sampless that will be
89 // to size the internal storage, when the capacity
91 StopWatch(const char *name, size_t capacity = kUseDefaultCapacity);
H A Dstopwatch.cpp54 StopWatch::StopWatch(const char *name, size_t capacity) argument
55 : mName(strdup(name)), mNum(0), mData(NULL), mDataLen(0), mCapacity(capacity * 2),
145 // Normally we should have enough capacity but if we have to
148 // a capacity when building the StopWatch.
154 fprintf(stderr, "# Increased capacity to %d for %s. Measurement affected.\n",
/system/core/libpixelflinger/codeflinger/tinyutils/
H A DVectorImpl.cpp93 sb = SharedBuffer::alloc(capacity() * mItemSize);
104 size_t VectorImpl::capacity() const function in class:android::tinyutils::VectorImpl
222 ALOG_ASSERT(index<capacity(),
223 "[%p] itemLocation: index=%d, capacity=%d, count=%d",
224 this, (int)index, (int)capacity(), (int)mCount);
234 ALOG_ASSERT(index<capacity(),
235 "[%p] editItemLocation: index=%d, capacity=%d, count=%d",
236 this, (int)index, (int)capacity(), (int)mCount);
246 size_t current_capacity = capacity();
249 // we can't reduce the capacity
[all...]
H A DKeyedVector.h57 inline size_t capacity() const { return mVector.capacity(); } function in class:android::tinyutils::KeyedVector
58 //! setst the capacity. capacity can never be reduced less than size()
H A DVectorImpl.h66 size_t capacity() const;
H A DSortedVector.h66 inline size_t capacity() const { return VectorImpl::capacity(); } function in class:android::tinyutils::SortedVector
67 //! setst the capacity. capacity can never be reduced less than size()
H A DVector.h74 inline size_t capacity() const { return VectorImpl::capacity(); } function in class:android::tinyutils::Vector
75 //! setst the capacity. capacity can never be reduced less than size()
/system/core/libutils/
H A DVectorImpl.cpp90 sb = SharedBuffer::alloc(capacity() * mItemSize);
101 size_t VectorImpl::capacity() const function in class:android::VectorImpl
298 ALOG_ASSERT(index<capacity(),
299 "[%p] editItemLocation: index=%d, capacity=%d, count=%d",
300 this, (int)index, (int)capacity(), (int)mCount);
302 if (index < capacity()) {
313 ALOG_ASSERT(index<capacity(),
314 "[%p] itemLocation: index=%d, capacity=%d, count=%d",
315 this, (int)index, (int)capacity(), (int)mCount);
317 if (index < capacity()) {
[all...]
/system/core/include/utils/
H A DKeyedVector.h58 inline size_t capacity() const { return mVector.capacity(); } function in class:android::KeyedVector
59 //! sets the capacity. capacity can never be reduced less than size()
H A DVectorImpl.h65 size_t capacity() const;
H A DSortedVector.h69 inline size_t capacity() const { return VectorImpl::capacity(); } function in class:android::SortedVector
70 //! sets the capacity. capacity can never be reduced less than size()
H A DVector.h79 inline size_t capacity() const { return VectorImpl::capacity(); } function in class:android::Vector
80 //! sets the capacity. capacity can never be reduced less than size()
H A DBasicHashtable.h115 // number of entries and returns its effective capacity.
173 /* Creates a hashtable with the specified minimum initial capacity.
176 * minimumInitialCapacity: The minimum initial capacity for the hashtable.
208 /* Returns the capacity of the hashtable, which is the number of elements that can
211 inline size_t capacity() const { function in class:android::BasicHashtable
287 * If the entry will not fit, then the hashtable's capacity is increased and
312 * Grows the hashtable to at least the specified minimum capacity or the
320 * Rehashing is the only way to change the capacity or load factor of the
322 * hashtable by choosing a minimum capacity that is smaller than the current
323 * capacity (suc
[all...]
H A DLruCache.h151 rehash(mTable->capacity() * 2);
/system/core/healthd/
H A Dhealthd_mode_charger.cpp104 /* current capacity being animated */
105 int capacity; member in struct:animation
167 .capacity = 0,
325 if (batt_anim->capacity < 0 || batt_anim->num_frames == 0)
396 /* find first frame given current capacity */
407 batt_anim->capacity = batt_prop->batteryLevel;
420 if (batt_anim->num_frames == 0 || batt_anim->capacity < 0) {

Completed in 281 milliseconds