17 #ifndef QUERYENGINE_GPUMEMUTILS_H
18 #define QUERYENGINE_GPUMEMUTILS_H
31 #include "../Shared/nocuda.h"
34 namespace CudaMgr_Namespace {
40 namespace Data_Namespace {
52 const size_t num_bytes,
68 const std::vector<int64_t*>& group_by_buffers,
70 const unsigned block_size_x,
71 const unsigned grid_size_x,
74 const int64_t num_input_rows,
75 const bool prepend_index_buffer,
76 const bool always_init_group_by_on_host,
77 const bool use_bump_allocator,
78 const bool has_varlen_output,
82 const std::vector<int64_t*>& group_by_buffers,
83 const size_t groups_buffer_size,
84 const int8_t* group_by_dev_buffers_mem,
86 const unsigned block_size_x,
87 const unsigned grid_size_x,
89 const bool prepend_index_buffer,
90 const bool has_varlen_output);
93 int8_t* projection_size_gpu,
99 int8_t* projection_buffer,
100 const size_t projection_count,
101 const int device_id);
103 #endif // QUERYENGINE_GPUMEMUTILS_H
GpuGroupByBuffers create_dev_group_by_buffers(DeviceAllocator *device_allocator, const std::vector< int64_t * > &group_by_buffers, const QueryMemoryDescriptor &query_mem_desc, const unsigned block_size_x, const unsigned grid_size_x, const int device_id, const ExecutorDispatchMode dispatch_mode, const int64_t num_input_rows, const bool prepend_index_buffer, const bool always_init_group_by_on_host, const bool use_bump_allocator, const bool has_varlen_output, Allocator *insitu_allocator)
size_t get_num_allocated_rows_from_gpu(DeviceAllocator &device_allocator, int8_t *projection_size_gpu, const int device_id)
unsigned long long CUdeviceptr
void copy_to_nvidia_gpu(Data_Namespace::DataMgr *data_mgr, CUdeviceptr dst, const void *src, const size_t num_bytes, const int device_id)
void copy_projection_buffer_from_gpu_columnar(Data_Namespace::DataMgr *data_mgr, const GpuGroupByBuffers &gpu_group_by_buffers, const QueryMemoryDescriptor &query_mem_desc, int8_t *projection_buffer, const size_t projection_count, const int device_id)
void copy_group_by_buffers_from_gpu(DeviceAllocator &device_allocator, const std::vector< int64_t * > &group_by_buffers, const size_t groups_buffer_size, const int8_t *group_by_dev_buffers_mem, const QueryMemoryDescriptor &query_mem_desc, const unsigned block_size_x, const unsigned grid_size_x, const int device_id, const bool prepend_index_buffer, const bool has_varlen_output)
int8_t * varlen_output_buffer