OmniSciDB  eb3a3d0a03
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
RegisteredQueryHint Struct Reference

#include <QueryHint.h>

Public Member Functions

 RegisteredQueryHint ()
 
RegisteredQueryHintoperator= (const RegisteredQueryHint &other)
 
 RegisteredQueryHint (const RegisteredQueryHint &other)
 
bool isAnyQueryHintDelivered () const
 
void registerHint (const QueryHint hint)
 
const bool isHintRegistered (const QueryHint hint) const
 

Static Public Member Functions

static RegisteredQueryHint defaults ()
 
static QueryHint translateQueryHint (const std::string &hint_name)
 

Public Attributes

bool cpu_mode
 
bool columnar_output
 
bool rowwise_output
 
double overlaps_bucket_threshold
 
size_t overlaps_max_size
 
bool overlaps_allow_gpu_build
 
bool overlaps_no_cache
 
double overlaps_keys_per_bin
 
std::vector< bool > registered_hint
 

Detailed Description

Definition at line 131 of file QueryHint.h.

Constructor & Destructor Documentation

RegisteredQueryHint::RegisteredQueryHint ( )
inline

Definition at line 137 of file QueryHint.h.

Referenced by defaults().

138  : cpu_mode(false)
141  , overlaps_bucket_threshold(std::numeric_limits<double>::max())
144  , overlaps_no_cache(false)
bool overlaps_allow_gpu_build
Definition: QueryHint.h:181
double overlaps_keys_per_bin
Definition: QueryHint.h:183
std::vector< bool > registered_hint
Definition: QueryHint.h:185
bool g_enable_columnar_output
Definition: Execute.cpp:95
double g_overlaps_target_entries_per_bin
Definition: Execute.cpp:102
size_t g_overlaps_max_table_size_bytes
Definition: Execute.cpp:101
size_t overlaps_max_size
Definition: QueryHint.h:180
double overlaps_bucket_threshold
Definition: QueryHint.h:179

+ Here is the caller graph for this function:

RegisteredQueryHint::RegisteredQueryHint ( const RegisteredQueryHint other)
inline

Definition at line 161 of file QueryHint.h.

References columnar_output, cpu_mode, overlaps_allow_gpu_build, overlaps_bucket_threshold, overlaps_keys_per_bin, overlaps_max_size, overlaps_no_cache, registered_hint, and rowwise_output.

Member Function Documentation

static RegisteredQueryHint RegisteredQueryHint::defaults ( )
inlinestatic

Definition at line 187 of file QueryHint.h.

References RegisteredQueryHint().

Referenced by RelAlgExecutor::createAggregateWorkUnit(), RelAlgExecutor::createCompoundWorkUnit(), RelAlgExecutor::createFilterWorkUnit(), RelAlgExecutor::createProjectWorkUnit(), RelAlgExecutor::createUnionWorkUnit(), RelAlgExecutor::executeWorkUnit(), HashJoin::getSyntheticInstance(), and OverlapsJoinHashTable::OverlapsJoinHashTable().

187 { return RegisteredQueryHint(); }

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool RegisteredQueryHint::isAnyQueryHintDelivered ( ) const
inline

Definition at line 199 of file QueryHint.h.

References registered_hint.

Referenced by OverlapsJoinHashTable::getInstance().

199  {
200  for (auto flag : registered_hint) {
201  if (flag) {
202  return true;
203  }
204  }
205  return false;
206  }
std::vector< bool > registered_hint
Definition: QueryHint.h:185

+ Here is the caller graph for this function:

const bool RegisteredQueryHint::isHintRegistered ( const QueryHint  hint) const
inline

Definition at line 215 of file QueryHint.h.

References kHintCount, and registered_hint.

Referenced by DBHandler::execute_rel_alg(), DBHandler::execute_rel_alg_df(), OverlapsJoinHashTable::getEffectiveMemoryLevel(), and Parser::LocalConnector::getOuterFragmentCount().

215  {
216  const auto hint_class = static_cast<int>(hint);
217  if (hint_class >= 0 && hint_class < QueryHint::kHintCount) {
218  return registered_hint[hint_class];
219  }
220  return false;
221  }
std::vector< bool > registered_hint
Definition: QueryHint.h:185

+ Here is the caller graph for this function:

RegisteredQueryHint& RegisteredQueryHint::operator= ( const RegisteredQueryHint other)
inline

Definition at line 148 of file QueryHint.h.

References columnar_output, cpu_mode, overlaps_allow_gpu_build, overlaps_bucket_threshold, overlaps_keys_per_bin, overlaps_max_size, overlaps_no_cache, registered_hint, and rowwise_output.

148  {
149  cpu_mode = other.cpu_mode;
158  return *this;
159  }
bool overlaps_allow_gpu_build
Definition: QueryHint.h:181
double overlaps_keys_per_bin
Definition: QueryHint.h:183
std::vector< bool > registered_hint
Definition: QueryHint.h:185
size_t overlaps_max_size
Definition: QueryHint.h:180
double overlaps_bucket_threshold
Definition: QueryHint.h:179
void RegisteredQueryHint::registerHint ( const QueryHint  hint)
inline

Definition at line 208 of file QueryHint.h.

References kHintCount, and registered_hint.

Referenced by RelAlgDagBuilder::registerQueryHints().

208  {
209  const auto hint_class = static_cast<int>(hint);
210  if (hint_class >= 0 && hint_class < QueryHint::kHintCount) {
211  registered_hint[hint_class] = true;
212  }
213  }
std::vector< bool > registered_hint
Definition: QueryHint.h:185

+ Here is the caller graph for this function:

static QueryHint RegisteredQueryHint::translateQueryHint ( const std::string &  hint_name)
inlinestatic

Definition at line 190 of file QueryHint.h.

References kInvalidHint, and SupportedQueryHints.

Referenced by details::RelAlgDispatcher::parseHintString().

190  {
191  const auto lowered_hint_name = boost::algorithm::to_lower_copy(hint_name);
192  auto it = SupportedQueryHints.find(hint_name);
193  if (it != SupportedQueryHints.end()) {
194  return it->second;
195  }
197  }
static const std::unordered_map< std::string, QueryHint > SupportedQueryHints
Definition: QueryHint.h:42

+ Here is the caller graph for this function:

Member Data Documentation

bool RegisteredQueryHint::columnar_output
bool RegisteredQueryHint::cpu_mode
bool RegisteredQueryHint::overlaps_allow_gpu_build
double RegisteredQueryHint::overlaps_bucket_threshold
double RegisteredQueryHint::overlaps_keys_per_bin
size_t RegisteredQueryHint::overlaps_max_size
bool RegisteredQueryHint::overlaps_no_cache
std::vector<bool> RegisteredQueryHint::registered_hint
bool RegisteredQueryHint::rowwise_output

The documentation for this struct was generated from the following file: