hashtable.h File Reference

Header for DynamoRIO Hashtable Extension. More...

Data Structures

struct  _hashtable_config_t
 

Typedefs

typedef struct _hashtable_config_t hashtable_config_t
 

Enumerations

enum  hash_type_t {
  HASH_INTPTR,
  HASH_STRING,
  HASH_STRING_NOCASE,
  HASH_CUSTOM
}
 
enum  hasthable_persist_flags_t {
  DR_HASHPERS_PAYLOAD_IS_POINTER = 0x0001,
  DR_HASHPERS_CLONE_PAYLOAD = 0x0002,
  DR_HASHPERS_REBASE_KEY = 0x0004,
  DR_HASHPERS_ONLY_IN_RANGE = 0x0008,
  DR_HASHPERS_ONLY_PERSISTED = 0x0010
}
 

Functions

bool stri_eq (const char *s1, const char *s2)
 
void hashtable_global_config (void *(*alloc_func)(size_t), void(*free_func)(void *, size_t), void(*assert_fail_func)(const char *))
 
void hashtable_init (hashtable_t *table, uint num_bits, hash_type_t hashtype, bool str_dup)
 
void hashtable_init_ex (hashtable_t *table, uint num_bits, hash_type_t hashtype, bool str_dup, bool synch, void(*free_payload_func)(void *), uint(*hash_key_func)(void *), bool(*cmp_key_func)(void *, void *))
 
void hashtable_configure (hashtable_t *table, hashtable_config_t *config)
 
void * hashtable_lookup (hashtable_t *table, void *key)
 
bool hashtable_add (hashtable_t *table, void *key, void *payload)
 
void * hashtable_add_replace (hashtable_t *table, void *key, void *payload)
 
bool hashtable_remove (hashtable_t *table, void *key)
 
bool hashtable_remove_range (hashtable_t *table, void *start, void *end)
 
void hashtable_apply_to_all_payloads (hashtable_t *table, void(*apply_func)(void *payload))
 
void hashtable_apply_to_all_payloads_user_data (hashtable_t *table, void(*apply_func)(void *payload, void *user_data), void *user_data)
 
void hashtable_clear (hashtable_t *table)
 
void hashtable_delete (hashtable_t *table)
 
void hashtable_lock (hashtable_t *table)
 
void hashtable_unlock (hashtable_t *table)
 
bool hashtable_lock_self_owns (hashtable_t *table)
 
size_t hashtable_persist_size (void *drcontext, hashtable_t *table, size_t entry_size, void *perscxt, hasthable_persist_flags_t flags)
 
bool hashtable_persist (void *drcontext, hashtable_t *table, size_t entry_size, file_t fd, void *perscxt, hasthable_persist_flags_t flags)
 
bool hashtable_resurrect (void *drcontext, byte **map, hashtable_t *table, size_t entry_size, void *perscxt, hasthable_persist_flags_t flags, bool(*process_payload)(void *key, void *payload, ptr_int_t shift))
 

Detailed Description

Header for DynamoRIO Hashtable Extension.