GCC Middle and Back End API Reference
|
#include <vec.h>
Public Types | |
typedef vl_ptr | default_layout |
Public Member Functions | |
template<typename T > | |
void | reserve (vec< T, va_heap, vl_embed > *&v, unsigned reserve, bool exact MEM_STAT_DECL) |
Static Public Member Functions | |
template<typename T > | |
static void | reserve (vec< T, va_heap, vl_embed > *&, unsigned, bool CXX_MEM_STAT_INFO) |
template<typename T > | |
static void | release (vec< T, va_heap, vl_embed > *&) |
Types of supported allocations va_heap - Allocation uses malloc/free. va_gc - Allocation uses ggc_alloc. va_gc_atomic - Same as GC, but individual elements of the array do not need to be marked during collection. va_stack - Allocation uses alloca.
Allocator type for heap vectors.
typedef vl_ptr va_heap::default_layout |
|
static |
|
inline |
Allocator for heap memory. Ensure there are at least RESERVE free slots in V. If EXACT is true, grow exactly, else grow exponentially. As a special case, if the vector had not been allocated and and RESERVE is 0, no vector will be created.
References vec_prefix::calculate_allocation(), and release().