Motr  M0
m0_varr Struct Reference

#include <varr.h>

Collaboration diagram for m0_varr:
Collaboration graph

Data Fields

uint64_t va_nr
 
uint64_t va_buff_nr
 
size_t va_obj_size
 
uint8_t va_obj_shift
 
size_t va_bufsize
 
uint8_t va_buf_shift
 
uint32_t va_depth
 
uint64_t va_bufptr_nr
 
uint8_t va_bufptr_nr_shift
 
void * va_tree [M0_VA_TNODE_NR]
 
struct varr_cacheva_cache
 
uint32_t va_failure_depth
 
uint64_t va_magic
 

Detailed Description

Definition at line 121 of file varr.h.

Field Documentation

◆ va_buf_shift

uint8_t va_buf_shift

Log of va_bufsize to the base two.

Definition at line 135 of file varr.h.

◆ va_buff_nr

uint64_t va_buff_nr

Number of leaf buffers.

Definition at line 125 of file varr.h.

◆ va_bufptr_nr

uint64_t va_bufptr_nr

Number of pointers that can be accommodated in one meta buffer. This number is easy to calculate and need not be stored as a member of structure. However, during tree traversal, this number is calculated multiple times in each trail, owing to significant and exactly same compute operations which can be easily avoided by maintaining it as a member.

Definition at line 148 of file varr.h.

◆ va_bufptr_nr_shift

uint8_t va_bufptr_nr_shift

Definition at line 149 of file varr.h.

◆ va_bufsize

size_t va_bufsize

Size of buffer which is used to store objects and buffer-pointers from a tree.

Definition at line 133 of file varr.h.

◆ va_cache

struct varr_cache* va_cache

Holds address of a buffer holding recently accessed object.

Definition at line 159 of file varr.h.

◆ va_depth

uint32_t va_depth

Depth of tree proportional to number of objects stored.

Definition at line 138 of file varr.h.

◆ va_failure_depth

uint32_t va_failure_depth

Holds the cursor depth in case of a failure.

Definition at line 161 of file varr.h.

◆ va_magic

uint64_t va_magic

Magic field to cross check sanity of structure.

Definition at line 163 of file varr.h.

◆ va_nr

uint64_t va_nr

Number of elements in array.

Definition at line 123 of file varr.h.

◆ va_obj_shift

uint8_t va_obj_shift

Log of object-size to the base two.

Definition at line 128 of file varr.h.

◆ va_obj_size

size_t va_obj_size

Definition at line 126 of file varr.h.

◆ va_tree

void* va_tree[M0_VA_TNODE_NR]

Array of radix tree nodes, each of which represents an abstraction of buffer containing multitude of objects. The arrangement is such that there could be n levels within any tree node before a leaf node is reached.

Definition at line 157 of file varr.h.


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