Lines Matching refs:std
29 const std::size_t my_size;
33 ArenaData( T* buf, std::size_t sz ) noexcept in ArenaData()
43 template <typename T, typename POCMA = std::false_type, typename CounterType = std::size_t>
65 using std::swap; in swap()
72 value_type* allocate( std::size_t n ) { in allocate()
73 std::size_t new_size = (my_data->my_allocated += n * sizeof(T)); in allocate()
79 void deallocate( value_type* ptr, std::size_t n ) { in deallocate()
88 std::size_t max_size() const noexcept { in max_size()
107 using counter_type = std::atomic<std::size_t>;
111 std::size_t max_items;
119 void set_counters( std::size_t it_allocated, std::size_t it_freed, in set_counters()
120 std::size_t it_constructed, std::size_t it_destroyed, in set_counters()
121 std::size_t allocs, std::size_t fres ) { in set_counters()
161 value_type* allocate( std::size_t n ) { in allocate()
163 TBB_TEST_THROW(std::bad_alloc()); in allocate()
171 void deallocate( value_type* ptr, std::size_t n ) { in deallocate()
179 base_traits::construct(*this, ptr, std::forward<Args>(args)...); in construct()
189 void set_limits( std::size_t max ) { in set_limits()
195 using counter_type = std::atomic<std::size_t>;
206 AllocatorCounters( std::size_t it_allocated, std::size_t it_freed, std::size_t it_constructed, in AllocatorCounters()
207 std::size_t it_destroyed, std::size_t allocs, std::size_t fres ) in AllocatorCounters()
244 using counter_type = std::atomic<std::size_t>;
250 static std::size_t max_items;
269 value_type* allocate( std::size_t n ) { in allocate()
272 TBB_TEST_THROW(std::bad_alloc{}); in allocate()
282 void deallocate(const pointer ptr, const std::size_t n){ in deallocate()
291 base_traits::construct(*this, ptr, std::forward<Args>(args)...); in construct()
313 static void set_limits( std::size_t max = 0, bool do_throw = true ) {
320 std::size_t StaticCountingAllocator<T>::max_items;
322 std::atomic<std::size_t> StaticCountingAllocator<T>::items_allocated;
324 std::atomic<std::size_t> StaticCountingAllocator<T>::items_freed;
326 std::atomic<std::size_t> StaticCountingAllocator<T>::items_constructed;
328 std::atomic<std::size_t> StaticCountingAllocator<T>::items_destroyed;
330 std::atomic<std::size_t> StaticCountingAllocator<T>::allocations;
332 std::atomic<std::size_t> StaticCountingAllocator<T>::frees;
337 using counter_type = std::atomic<std::size_t>;
339 static std::size_t max_items;
362 static void set_limits( std::size_t max = 0, bool do_throw = true ) {
368 std::size_t StaticSharedCountingAllocatorBase::max_items;
369 std::atomic<std::size_t> StaticSharedCountingAllocatorBase::items_constructed;
370 std::atomic<std::size_t> StaticSharedCountingAllocatorBase::items_destroyed;
371 std::atomic<std::size_t> StaticSharedCountingAllocatorBase::items_allocated;
372 std::atomic<std::size_t> StaticSharedCountingAllocatorBase::items_freed;
373 std::atomic<std::size_t> StaticSharedCountingAllocatorBase::allocations;
374 std::atomic<std::size_t> StaticSharedCountingAllocatorBase::frees;
405 value_type* allocate( std::size_t n ) { in allocate()
409 TBB_TEST_THROW(std::bad_alloc()); in allocate()
418 void deallocate( value_type* ptr, std::size_t n ) { in deallocate()
426 base_traits::construct(*this, ptr, std::forward<Args>(args)...); in construct()
494 namespace std {
497 std::size_t operator()(const AllocatorAwareData<Allocator>& obj) const {
498 return std::hash<int>()(obj.value());
503 template <typename Allocator, typename POCMA = std::false_type, typename POCCA = std::false_type,
504 typename POCS = std::false_type>
506 using base_allocator_traits = std::allocator_traits<Allocator>;
579 using AlwaysPropagatingAllocator = PropagatingAllocator<std::allocator<T>, /*POCMA = */std::true_ty…
580 … /*POCCA = */std::true_type, /*POCS = */std::true_type>;
582 using NeverPropagatingAllocator = PropagatingAllocator<std::allocator<T>>;
584 using PocmaAllocator = PropagatingAllocator<std::allocator<T>, /*POCMA = */std::true_type>;
586 using PoccaAllocator = PropagatingAllocator<std::allocator<T>, /*POCMA = */std::false_type, /*POCCA…
588 using PocsAllocator = PropagatingAllocator<std::allocator<T>, /*POCMA = */std::false_type, /*POCCA …
589 /*POCS = */std::true_type>;
592 class AlwaysEqualAllocator : public std::allocator<T> {
593 using base_allocator = std::allocator<T>;
595 using is_always_equal = std::true_type;
597 using propagate_on_container_move_assignment = std::false_type;
614 class NotAlwaysEqualAllocator : public std::allocator<T> {
615 using base_allocator = std::allocator<T>;
617 using is_always_equal = std::false_type;
619 using propagate_on_container_swap = std::false_type;