OmniSciDB  04ee39c94c
HashJoinRuntime.h
Go to the documentation of this file.
1 /*
2  * Copyright 2017 MapD Technologies, Inc.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 /*
18  * @file HashJoinRuntime.h
19  * @author Alex Suhan <alex@mapd.com>
20  *
21  * Copyright (c) 2015 MapD Technologies, Inc. All rights reserved.
22  */
23 
24 #ifndef QUERYENGINE_HASHJOINRUNTIME_H
25 #define QUERYENGINE_HASHJOINRUNTIME_H
26 
27 #include <cstddef>
28 #include <cstdint>
29 #include <vector>
30 #include "../Shared/SqlTypesLayout.h"
31 #include "../Shared/sqltypes.h"
32 
33 struct GenericKeyHandler;
34 struct OverlapsKeyHandler;
35 
36 struct HashEntryInfo {
37  alignas(sizeof(int64_t)) size_t hash_entry_count;
38  alignas(sizeof(int64_t)) int64_t bucket_normalization;
39 
40  inline size_t getNormalizedHashEntryCount() const {
41  CHECK_GT(bucket_normalization, 0);
42  auto modulo_res = hash_entry_count % static_cast<size_t>(bucket_normalization);
43  auto entry_count = hash_entry_count / static_cast<size_t>(bucket_normalization);
44  if (modulo_res) {
45  return entry_count + 1;
46  }
47  return entry_count;
48  }
49 
50  bool operator!() const { return !(this->getNormalizedHashEntryCount()); }
51 };
52 
54 
55 void init_hash_join_buff(int32_t* buff,
56  const int32_t entry_count,
57  const int32_t invalid_slot_val,
58  const int32_t cpu_thread_idx,
59  const int32_t cpu_thread_count);
60 
61 void init_hash_join_buff_on_device(int32_t* buff,
62  const int32_t entry_count,
63  const int32_t invalid_slot_val,
64  const size_t block_size_x,
65  const size_t grid_size_x);
66 
67 void init_baseline_hash_join_buff_32(int8_t* hash_join_buff,
68  const int32_t entry_count,
69  const size_t key_component_count,
70  const bool with_val_slot,
71  const int32_t invalid_slot_val,
72  const int32_t cpu_thread_idx,
73  const int32_t cpu_thread_count);
74 
75 void init_baseline_hash_join_buff_64(int8_t* hash_join_buff,
76  const int32_t entry_count,
77  const size_t key_component_count,
78  const bool with_val_slot,
79  const int32_t invalid_slot_val,
80  const int32_t cpu_thread_idx,
81  const int32_t cpu_thread_count);
82 
83 void init_baseline_hash_join_buff_on_device_32(int8_t* hash_join_buff,
84  const int32_t entry_count,
85  const size_t key_component_count,
86  const bool with_val_slot,
87  const int32_t invalid_slot_val,
88  const size_t block_size_x,
89  const size_t grid_size_x);
90 
91 void init_baseline_hash_join_buff_on_device_64(int8_t* hash_join_buff,
92  const int32_t entry_count,
93  const size_t key_component_count,
94  const bool with_val_slot,
95  const int32_t invalid_slot_val,
96  const size_t block_size_x,
97  const size_t grid_size_x);
98 
99 enum ColumnType { SmallDate = 0, Signed = 1, Unsigned = 2 };
100 
101 struct JoinColumn {
102  const int8_t* col_buff;
103  const size_t num_elems;
104 };
105 
107  const size_t elem_sz;
108  const int64_t min_val;
109  const int64_t max_val;
110  const int64_t null_val;
111  const bool uses_bw_eq;
112  const int64_t translated_null_val;
114 };
115 
117  if (ti.is_date_in_days()) {
118  return SmallDate;
119  } else {
120  return is_unsigned_type(ti) ? Unsigned : Signed;
121  }
122 }
123 
125  std::vector<double> bucket_sizes_for_dimension;
126  bool is_double; // TODO(adb): assume float otherwise (?)
127 };
128 
129 int fill_hash_join_buff_bucketized(int32_t* buff,
130  const int32_t invalid_slot_val,
131  const JoinColumn join_column,
132  const JoinColumnTypeInfo type_info,
133  const void* sd_inner,
134  const void* sd_outer,
135  const int32_t cpu_thread_idx,
136  const int32_t cpu_thread_count,
137  const int64_t bucket_normalization);
138 
139 int fill_hash_join_buff(int32_t* buff,
140  const int32_t invalid_slot_val,
141  const JoinColumn join_column,
142  const JoinColumnTypeInfo type_info,
143  const void* sd_inner,
144  const void* sd_outer,
145  const int32_t cpu_thread_idx,
146  const int32_t cpu_thread_count);
147 
148 void fill_hash_join_buff_on_device(int32_t* buff,
149  const int32_t invalid_slot_val,
150  int* dev_err_buff,
151  const JoinColumn join_column,
152  const JoinColumnTypeInfo type_info,
153  const size_t block_size_x,
154  const size_t grid_size_x);
156  const int32_t invalid_slot_val,
157  int* dev_err_buff,
158  const JoinColumn join_column,
159  const JoinColumnTypeInfo type_info,
160  const size_t block_size_x,
161  const size_t grid_size_x,
162  const int64_t bucket_normalization);
163 
164 struct ShardInfo {
165  const size_t shard;
166  const size_t entry_count_per_shard;
167  const size_t num_shards;
168  const int device_count;
169 };
170 
171 void fill_hash_join_buff_on_device_sharded(int32_t* buff,
172  const int32_t invalid_slot_val,
173  int* dev_err_buff,
174  const JoinColumn join_column,
175  const JoinColumnTypeInfo type_info,
176  const ShardInfo shard_info,
177  const size_t block_size_x,
178  const size_t grid_size_x);
179 
181  const int32_t invalid_slot_val,
182  int* dev_err_buff,
183  const JoinColumn join_column,
184  const JoinColumnTypeInfo type_info,
185  const ShardInfo shard_info,
186  const size_t block_size_x,
187  const size_t grid_size_x,
188  const int64_t bucket_normalization);
189 
190 void fill_one_to_many_hash_table(int32_t* buff,
191  const HashEntryInfo hash_entry_info,
192  const int32_t invalid_slot_val,
193  const JoinColumn& join_column,
194  const JoinColumnTypeInfo& type_info,
195  const void* sd_inner_proxy,
196  const void* sd_outer_proxy,
197  const unsigned cpu_thread_count);
198 
199 void fill_one_to_many_hash_table_bucketized(int32_t* buff,
200  const HashEntryInfo hash_entry_info,
201  const int32_t invalid_slot_val,
202  const JoinColumn& join_column,
203  const JoinColumnTypeInfo& type_info,
204  const void* sd_inner_proxy,
205  const void* sd_outer_proxy,
206  const unsigned cpu_thread_count);
207 
209  const HashEntryInfo hash_entry_info,
210  const int32_t invalid_slot_val,
211  const JoinColumn& join_column,
212  const JoinColumnTypeInfo& type_info,
213  const ShardInfo& shard_info,
214  const void* sd_inner_proxy,
215  const void* sd_outer_proxy,
216  const unsigned cpu_thread_count);
217 
218 void fill_one_to_many_hash_table_on_device(int32_t* buff,
219  const HashEntryInfo hash_entry_info,
220  const int32_t invalid_slot_val,
221  const JoinColumn& join_column,
222  const JoinColumnTypeInfo& type_info,
223  const size_t block_size_x,
224  const size_t grid_size_x);
225 
227  const HashEntryInfo hash_entry_info,
228  const int32_t invalid_slot_val,
229  const JoinColumn& join_column,
230  const JoinColumnTypeInfo& type_info,
231  const size_t block_size_x,
232  const size_t grid_size_x);
233 
235  const HashEntryInfo hash_entry_info,
236  const int32_t invalid_slot_val,
237  const JoinColumn& join_column,
238  const JoinColumnTypeInfo& type_info,
239  const ShardInfo& shard_info,
240  const size_t block_size_x,
241  const size_t grid_size_x);
242 
243 int fill_baseline_hash_join_buff_32(int8_t* hash_buff,
244  const size_t entry_count,
245  const int32_t invalid_slot_val,
246  const size_t key_component_count,
247  const bool with_val_slot,
248  const GenericKeyHandler* key_handler,
249  const size_t num_elems,
250  const int32_t cpu_thread_idx,
251  const int32_t cpu_thread_count);
252 
253 int overlaps_fill_baseline_hash_join_buff_32(int8_t* hash_buff,
254  const size_t entry_count,
255  const int32_t invalid_slot_val,
256  const size_t key_component_count,
257  const bool with_val_slot,
258  const OverlapsKeyHandler* key_handler,
259  const size_t num_elems,
260  const int32_t cpu_thread_idx,
261  const int32_t cpu_thread_count);
262 
263 int fill_baseline_hash_join_buff_64(int8_t* hash_buff,
264  const size_t entry_count,
265  const int32_t invalid_slot_val,
266  const size_t key_component_count,
267  const bool with_val_slot,
268  const GenericKeyHandler* key_handler,
269  const size_t num_elems,
270  const int32_t cpu_thread_idx,
271  const int32_t cpu_thread_count);
272 
273 int overlaps_fill_baseline_hash_join_buff_64(int8_t* hash_buff,
274  const size_t entry_count,
275  const int32_t invalid_slot_val,
276  const size_t key_component_count,
277  const bool with_val_slot,
278  const OverlapsKeyHandler* key_handler,
279  const size_t num_elems,
280  const int32_t cpu_thread_idx,
281  const int32_t cpu_thread_count);
282 
283 void fill_baseline_hash_join_buff_on_device_32(int8_t* hash_buff,
284  const size_t entry_count,
285  const int32_t invalid_slot_val,
286  const size_t key_component_count,
287  const bool with_val_slot,
288  int* dev_err_buff,
289  const GenericKeyHandler* key_handler,
290  const size_t num_elems,
291  const size_t block_size_x,
292  const size_t grid_size_x);
293 
294 void fill_baseline_hash_join_buff_on_device_64(int8_t* hash_buff,
295  const size_t entry_count,
296  const int32_t invalid_slot_val,
297  const size_t key_component_count,
298  const bool with_val_slot,
299  int* dev_err_buff,
300  const GenericKeyHandler* key_handler,
301  const size_t num_elems,
302  const size_t block_size_x,
303  const size_t grid_size_x);
304 
306  int8_t* hash_buff,
307  const size_t entry_count,
308  const int32_t invalid_slot_val,
309  const size_t key_component_count,
310  const bool with_val_slot,
311  int* dev_err_buff,
312  const OverlapsKeyHandler* key_handler,
313  const size_t num_elems,
314  const size_t block_size_x,
315  const size_t grid_size_x);
316 
318  int32_t* buff,
319  const int32_t* composite_key_dict,
320  const size_t hash_entry_count,
321  const int32_t invalid_slot_val,
322  const size_t key_component_count,
323  const std::vector<JoinColumn>& join_column_per_key,
324  const std::vector<JoinColumnTypeInfo>& type_info_per_key,
325  const std::vector<JoinBucketInfo>& join_bucket_info,
326  const std::vector<const void*>& sd_inner_proxy_per_key,
327  const std::vector<const void*>& sd_outer_proxy_per_key,
328  const int32_t cpu_thread_count);
329 
331  int32_t* buff,
332  const int64_t* composite_key_dict,
333  const size_t hash_entry_count,
334  const int32_t invalid_slot_val,
335  const size_t key_component_count,
336  const std::vector<JoinColumn>& join_column_per_key,
337  const std::vector<JoinColumnTypeInfo>& type_info_per_key,
338  const std::vector<JoinBucketInfo>& join_bucket_info,
339  const std::vector<const void*>& sd_inner_proxy_per_key,
340  const std::vector<const void*>& sd_outer_proxy_per_key,
341  const int32_t cpu_thread_count);
342 
344  int32_t* buff,
345  const int32_t* composite_key_dict,
346  const size_t hash_entry_count,
347  const int32_t invalid_slot_val,
348  const size_t key_component_count,
349  const GenericKeyHandler* key_handler,
350  const size_t num_elems,
351  const size_t block_size_x,
352  const size_t grid_size_x);
353 
355  int32_t* buff,
356  const int64_t* composite_key_dict,
357  const size_t hash_entry_count,
358  const int32_t invalid_slot_val,
359  const GenericKeyHandler* key_handler,
360  const size_t num_elems,
361  const size_t block_size_x,
362  const size_t grid_size_x);
363 
365  int32_t* buff,
366  const int64_t* composite_key_dict,
367  const size_t hash_entry_count,
368  const int32_t invalid_slot_val,
369  const OverlapsKeyHandler* key_handler,
370  const size_t num_elems,
371  const size_t block_size_x,
372  const size_t grid_size_x);
373 
374 void approximate_distinct_tuples(uint8_t* hll_buffer_all_cpus,
375  const uint32_t b,
376  const size_t padded_size_bytes,
377  const std::vector<JoinColumn>& join_column_per_key,
378  const std::vector<JoinColumnTypeInfo>& type_info_per_key,
379  const int thread_count);
380 
382  uint8_t* hll_buffer_all_cpus,
383  std::vector<int32_t>& row_counts,
384  const uint32_t b,
385  const size_t padded_size_bytes,
386  const std::vector<JoinColumn>& join_column_per_key,
387  const std::vector<JoinColumnTypeInfo>& type_info_per_key,
388  const std::vector<JoinBucketInfo>& join_buckets_per_key,
389  const int thread_count);
390 
391 void approximate_distinct_tuples_on_device(uint8_t* hll_buffer,
392  const uint32_t b,
393  const GenericKeyHandler* key_handler,
394  const size_t num_elems,
395  const size_t block_size_x,
396  const size_t grid_size_x);
397 
398 void approximate_distinct_tuples_on_device_overlaps(uint8_t* hll_buffer,
399  const uint32_t b,
400  int32_t* row_counts_buffer,
401  const OverlapsKeyHandler* key_handler,
402  const size_t num_elems,
403  const size_t block_size_x,
404  const size_t grid_size_x);
405 
406 void compute_bucket_sizes(std::vector<double>& bucket_sizes_for_dimension,
407  const JoinColumn& join_column,
408  const double bucket_size_threshold,
409  const int thread_count);
410 
411 void compute_bucket_sizes_on_device(double* bucket_sizes_buffer,
412  const JoinColumn* join_column_for_key,
413  const double bucket_sz_threshold,
414  const size_t block_size_x,
415  const size_t grid_size_x);
416 
417 #endif // QUERYENGINE_HASHJOINRUNTIME_H
const ColumnType column_type
const size_t num_shards
void fill_one_to_many_hash_table_on_device(int32_t *buff, const HashEntryInfo hash_entry_info, const int32_t invalid_slot_val, const JoinColumn &join_column, const JoinColumnTypeInfo &type_info, const size_t block_size_x, const size_t grid_size_x)
const int8_t * col_buff
int fill_baseline_hash_join_buff_64(int8_t *hash_buff, const size_t entry_count, const int32_t invalid_slot_val, const size_t key_component_count, const bool with_val_slot, const GenericKeyHandler *key_handler, const size_t num_elems, const int32_t cpu_thread_idx, const int32_t cpu_thread_count)
void overlaps_fill_baseline_hash_join_buff_on_device_64(int8_t *hash_buff, const size_t entry_count, const int32_t invalid_slot_val, const size_t key_component_count, const bool with_val_slot, int *dev_err_buff, const OverlapsKeyHandler *key_handler, const size_t num_elems, const size_t block_size_x, const size_t grid_size_x)
int overlaps_fill_baseline_hash_join_buff_64(int8_t *hash_buff, const size_t entry_count, const int32_t invalid_slot_val, const size_t key_component_count, const bool with_val_slot, const OverlapsKeyHandler *key_handler, const size_t num_elems, const int32_t cpu_thread_idx, const int32_t cpu_thread_count)
void fill_one_to_many_baseline_hash_table_on_device_32(int32_t *buff, const int32_t *composite_key_dict, const size_t hash_entry_count, const int32_t invalid_slot_val, const size_t key_component_count, const GenericKeyHandler *key_handler, const size_t num_elems, const size_t block_size_x, const size_t grid_size_x)
void fill_baseline_hash_join_buff_on_device_32(int8_t *hash_buff, const size_t entry_count, const int32_t invalid_slot_val, const size_t key_component_count, const bool with_val_slot, int *dev_err_buff, const GenericKeyHandler *key_handler, const size_t num_elems, const size_t block_size_x, const size_t grid_size_x)
size_t getNormalizedHashEntryCount() const
void fill_one_to_many_hash_table_bucketized(int32_t *buff, const HashEntryInfo hash_entry_info, const int32_t invalid_slot_val, const JoinColumn &join_column, const JoinColumnTypeInfo &type_info, const void *sd_inner_proxy, const void *sd_outer_proxy, const unsigned cpu_thread_count)
void init_baseline_hash_join_buff_32(int8_t *hash_join_buff, const int32_t entry_count, const size_t key_component_count, const bool with_val_slot, const int32_t invalid_slot_val, const int32_t cpu_thread_idx, const int32_t cpu_thread_count)
void fill_one_to_many_hash_table_on_device_sharded(int32_t *buff, const HashEntryInfo hash_entry_info, const int32_t invalid_slot_val, const JoinColumn &join_column, const JoinColumnTypeInfo &type_info, const ShardInfo &shard_info, const size_t block_size_x, const size_t grid_size_x)
int fill_hash_join_buff(int32_t *buff, const int32_t invalid_slot_val, const JoinColumn join_column, const JoinColumnTypeInfo type_info, const void *sd_inner, const void *sd_outer, const int32_t cpu_thread_idx, const int32_t cpu_thread_count)
int overlaps_fill_baseline_hash_join_buff_32(int8_t *hash_buff, const size_t entry_count, const int32_t invalid_slot_val, const size_t key_component_count, const bool with_val_slot, const OverlapsKeyHandler *key_handler, const size_t num_elems, const int32_t cpu_thread_idx, const int32_t cpu_thread_count)
void fill_hash_join_buff_on_device(int32_t *buff, const int32_t invalid_slot_val, int *dev_err_buff, const JoinColumn join_column, const JoinColumnTypeInfo type_info, const size_t block_size_x, const size_t grid_size_x)
void compute_bucket_sizes(std::vector< double > &bucket_sizes_for_dimension, const JoinColumn &join_column, const double bucket_size_threshold, const int thread_count)
const size_t elem_sz
int fill_hash_join_buff_bucketized(int32_t *buff, const int32_t invalid_slot_val, const JoinColumn join_column, const JoinColumnTypeInfo type_info, const void *sd_inner, const void *sd_outer, const int32_t cpu_thread_idx, const int32_t cpu_thread_count, const int64_t bucket_normalization)
const int device_count
void approximate_distinct_tuples_overlaps(uint8_t *hll_buffer_all_cpus, std::vector< int32_t > &row_counts, const uint32_t b, const size_t padded_size_bytes, const std::vector< JoinColumn > &join_column_per_key, const std::vector< JoinColumnTypeInfo > &type_info_per_key, const std::vector< JoinBucketInfo > &join_buckets_per_key, const int thread_count)
const int64_t null_val
void init_hash_join_buff(int32_t *buff, const int32_t entry_count, const int32_t invalid_slot_val, const int32_t cpu_thread_idx, const int32_t cpu_thread_count)
#define CHECK_GT(x, y)
Definition: Logger.h:199
const size_t entry_count_per_shard
const int64_t translated_null_val
void fill_hash_join_buff_on_device_sharded(int32_t *buff, const int32_t invalid_slot_val, int *dev_err_buff, const JoinColumn join_column, const JoinColumnTypeInfo type_info, const ShardInfo shard_info, const size_t block_size_x, const size_t grid_size_x)
void fill_one_to_many_hash_table_on_device_bucketized(int32_t *buff, const HashEntryInfo hash_entry_info, const int32_t invalid_slot_val, const JoinColumn &join_column, const JoinColumnTypeInfo &type_info, const size_t block_size_x, const size_t grid_size_x)
int fill_baseline_hash_join_buff_32(int8_t *hash_buff, const size_t entry_count, const int32_t invalid_slot_val, const size_t key_component_count, const bool with_val_slot, const GenericKeyHandler *key_handler, const size_t num_elems, const int32_t cpu_thread_idx, const int32_t cpu_thread_count)
const size_t num_elems
void approximate_distinct_tuples_on_device(uint8_t *hll_buffer, const uint32_t b, const GenericKeyHandler *key_handler, const size_t num_elems, const size_t block_size_x, const size_t grid_size_x)
void init_baseline_hash_join_buff_on_device_32(int8_t *hash_join_buff, const int32_t entry_count, const size_t key_component_count, const bool with_val_slot, const int32_t invalid_slot_val, const size_t block_size_x, const size_t grid_size_x)
int64_t bucket_normalization
std::vector< double > bucket_sizes_for_dimension
void fill_one_to_many_hash_table(int32_t *buff, const HashEntryInfo hash_entry_info, const int32_t invalid_slot_val, const JoinColumn &join_column, const JoinColumnTypeInfo &type_info, const void *sd_inner_proxy, const void *sd_outer_proxy, const unsigned cpu_thread_count)
const size_t shard
size_t hash_entry_count
const int64_t max_val
void fill_one_to_many_baseline_hash_table_32(int32_t *buff, const int32_t *composite_key_dict, const size_t hash_entry_count, const int32_t invalid_slot_val, const size_t key_component_count, const std::vector< JoinColumn > &join_column_per_key, const std::vector< JoinColumnTypeInfo > &type_info_per_key, const std::vector< JoinBucketInfo > &join_bucket_info, const std::vector< const void *> &sd_inner_proxy_per_key, const std::vector< const void *> &sd_outer_proxy_per_key, const int32_t cpu_thread_count)
void init_baseline_hash_join_buff_on_device_64(int8_t *hash_join_buff, const int32_t entry_count, const size_t key_component_count, const bool with_val_slot, const int32_t invalid_slot_val, const size_t block_size_x, const size_t grid_size_x)
ColumnType
void fill_one_to_many_baseline_hash_table_on_device_64(int32_t *buff, const int64_t *composite_key_dict, const size_t hash_entry_count, const int32_t invalid_slot_val, const GenericKeyHandler *key_handler, const size_t num_elems, const size_t block_size_x, const size_t grid_size_x)
void init_hash_join_buff_on_device(int32_t *buff, const int32_t entry_count, const int32_t invalid_slot_val, const size_t block_size_x, const size_t grid_size_x)
const int64_t min_val
void fill_baseline_hash_join_buff_on_device_64(int8_t *hash_buff, const size_t entry_count, const int32_t invalid_slot_val, const size_t key_component_count, const bool with_val_slot, int *dev_err_buff, const GenericKeyHandler *key_handler, const size_t num_elems, const size_t block_size_x, const size_t grid_size_x)
ColumnType get_join_column_type_kind(const SQLTypeInfo &ti)
void approximate_distinct_tuples_on_device_overlaps(uint8_t *hll_buffer, const uint32_t b, int32_t *row_counts_buffer, const OverlapsKeyHandler *key_handler, const size_t num_elems, const size_t block_size_x, const size_t grid_size_x)
void init_baseline_hash_join_buff_64(int8_t *hash_join_buff, const int32_t entry_count, const size_t key_component_count, const bool with_val_slot, const int32_t invalid_slot_val, const int32_t cpu_thread_idx, const int32_t cpu_thread_count)
void fill_one_to_many_baseline_hash_table_64(int32_t *buff, const int64_t *composite_key_dict, const size_t hash_entry_count, const int32_t invalid_slot_val, const size_t key_component_count, const std::vector< JoinColumn > &join_column_per_key, const std::vector< JoinColumnTypeInfo > &type_info_per_key, const std::vector< JoinBucketInfo > &join_bucket_info, const std::vector< const void *> &sd_inner_proxy_per_key, const std::vector< const void *> &sd_outer_proxy_per_key, const int32_t cpu_thread_count)
void overlaps_fill_one_to_many_baseline_hash_table_on_device_64(int32_t *buff, const int64_t *composite_key_dict, const size_t hash_entry_count, const int32_t invalid_slot_val, const OverlapsKeyHandler *key_handler, const size_t num_elems, const size_t block_size_x, const size_t grid_size_x)
bool operator!() const
void fill_one_to_many_hash_table_sharded_bucketized(int32_t *buff, const HashEntryInfo hash_entry_info, const int32_t invalid_slot_val, const JoinColumn &join_column, const JoinColumnTypeInfo &type_info, const ShardInfo &shard_info, const void *sd_inner_proxy, const void *sd_outer_proxy, const unsigned cpu_thread_count)
void compute_bucket_sizes_on_device(double *bucket_sizes_buffer, const JoinColumn *join_column_for_key, const double bucket_sz_threshold, const size_t block_size_x, const size_t grid_size_x)
const size_t g_maximum_conditions_to_coalesce
void approximate_distinct_tuples(uint8_t *hll_buffer_all_cpus, const uint32_t b, const size_t padded_size_bytes, const std::vector< JoinColumn > &join_column_per_key, const std::vector< JoinColumnTypeInfo > &type_info_per_key, const int thread_count)
void fill_hash_join_buff_on_device_sharded_bucketized(int32_t *buff, const int32_t invalid_slot_val, int *dev_err_buff, const JoinColumn join_column, const JoinColumnTypeInfo type_info, const ShardInfo shard_info, const size_t block_size_x, const size_t grid_size_x, const int64_t bucket_normalization)
void fill_hash_join_buff_on_device_bucketized(int32_t *buff, const int32_t invalid_slot_val, int *dev_err_buff, const JoinColumn join_column, const JoinColumnTypeInfo type_info, const size_t block_size_x, const size_t grid_size_x, const int64_t bucket_normalization)
bool is_unsigned_type(const SQLTypeInfo &ti)