Anklang 0.3.0-460-gc4ef46ba
ASE — Anklang Sound Engine (C++)

« « « Anklang Documentation
Loading...
Searching...
No Matches
Classes | Public Member Functions | List of all members
Ase::Loft::BumpAllocator Struct Reference

Public Member Functions

void * bump_alloc (size_t size)
 
size_t grow_spans (size_t needed, bool preallocating)
 
size_t free_block () const
 
void list_arenas (ArenaList &arenas)
 
size_t totalmem () const
 

Detailed Description

BumpAllocator - satisfy allocations by bumping an offset into mmap based spans. This allocator satisfies allocation requests from pre-allocated mmap regions. The regions support transparent huge pages and are setup to allow upwards growth instead of accumulating a long list of individual mappings. As long as enough pre-allocated memory is available, allocation requests are served via a single lock-free offset increment. Atm, no memory is released back to the OS ever.

Definition at line 39 of file loft.cc.

Member Function Documentation

◆ bump_alloc()

void * Ase::Loft::BumpAllocator::bump_alloc ( size_t  size)

Definition at line 226 of file loft.cc.

◆ free_block()

size_t Ase::Loft::BumpAllocator::free_block ( ) const

Definition at line 67 of file loft.cc.

◆ grow_spans()

size_t Ase::Loft::BumpAllocator::grow_spans ( size_t  needed,
bool  preallocating 
)

Definition at line 79 of file loft.cc.

◆ list_arenas()

void Ase::Loft::BumpAllocator::list_arenas ( ArenaList arenas)

Definition at line 60 of file loft.cc.

◆ totalmem()

size_t Ase::Loft::BumpAllocator::totalmem ( ) const

Definition at line 44 of file loft.cc.


The documentation for this struct was generated from the following file: