/external/webrtc/rtc_base/ |
D | copy_on_write_buffer.cc | 83 void CopyOnWriteBuffer::EnsureCapacity(size_t new_capacity) { in EnsureCapacity() argument 86 if (new_capacity > 0) { in EnsureCapacity() 87 buffer_ = new RefCountedObject<Buffer>(0, new_capacity); in EnsureCapacity() 93 } else if (new_capacity <= capacity()) { in EnsureCapacity() 97 UnshareAndEnsureCapacity(new_capacity); in EnsureCapacity() 115 void CopyOnWriteBuffer::UnshareAndEnsureCapacity(size_t new_capacity) { in UnshareAndEnsureCapacity() argument 116 if (buffer_->HasOneRef() && new_capacity <= capacity()) { in UnshareAndEnsureCapacity() 121 new_capacity); in UnshareAndEnsureCapacity()
|
/external/perfetto/include/perfetto/ext/base/ |
D | circular_queue.h | 250 void Grow(size_t new_capacity = 0) { 253 new_capacity = new_capacity ? new_capacity : capacity_ * 2; 254 PERFETTO_CHECK((new_capacity & (new_capacity - 1)) == 0); // Must be pow2. 258 PERFETTO_CHECK(new_capacity > capacity_); 259 size_t malloc_size = new_capacity * sizeof(T); 260 PERFETTO_CHECK(malloc_size > new_capacity); 276 capacity_ = new_capacity;
|
D | container_annotations.h | 45 new_capacity) \ argument 47 ANNOTATE_NEW_BUFFER(buffer, new_capacity, buffer_size); 54 new_capacity) argument
|
/external/marisa-trie/lib/marisa/ |
D | keyset.cc | 125 const std::size_t new_capacity = in append_base_block() local 128 new (std::nothrow) scoped_array<char>[new_capacity]); in append_base_block() 134 base_blocks_capacity_ = new_capacity; in append_base_block() 147 const std::size_t new_capacity = in append_extra_block() local 150 new (std::nothrow) scoped_array<char>[new_capacity]); in append_extra_block() 156 extra_blocks_capacity_ = new_capacity; in append_extra_block() 165 const std::size_t new_capacity = in append_key_block() local 168 new (std::nothrow) scoped_array<Key>[new_capacity]); in append_key_block() 174 key_blocks_capacity_ = new_capacity; in append_key_block()
|
/external/mesa3d/src/util/ |
D | string_buffer.c | 34 uint32_t new_capacity = str->capacity * 2; in ensure_capacity() local 35 while (needed_capacity > new_capacity) in ensure_capacity() 36 new_capacity *= 2; in ensure_capacity() 38 str->buf = reralloc_array_size(str, str->buf, sizeof(char), new_capacity); in ensure_capacity() 42 str->capacity = new_capacity; in ensure_capacity()
|
/external/marisa-trie/lib/marisa/grimoire/vector/ |
D | vector.h | 88 std::size_t new_capacity = capacity; in reserve() local 91 new_capacity = max_size(); in reserve() 93 new_capacity = capacity_ * 2; in reserve() 96 realloc(new_capacity); in reserve() 226 void realloc(std::size_t new_capacity) { in realloc() argument 227 MARISA_DEBUG_IF(new_capacity > max_size(), MARISA_SIZE_ERROR); in realloc() 230 new (std::nothrow) char[sizeof(T) * new_capacity]); in realloc() 244 capacity_ = new_capacity; in realloc()
|
/external/libchrome/base/task/sequence_manager/ |
D | lazily_deallocated_deque.h | 169 size_t new_capacity = max_size_ + 1; in MaybeShrinkQueue() local 170 if (new_capacity < kMinimumRingSize) in MaybeShrinkQueue() 171 new_capacity = kMinimumRingSize; in MaybeShrinkQueue() 179 if (new_capacity + kReclaimThreshold >= capacity()) in MaybeShrinkQueue() 182 SetCapacity(new_capacity); in MaybeShrinkQueue() 187 void SetCapacity(size_t new_capacity) { in SetCapacity() argument 188 std::unique_ptr<Ring> new_ring = std::make_unique<Ring>(new_capacity); in SetCapacity() 190 DCHECK_GE(new_capacity, size_ + 1); in SetCapacity()
|
/external/vixl/src/ |
D | code-buffer-vixl.cc | 172 void CodeBuffer::Grow(size_t new_capacity) { in Grow() argument 174 VIXL_ASSERT(new_capacity > capacity_); in Grow() 177 buffer_ = static_cast<byte*>(realloc(buffer_, new_capacity)); in Grow() 187 mremap(buffer_, capacity_, new_capacity, MREMAP_MAYMOVE)); in Grow() 195 capacity_ = new_capacity; in Grow()
|
/external/swiftshader/third_party/subzero/src/ |
D | IceAssembler.cpp | 117 intptr_t new_capacity = std::min(old_capacity * 2, old_capacity + OneMB); in extendCapacity() local 118 if (new_capacity < old_capacity) { in extendCapacity() 124 uintptr_t new_contents = NewContents(Assemblr, new_capacity); in extendCapacity() 134 Limit = computeLimit(new_contents, new_capacity); in extendCapacity() 137 assert(capacity() == new_capacity); in extendCapacity()
|
/external/igt-gpu-tools/lib/ |
D | igt_stats.c | 71 unsigned int new_capacity; in get_new_capacity() local 74 new_capacity = (need >> 6) + (need < 9 ? 3 : 6); in get_new_capacity() 75 new_capacity += need; in get_new_capacity() 77 return new_capacity; in get_new_capacity() 84 unsigned int new_capacity; in igt_stats_ensure_capacity() local 89 new_capacity = get_new_capacity(new_n_values); in igt_stats_ensure_capacity() 91 sizeof(*stats->values_u64) * new_capacity); in igt_stats_ensure_capacity() 94 stats->capacity = new_capacity; in igt_stats_ensure_capacity()
|
/external/angle/third_party/abseil-cpp/absl/container/internal/ |
D | inlined_vector.h | 526 size_type new_capacity = ComputeCapacity(GetInlinedCapacity(), n); in InitFrom() local 527 dst = AllocatorTraits::allocate(*GetAllocPtr(), new_capacity); in InitFrom() 528 SetAllocatedData(dst, new_capacity); in InitFrom() 553 size_type new_capacity = ComputeCapacity(GetInlinedCapacity(), new_size); variable 554 construct_data = AllocatorTraits::allocate(*GetAllocPtr(), new_capacity); 555 SetAllocatedData(construct_data, new_capacity); 582 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 583 construct_loop = {allocation_tx.Allocate(new_capacity), new_size}; 636 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 637 pointer new_data = allocation_tx.Allocate(new_capacity); [all …]
|
/external/libchrome/base/ |
D | pickle.cc | 336 void Pickle::Resize(size_t new_capacity) { in Resize() argument 338 capacity_after_header_ = bits::Align(new_capacity, kPayloadUnit); in Resize() 413 size_t new_capacity = capacity_after_header_ * 2; in ClaimUninitializedBytesInternal() local 415 if (new_capacity > kPickleHeapAlign) in ClaimUninitializedBytesInternal() 416 new_capacity = bits::Align(new_capacity, kPickleHeapAlign) - kPayloadUnit; in ClaimUninitializedBytesInternal() 417 Resize(std::max(new_capacity, new_size)); in ClaimUninitializedBytesInternal()
|
/external/abseil-cpp/absl/container/internal/ |
D | inlined_vector.h | 482 size_type new_capacity = ComputeCapacity(GetInlinedCapacity(), new_size); variable 483 construct_data = AllocatorTraits::allocate(*GetAllocPtr(), new_capacity); 484 SetAllocatedData(construct_data, new_capacity); 511 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 512 construct_loop = {allocation_tx.Allocate(new_capacity), new_size}; 557 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 558 pointer new_data = allocation_tx.Allocate(new_capacity); 609 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 610 pointer new_data = allocation_tx.Allocate(new_capacity); 695 size_type new_capacity = NextCapacity(storage_view.capacity); variable [all …]
|
/external/openscreen/third_party/abseil/src/absl/container/internal/ |
D | inlined_vector.h | 485 size_type new_capacity = ComputeCapacity(GetInlinedCapacity(), new_size); variable 486 construct_data = AllocatorTraits::allocate(*GetAllocPtr(), new_capacity); 487 SetAllocatedData(construct_data, new_capacity); 514 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 515 construct_loop = {allocation_tx.Allocate(new_capacity), new_size}; 568 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 569 pointer new_data = allocation_tx.Allocate(new_capacity); 606 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 607 pointer new_data = allocation_tx.Allocate(new_capacity); 704 size_type new_capacity = NextCapacity(storage_view.capacity); variable [all …]
|
/external/rust/crates/grpcio-sys/grpc/third_party/abseil-cpp/absl/container/internal/ |
D | inlined_vector.h | 482 size_type new_capacity = ComputeCapacity(GetInlinedCapacity(), new_size); variable 483 construct_data = AllocatorTraits::allocate(*GetAllocPtr(), new_capacity); 484 SetAllocatedData(construct_data, new_capacity); 511 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 512 construct_loop = {allocation_tx.Allocate(new_capacity), new_size}; 557 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 558 pointer new_data = allocation_tx.Allocate(new_capacity); 609 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 610 pointer new_data = allocation_tx.Allocate(new_capacity); 695 size_type new_capacity = NextCapacity(storage_view.capacity); variable [all …]
|
/external/libtextclassifier/abseil-cpp/absl/container/internal/ |
D | inlined_vector.h | 482 size_type new_capacity = ComputeCapacity(GetInlinedCapacity(), new_size); variable 483 construct_data = AllocatorTraits::allocate(*GetAllocPtr(), new_capacity); 484 SetAllocatedData(construct_data, new_capacity); 511 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 512 construct_loop = {allocation_tx.Allocate(new_capacity), new_size}; 557 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 558 pointer new_data = allocation_tx.Allocate(new_capacity); 609 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 610 pointer new_data = allocation_tx.Allocate(new_capacity); 695 size_type new_capacity = NextCapacity(storage_view.capacity); variable [all …]
|
/external/webrtc/third_party/abseil-cpp/absl/container/internal/ |
D | inlined_vector.h | 482 size_type new_capacity = ComputeCapacity(GetInlinedCapacity(), new_size); variable 483 construct_data = AllocatorTraits::allocate(*GetAllocPtr(), new_capacity); 484 SetAllocatedData(construct_data, new_capacity); 511 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 512 construct_loop = {allocation_tx.Allocate(new_capacity), new_size}; 557 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 558 pointer new_data = allocation_tx.Allocate(new_capacity); 609 size_type new_capacity = ComputeCapacity(storage_view.capacity, new_size); variable 610 pointer new_data = allocation_tx.Allocate(new_capacity); 695 size_type new_capacity = NextCapacity(storage_view.capacity); variable [all …]
|
/external/mesa3d/src/freedreno/vulkan/ |
D | tu_cs.c | 98 uint32_t new_capacity = MAX2(4, 2 * cs->bo_capacity); in tu_cs_add_bo() local 100 realloc(cs->bos, new_capacity * sizeof(struct tu_bo *)); in tu_cs_add_bo() 104 cs->bo_capacity = new_capacity; in tu_cs_add_bo() 145 uint32_t new_capacity = MAX2(4, cs->entry_capacity * 2); in tu_cs_reserve_entry() local 147 realloc(cs->entries, new_capacity * sizeof(struct tu_cs_entry)); in tu_cs_reserve_entry() 151 cs->entry_capacity = new_capacity; in tu_cs_reserve_entry()
|
/external/perfetto/src/protozero/ |
D | proto_decoder.cc | 228 uint32_t new_capacity = capacity_ * 2; in ExpandHeapStorage() local 229 PERFETTO_CHECK(new_capacity > size_); in ExpandHeapStorage() 230 std::unique_ptr<Field[]> new_storage(new Field[new_capacity]); in ExpandHeapStorage() 238 capacity_ = new_capacity; in ExpandHeapStorage()
|
/external/flac/src/libFLAC/ |
D | bitwriter.c | 104 uint32_t new_capacity; in bitwriter_grow_() local 111 …new_capacity = bw->words + ((bw->bits + bits_to_add + FLAC__BITS_PER_WORD - 1) / FLAC__BITS_PER_WO… in bitwriter_grow_() 116 if(bw->capacity >= new_capacity) in bitwriter_grow_() 120 if((new_capacity - bw->capacity) % FLAC__BITWRITER_DEFAULT_INCREMENT) in bitwriter_grow_() 121 …new_capacity += FLAC__BITWRITER_DEFAULT_INCREMENT - ((new_capacity - bw->capacity) % FLAC__BITWRIT… in bitwriter_grow_() 123 FLAC__ASSERT(0 == (new_capacity - bw->capacity) % FLAC__BITWRITER_DEFAULT_INCREMENT); in bitwriter_grow_() 124 FLAC__ASSERT(new_capacity > bw->capacity); in bitwriter_grow_() 125 …FLAC__ASSERT(new_capacity >= bw->words + ((bw->bits + bits_to_add + FLAC__BITS_PER_WORD - 1) / FLA… in bitwriter_grow_() 127 new_buffer = safe_realloc_mul_2op_(bw->buffer, sizeof(bwword), /*times*/new_capacity); in bitwriter_grow_() 131 bw->capacity = new_capacity; in bitwriter_grow_()
|
/external/XNNPACK/src/ |
D | subgraph.c | 68 const size_t new_capacity = max(min(capacity * 2, capacity + 512), capacity + 64); in xnn_subgraph_new_internal_value() local 69 assert(new_capacity >= size + 1); in xnn_subgraph_new_internal_value() 70 values = xnn_reallocate_memory(values, new_capacity * sizeof(struct xnn_value)); in xnn_subgraph_new_internal_value() 77 memset(values + size, 0, (new_capacity - size) * sizeof(struct xnn_value)); in xnn_subgraph_new_internal_value() 78 subgraph->num_reserved_values = new_capacity; in xnn_subgraph_new_internal_value() 106 const size_t new_capacity = max(min(capacity * 2, capacity + 512), capacity + 64); in xnn_subgraph_new_node() local 107 assert(new_capacity >= size + 1); in xnn_subgraph_new_node() 108 nodes = xnn_reallocate_memory(nodes, new_capacity * sizeof(struct xnn_node)); in xnn_subgraph_new_node() 115 memset(nodes + size, 0, (new_capacity - size) * sizeof(struct xnn_node)); in xnn_subgraph_new_node() 116 subgraph->num_reserved_nodes = new_capacity; in xnn_subgraph_new_node()
|
/external/protobuf/src/google/protobuf/stubs/ |
D | bytestream.cc | 124 size_t new_capacity = std::max(capacity_ + amount, (3 * capacity_) / 2); in Expand() local 125 char* bigger = new char[new_capacity]; in Expand() 129 capacity_ = new_capacity; in Expand()
|
/external/libchrome/base/containers/ |
D | circular_deque.h | 585 void reserve(size_type new_capacity) { in reserve() argument 586 if (new_capacity > capacity()) in reserve() 587 SetCapacityTo(new_capacity); in reserve() 940 void SetCapacityTo(size_t new_capacity) { in SetCapacityTo() argument 943 VectorBuffer new_buffer(new_capacity + 1); in SetCapacityTo() 958 size_t new_capacity = in ExpandCapacityIfNecessary() local 960 SetCapacityTo(new_capacity); in ExpandCapacityIfNecessary() 976 size_t new_capacity = in ShrinkCapacityIfNecessary() local 978 if (new_capacity < capacity()) { in ShrinkCapacityIfNecessary() 980 SetCapacityTo(new_capacity); in ShrinkCapacityIfNecessary()
|
/external/compiler-rt/lib/sanitizer_common/ |
D | sanitizer_common.h | 519 uptr new_capacity = RoundUpToPowerOfTwo(size_ + 1); in push_back() local 520 Resize(new_capacity); in push_back() 562 void Resize(uptr new_capacity) { in Resize() argument 563 CHECK_GT(new_capacity, 0); in Resize() 564 CHECK_LE(size_, new_capacity); in Resize() 565 T *new_data = (T *)MmapOrDie(new_capacity * sizeof(T), in Resize() 571 capacity_ = new_capacity; in Resize()
|
/external/libaom/libaom/common/ |
D | obudec.c | 197 const size_t new_capacity = capacity + growth_amount; in obudec_grow_buffer() local 200 if (new_capacity > AOM_MAX_ALLOCABLE_MEMORY) { in obudec_grow_buffer() 206 uint8_t *new_buffer = (uint8_t *)realloc(*obu_buffer, new_capacity); in obudec_grow_buffer() 213 *obu_buffer_capacity = new_capacity; in obudec_grow_buffer()
|