|
__host__ | SingleValueHashTable (const index_type min_capacity, const key_type seed=defaults::seed< key_type >(), const bool no_init=false) noexcept |
| constructor More...
|
|
__host____device__ | SingleValueHashTable (const SingleValueHashTable &o) noexcept |
| copy-constructor (shallow) More...
|
|
__host__ | SingleValueHashTable (SingleValueHashTable &&o) noexcept |
| move-constructor More...
|
|
__host__ | ~SingleValueHashTable () noexcept |
| destructor More...
|
|
__host__ void | init (const key_type seed, const cudaStream_t stream=0) noexcept |
| (re)initialize the hash table More...
|
|
__host__ void | init (const cudaStream_t stream=0) noexcept |
| (re)initialize the hash table More...
|
|
__device__ status_type | insert (const key_type key_in, const value_type &value_in, const cg::thread_block_tile< cg_size()> &group, const index_type probing_length=defaults::probing_length()) noexcept |
| inserts a key into the hash table More...
|
|
template<class StatusHandler = defaults::status_handler_t> |
__host__ void | insert (const key_type *const keys_in, const value_type *const values_in, const index_type num_in, const cudaStream_t stream=0, const index_type probing_length=defaults::probing_length(), typename StatusHandler::base_type *const status_out=nullptr) noexcept |
| insert a set of keys into the hash table More...
|
|
__device__ status_type | retrieve (const key_type key_in, value_type &value_out, const cg::thread_block_tile< cg_size()> &group, const index_type probing_length=defaults::probing_length()) const noexcept |
| retrieves a key from the hash table More...
|
|
template<class StatusHandler = defaults::status_handler_t> |
__host__ void | retrieve (const key_type *const keys_in, const index_type num_in, value_type *const values_out, const cudaStream_t stream=0, const index_type probing_length=defaults::probing_length(), typename StatusHandler::base_type *const status_out=nullptr) const noexcept |
| retrieve a set of keys from the hash table More...
|
|
template<class StatusHandler = defaults::status_handler_t> |
__host__ void | retrieve (const key_type *const keys_in, const index_type num_in, key_type *const keys_out, value_type *const values_out, index_type &num_out, const cudaStream_t stream=0, const index_type probing_length=defaults::probing_length(), typename StatusHandler::base_type *const status_out=nullptr) const noexcept |
| retrieve a set of keys from the hash table More...
|
|
__host__ void | retrieve_all (key_type *const keys_out, value_type *const values_out, index_type &num_out, const cudaStream_t stream=0) const noexcept |
| retrieves all elements from the hash table More...
|
|
__device__ status_type | erase (const key_type key_in, const cg::thread_block_tile< cg_size()> &group, const index_type probing_length=defaults::probing_length()) noexcept |
| erases a key from the hash table More...
|
|
template<class StatusHandler = defaults::status_handler_t> |
__host__ void | erase (const key_type *const keys_in, const index_type num_in, const cudaStream_t stream=0, const index_type probing_length=defaults::probing_length(), typename StatusHandler::base_type *const status_out=nullptr) noexcept |
| erases a set of keys from the hash table More...
|
|
template<class Func > |
__host__ void | for_each (Func f, const cudaStream_t stream=0, const index_type smem_bytes=0) const noexcept |
| applies a funtion over all key value pairs inside the table More...
|
|
__host__ index_type | size (const cudaStream_t stream=0) const noexcept |
| number of key/value pairs stored inside the hash table More...
|
|
__host__ float | load_factor (const cudaStream_t stream=0) const noexcept |
| current load factor of the hash table More...
|
|
__host__ float | storage_density (const cudaStream_t stream=0) const noexcept |
| current storage density of the hash table More...
|
|
__host____device__ index_type | capacity () const noexcept |
| get the capacity of the hash table More...
|
|
__host__ index_type | bytes_total () const noexcept |
| get the total number of bytes occupied by this data structure More...
|
|
__host____device__ bool | is_initialized () const noexcept |
| indicates if the hash table is properly initialized More...
|
|
__host__ status_type | peek_status (const cudaStream_t stream=0) const noexcept |
| get the status of the hash table More...
|
|
__host__ status_type | pop_status (const cudaStream_t stream=0) noexcept |
| get and reset the status of the hash table More...
|
|
__host____device__ key_type | seed () const noexcept |
| get random seed More...
|
|
__host____device__ bool | is_copy () const noexcept |
| indicates if this object is a shallow copy More...
|
|
template<class Key, class Value, Key EmptyKey = defaults::empty_key<Key>(), Key TombstoneKey = defaults::tombstone_key<Key>(), class ProbingScheme = defaults::probing_scheme_t<Key, 8>, class TableStorage = defaults::table_storage_t<Key, Value>, index_t TempMemoryBytes = defaults::temp_memory_bytes()>
class warpcore::SingleValueHashTable< Key, Value, EmptyKey, TombstoneKey, ProbingScheme, TableStorage, TempMemoryBytes >
single-value hash table
- Template Parameters
-
Key | key type (std::uint32_t or std::uint64_t ) |
Value | value type |
EmptyKey | key which represents an empty slot |
TombstoneKey | key which represents an erased slot |
ProbingScheme | probing scheme from warpcore::probing_schemes |
TableStorage | memory layout from warpcore::storage::key_value |
TempMemoryBytes | size of temporary storage (typically a few kB) |
Definition at line 37 of file single_value_hash_table.cuh.
template<class Key , class Value , Key EmptyKey = defaults::empty_key<Key>(), Key TombstoneKey = defaults::tombstone_key<Key>(), class ProbingScheme = defaults::probing_scheme_t<Key, 8>, class TableStorage = defaults::table_storage_t<Key, Value>, index_t TempMemoryBytes = defaults::temp_memory_bytes()>
template<class StatusHandler = defaults::status_handler_t>
__host__ void warpcore::SingleValueHashTable< Key, Value, EmptyKey, TombstoneKey, ProbingScheme, TableStorage, TempMemoryBytes >::erase |
( |
const key_type *const |
keys_in, |
|
|
const index_type |
num_in, |
|
|
const cudaStream_t |
stream = 0 , |
|
|
const index_type |
probing_length = defaults::probing_length() , |
|
|
typename StatusHandler::base_type *const |
status_out = nullptr |
|
) |
| |
|
inlinenoexcept |
erases a set of keys from the hash table
- Template Parameters
-
- Parameters
-
[in] | keys_in | pointer to keys to erase from the hash table |
[in] | num_in | number of keys to erase |
[in] | probing_length | maximum number of probing attempts |
[in] | stream | CUDA stream in which this operation is executed in |
[out] | status_out | status information (per key) |
Definition at line 480 of file single_value_hash_table.cuh.
template<class Key , class Value , Key EmptyKey = defaults::empty_key<Key>(), Key TombstoneKey = defaults::tombstone_key<Key>(), class ProbingScheme = defaults::probing_scheme_t<Key, 8>, class TableStorage = defaults::table_storage_t<Key, Value>, index_t TempMemoryBytes = defaults::temp_memory_bytes()>
template<class StatusHandler = defaults::status_handler_t>
__host__ void warpcore::SingleValueHashTable< Key, Value, EmptyKey, TombstoneKey, ProbingScheme, TableStorage, TempMemoryBytes >::insert |
( |
const key_type *const |
keys_in, |
|
|
const value_type *const |
values_in, |
|
|
const index_type |
num_in, |
|
|
const cudaStream_t |
stream = 0 , |
|
|
const index_type |
probing_length = defaults::probing_length() , |
|
|
typename StatusHandler::base_type *const |
status_out = nullptr |
|
) |
| |
|
inlinenoexcept |
insert a set of keys into the hash table
- Template Parameters
-
- Parameters
-
[in] | keys_in | pointer to keys to insert into the hash table |
[in] | values_in | corresponds values to keys_in |
[in] | num_in | number of keys to insert |
[in] | stream | CUDA stream in which this operation is executed in |
[in] | probing_length | maximum number of probing attempts |
[out] | status_out | status information per key |
Definition at line 241 of file single_value_hash_table.cuh.
template<class Key , class Value , Key EmptyKey = defaults::empty_key<Key>(), Key TombstoneKey = defaults::tombstone_key<Key>(), class ProbingScheme = defaults::probing_scheme_t<Key, 8>, class TableStorage = defaults::table_storage_t<Key, Value>, index_t TempMemoryBytes = defaults::temp_memory_bytes()>
template<class StatusHandler = defaults::status_handler_t>
__host__ void warpcore::SingleValueHashTable< Key, Value, EmptyKey, TombstoneKey, ProbingScheme, TableStorage, TempMemoryBytes >::retrieve |
( |
const key_type *const |
keys_in, |
|
|
const index_type |
num_in, |
|
|
key_type *const |
keys_out, |
|
|
value_type *const |
values_out, |
|
|
index_type & |
num_out, |
|
|
const cudaStream_t |
stream = 0 , |
|
|
const index_type |
probing_length = defaults::probing_length() , |
|
|
typename StatusHandler::base_type *const |
status_out = nullptr |
|
) |
| const |
|
inlinenoexcept |
retrieve a set of keys from the hash table
- Template Parameters
-
- Parameters
-
[in] | keys_in | pointer to keys to retrieve from the hash table |
[in] | num_in | number of keys to retrieve |
[out] | keys_out | keys retrieved from the hash table |
[out] | values_out | retrieved values |
[out] | num_out | number of pairs retrieved |
[in] | stream | CUDA stream in which this operation is executed in |
[in] | probing_length | maximum number of probing attempts |
[out] | status_out | status information (per key) |
Definition at line 352 of file single_value_hash_table.cuh.
template<class Key , class Value , Key EmptyKey = defaults::empty_key<Key>(), Key TombstoneKey = defaults::tombstone_key<Key>(), class ProbingScheme = defaults::probing_scheme_t<Key, 8>, class TableStorage = defaults::table_storage_t<Key, Value>, index_t TempMemoryBytes = defaults::temp_memory_bytes()>
template<class StatusHandler = defaults::status_handler_t>
__host__ void warpcore::SingleValueHashTable< Key, Value, EmptyKey, TombstoneKey, ProbingScheme, TableStorage, TempMemoryBytes >::retrieve |
( |
const key_type *const |
keys_in, |
|
|
const index_type |
num_in, |
|
|
value_type *const |
values_out, |
|
|
const cudaStream_t |
stream = 0 , |
|
|
const index_type |
probing_length = defaults::probing_length() , |
|
|
typename StatusHandler::base_type *const |
status_out = nullptr |
|
) |
| const |
|
inlinenoexcept |
retrieve a set of keys from the hash table
- Template Parameters
-
- Parameters
-
[in] | keys_in | pointer to keys to retrieve from the hash table |
[in] | num_in | number of keys to retrieve |
[out] | values_out | retrieved values of keys in key_in |
[in] | stream | CUDA stream in which this operation is executed in |
[in] | probing_length | maximum number of probing attempts |
[out] | status_out | status information (per key) |
Definition at line 320 of file single_value_hash_table.cuh.
template<class Key , class Value , Key EmptyKey = defaults::empty_key<Key>(), Key TombstoneKey = defaults::tombstone_key<Key>(), class ProbingScheme = defaults::probing_scheme_t<Key, 8>, class TableStorage = defaults::table_storage_t<Key, Value>, index_t TempMemoryBytes = defaults::temp_memory_bytes()>
template<class Key_ , class Value_ , Key_ EmptyKey_, Key_ TombstoneKey_, class ValueStore_ , class ProbingScheme_ >
template<class Key , class Value , Key EmptyKey = defaults::empty_key<Key>(), Key TombstoneKey = defaults::tombstone_key<Key>(), class ProbingScheme = defaults::probing_scheme_t<Key, 8>, class TableStorage = defaults::table_storage_t<Key, Value>, index_t TempMemoryBytes = defaults::temp_memory_bytes()>
template<class Key_ , class Value_ , Key_ EmptyKey_, Key_ TombstoneKey_, class ProbingScheme_ , class TableStorage_ , index_type TempMemoryBytes_>