38schedule_entry_debug_info(
const char *caller,
const struct schedule_entry *e)
67 if (e1->
tv.tv_sec < e2->
tv.tv_sec)
71 else if (e1->
tv.tv_sec > e2->
tv.tv_sec)
77 if (e1->
tv.tv_usec < e2->
tv.tv_usec)
81 else if (e1->
tv.tv_usec > e2->
tv.tv_usec)
91 else if (e1->
pri > e2->
pri)
165 else if (gp->
lt == p)
222 while (e->
lt || e->
gt)
314 schedule_entry_debug_info(
"schedule_add_modify", e);
361 schedule_entry_debug_info(
"schedule_find_least", e);
Buffer management functions and garbage collection.
static void gc_free(struct gc_arena *a)
Free all allocations in a garbage collection arena.
#define ALLOC_OBJ_CLEAR(dptr, type)
Allocate and zero-initialise memory for a single object of the given type.
static struct gc_arena gc_new(void)
Allocate and return a new, empty garbage collection arena.
Data Channel Cryptography Module.
static bool check_debug_level(msglvl_t level)
const char * tv_string_abs(const struct timeval *tv, struct gc_arena *gc)
static void schedule_set_pri(struct schedule_entry *e)
static void schedule_rotate_up(struct schedule *s, struct schedule_entry *e)
void schedule_remove_entry(struct schedule *s, struct schedule_entry *e)
struct schedule * schedule_init(void)
void schedule_remove_node(struct schedule *s, struct schedule_entry *e)
struct schedule_entry * schedule_find_least(struct schedule_entry *e)
int schedule_entry_compare(const struct schedule_entry *e1, const struct schedule_entry *e2)
This method compares two schedule entries and return which one is earlier,later or equal.
void schedule_add_modify(struct schedule *s, struct schedule_entry *e)
static void schedule_insert(struct schedule *s, struct schedule_entry *e)
void schedule_free(struct schedule *s)
static void schedule_detach_parent(struct schedule *s, struct schedule_entry *e)
Garbage collection arena used to keep track of dynamically allocated memory.
struct schedule_entry * lt
struct schedule_entry * parent
struct schedule_entry * gt
struct schedule_entry * earliest_wakeup
struct schedule_entry * root