unbound
0.1
|
Hash table that keeps LRU list of entries. More...
#include <lruhash.h>
Data Fields | |
lock_quick_type | lock |
lock for exclusive access, to the lookup array | |
lruhash_sizefunc_type | sizefunc |
the size function for entries in this table | |
lruhash_compfunc_type | compfunc |
the compare function for entries in this table. More... | |
lruhash_delkeyfunc_type | delkeyfunc |
how to delete keys. More... | |
lruhash_deldatafunc_type | deldatafunc |
how to delete data. More... | |
lruhash_markdelfunc_type | markdelfunc |
how to mark a key pending deletion | |
void * | cb_arg |
user argument for user functions | |
size_t | size |
the size of the lookup array | |
int | size_mask |
size bitmask - since size is a power of 2 | |
struct lruhash_bin * | array |
lookup array of bins | |
struct lruhash_entry * | lru_start |
the lru list, start and end, noncyclical double linked list. More... | |
struct lruhash_entry * | lru_end |
lru list end item (least recently used) | |
size_t | num |
the number of entries in the hash table. More... | |
size_t | space_used |
the amount of space used, roughly the number of bytes in use. More... | |
size_t | space_max |
the amount of space the hash table is maximally allowed to use. More... | |
Hash table that keeps LRU list of entries.
lruhash_compfunc_type lruhash::compfunc |
the compare function for entries in this table.
Referenced by bin_find_entry(), lruhash_create(), lruhash_insert(), lruhash_insert_or_retrieve(), lruhash_lookup(), lruhash_remove(), and slabhash_create().
lruhash_delkeyfunc_type lruhash::delkeyfunc |
how to delete keys.
Referenced by bin_clear(), bin_delete(), lruhash_clear(), lruhash_create(), lruhash_insert(), lruhash_insert_or_retrieve(), lruhash_remove(), and slabhash_create().
lruhash_deldatafunc_type lruhash::deldatafunc |
how to delete data.
Referenced by bin_clear(), bin_delete(), lruhash_clear(), lruhash_create(), lruhash_insert(), lruhash_insert_or_retrieve(), lruhash_remove(), and slabhash_create().
struct lruhash_entry* lruhash::lru_start |
the lru list, start and end, noncyclical double linked list.
Referenced by check_lru_table(), check_table(), dump_msg_lruhash(), dump_rrset_lruhash(), lru_demote(), lru_front(), lru_remove(), lru_touch(), lruhash_clear(), lruhash_create(), and test_lru().
size_t lruhash::num |
the number of entries in the hash table.
Referenced by check_lru_table(), check_table(), lruhash_clear(), lruhash_create(), lruhash_insert(), lruhash_insert_or_retrieve(), lruhash_remove(), lruhash_status(), reclaim_space(), and test_long_table().
size_t lruhash::space_used |
the amount of space used, roughly the number of bytes in use.
Referenced by check_lru_table(), check_table(), lruhash_clear(), lruhash_create(), lruhash_get_mem(), lruhash_insert(), lruhash_insert_or_retrieve(), lruhash_remove(), lruhash_status(), and reclaim_space().
size_t lruhash::space_max |
the amount of space the hash table is maximally allowed to use.
Referenced by check_lru_table(), check_table(), lruhash_create(), lruhash_insert(), lruhash_insert_or_retrieve(), lruhash_status(), reclaim_space(), slabhash_get_size(), and test_long_table().