Home
last modified time | relevance | path

Searched refs:capacity_ (Results 1 – 25 of 45) sorted by relevance

12

/external/v8/src/compiler/
Dvalue-numbering-reducer.cc47 capacity_(0), in ValueNumberingReducer()
61 DCHECK(capacity_ == 0); in Reduce()
63 capacity_ = kInitialCapacity; in Reduce()
71 DCHECK(size_ < capacity_); in Reduce()
72 DCHECK(size_ + size_ / 4 < capacity_); in Reduce()
74 const size_t mask = capacity_ - 1; in Reduce()
75 size_t dead = capacity_; in Reduce()
80 if (dead != capacity_) { in Reduce()
89 if (size_ + size_ / 4 >= capacity_) Grow(); in Reduce()
91 DCHECK(size_ + size_ / 4 < capacity_); in Reduce()
[all …]
/external/protobuf/src/google/protobuf/stubs/
Dbytestream.cc67 : outbuf_(outbuf), capacity_(capacity), size_(0), overflowed_(false) { in CheckedArrayByteSink()
71 size_t available = capacity_ - size_; in Append()
78 GOOGLE_DCHECK(!(outbuf_ <= bytes && bytes < (outbuf_ + capacity_))) in Append()
86 : capacity_(estimated_size), in GrowingArrayByteSink()
96 size_t available = capacity_ - size_; in Append()
100 GOOGLE_DCHECK(!(buf_ <= bytes && bytes < (buf_ + capacity_))) in Append()
117 size_ = capacity_ = 0; in GetBuffer()
122 size_t new_capacity = std::max(capacity_ + amount, (3 * capacity_) / 2); in Expand()
127 capacity_ = new_capacity; in Expand()
133 if (capacity_ > 256 && size_ < (3 * capacity_) / 4) { in ShrinkToFit()
[all …]
/external/vixl/src/
Dcode-buffer-vixl.cc48 capacity_(capacity) { in CodeBuffer()
49 if (capacity_ == 0) { in CodeBuffer()
53 buffer_ = reinterpret_cast<byte*>(malloc(capacity_)); in CodeBuffer()
78 capacity_(capacity) { in CodeBuffer()
89 munmap(buffer_, capacity_); in ~CodeBuffer()
99 int ret = mprotect(buffer_, capacity_, PROT_READ | PROT_EXEC); in SetExecutable()
107 int ret = mprotect(buffer_, capacity_, PROT_READ | PROT_WRITE); in SetWritable()
153 memset(buffer_, 0, capacity_); in Reset()
163 VIXL_ASSERT(new_capacity > capacity_); in Grow()
176 mremap(buffer_, capacity_, new_capacity, MREMAP_MAYMOVE)); in Grow()
[all …]
Dcode-buffer-vixl.h98 VIXL_ASSERT((cursor_ >= buffer_) && (cursor_ <= (buffer_ + capacity_))); in GetRemainingBytes()
99 return (buffer_ + capacity_) - cursor_; in GetRemainingBytes()
106 VIXL_ASSERT((cursor_ >= buffer_) && (cursor_ <= (buffer_ + capacity_))); in GetSizeInBytes()
141 size_t GetCapacity() const { return capacity_; } in GetCapacity()
160 if (is_full) Grow(capacity_ * 2 + amount); in EnsureSpaceFor()
181 size_t capacity_; variable
/external/webrtc/webrtc/base/
Dbuffer.h96 return capacity_; in capacity()
108 capacity_ = buf.capacity_;
165 if (capacity <= capacity_) in EnsureCapacity()
170 capacity_ = capacity; in EnsureCapacity()
187 capacity_ = 0; in Clear()
195 swap(a.capacity_, b.capacity_); in swap()
205 return (data_ || capacity_ == 0) && capacity_ >= size_; in IsConsistent()
215 capacity_ = 0; in OnMovedFrom()
219 capacity_ = 0; in OnMovedFrom()
224 size_t capacity_; variable
Dcryptstring.h75 capacity_ = 32; in FormatCryptString()
109 if (capacity_ >= n) { in EnsureStorage()
113 size_t old_capacity = capacity_; in EnsureStorage()
117 capacity_ *= 2; in EnsureStorage()
118 if (capacity_ >= n) in EnsureStorage()
122 storage_ = new char[capacity_]; in EnsureStorage()
137 if (capacity_) { in ~FormatCryptString()
139 for (size_t i = 1; i < capacity_; i++) { in ~FormatCryptString()
147 size_t capacity_; variable
Dbuffer.cc18 Buffer::Buffer() : size_(0), capacity_(0), data_(nullptr) { in Buffer()
27 capacity_(buf.capacity()), in Buffer()
38 capacity_(std::max(size, capacity)), in Buffer()
39 data_(new uint8_t[capacity_]) { in Buffer()
Dbufferqueue.cc16 : capacity_(capacity), default_size_(default_size) { in BufferQueue()
41 bool was_writable = queue_.size() < capacity_; in ReadFront()
60 if (queue_.size() == capacity_) { in WriteBack()
/external/webrtc/webrtc/modules/video_coding/
Dtimestamp_map.cc21 capacity_(capacity), in VCMTimestampMap()
30 next_add_idx_ = (next_add_idx_ + 1) % capacity_; in Add()
34 next_pop_idx_ = (next_pop_idx_ + 1) % capacity_; in Add()
44 next_pop_idx_ = (next_pop_idx_ + 1) % capacity_; in Pop()
53 next_pop_idx_ = (next_pop_idx_ + 1) % capacity_; in Pop()
/external/libtextclassifier/util/utf8/
Dunicodetext.cc31 capacity_ = size; in PointTo()
44 if (!ours_ || new_size > capacity_) reserve(new_size); in resize()
54 if (capacity_ >= new_capacity && ours_) return; in reserve()
57 capacity_ = std::max(new_capacity, (3 * capacity_) / 2 + 20); in reserve()
58 char* new_data = new char[capacity_]; in reserve()
79 size_ = capacity_ = 0; in clear()
/external/icu/icu4c/source/i18n/
Dcollationkeys.h35 : buffer_(dest), capacity_(destCapacity), in SortKeyByteSink()
46 if (appended_ < capacity_ || Resize(1, appended_)) { in Append()
64 return ignore_ + capacity_ - appended_; in GetRemainingCapacity()
67 UBool Overflowed() const { return appended_ > capacity_; } in Overflowed()
77 capacity_ = 0; in SetNotOk()
81 int32_t capacity_; variable
/external/v8/src/base/
Dhashmap.h79 uint32_t capacity() const { return capacity_; } in capacity()
94 uint32_t capacity_; variable
100 Entry* map_end() const { return map_ + capacity_; } in map_end()
192 DCHECK(occupancy_ < capacity_); in Remove()
211 Entry* r = map_ + (q->hash & (capacity_ - 1)); in Remove()
232 for (size_t i = 0; i < capacity_; ++i) { in Clear()
265 DCHECK(base::bits::IsPowerOfTwo32(capacity_)); in Probe()
266 size_t i = hash & (capacity_ - 1); in Probe()
267 DCHECK(i < capacity_); in Probe()
269 DCHECK(occupancy_ < capacity_); // Guarantees loop termination. in Probe()
[all …]
/external/v8/src/zone/
Dzone-chunk-list.h105 uint32_t capacity_ = 0; member
115 chunk->capacity_ = capacity; in NewChunk()
155 if (position_ >= current_->capacity_) { in MoveNext()
164 position_ = current_ ? current_->capacity_ - 1 : 0; in MoveRNext()
216 DCHECK_LE(list->back_->position_, list->back_->capacity_); in End()
217 if (list->back_->position_ == list->back_->capacity_) { in End()
266 list->back_->previous_, list->back_->previous_->capacity_ - 1); in Begin()
308 DCHECK_LE(back_->position_, back_->capacity_); in push_back()
309 if (back_->position_ == back_->capacity_) { in push_back()
311 Chunk* chunk = NewChunk(Min(back_->capacity_ << 1, kMaxChunkCapacity)); in push_back()
[all …]
/external/v8/src/
Dlist-inl.h19 if (length_ < capacity_) { in Add()
36 if (capacity_ < result_length) Resize(result_length, alloc); in AddAll()
56 DCHECK(length_ >= capacity_); in ResizeAddInternal()
59 int new_capacity = 1 + 2 * capacity_; in ResizeAddInternal()
75 capacity_ = new_capacity; in Resize()
132 std::swap(capacity_, list->capacity_); in Swap()
149 capacity_ = 0; in Clear()
163 if (length_ < capacity_ / 4) { in Trim()
164 Resize(capacity_ / 2, alloc); in Trim()
Dstring-stream.h107 capacity_(kInitialCapacity), in allocator_()
172 unsigned capacity_; variable
176 bool full() const { return (capacity_ - length_) == 1; } in full()
177 int space() const { return capacity_ - length_; } in space()
Dstring-stream.cc37 DCHECK(length_ < capacity_); in Put()
41 if (length_ == capacity_ - 2) { in Put()
42 unsigned new_capacity = capacity_; in Put()
44 if (new_capacity > capacity_) { in Put()
45 capacity_ = new_capacity; in Put()
49 DCHECK(capacity_ >= 5); in Put()
50 length_ = capacity_ - 1; // Indicate fullness of the stream. in Put()
Dlist.h81 INLINE(int capacity() const) { return capacity_; } in INLINE()
173 capacity_ = capacity;
179 int capacity_; variable
/external/webrtc/webrtc/modules/audio_coding/neteq/
Daudio_vector.cc24 capacity_(kDefaultInitialSize) { in AudioVector()
30 capacity_(initial_size) { in AudioVector()
43 assert(copy_to->capacity_ >= Size()); in CopyTo()
115 position = std::min(capacity_, position); in InsertZerosAt()
182 if (capacity_ < n) { in Reserve()
186 capacity_ = n; in Reserve()
/external/icu/icu4c/source/common/
Dbytestream.cpp32 : outbuf_(outbuf), capacity_(capacity < 0 ? 0 : capacity), in CheckedArrayByteSink()
49 int32_t available = capacity_ - size_; in Append()
69 int32_t available = capacity_ - size_; in GetAppendBuffer()
/external/v8/src/crankshaft/
Dunique.h150 UniqueSet() : size_(0), capacity_(0), array_(NULL) { } in UniqueSet()
154 : size_(0), capacity_(capacity), in UniqueSet()
161 : size_(1), capacity_(1), array_(zone->NewArray<Unique<T> >(1)) { in UniqueSet()
340 uint16_t capacity_; variable
346 if (capacity_ < size) { in Grow()
347 int new_capacity = 2 * capacity_ + size; in Grow()
353 capacity_ = new_capacity; in Grow()
/external/v8/src/heap/
Dspaces.h1247 return capacity_ < size ? 0 : capacity_ - size; in Available()
1354 size_t capacity_; variable
1544 capacity_ = 0; in Clear()
1549 void ClearSize() { size_ = capacity_; } in ClearSize()
1552 size_t Capacity() { return capacity_; } in Capacity()
1561 DCHECK_GE(capacity_ + bytes, capacity_); in ExpandSpace()
1562 capacity_ += bytes; in ExpandSpace()
1564 if (capacity_ > max_capacity_) { in ExpandSpace()
1565 max_capacity_ = capacity_; in ExpandSpace()
1573 DCHECK_GE(capacity_, bytes); in ShrinkSpace()
[all …]
/external/webrtc/webrtc/modules/remote_bitrate_estimator/test/
Dbwe.h73 explicit LinkedSet(int capacity) : capacity_(capacity) {} in LinkedSet()
92 size_t capacity() const { return capacity_; } in capacity()
106 size_t capacity_; variable
/external/compiler-rt/lib/sanitizer_common/
Dsanitizer_common.h501 capacity_ = Max(initial_capacity, (uptr)1); in Initialize()
503 data_ = (T *)MmapOrDie(capacity_ * sizeof(T), "InternalMmapVectorNoCtor"); in Initialize()
506 UnmapOrDie(data_, capacity_ * sizeof(T)); in Destroy()
517 CHECK_LE(size_, capacity_); in push_back()
518 if (size_ == capacity_) { in push_back()
542 return capacity_; in capacity()
570 UnmapOrDie(old_data, capacity_ * sizeof(T)); in Resize()
571 capacity_ = new_capacity; in Resize()
575 uptr capacity_; variable
/external/fmtlib/fmt/
Dstring.h32 this->capacity_ = size; in grow()
43 this->capacity_ = this->size_ = 0; in move_to()
/external/v8/src/interpreter/
Dconstant-array-builder.h89 inline size_t capacity() const { return capacity_; } in capacity()
97 const size_t capacity_; member

12