GCC Middle and Back End API Reference
va_gc_atomic Struct Reference

#include <vec.h>

Inheritance diagram for va_gc_atomic:
Collaboration diagram for va_gc_atomic:

Public Types

typedef vl_embed default_layout

Public Member Functions

template<typename T , typename A >
void reserve (vec< T, A, vl_embed > *&v, unsigned reserve, bool exact MEM_STAT_DECL)

Static Public Member Functions

template<typename T , typename A >
static void reserve (vec< T, A, vl_embed > *&, unsigned, bool CXX_MEM_STAT_INFO)
template<typename T , typename A >
static void release (vec< T, A, vl_embed > *&v)

Detailed Description

   Allocator type for GC vectors.  This is for vectors of types
   atomics w.r.t. collection, so allocation and deallocation is
   completely inherited from va_gc.  

Member Typedef Documentation

typedef vl_embed va_gc::default_layout
inherited
     Use vl_embed as the default layout for GC vectors.  Due to GTY
     limitations, GC vectors must always be pointers, so it is more
     efficient to use a pointer to the vl_embed layout, rather than
     using a pointer to a pointer as would be the case with vl_ptr.  

Member Function Documentation

template<typename T , typename A >
void va_gc::release ( vec< T, A, vl_embed > *&  v)
inlinestaticinherited
   Free GC memory used by V and reset V to NULL.  

Referenced by va_heap::release().

template<typename T , typename A >
static void va_gc::reserve ( vec< T, A, vl_embed > *&  ,
unsigned  ,
bool  CXX_MEM_STAT_INFO 
)
staticinherited

Referenced by va_heap::release().

template<typename T , typename A >
void va_gc::reserve ( vec< T, A, vl_embed > *&  v,
unsigned  reserve,
bool exact  MEM_STAT_DECL 
)
inherited
   Allocator for GC 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.  
     Calculate the amount of space we want.  
     Ask the allocator how much space it will really give us.  
     Adjust the number of slots accordingly.  
     And finally, recalculate the amount of space we ask for.  

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