Spec SinglePoolAllocator
Allocator that pools memory blocks of a specific size.

Extends Allocator
All Extended Allocator
Defined in <seqan/basic.h>
Signature template <unsigned SIZE, typename TParentAllocator> class Allocator;

Template Parameters

SIZE The size of the blocks.
TParentAllocator The parent allocator to use.

Interface Function Overview

Interface Functions Inherited From Allocator

Detailed Description

A pool allocator allocates several memory blocks at once. Freed blocks are not immediately deallocated but recycled in subsequential allocations. This way, the number of calls to the heap manager is reduced, and that might speed up memory management.

The single pool allocator only pools memory blocks of size at most $SIZE$. Blocks of other sizes are allocated and deallocated using an allocator of type $ParentAllocator$. Using the single pool allocator for blocksizes larger than a few KB is not advised.