FD.io VPP  v21.06-3-gbb25fbf28
Vector Packet Processing
stat_segment.h File Reference
+ Include dependency graph for stat_segment.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  stat_segment_gauges_pool_t
 
struct  stat_segment_main_t
 

Macros

#define foreach_stat_segment_node_counter_name
 
#define foreach_stat_segment_counter_name
 
#define STAT_SEGMENT_DEFAULT_SIZE   (32<<20)
 
#define STAT_SEGMENT_VERSION   2
 
#define STAT_SEGMENT_INDEX_INVALID   UINT32_MAX
 

Typedefs

typedef void(* stat_segment_update_fn) (stat_segment_directory_entry_t *e, u32 i)
 

Enumerations

enum  stat_segment_counter_t {
  STAT_COUNTER_NUM_WORKER_THREADS = 0, STAT_COUNTER_INPUT_RATE, STAT_COUNTER_LAST_UPDATE, STAT_COUNTER_LAST_STATS_CLEAR,
  STAT_COUNTER_HEARTBEAT, STAT_COUNTER_NODE_CLOCKS, STAT_COUNTER_NODE_VECTORS, STAT_COUNTER_NODE_CALLS,
  STAT_COUNTER_NODE_SUSPENDS, STAT_COUNTER_INTERFACE_NAMES, STAT_COUNTER_NODE_NAMES, STAT_COUNTERS
}
 

Functions

clib_error_tstat_segment_register_gauge (u8 *names, stat_segment_update_fn update_fn, u32 index)
 
clib_error_tstat_segment_register_state_counter (u8 *name, u32 *index)
 
clib_error_tstat_segment_deregister_state_counter (u32 index)
 
void stat_segment_set_state_counter (u32 index, u64 value)
 
void stat_segment_poll_add (u32 vector_index, stat_segment_update_fn update_fn, u32 caller_index, u32 interval)
 
u32 stat_segment_new_entry (u8 *name, stat_directory_type_t t)
 
void vlib_stats_register_mem_heap (clib_mem_heap_t *heap)
 
void vlib_stat_segment_lock (void)
 
void vlib_stat_segment_unlock (void)
 
void vlib_stats_register_symlink (void *oldheap, u8 *name, u32 index1, u32 index2, u8 lock)
 
void stat_provider_register_vector_rate (u32 num_workers)
 

Variables

stat_segment_main_t stat_segment_main
 

Macro Definition Documentation

◆ foreach_stat_segment_counter_name

#define foreach_stat_segment_counter_name
Value:
_ (NUM_WORKER_THREADS, SCALAR_INDEX, num_worker_threads, /sys) \
_ (INPUT_RATE, SCALAR_INDEX, input_rate, /sys) \
_ (LAST_UPDATE, SCALAR_INDEX, last_update, /sys) \
_ (LAST_STATS_CLEAR, SCALAR_INDEX, last_stats_clear, /sys) \
_ (HEARTBEAT, SCALAR_INDEX, heartbeat, /sys) \
_ (INTERFACE_NAMES, NAME_VECTOR, names, /if) \
_ (NODE_NAMES, NAME_VECTOR, names, /sys/node) \
foreach_stat_segment_node_counter_name

Definition at line 46 of file stat_segment.h.

◆ foreach_stat_segment_node_counter_name

#define foreach_stat_segment_node_counter_name
Value:
_ (NODE_CLOCKS, COUNTER_VECTOR_SIMPLE, clocks, /sys/node) \
_ (NODE_VECTORS, COUNTER_VECTOR_SIMPLE, vectors, /sys/node) \
_ (NODE_CALLS, COUNTER_VECTOR_SIMPLE, calls, /sys/node) \
_ (NODE_SUSPENDS, COUNTER_VECTOR_SIMPLE, suspends, /sys/node)

Definition at line 40 of file stat_segment.h.

◆ STAT_SEGMENT_DEFAULT_SIZE

#define STAT_SEGMENT_DEFAULT_SIZE   (32<<20)

Definition at line 58 of file stat_segment.h.

◆ STAT_SEGMENT_INDEX_INVALID

#define STAT_SEGMENT_INDEX_INVALID   UINT32_MAX

Definition at line 63 of file stat_segment.h.

◆ STAT_SEGMENT_VERSION

#define STAT_SEGMENT_VERSION   2

Definition at line 61 of file stat_segment.h.

Typedef Documentation

◆ stat_segment_update_fn

typedef void(* stat_segment_update_fn) (stat_segment_directory_entry_t *e, u32 i)

Definition at line 65 of file stat_segment.h.

Enumeration Type Documentation

◆ stat_segment_counter_t

Enumerator
STAT_COUNTER_NUM_WORKER_THREADS 
STAT_COUNTER_INPUT_RATE 
STAT_COUNTER_LAST_UPDATE 
STAT_COUNTER_LAST_STATS_CLEAR 
STAT_COUNTER_HEARTBEAT 
STAT_COUNTER_NODE_CLOCKS 
STAT_COUNTER_NODE_VECTORS 
STAT_COUNTER_NODE_CALLS 
STAT_COUNTER_NODE_SUSPENDS 
STAT_COUNTER_INTERFACE_NAMES 
STAT_COUNTER_NODE_NAMES 
STAT_COUNTERS 

Definition at line 23 of file stat_segment.h.

Function Documentation

◆ stat_provider_register_vector_rate()

void stat_provider_register_vector_rate ( u32  num_workers)

Definition at line 173 of file stat_segment_provider.c.

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

◆ stat_segment_deregister_state_counter()

clib_error_t* stat_segment_deregister_state_counter ( u32  index)

Definition at line 934 of file stat_segment.c.

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

◆ stat_segment_new_entry()

u32 stat_segment_new_entry ( u8 name,
stat_directory_type_t  t 
)

Definition at line 393 of file stat_segment.c.

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

◆ stat_segment_poll_add()

void stat_segment_poll_add ( u32  vector_index,
stat_segment_update_fn  update_fn,
u32  caller_index,
u32  interval 
)

Definition at line 884 of file stat_segment.c.

+ Here is the caller graph for this function:

◆ stat_segment_register_gauge()

clib_error_t* stat_segment_register_gauge ( u8 names,
stat_segment_update_fn  update_fn,
u32  index 
)

Definition at line 23 of file pnat_test_stubs.h.

+ Here is the call graph for this function:

◆ stat_segment_register_state_counter()

clib_error_t* stat_segment_register_state_counter ( u8 name,
u32 index 
)

Definition at line 922 of file stat_segment.c.

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

◆ stat_segment_set_state_counter()

void stat_segment_set_state_counter ( u32  index,
u64  value 
)

Definition at line 962 of file stat_segment.c.

+ Here is the caller graph for this function:

◆ vlib_stat_segment_lock()

void vlib_stat_segment_lock ( void  )

Definition at line 30 of file stat_segment.c.

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

◆ vlib_stat_segment_unlock()

void vlib_stat_segment_unlock ( void  )

Definition at line 38 of file stat_segment.c.

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

◆ vlib_stats_register_mem_heap()

void vlib_stats_register_mem_heap ( clib_mem_heap_t heap)

Definition at line 84 of file stat_segment_provider.c.

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

◆ vlib_stats_register_symlink()

void vlib_stats_register_symlink ( void *  oldheap,
u8 name,
u32  index1,
u32  index2,
u8  lock 
)

Definition at line 249 of file stat_segment.c.

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

Variable Documentation

◆ stat_segment_main

stat_segment_main_t stat_segment_main

Definition at line 24 of file stat_segment.c.

node
vlib_main_t vlib_node_runtime_t * node
Definition: nat44_ei.c:3047