GCC Middle and Back End API Reference
object_allocator< T > Class Template Reference

#include <alloc-pool.h>

Inheritance diagram for object_allocator< T >:
Collaboration diagram for object_allocator< T >:

Public Member Functions

 object_allocator (const char *name CXX_MEM_STAT_INFO)
 
void release ()
 
void release_if_empty ()
 
Tallocate () ATTRIBUTE_MALLOC
 
void * allocate_raw () ATTRIBUTE_MALLOC
 
void remove (T *object)
 
void remove_raw (void *object)
 
size_t num_elts_current ()
 

Private Attributes

pool_allocator m_allocator
 

Detailed Description

template<typename T>
class object_allocator< T >
Type based memory pool allocator.   

Constructor & Destructor Documentation

◆ object_allocator()

template<typename T>
object_allocator< T >::object_allocator ( const char *name CXX_MEM_STAT_INFO)
inline

Member Function Documentation

◆ allocate()

template<typename T>
T * object_allocator< T >::allocate ( )
inline

◆ allocate_raw()

template<typename T>
void * object_allocator< T >::allocate_raw ( )
inline

References m_allocator.

◆ num_elts_current()

template<typename T>
size_t object_allocator< T >::num_elts_current ( )
inline

References m_allocator.

◆ release()

template<typename T>
void object_allocator< T >::release ( )
inline

References m_allocator.

Referenced by optimize_constant_pool().

◆ release_if_empty()

template<typename T>
void object_allocator< T >::release_if_empty ( )
inline

References m_allocator.

◆ remove()

◆ remove_raw()

template<typename T>
void object_allocator< T >::remove_raw ( void * object)
inline

References m_allocator.

Field Documentation

◆ m_allocator


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