#define DEFAULT_MIN_ALLOC_SIZE 1
#define DEFAULT_RAND_POOL 1000000
+/*
+ * Note: the hash seed should be a random value for hash tables
+ * targeting production environments to provide protection against
+ * denial of service attacks. We keep it a static value within this test
+ * program to compare identical benchmark runs.
+ */
#define TEST_HASH_SEED 0x42UL
/* Make this big enough to include the POWER5+ L3 cacheline size of 256B */
cds_lfht_test_lookup(test_ht,
(void *)(((unsigned long) rand_r(&rand_lookup) % write_pool_size) + write_pool_offset),
sizeof(void *), &iter);
- ret = cds_lfht_del(test_ht, &iter);
+ ret = cds_lfht_del(test_ht, cds_lfht_iter_get_node(&iter));
rcu_read_unlock();
if (ret == 0) {
node = cds_lfht_iter_get_test_node(&iter);
cds_lfht_for_each_entry(ht, &iter, node, node) {
int ret;
- ret = cds_lfht_del(test_ht, &iter);
+ ret = cds_lfht_del(test_ht, cds_lfht_iter_get_node(&iter));
assert(!ret);
call_rcu(&node->head, free_node_cb);
count++;