Home
last modified time | relevance | path

Searched refs:new_size (Results 1 – 25 of 254) sorted by relevance

1234567891011

/external/eigen/Eigen/src/StlSupport/
DStdVector.h80 void resize(size_type new_size) in resize() argument
81 { resize(new_size, T()); } in resize()
85 void resize(size_type new_size, const value_type& x) in resize() argument
87 if (vector_base::size() < new_size) in resize()
88 vector_base::_Insert_n(vector_base::end(), new_size - vector_base::size(), x); in resize()
89 else if (new_size < vector_base::size()) in resize()
90 vector_base::erase(vector_base::begin() + new_size, vector_base::end()); in resize()
97 void insert(const_iterator position, size_type new_size, const value_type& x) in insert() argument
98 { vector_base::insert(position, new_size, x); } in insert()
102 void resize(size_type new_size, const value_type& x) in resize() argument
[all …]
DStdDeque.h80 void resize(size_type new_size) in resize() argument
81 { resize(new_size, T()); } in resize()
85 void resize(size_type new_size, const value_type& x) in resize() argument
87 if (deque_base::size() < new_size) in resize()
88 deque_base::_Insert_n(deque_base::end(), new_size - deque_base::size(), x); in resize()
89 else if (new_size < deque_base::size()) in resize()
90 deque_base::erase(deque_base::begin() + new_size, deque_base::end()); in resize()
99 void insert(const_iterator position, size_type new_size, const value_type& x) in insert() argument
100 { deque_base::insert(position, new_size, x); } in insert()
103 void resize(size_type new_size, const value_type& x) in resize() argument
[all …]
DStdList.h80 void resize(size_type new_size) in resize() argument
81 { resize(new_size, T()); } in resize()
83 void resize(size_type new_size, const value_type& x) in resize() argument
85 if (list_base::size() < new_size) in resize()
86 list_base::insert(list_base::end(), new_size - list_base::size(), x); in resize()
88 while (new_size < list_base::size()) list_base::pop_back(); in resize()
98 void insert(const_iterator position, size_type new_size, const value_type& x) in insert() argument
99 { list_base::insert(position, new_size, x); } in insert()
/external/protobuf/src/google/protobuf/
Drepeated_field.cc47 int new_size = current_size_ + extend_amount; in InternalExtend() local
48 if (total_size_ >= new_size) { in InternalExtend()
55 new_size = std::max(kMinRepeatedFieldAllocationSize, in InternalExtend()
56 std::max(total_size_ * 2, new_size)); in InternalExtend()
57 GOOGLE_CHECK_LE(new_size, in InternalExtend()
63 new char[kRepHeaderSize + sizeof(old_rep->elements[0]) * new_size]); in InternalExtend()
67 kRepHeaderSize + sizeof(old_rep->elements[0]) * new_size)); in InternalExtend()
69 total_size_ = new_size; in InternalExtend()
83 void RepeatedPtrFieldBase::Reserve(int new_size) { in Reserve() argument
84 if (new_size > current_size_) { in Reserve()
[all …]
/external/ltp/testcases/kernel/tracing/ftrace_test/ftrace_stress/
Dftrace_buffer_size_kb.sh30 new_size=1
33 echo $new_size > "$TRACING_PATH"/buffer_size_kb
34 new_size=$(( $new_size + $step ))
40 new_size=$(( $new_size - $step ))
41 echo $new_size > "$TRACING_PATH"/buffer_size_kb
/external/python/cpython2/Lib/ctypes/test/
Dtest_varsize_struct.py17 new_size = sizeof(X) + sizeof(c_int) * 1
18 resize(x, new_size)
19 self.assertEqual(sizeof(x), new_size)
23 new_size = sizeof(X) + sizeof(c_int) * 9
24 resize(x, new_size)
25 self.assertEqual(sizeof(x), new_size)
29 new_size = sizeof(X) + sizeof(c_int) * 1
30 resize(x, new_size)
31 self.assertEqual(sizeof(x), new_size)
/external/ltp/testcases/kernel/syscalls/mremap/
Dmremap05.c53 size_t new_size; /* in pages */ member
76 .new_size = 1,
85 .new_size = 1,
94 .new_size = 1,
103 .new_size = 1,
110 .new_size = 1,
140 t->ret = mremap(t->old_address, t->old_size, t->new_size, t->flags, in test_mremap()
165 t->new_address = get_test_area(t->new_size * pagesize, 1); in setup0()
171 t->new_address = get_test_area((t->new_size + 1) * pagesize, 1) + 1; in setup1()
183 t->new_address = get_test_area(t->new_size * pagesize, 1); in setup3()
[all …]
/external/syslinux/gpxe/src/arch/i386/interface/pcbios/
Dmemtop_umalloc.c137 static userptr_t memtop_urealloc ( userptr_t ptr, size_t new_size ) { in memtop_urealloc() argument
161 extmem.used = ( new_size > 0 ); in memtop_urealloc()
166 new = userptr_add ( ptr, - ( new_size - extmem.size ) ); in memtop_urealloc()
168 new_size += align; in memtop_urealloc()
174 user_to_phys ( new, new_size )); in memtop_urealloc()
175 memmove_user ( new, 0, ptr, 0, ( ( extmem.size < new_size ) ? in memtop_urealloc()
176 extmem.size : new_size ) ); in memtop_urealloc()
177 extmem.size = new_size; in memtop_urealloc()
181 if ( new_size > extmem.size ) { in memtop_urealloc()
199 return ( new_size ? new : UNOWHERE ); in memtop_urealloc()
/external/syslinux/gpxe/src/interface/efi/
Defi_umalloc.c44 static userptr_t efi_urealloc ( userptr_t old_ptr, size_t new_size ) { in efi_urealloc() argument
55 if ( new_size ) { in efi_urealloc()
56 new_pages = ( EFI_SIZE_TO_PAGES ( new_size ) + 1 ); in efi_urealloc()
68 &new_size, sizeof ( new_size ) ); in efi_urealloc()
82 ( (old_size < new_size) ? old_size : new_size )); in efi_urealloc()
/external/e2fsprogs/resize/
Dmain.c258 blk64_t new_size = 0; in main() local
495 new_size = min_size; in main()
497 new_size = parse_num_blocks2(new_size_str, in main()
499 if (new_size == 0) { in main()
505 new_size = max_size; in main()
508 new_size &= ~((sys_page_size / blocksize)-1); in main()
512 new_size = ext2fs_blocks_count(fs->super); in main()
516 if (new_size == (1ULL << 32)) in main()
517 new_size--; in main()
518 else if (new_size > (1ULL << 32)) { in main()
[all …]
Donline.c52 blk64_t *new_size, int flags EXT2FS_ATTR((unused))) in online_resize_fs() argument
89 if (*new_size < ext2fs_blocks_count(sb)) { in online_resize_fs()
99 ext2fs_div64_ceil(*new_size - in online_resize_fs()
127 (*new_size > MAX_32_NUM)) { in online_resize_fs()
143 } else if (ioctl(fd, EXT4_IOC_RESIZE_FS, new_size)) { in online_resize_fs()
214 retval = adjust_fs_info(new_fs, fs, 0, *new_size); in online_resize_fs()
221 fs->device_name, *new_size, fs->blocksize / 1024); in online_resize_fs()
225 if (size > *new_size) in online_resize_fs()
226 size = *new_size; in online_resize_fs()
/external/mesa3d/src/gallium/auxiliary/util/
Du_bitmask.c93 unsigned new_size; in util_bitmask_resize() local
104 new_size = bm->size; in util_bitmask_resize()
105 while(new_size < minimum_size) { in util_bitmask_resize()
106 new_size *= 2; in util_bitmask_resize()
108 if(new_size < bm->size) in util_bitmask_resize()
111 assert(new_size); in util_bitmask_resize()
112 assert(new_size % UTIL_BITMASK_BITS_PER_WORD == 0); in util_bitmask_resize()
116 new_size / UTIL_BITMASK_BITS_PER_BYTE); in util_bitmask_resize()
122 (new_size - bm->size)/UTIL_BITMASK_BITS_PER_BYTE); in util_bitmask_resize()
124 bm->size = new_size; in util_bitmask_resize()
Du_handle_table.c103 unsigned new_size; in handle_table_resize() local
109 new_size = ht->size; in handle_table_resize()
110 while(!(new_size > minimum_size)) in handle_table_resize()
111 new_size *= 2; in handle_table_resize()
112 assert(new_size); in handle_table_resize()
116 new_size*sizeof(void *)); in handle_table_resize()
120 memset(new_objects + ht->size, 0, (new_size - ht->size)*sizeof(void *)); in handle_table_resize()
122 ht->size = new_size; in handle_table_resize()
/external/valgrind/drd/
Ddrd_malloc_wrappers.c178 static void* drd_realloc(ThreadId tid, void* p_old, SizeT new_size) in drd_realloc() argument
185 return drd_malloc(tid, new_size); in drd_realloc()
187 if (new_size == 0) in drd_realloc()
195 s_cmalloc_bs_mallocd += new_size; in drd_realloc()
206 if (old_size == new_size) in drd_realloc()
212 else if (new_size < old_size) in drd_realloc()
215 s_stop_using_mem_callback(mc->data + new_size, old_size - new_size); in drd_realloc()
216 mc->size = new_size; in drd_realloc()
223 p_new = VG_(cli_malloc)(VG_(clo_alignment), new_size); in drd_realloc()
238 mc->size = new_size; in drd_realloc()
[all …]
/external/compiler-rt/lib/sanitizer_common/
Dsanitizer_tls_get_addr.cc53 static inline void DTLS_Resize(uptr new_size) { in DTLS_Resize() argument
54 if (dtls.dtv_size >= new_size) return; in DTLS_Resize()
55 new_size = RoundUpToPowerOfTwo(new_size); in DTLS_Resize()
56 new_size = Max(new_size, 4096UL / sizeof(DTLS::DTV)); in DTLS_Resize()
58 (DTLS::DTV *)MmapOrDie(new_size * sizeof(DTLS::DTV), "DTLS_Resize"); in DTLS_Resize()
68 dtls.dtv_size = new_size; in DTLS_Resize()
/external/v8/src/zone/
Dzone.cc144 size_t new_size = kSegmentOverhead + new_size_no_overhead; in NewExpand() local
147 if (new_size_no_overhead < size || new_size < kSegmentOverhead) { in NewExpand()
151 if (new_size < kMinimumSegmentSize) { in NewExpand()
152 new_size = kMinimumSegmentSize; in NewExpand()
153 } else if (new_size > kMaximumSegmentSize) { in NewExpand()
158 new_size = Max(min_new_size, kMaximumSegmentSize); in NewExpand()
160 if (new_size > INT_MAX) { in NewExpand()
164 Segment* segment = NewSegment(new_size); in NewExpand()
/external/compiler-rt/lib/builtins/
Demutls.c166 uintptr_t new_size = emutls_new_data_array_size(index); in emutls_get_address_array() local
167 array = malloc(new_size * sizeof(void *) + sizeof(emutls_address_array)); in emutls_get_address_array()
169 memset(array->data, 0, new_size * sizeof(void*)); in emutls_get_address_array()
170 emutls_check_array_set_size(array, new_size); in emutls_get_address_array()
173 uintptr_t new_size = emutls_new_data_array_size(index); in emutls_get_address_array() local
174 array = realloc(array, new_size * sizeof(void *) + sizeof(emutls_address_array)); in emutls_get_address_array()
177 (new_size - orig_size) * sizeof(void*)); in emutls_get_address_array()
178 emutls_check_array_set_size(array, new_size); in emutls_get_address_array()
/external/mesa3d/src/egl/main/
Deglarray.c42 EGLint new_size; in _eglGrowArray() local
45 new_size = array->MaxSize; in _eglGrowArray()
46 while (new_size <= array->Size) in _eglGrowArray()
47 new_size *= 2; in _eglGrowArray()
49 elems = realloc(array->Elements, new_size * sizeof(array->Elements[0])); in _eglGrowArray()
52 array->Name, new_size); in _eglGrowArray()
57 array->MaxSize = new_size; in _eglGrowArray()
/external/compiler-rt/lib/msan/
Dmsan_allocator.cc177 void *MsanReallocate(StackTrace *stack, void *old_p, uptr new_size, in MsanReallocate() argument
180 return MsanAllocate(stack, new_size, alignment, zeroise); in MsanReallocate()
181 if (!new_size) { in MsanReallocate()
188 if (new_size <= actually_allocated_size) { in MsanReallocate()
190 meta->requested_size = new_size; in MsanReallocate()
191 if (new_size > old_size) { in MsanReallocate()
194 new_size - old_size); in MsanReallocate()
197 PoisonMemory((char *)old_p + old_size, new_size - old_size, stack); in MsanReallocate()
202 uptr memcpy_size = Min(new_size, old_size); in MsanReallocate()
203 void *new_p = MsanAllocate(stack, new_size, alignment, zeroise); in MsanReallocate()
/external/valgrind/callgrind/
Dcontext.c88 UInt i, new_size, conflicts1 = 0, conflicts2 = 0; in resize_cxt_table() local
92 new_size = 2* cxts.size +3; in resize_cxt_table()
94 new_size * sizeof(Context*)); in resize_cxt_table()
96 for (i = 0; i < new_size; i++) in resize_cxt_table()
106 new_idx = (UInt) (curr->hash % new_size); in resize_cxt_table()
124 cxts.size, new_size, in resize_cxt_table()
127 cxts.size = new_size; in resize_cxt_table()
297 UInt new_size = CLG_(current_fn_stack).size *2; in CLG_() local
299 new_size * sizeof(fn_node*)); in CLG_()
308 CLG_(current_fn_stack).size, new_size, in CLG_()
[all …]
/external/compiler-rt/lib/tsan/rtl/
Dtsan_stack_trace.cc26 void VarSizeStackTrace::ResizeBuffer(uptr new_size) { in ResizeBuffer() argument
31 (new_size > 0) in ResizeBuffer()
33 new_size * sizeof(trace_buffer[0])) in ResizeBuffer()
36 size = new_size; in ResizeBuffer()
/external/libtextclassifier/util/utf8/
Dunicodetext.cc40 void UnicodeText::Repr::resize(int new_size) { in resize() argument
41 if (new_size == 0) { in resize()
44 if (!ours_ || new_size > capacity_) reserve(new_size); in resize()
46 if (size_ < new_size) memset(data_ + size_, 0, new_size - size_); in resize()
47 size_ = new_size; in resize()
/external/eigen/Eigen/src/Core/util/
DMemory.h188 inline void* aligned_realloc(void *ptr, std::size_t new_size, std::size_t old_size) in aligned_realloc() argument
194 result = std::realloc(ptr,new_size); in aligned_realloc()
196 result = handmade_aligned_realloc(ptr,new_size,old_size); in aligned_realloc()
199 if (!result && new_size) in aligned_realloc()
238 template<bool Align> inline void* conditional_aligned_realloc(void* ptr, std::size_t new_size, std:… in conditional_aligned_realloc() argument
240 return aligned_realloc(ptr, new_size, old_size); in conditional_aligned_realloc()
243 template<> inline void* conditional_aligned_realloc<false>(void* ptr, std::size_t new_size, std::si…
245 return std::realloc(ptr, new_size);
346 …VICE_FUNC inline T* conditional_aligned_realloc_new(T* pts, std::size_t new_size, std::size_t old_… in conditional_aligned_realloc_new() argument
348 check_size_for_overflow<T>(new_size); in conditional_aligned_realloc_new()
[all …]
/external/sfntly/cpp/src/sample/subtly/
Dstats.cc54 int32_t new_size = 0; in PrintComparison() local
57 new_size = new_table->DataLength(); in PrintComparison()
61 if (new_size == size) { in PrintComparison()
64 fprintf(out, "-> %d (%lf%%) | %lf%% of original\n", new_size, in PrintComparison()
65 size_percent, static_cast<double>(new_size) / size * 100); in PrintComparison()
/external/mesa3d/src/gallium/auxiliary/pipebuffer/
Dpb_validate.c87 unsigned new_size; in pb_validate_add_buffer() local
90 new_size = vl->size * 2; in pb_validate_add_buffer()
91 if(!new_size) in pb_validate_add_buffer()
96 new_size*sizeof(struct pb_validate_entry)); in pb_validate_add_buffer()
100 memset(new_entries + vl->size, 0, (new_size - vl->size)*sizeof(struct pb_validate_entry)); in pb_validate_add_buffer()
102 vl->size = new_size; in pb_validate_add_buffer()

1234567891011