59#ifndef ATLALLOCATORS_ARENASHAREDHEAPSTLALLOCATOR_H
60#define ATLALLOCATORS_ARENASHAREDHEAPSTLALLOCATOR_H
153 void report (std::ostream& os)
const;
319 template <
bool = true>
320 requires (!std::same_as<reference,const_reference>)
338 template <
bool = true>
339 requires (!std::same_as<reference,const_reference>)
361 template <class...
Args>
Registry of allocator factories. See Arena.h for an overview of the arena-based memory allocators.
Heap-based allocator. See Arena.h for an overview of the arena-based memory allocators.
STL-style allocator wrapper for ArenaHeapAllocator.
#define ATLAS_THREAD_SAFE
Common base class for arena allocator classes.
const T & const_reference
ArenaSharedHeapSTLAllocator(const ArenaSharedHeapSTLAllocator< U > &a)
Constructor from another ArenaSharedHeapSTLAllocator.
void construct(pointer p, Args &&... args)
void reserve(size_t size)
std::true_type propagate_on_container_swap
bool operator!=(const ArenaSharedHeapSTLAllocator &other) const
Inequality test.
std::true_type propagate_on_container_move_assignment
Move allocators on move/swap.
bool operator==(const ArenaSharedHeapSTLAllocator &other) const
Equality test.
void swap(ArenaSharedHeapSTLAllocator &a)
Swap.
std::false_type propagate_on_container_copy_assignment
When we assign to a container, the target should retain its allocator.
ArenaSharedHeapSTLHeader * m_header
void report(std::ostream &os) const
ArenaAllocatorBase::Stats stats() const
T * pointer
Standard STL allocator typedefs.
pointer address(reference x) const
Convert a reference to an address.
size_type max_size() const
Return the maximum number of objects we can allocate at once.
friend class ArenaSharedHeapSTLAllocator
Make all instantiations of this class friends (to be able to copy the header pointer).
~ArenaSharedHeapSTLAllocator()
Destructor.
const std::string & name() const
ArenaSharedHeapSTLAllocator & operator=(const ArenaSharedHeapSTLAllocator &a)
Assignment.
ptrdiff_t difference_type
ArenaHeapAllocator * poolptr()
ArenaHeapAllocator * m_pool
void deallocate(pointer, size_type n)
Deallocate objects.
ArenaSharedHeapSTLAllocator(size_t nblock=1000)
Default constructor.
ArenaSharedHeapSTLAllocator(const ArenaSharedHeapSTLAllocator &a)
Copy constructor.
pointer allocate(size_type n, const void *hint=0)
Allocate new objects.
ArenaSharedHeapSTLAllocator(ArenaSharedHeapSTLAllocator &&a)=default
Move constructor is the same as the copy constructor.
ArenaAllocatorBase::Stats totstats() const
void maybeUnprotect(ArenaHeapSTLAllocator< T, VETO > &a)
Hook for unprotecting an arena.
void swap(ArenaSharedHeapSTLAllocator< T > &a, ArenaSharedHeapSTLAllocator< T > &b)
Statistics for an allocator.
Standard STL allocator rebinder.
ArenaSharedHeapSTLAllocator< U > other