libcopp
2.2.0
|
memory allocator this allocator will maintain buffer using malloc/free function More...
#include <stack_allocator_pool.h>
Public Types | |
using | pool_type = TPool |
using | pool_t = pool_type |
Public Member Functions | |
stack_allocator_pool () LIBCOPP_MACRO_NOEXCEPT | |
stack_allocator_pool (const std::shared_ptr< pool_type > &p) LIBCOPP_MACRO_NOEXCEPT | |
~stack_allocator_pool () | |
void | attach (const std::shared_ptr< pool_type > &p) LIBCOPP_MACRO_NOEXCEPT |
void | allocate (stack_context &ctx, std::size_t) LIBCOPP_MACRO_NOEXCEPT |
void | deallocate (stack_context &ctx) LIBCOPP_MACRO_NOEXCEPT |
Private Attributes | |
std::shared_ptr< pool_type > | pool_ |
memory allocator this allocator will maintain buffer using malloc/free function
Definition at line 27 of file stack_allocator_pool.h.
using allocator::stack_allocator_pool< TPool >::pool_t = pool_type |
Definition at line 32 of file stack_allocator_pool.h.
using allocator::stack_allocator_pool< TPool >::pool_type = TPool |
Definition at line 29 of file stack_allocator_pool.h.
|
inline |
Definition at line 35 of file stack_allocator_pool.h.
|
inline |
Definition at line 36 of file stack_allocator_pool.h.
|
inline |
Definition at line 37 of file stack_allocator_pool.h.
|
inline |
allocate memory and attach to stack context [standard function]
ctx | stack context |
size | ignored |
Definition at line 53 of file stack_allocator_pool.h.
|
inline |
specify memory section allocated
start_ptr | buffer start address |
max_size | buffer size |
Definition at line 45 of file stack_allocator_pool.h.
|
inline |
deallocate memory from stack context [standard function]
ctx | stack context |
Definition at line 64 of file stack_allocator_pool.h.
|
private |
Definition at line 72 of file stack_allocator_pool.h.