FD.io VPP  v16.12-rc0-308-g931be3a
Vector Packet Processing
timing_wheel.c File Reference
+ Include dependency graph for timing_wheel.c:

Go to the source code of this file.

Functions

void timing_wheel_init (timing_wheel_t *w, u64 current_cpu_time, f64 cpu_clocks_per_second)
 
static uword get_level_and_relative_time (timing_wheel_t *w, u64 cpu_time, uword *rtime_result)
 
static uword time_index_to_wheel_index (timing_wheel_t *w, uword level_index, u64 ti)
 
static uword current_time_wheel_index (timing_wheel_t *w, uword level_index)
 
static uword wheel_add (timing_wheel_t *w, word x)
 
static uword rtime_to_wheel_index (timing_wheel_t *w, uword level_index, uword rtime)
 
static clib_error_tvalidate_level (timing_wheel_t *w, uword level_index, uword *n_elts)
 
void timing_wheel_validate (timing_wheel_t *w)
 
static void free_elt_vector (timing_wheel_t *w, timing_wheel_elt_t *ev)
 
static timing_wheel_elt_tinsert_helper (timing_wheel_t *w, uword level_index, uword rtime)
 
static void timing_wheel_insert_helper (timing_wheel_t *w, u64 insert_cpu_time, u32 user_data)
 
static uword elt_is_deleted (timing_wheel_t *w, u32 user_data)
 
static timing_wheel_elt_tdelete_user_data (timing_wheel_elt_t *elts, u32 user_data)
 
void timing_wheel_insert (timing_wheel_t *w, u64 insert_cpu_time, u32 user_data)
 
void timing_wheel_delete (timing_wheel_t *w, u32 user_data)
 
u64 timing_wheel_next_expiring_elt_time (timing_wheel_t *w)
 
static void insert_elt (timing_wheel_t *w, timing_wheel_elt_t *e)
 
static u64 elt_cpu_time (timing_wheel_t *w, timing_wheel_elt_t *e)
 
static void validate_expired_elt (timing_wheel_t *w, timing_wheel_elt_t *e, u64 current_cpu_time)
 
static u32expire_bin (timing_wheel_t *w, uword level_index, uword wheel_index, u64 advance_cpu_time, u32 *expired_user_data)
 
static void advance_cpu_time_base (timing_wheel_t *w, u32 *expired_user_data)
 
static u32refill_level (timing_wheel_t *w, uword level_index, u64 advance_cpu_time, uword from_wheel_index, uword to_wheel_index, u32 *expired_user_data)
 
u32timing_wheel_advance (timing_wheel_t *w, u64 advance_cpu_time, u32 *expired_user_data, u64 *next_expiring_element_cpu_time)
 
u8format_timing_wheel (u8 *s, va_list *va)
 

Function Documentation

static void advance_cpu_time_base ( timing_wheel_t w,
u32 expired_user_data 
)
static

Definition at line 472 of file timing_wheel.c.

+ Here is the caller graph for this function:

static uword current_time_wheel_index ( timing_wheel_t w,
uword  level_index 
)
inlinestatic

Definition at line 89 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static timing_wheel_elt_t* delete_user_data ( timing_wheel_elt_t elts,
u32  user_data 
)
static

Definition at line 261 of file timing_wheel.c.

static u64 elt_cpu_time ( timing_wheel_t w,
timing_wheel_elt_t e 
)
inlinestatic

Definition at line 416 of file timing_wheel.c.

+ Here is the caller graph for this function:

static uword elt_is_deleted ( timing_wheel_t w,
u32  user_data 
)
inlinestatic

Definition at line 254 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static u32* expire_bin ( timing_wheel_t w,
uword  level_index,
uword  wheel_index,
u64  advance_cpu_time,
u32 expired_user_data 
)
static

Definition at line 436 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u8* format_timing_wheel ( u8 s,
va_list *  va 
)

Definition at line 709 of file timing_wheel.c.

+ Here is the call graph for this function:

static void free_elt_vector ( timing_wheel_t w,
timing_wheel_elt_t ev 
)
inlinestatic

Definition at line 183 of file timing_wheel.c.

+ Here is the caller graph for this function:

static uword get_level_and_relative_time ( timing_wheel_t w,
u64  cpu_time,
uword rtime_result 
)
inlinestatic

Definition at line 56 of file timing_wheel.c.

+ Here is the caller graph for this function:

static void insert_elt ( timing_wheel_t w,
timing_wheel_elt_t e 
)
inlinestatic

Definition at line 409 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static timing_wheel_elt_t* insert_helper ( timing_wheel_t w,
uword  level_index,
uword  rtime 
)
static

Definition at line 193 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static u32* refill_level ( timing_wheel_t w,
uword  level_index,
u64  advance_cpu_time,
uword  from_wheel_index,
uword  to_wheel_index,
u32 expired_user_data 
)
static

Definition at line 525 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static uword rtime_to_wheel_index ( timing_wheel_t w,
uword  level_index,
uword  rtime 
)
inlinestatic

Definition at line 102 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static uword time_index_to_wheel_index ( timing_wheel_t w,
uword  level_index,
u64  ti 
)
inlinestatic

Definition at line 81 of file timing_wheel.c.

+ Here is the caller graph for this function:

u32* timing_wheel_advance ( timing_wheel_t w,
u64  advance_cpu_time,
u32 expired_user_data,
u64 next_expiring_element_cpu_time 
)

Definition at line 587 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void timing_wheel_delete ( timing_wheel_t w,
u32  user_data 
)

Definition at line 329 of file timing_wheel.c.

+ Here is the caller graph for this function:

void timing_wheel_init ( timing_wheel_t w,
u64  current_cpu_time,
f64  cpu_clocks_per_second 
)

Definition at line 21 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void timing_wheel_insert ( timing_wheel_t w,
u64  insert_cpu_time,
u32  user_data 
)

Definition at line 292 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static void timing_wheel_insert_helper ( timing_wheel_t w,
u64  insert_cpu_time,
u32  user_data 
)
static

Definition at line 227 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u64 timing_wheel_next_expiring_elt_time ( timing_wheel_t w)

Definition at line 340 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void timing_wheel_validate ( timing_wheel_t w)

Definition at line 164 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static void validate_expired_elt ( timing_wheel_t w,
timing_wheel_elt_t e,
u64  current_cpu_time 
)
inlinestatic

Definition at line 422 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static clib_error_t* validate_level ( timing_wheel_t w,
uword  level_index,
uword n_elts 
)
static

Definition at line 109 of file timing_wheel.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static uword wheel_add ( timing_wheel_t w,
word  x 
)
inlinestatic

Definition at line 96 of file timing_wheel.c.

+ Here is the caller graph for this function: