OmniSciDB  1dac507f6e
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
HashTypeCache Class Reference

#include <BaselineJoinHashTable.h>

Static Public Member Functions

static void set (const std::vector< ChunkKey > &key, const JoinHashTableInterface::HashType hash_type)
 
static std::pair
< JoinHashTableInterface::HashType,
bool > 
get (const std::vector< ChunkKey > &key)
 

Static Private Attributes

static std::map< std::vector
< ChunkKey >
, JoinHashTableInterface::HashType
hash_type_cache_
 
static std::mutex hash_type_cache_mutex_
 

Detailed Description

Definition at line 292 of file BaselineJoinHashTable.h.

Member Function Documentation

std::pair< JoinHashTableInterface::HashType, bool > HashTypeCache::get ( const std::vector< ChunkKey > &  key)
static

Definition at line 1354 of file BaselineJoinHashTable.cpp.

References hash_type_cache_, hash_type_cache_mutex_, and JoinHashTableInterface::OneToOne.

Referenced by BaselineJoinHashTable::reify().

1355  {
1356  std::lock_guard<std::mutex> hash_type_cache_lock(hash_type_cache_mutex_);
1357  const auto it = hash_type_cache_.find(key);
1358  if (it == hash_type_cache_.end()) {
1360  }
1361  return {it->second, true};
1362 }
static std::map< std::vector< ChunkKey >, JoinHashTableInterface::HashType > hash_type_cache_
static std::mutex hash_type_cache_mutex_

+ Here is the caller graph for this function:

void HashTypeCache::set ( const std::vector< ChunkKey > &  key,
const JoinHashTableInterface::HashType  hash_type 
)
static

Definition at line 1348 of file BaselineJoinHashTable.cpp.

References hash_type_cache_, and hash_type_cache_mutex_.

Referenced by BaselineJoinHashTable::reify().

1349  {
1350  std::lock_guard<std::mutex> hash_type_cache_lock(hash_type_cache_mutex_);
1351  hash_type_cache_[key] = hash_type;
1352 }
static std::map< std::vector< ChunkKey >, JoinHashTableInterface::HashType > hash_type_cache_
static std::mutex hash_type_cache_mutex_

+ Here is the caller graph for this function:

Member Data Documentation

std::map< std::vector< ChunkKey >, JoinHashTableInterface::HashType > HashTypeCache::hash_type_cache_
staticprivate

Definition at line 302 of file BaselineJoinHashTable.h.

Referenced by get(), and set().

std::mutex HashTypeCache::hash_type_cache_mutex_
staticprivate

Definition at line 303 of file BaselineJoinHashTable.h.

Referenced by get(), and set().


The documentation for this class was generated from the following files: