Class Specialization
Single Pool Allocator
Allocator that pools memory blocks of specific size.

Allocator

Single Pool Allocator

Allocator< SinglePool<SIZE, ParentAllocator> >
Include Headers
seqan/basic.h
Parameters

SIZE | Size of memory blocks that are pooled.
ParentAllocator | An allocator that is by the pool allocator used to allocate memory. Note: The single pool allocator only supports clear if this function is also implemented for ParentAllocator. Default: Simple Allocator

Remarks
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 speeds 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 some KB is not advised.
Specialization of
Allocator
Functions

allocate | Allocates memory from heap. (Allocator)
clear | Deallocates all memory blocks. (Allocator)
deallocate | Deallocates memory. (Allocator)

Example Programs
Allocators
See Also
Allocators
SeqAn - Sequence Analysis Library - www.seqan.de

Page built @2014/10/13 16:13:00