Back to index

plt-scheme  4.2.1
Static Public Member Functions
single_client_traceable_alloc_template< dummy > Class Template Reference

#include <new_gc_alloc.h>

List of all members.

Static Public Member Functions

static voidallocate (size_t n)
static voidptr_free_allocate (size_t n)
static void deallocate (void *p, size_t n)
static void ptr_free_deallocate (void *p, size_t n)

Detailed Description

template<int dummy>
class single_client_traceable_alloc_template< dummy >

Definition at line 257 of file new_gc_alloc.h.


Member Function Documentation

template<int dummy>
static void* single_client_traceable_alloc_template< dummy >::allocate ( size_t  n) [inline, static]

Definition at line 259 of file new_gc_alloc.h.

        {
           size_t nwords = GC_round_up_uncollectable(n);
           void ** flh;
           void * op;

           if (n > GC_max_fast_bytes) return GC_malloc_uncollectable(n);
           flh = GC_uobjfreelist_ptr + nwords;
           if (0 == (op = *flh)) {
              return GC_aux::GC_out_of_line_malloc(nwords, GC_UNCOLLECTABLE);
           }
           *flh = GC_obj_link(op);
           GC_aux::GC_uncollectable_words_recently_allocd += nwords;
           return op;
        }

Here is the call graph for this function:

template<int dummy>
static void single_client_traceable_alloc_template< dummy >::deallocate ( void p,
size_t  n 
) [inline, static]

Definition at line 289 of file new_gc_alloc.h.

       {
            size_t nwords = GC_round_up_uncollectable(n);
            void ** flh;
          
           if (n > GC_max_fast_bytes)  {
              GC_free(p);
           } else {
               flh = GC_uobjfreelist_ptr + nwords;
               GC_obj_link(p) = *flh;
               *flh = p;
               GC_aux::GC_uncollectable_mem_recently_freed += nwords;
           }
       }

Here is the call graph for this function:

template<int dummy>
static void* single_client_traceable_alloc_template< dummy >::ptr_free_allocate ( size_t  n) [inline, static]

Definition at line 274 of file new_gc_alloc.h.

        {
           size_t nwords = GC_round_up_uncollectable(n);
           void ** flh;
           void * op;

           if (n > GC_max_fast_bytes) return GC_malloc_atomic_uncollectable(n);
           flh = GC_auobjfreelist_ptr + nwords;
           if (0 == (op = *flh)) {
              return GC_aux::GC_out_of_line_malloc(nwords, GC_AUNCOLLECTABLE);
           }
           *flh = GC_obj_link(op);
           GC_aux::GC_uncollectable_words_recently_allocd += nwords;
           return op;
        }

Here is the call graph for this function:

template<int dummy>
static void single_client_traceable_alloc_template< dummy >::ptr_free_deallocate ( void p,
size_t  n 
) [inline, static]

Definition at line 303 of file new_gc_alloc.h.

       {
            size_t nwords = GC_round_up_uncollectable(n);
            void ** flh;
          
           if (n > GC_max_fast_bytes) {
              GC_free(p);
           } else {
              flh = GC_auobjfreelist_ptr + nwords;
              GC_obj_link(p) = *flh;
              *flh = p;
              GC_aux::GC_uncollectable_mem_recently_freed += nwords;
           }
       }

Here is the call graph for this function:


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