PostgreSQL Source Code
git master
|
Go to the source code of this file.
Typedefs | |
typedef struct bloom_filter | bloom_filter |
Functions | |
bloom_filter * | bloom_create (int64 total_elems, int bloom_work_mem, uint64 seed) |
void | bloom_free (bloom_filter *filter) |
void | bloom_add_element (bloom_filter *filter, unsigned char *elem, size_t len) |
bool | bloom_lacks_element (bloom_filter *filter, unsigned char *elem, size_t len) |
double | bloom_prop_bits_set (bloom_filter *filter) |
typedef struct bloom_filter bloom_filter |
Definition at line 1 of file bloomfilter.h.
void bloom_add_element | ( | bloom_filter * | filter, |
unsigned char * | elem, | ||
size_t | len | ||
) |
Definition at line 135 of file bloomfilter.c.
References bloom_filter::bitset, i, bloom_filter::k_hash_funcs, k_hashes(), len, and MAX_HASH_FUNCS.
Referenced by bt_target_page_check(), populate_with_dummy_strings(), and roles_list_append().
bloom_filter* bloom_create | ( | int64 | total_elems, |
int | bloom_work_mem, | ||
uint64 | seed | ||
) |
Definition at line 87 of file bloomfilter.c.
References BITS_PER_BYTE, bloom_filter::k_hash_funcs, bloom_filter::m, Max, Min, my_bloom_power(), optimal_k(), palloc0(), bloom_filter::seed, and UINT64CONST.
Referenced by bt_check_every_level(), create_and_test_bloom(), and roles_list_append().
void bloom_free | ( | bloom_filter * | filter | ) |
Definition at line 126 of file bloomfilter.c.
References pfree().
Referenced by bt_check_every_level(), create_and_test_bloom(), and roles_is_member_of().
bool bloom_lacks_element | ( | bloom_filter * | filter, |
unsigned char * | elem, | ||
size_t | len | ||
) |
Definition at line 157 of file bloomfilter.c.
References bloom_filter::bitset, i, bloom_filter::k_hash_funcs, k_hashes(), len, and MAX_HASH_FUNCS.
Referenced by bt_tuple_present_callback(), nfalsepos_for_missing_strings(), and roles_list_append().
double bloom_prop_bits_set | ( | bloom_filter * | filter | ) |
Definition at line 187 of file bloomfilter.c.
References BITS_PER_BYTE, bloom_filter::bitset, bloom_filter::m, and pg_popcount().
Referenced by bt_check_every_level(), and create_and_test_bloom().