Lines Matching refs:md

157     struct ht_mutable_data_st *md;  member
216 new->md = OPENSSL_zalloc(sizeof(*new->md)); in ossl_ht_new()
217 if (new->md == NULL) in ossl_ht_new()
220 new->md->neighborhoods = in ossl_ht_new()
222 &new->md->neighborhood_ptr_to_free); in ossl_ht_new()
223 if (new->md->neighborhoods == NULL) in ossl_ht_new()
225 new->md->neighborhood_mask = new->wpd.neighborhood_len - 1; in ossl_ht_new()
239 if (new->md != NULL) in ossl_ht_new()
240 OPENSSL_free(new->md->neighborhood_ptr_to_free); in ossl_ht_new()
241 OPENSSL_free(new->md); in ossl_ht_new()
313 oldmd = ossl_rcu_deref(&h->md); in ossl_ht_flush_internal()
314 ossl_rcu_assign_ptr(&h->md, &newmd); in ossl_ht_flush_internal()
341 OPENSSL_free(h->md->neighborhood_ptr_to_free); in ossl_ht_free()
342 OPENSSL_free(h->md); in ossl_ht_free()
359 struct ht_mutable_data_st *md; in ossl_ht_foreach_until() local
361 md = ossl_rcu_deref(&h->md); in ossl_ht_foreach_until()
362 for (i = 0; i < md->neighborhood_mask + 1; i++) { in ossl_ht_foreach_until()
363 PREFETCH_NEIGHBORHOOD(md->neighborhoods[i + 1]); in ossl_ht_foreach_until()
365 if (md->neighborhoods[i].entries[j].value != NULL) { in ossl_ht_foreach_until()
366 if (!cb((HT_VALUE *)md->neighborhoods[i].entries[j].value, arg)) in ossl_ht_foreach_until()
379 struct ht_mutable_data_st *md; in ossl_ht_filter() local
394 md = ossl_rcu_deref(&h->md); in ossl_ht_filter()
395 for (i = 0; i < md->neighborhood_mask + 1; i++) { in ossl_ht_filter()
396 PREFETCH_NEIGHBORHOOD(md->neighborhoods[i+1]); in ossl_ht_filter()
398 v = md->neighborhoods[i].entries[j].value; in ossl_ht_filter()
435 struct ht_mutable_data_st *oldmd = ossl_rcu_deref(&h->md); in grow_hashtable()
497 ossl_rcu_assign_ptr(&h->md, &newmd); in grow_hashtable()
544 struct ht_mutable_data_st *md = h->md; in ossl_ht_insert_locked() local
545 uint64_t neigh_idx_start = hash & md->neighborhood_mask; in ossl_ht_insert_locked()
554 PREFETCH_NEIGHBORHOOD(md->neighborhoods[neigh_idx]); in ossl_ht_insert_locked()
557 ival = ossl_rcu_deref(&md->neighborhoods[neigh_idx].entries[j].value); in ossl_ht_insert_locked()
565 if (!CRYPTO_atomic_load(&md->neighborhoods[neigh_idx].entries[j].hash, in ossl_ht_insert_locked()
575 if (!CRYPTO_atomic_store(&md->neighborhoods[neigh_idx].entries[j].hash, in ossl_ht_insert_locked()
578 *olddata = (HT_VALUE *)md->neighborhoods[neigh_idx].entries[j].value; in ossl_ht_insert_locked()
579 ossl_rcu_assign_ptr(&md->neighborhoods[neigh_idx].entries[j].value, in ossl_ht_insert_locked()
589 neigh_idx = (neigh_idx + 1) & md->neighborhood_mask; in ossl_ht_insert_locked()
596 if (!CRYPTO_atomic_store(&md->neighborhoods[neigh_idx].entries[empty_idx].hash, in ossl_ht_insert_locked()
600 ossl_rcu_assign_ptr(&md->neighborhoods[neigh_idx].entries[empty_idx].value, in ossl_ht_insert_locked()
677 struct ht_mutable_data_st *md; in ossl_ht_get() local
688 md = ossl_rcu_deref(&h->md); in ossl_ht_get()
689 neigh_idx = neigh_idx_start = hash & md->neighborhood_mask; in ossl_ht_get()
691 PREFETCH_NEIGHBORHOOD(md->neighborhoods[neigh_idx]); in ossl_ht_get()
693 ival = ossl_rcu_deref(&md->neighborhoods[neigh_idx].entries[j].value); in ossl_ht_get()
700 if (!CRYPTO_atomic_load(&md->neighborhoods[neigh_idx].entries[j].hash, in ossl_ht_get()
709 neigh_idx = (neigh_idx + 1) & md->neighborhood_mask; in ossl_ht_get()
737 neigh_idx = hash & h->md->neighborhood_mask; in ossl_ht_delete()
738 PREFETCH_NEIGHBORHOOD(h->md->neighborhoods[neigh_idx]); in ossl_ht_delete()
740 v = (struct ht_internal_value_st *)h->md->neighborhoods[neigh_idx].entries[j].value; in ossl_ht_delete()
743 if (compare_hash(hash, h->md->neighborhoods[neigh_idx].entries[j].hash) in ossl_ht_delete()
745 if (!CRYPTO_atomic_store(&h->md->neighborhoods[neigh_idx].entries[j].hash, in ossl_ht_delete()
749 ossl_rcu_assign_ptr(&h->md->neighborhoods[neigh_idx].entries[j].value, in ossl_ht_delete()