FD.io VPP  v21.10.1-2-g0a485f517
Vector Packet Processing
mem_bulk.c File Reference
+ Include dependency graph for mem_bulk.c:

Go to the source code of this file.

Data Structures

struct  clib_mem_bulk_chunk_hdr
 
struct  clib_mem_bulk_t
 

Macros

#define CLIB_MEM_BULK_DEFAULT_MIN_ELTS_PER_CHUNK   32
 

Typedefs

typedef struct clib_mem_bulk_chunk_hdr clib_mem_bulk_chunk_hdr_t
 

Functions

static uword bulk_chunk_size (clib_mem_bulk_t *b)
 
__clib_export clib_mem_bulk_handle_t clib_mem_bulk_init (u32 elt_sz, u32 align, u32 min_elts_per_chunk)
 
__clib_export void clib_mem_bulk_destroy (clib_mem_bulk_handle_t h)
 
static void * get_chunk_elt_ptr (clib_mem_bulk_t *b, clib_mem_bulk_chunk_hdr_t *c, u32 index)
 
static void add_to_chunk_list (clib_mem_bulk_chunk_hdr_t **first, clib_mem_bulk_chunk_hdr_t *c)
 
static void remove_from_chunk_list (clib_mem_bulk_chunk_hdr_t **first, clib_mem_bulk_chunk_hdr_t *c)
 
__clib_export void * clib_mem_bulk_alloc (clib_mem_bulk_handle_t h)
 
__clib_export void clib_mem_bulk_free (clib_mem_bulk_handle_t h, void *p)
 
__clib_export u8format_clib_mem_bulk (u8 *s, va_list *args)
 

Macro Definition Documentation

◆ CLIB_MEM_BULK_DEFAULT_MIN_ELTS_PER_CHUNK

#define CLIB_MEM_BULK_DEFAULT_MIN_ELTS_PER_CHUNK   32

Definition at line 27 of file mem_bulk.c.

Typedef Documentation

◆ clib_mem_bulk_chunk_hdr_t

Function Documentation

◆ add_to_chunk_list()

static void add_to_chunk_list ( clib_mem_bulk_chunk_hdr_t **  first,
clib_mem_bulk_chunk_hdr_t c 
)
inlinestatic

Definition at line 118 of file mem_bulk.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ bulk_chunk_size()

static uword bulk_chunk_size ( clib_mem_bulk_t b)
inlinestatic

Definition at line 48 of file mem_bulk.c.

+ Here is the caller graph for this function:

◆ clib_mem_bulk_alloc()

__clib_export void* clib_mem_bulk_alloc ( clib_mem_bulk_handle_t  h)

Definition at line 141 of file mem_bulk.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ clib_mem_bulk_destroy()

__clib_export void clib_mem_bulk_destroy ( clib_mem_bulk_handle_t  h)

Definition at line 83 of file mem_bulk.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ clib_mem_bulk_free()

__clib_export void clib_mem_bulk_free ( clib_mem_bulk_handle_t  h,
void *  p 
)

Definition at line 179 of file mem_bulk.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ clib_mem_bulk_init()

__clib_export clib_mem_bulk_handle_t clib_mem_bulk_init ( u32  elt_sz,
u32  align,
u32  min_elts_per_chunk 
)

Definition at line 54 of file mem_bulk.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ format_clib_mem_bulk()

__clib_export u8* format_clib_mem_bulk ( u8 s,
va_list *  args 
)

Definition at line 213 of file mem_bulk.c.

◆ get_chunk_elt_ptr()

static void* get_chunk_elt_ptr ( clib_mem_bulk_t b,
clib_mem_bulk_chunk_hdr_t c,
u32  index 
)
inlinestatic

Definition at line 112 of file mem_bulk.c.

+ Here is the caller graph for this function:

◆ remove_from_chunk_list()

static void remove_from_chunk_list ( clib_mem_bulk_chunk_hdr_t **  first,
clib_mem_bulk_chunk_hdr_t c 
)
inlinestatic

Definition at line 129 of file mem_bulk.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function: