Home
last modified time | relevance | path

Searched refs:nelem (Results 1 – 25 of 41) sorted by relevance

12

/third_party/boost/boost/sort/common/util/
Dcircular_buffer.hpp62 size_t nelem, first_pos; member
71 : ptr(nullptr), nelem(0), first_pos(0), initialized(false) in circular_buffer()
125 bool empty(void) const {return (nelem == 0); }; in empty()
132 bool full(void) const { return (nelem == NMAX); }; in full()
139 size_t size(void) const { return nelem;}; in size()
153 size_t free_size(void) const { return (NMAX - nelem); }; in free_size()
159 void clear(void) { nelem = first_pos = 0; }; in clear()
169 assert (nelem > 0); in front()
182 assert ( nelem > 0 ); in front()
195 assert ( nelem > 0 ); in back()
[all …]
/third_party/boost/boost/sort/common/
Dindirect.hpp77 auto nelem = last - first; in create_index() local
78 assert(nelem >= 0); in create_index()
80 index.reserve(nelem); in create_index()
100 size_t nelem = index.size(); in sort_index() local
103 while (pos_in_vector < nelem) in sort_index()
105 while (pos_in_vector < nelem and in sort_index()
111 if (pos_in_vector == nelem) return; in sort_index()
135 auto nelem = (last - first); in indirect_sort() local
136 assert(nelem >= 0); in indirect_sort()
137 if (nelem < 2) return; in indirect_sort()
[all …]
Dscheduler.hpp72 size_t nelem; member
79 scheduler(void) : mp(), nelem(0) { }; in scheduler()
112 return nelem; in size()
123 nelem = 0; in clear_all()
147 nelem++; in insert()
171 nelem++; in emplace()
208 nelem++; in insert_range()
224 if (nelem == 0) return false; in extract()
231 --nelem; in extract()
239 --nelem; in extract()
[all …]
Dmerge_vector.hpp75 uint32_t nelem = (nrange + nmerge - 1) / nmerge; in merge_level4() local
76 range1_t rz = full_merge4(dest, &v_input[pos_ini], nelem, comp); in merge_level4()
79 pos_ini += nelem; in merge_level4()
80 nrange -= nelem; in merge_level4()
122 uint32_t nelem = (nrange + nmerge - 1) / nmerge; in uninit_merge_level4() local
123 range1_t rz = uninit_full_merge4(dest, &v_input[pos_ini], nelem, comp); in uninit_merge_level4()
126 pos_ini += nelem; in uninit_merge_level4()
127 nrange -= nelem; in uninit_merge_level4()
Drearrange.hpp78 size_t nelem = size_t(itx_last - itx_first); in rearrange() local
83 while (pos_ini < nelem) in rearrange()
85 while (pos_ini < nelem and pos(index[pos_ini]) == pos_ini) in rearrange()
87 if (pos_ini == nelem) return; in rearrange()
Dmerge_block.hpp63 size_t nelem; member
106 nelem = size_t(last - first); in merge_block()
107 nblock = (nelem + BLOCK_SIZE - 1) / BLOCK_SIZE; in merge_block()
108 ntail = (nelem % BLOCK_SIZE); in merge_block()
384 size_t nelem = index.size(); in rearrange_with_index() local
391 while (pos_ini < nelem) in rearrange_with_index()
393 while (pos_ini < nelem and index[pos_ini] == pos_ini) in rearrange_with_index()
395 if (pos_ini == nelem) return; in rearrange_with_index()
Dsort_basic.hpp233 size_t nelem = (rng1.size() + 1) >> 1; in internal_sort() local
235 range<Iter1_t> rng1_left(rng1.first, rng1.first + nelem), in internal_sort()
236 rng1_right(rng1.first + nelem, rng1.last); in internal_sort()
238 range<Iter2_t> rng2_left(rng2.first, rng2.first + nelem), in internal_sort()
239 rng2_right(rng2.first + nelem, rng2.last); in internal_sort()
241 if (nelem <= 32 and (level & 1) == even) in internal_sort()
/third_party/boost/boost/sort/heap_sort/
Dheap_sort.hpp125 void make_heap (Iter_t first, size_t nelem, Compare comp) in make_heap()
131 for (size_t i = 1; i < nelem; ++i) in make_heap()
159 size_t nelem = last - first; in heap_sort() local
160 if (nelem < 2) return; in heap_sort()
165 make_heap (first, nelem, comp); in heap_sort()
174 for (size_t i = 1; i < nelem; ++i) in heap_sort()
176 std::swap (*first, *(first + (nelem - i))); in heap_sort()
181 while (sw and pos_son < (nelem - i)) in heap_sort()
185 if ((pos_son + 1) < (nelem - i) and in heap_sort()
/third_party/boost/boost/sort/block_indirect_sort/blk_detail/
Dparallel_sort.hpp137 size_t nelem = size_t(last - first); in parallel_sort() local
152 size_t nelem2 = nelem >> 1; in parallel_sort()
164 uint32_t level = ((nbits64(nelem / max_per_thread)) * 3) / 2; in parallel_sort()
167 if (nelem < (max_per_thread)) in parallel_sort()
197 size_t nelem = last - first; in divide_sort() local
198 if (level == 0 or nelem < (max_per_thread)) in divide_sort()
Dbackbone.hpp73 size_t nelem; member
185 nelem = size_t (last - first); in backbone()
186 nblock = (nelem + Block_size - 1) / Block_size; in backbone()
187 ntail = (nelem % Block_size); in backbone()
/third_party/boost/boost/sort/flat_stable_sort/
Dflat_stable_sort.hpp181 size_t nelem = rng.size(); in is_sorted_forward() local
182 size_t min_process = (std::max)(BLOCK_SIZE, (nelem >> 3)); in is_sorted_forward()
186 if (nsorted1 == nelem) return true; in is_sorted_forward()
189 size_t nsorted2 = nelem - nsorted1; in is_sorted_forward()
223 size_t nelem = rng.size(); in is_sorted_backward() local
224 size_t min_process = (std::max)(BLOCK_SIZE, (nelem >> 3)); in is_sorted_backward()
228 if (nsorted2 == nelem) return true; in is_sorted_backward()
231 size_t nsorted1 = nelem - nsorted2; in is_sorted_backward()
/third_party/node/deps/cares/src/lib/
Dares__sortaddrinfo.c454 int nelem = 0, i; in ares__sortaddrinfo() local
461 ++nelem; in ares__sortaddrinfo()
465 if (!nelem) in ares__sortaddrinfo()
469 nelem * sizeof(struct addrinfo_sort_elem)); in ares__sortaddrinfo()
479 for (i = 0, cur = list_sentinel->ai_next; i < nelem; ++i, cur = cur->ai_next) in ares__sortaddrinfo()
495 qsort((void *)elems, nelem, sizeof(struct addrinfo_sort_elem), in ares__sortaddrinfo()
499 for (i = 0; i < nelem - 1; ++i) in ares__sortaddrinfo()
503 elems[nelem - 1].ai->ai_next = NULL; in ares__sortaddrinfo()
/third_party/boost/boost/sort/parallel_stable_sort/
Dparallel_stable_sort.hpp58 size_t nelem; member
124 uint32_t nthread) : nelem(0), ptr(nullptr) in parallel_stable_sort()
129 nelem = range_initial.size(); in parallel_stable_sort()
130 size_t nptr = (nelem + 1) >> 1; in parallel_stable_sort()
132 if (nelem < nelem_min or nthread < 2) in parallel_stable_sort()
151 size_t nelem2 = nelem >> 1; in parallel_stable_sort()
/third_party/openssl/test/
Dbioprinttest.c19 #define nelem(x) (int)(sizeof(x) / sizeof((x)[0])) macro
195 for (i = 0; i < nelem(fspecs); i++) { in dofptest()
262 ADD_ALL_TESTS(test_fp, nelem(pw_params)); in setup_tests()
263 ADD_ALL_TESTS(test_zu, nelem(zu_data)); in setup_tests()
264 ADD_ALL_TESTS(test_j, nelem(jf_data)); in setup_tests()
Ddanetest.c94 static STACK_OF(X509) *load_chain(BIO *fp, int nelem) in STACK_OF()
109 count < nelem && errtype == 0 in STACK_OF()
140 if (count == nelem) { in STACK_OF()
/third_party/boost/boost/sort/sample_sort/
Dsample_sort.hpp245 size_t nelem = size_t(last - first); in sample_sort() local
251 while (nelem > thread_min and (nthread * nthread) > (nelem >> 3)) in sample_sort()
257 if (nthread < 2 or nelem <= (thread_min)) in sample_sort()
275 size_t nelem2 = nelem >> 1; in sample_sort()
291 value_t *ptr = std::get_temporary_buffer<value_t>(nelem).first; in sample_sort()
294 global_buf = range_buf(ptr, ptr + nelem); in sample_sort()
347 size_t nelem = global_range.size(); in initial_configuration() local
350 size_t cupo = nelem / nthread; in initial_configuration()
/third_party/python/Modules/
D_tracemalloc.c581 tracemalloc_alloc(int use_calloc, void *ctx, size_t nelem, size_t elsize) in tracemalloc_alloc() argument
586 assert(elsize == 0 || nelem <= SIZE_MAX / elsize); in tracemalloc_alloc()
589 ptr = alloc->calloc(alloc->ctx, nelem, elsize); in tracemalloc_alloc()
591 ptr = alloc->malloc(alloc->ctx, nelem * elsize); in tracemalloc_alloc()
596 if (ADD_TRACE(ptr, nelem * elsize) < 0) { in tracemalloc_alloc()
678 tracemalloc_alloc_gil(int use_calloc, void *ctx, size_t nelem, size_t elsize) in tracemalloc_alloc_gil() argument
685 return alloc->calloc(alloc->ctx, nelem, elsize); in tracemalloc_alloc_gil()
687 return alloc->malloc(alloc->ctx, nelem * elsize); in tracemalloc_alloc_gil()
695 ptr = tracemalloc_alloc(use_calloc, ctx, nelem, elsize); in tracemalloc_alloc_gil()
710 tracemalloc_calloc_gil(void *ctx, size_t nelem, size_t elsize) in tracemalloc_calloc_gil() argument
[all …]
/third_party/ffmpeg/libavutil/
Dinternal.h102 #define FF_ALLOC_TYPED_ARRAY(p, nelem) (p = av_malloc_array(nelem, sizeof(*p))) argument
103 #define FF_ALLOCZ_TYPED_ARRAY(p, nelem) (p = av_mallocz_array(nelem, sizeof(*p))) argument
Dthreadmessage.c41 unsigned nelem, in av_thread_message_queue_alloc() argument
48 if (nelem > INT_MAX / elsize) in av_thread_message_queue_alloc()
67 if (!(rmq->fifo = av_fifo_alloc(elsize * nelem))) { in av_thread_message_queue_alloc()
/third_party/python/Objects/
Dobmalloc.c18 static void* _PyMem_DebugRawCalloc(void *ctx, size_t nelem, size_t elsize);
23 static void* _PyMem_DebugCalloc(void *ctx, size_t nelem, size_t elsize);
78 static void* _PyObject_Calloc(void *ctx, size_t nelem, size_t elsize);
103 _PyMem_RawCalloc(void *ctx, size_t nelem, size_t elsize) in _PyMem_RawCalloc() argument
109 if (nelem == 0 || elsize == 0) { in _PyMem_RawCalloc()
110 nelem = 1; in _PyMem_RawCalloc()
113 return calloc(nelem, elsize); in _PyMem_RawCalloc()
576 PyMem_RawCalloc(size_t nelem, size_t elsize) in PyMem_RawCalloc() argument
579 if (elsize != 0 && nelem > (size_t)PY_SSIZE_T_MAX / elsize) in PyMem_RawCalloc()
581 return _PyMem_Raw.calloc(_PyMem_Raw.ctx, nelem, elsize); in PyMem_RawCalloc()
[all …]
/third_party/python/Include/cpython/
Dpymem.h6 PyAPI_FUNC(void *) PyMem_RawCalloc(size_t nelem, size_t elsize);
55 void* (*calloc) (void *ctx, size_t nelem, size_t elsize);
/third_party/boost/boost/sort/spinsort/
Dspinsort.hpp446 size_t nelem = range_input.size(); in spinsort() local
449 nptr = (nelem + 1) >> 1; in spinsort()
451 size_t nelem_2 = nelem - nelem_1; in spinsort()
453 if (nelem <= (Sort_min << 1)) in spinsort()
471 size_t nelem2 = nelem >> 1; in spinsort()
489 uint32_t nlevel = nbits64(((nelem + Sort_min - 1) / Sort_min) - 1) - 1; in spinsort()
/third_party/boost/boost/sort/block_indirect_sort/
Dblock_indirect_sort.hpp195 size_t nelem = size_t(last - first); in block_indirect_sort() local
196 if (nelem == 0) return; in block_indirect_sort()
211 size_t nelem2 = nelem >> 1; in block_indirect_sort()
221 size_t nthreadmax = nelem / (Block_size * Group_size) + 1; in block_indirect_sort()
228 if (nelem < (max_per_thread) or nthread < 2) in block_indirect_sort()
/third_party/libevdev/libevdev/
Dlibevdev-int.h287 queue_set_num_elements(struct libevdev *dev, size_t nelem) in queue_set_num_elements() argument
289 if (nelem > dev->queue_size) in queue_set_num_elements()
292 dev->queue_next = nelem; in queue_set_num_elements()
/third_party/libphonenumber/cpp/src/phonenumbers/utf/
Dutfdef.h27 #define nelem(x) (sizeof(x)/sizeof((x)[0])) macro

12