Template Class DynamicSizePool¶
Defined in File DynamicSizePool.hpp
Inheritance Relationships¶
Base Type¶
private umpire::strategy::mixins::AlignedAllocation(Class AlignedAllocation)
Class Documentation¶
-
template<class
IA= StdAllocator>
classDynamicSizePool: private umpire::strategy::mixins::AlignedAllocation¶ Public Functions
-
DynamicSizePool(umpire::strategy::AllocationStrategy *strat, const std::size_t first_minimum_pool_allocation_size = (16 * 1024), const std::size_t next_minimum_pool_allocation_size = 256, const std::size_t alignment = 16)¶
-
DynamicSizePool(const DynamicSizePool&) = delete¶
-
~DynamicSizePool()¶
-
void *
allocate(std::size_t bytes)¶
-
void
deallocate(void *ptr)¶
-
void
release()¶
-
std::size_t
getActualSize() const¶
-
std::size_t
getCurrentSize() const¶
-
std::size_t
getBlocksInPool() const¶
-
std::size_t
getLargestAvailableBlock() const¶
-
std::size_t
getReleasableSize() const¶
-
std::size_t
getFreeBlocks() const¶
-
std::size_t
getInUseBlocks() const¶
-
void
coalesce()¶
Protected Types
-
typedef FixedSizePool<struct Block, IA, IA, (1 << 6)>
BlockPool¶
Protected Attributes
-
std::size_t
m_actual_bytes¶
-
std::size_t
m_current_size= {0}¶
-
std::size_t
m_first_minimum_pool_allocation_size¶
-
std::size_t
m_next_minimum_pool_allocation_size¶
-
bool
m_is_destructing= {false}¶
Private Functions
-
std::size_t
aligned_round_up(std::size_t size)¶ Round up the size to be an integral multple of configured alignment.
- Return
Size rounded up to be integral multiple of configured alignment
-
void *
aligned_allocate(const std::size_t size)¶ Return an allocation of
sizebytes that is aligned on the configured alignment boundary.
-
void
aligned_deallocate(void *ptr)¶ Deallocate previously alligned allocation.
Private Members
-
strategy::AllocationStrategy *
m_allocator¶
-
struct
Block¶
-