OmniSciDB  a47db9e897
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
TableFunctionExecutionContext.h
Go to the documentation of this file.
1 /*
2  * Copyright 2019 OmniSci, 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 #pragma once
18 
22 
23 struct InputTableInfo;
25 class ColumnFetcher;
26 class Executor;
27 
29  public:
30  TableFunctionExecutionContext(std::shared_ptr<RowSetMemoryOwner> row_set_mem_owner)
31  : row_set_mem_owner_(row_set_mem_owner) {}
32 
33  // non-copyable
36 
38  const InputTableInfo& table_info,
39  const TableFunctionCompilationContext* compilation_context,
40  const ColumnFetcher& column_fetcher,
41  const ExecutorDeviceType device_type,
42  Executor* executor);
43 
44  private:
46  const TableFunctionCompilationContext* compilation_context,
47  std::vector<const int8_t*>& col_buf_ptrs,
48  const size_t elem_count,
49  Executor* executor);
51  const TableFunctionCompilationContext* compilation_context,
52  std::vector<const int8_t*>& col_buf_ptrs,
53  const size_t elem_count,
54  const int device_id,
55  Executor* executor);
56 
57  std::shared_ptr<RowSetMemoryOwner> row_set_mem_owner_;
58 };
ResultSetPtr launchCpuCode(const TableFunctionExecutionUnit &exe_unit, const TableFunctionCompilationContext *compilation_context, std::vector< const int8_t * > &col_buf_ptrs, const size_t elem_count, Executor *executor)
ExecutorDeviceType
ResultSetPtr launchGpuCode(const TableFunctionExecutionUnit &exe_unit, const TableFunctionCompilationContext *compilation_context, std::vector< const int8_t * > &col_buf_ptrs, const size_t elem_count, const int device_id, Executor *executor)
ResultSetPtr execute(const TableFunctionExecutionUnit &exe_unit, const InputTableInfo &table_info, const TableFunctionCompilationContext *compilation_context, const ColumnFetcher &column_fetcher, const ExecutorDeviceType device_type, Executor *executor)
std::shared_ptr< ResultSet > ResultSetPtr
std::shared_ptr< RowSetMemoryOwner > row_set_mem_owner_
TableFunctionExecutionContext & operator=(const TableFunctionExecutionContext &)=delete
Execution unit for relational algebra. It&#39;s a low-level description of any relational algebra operati...
TableFunctionExecutionContext(std::shared_ptr< RowSetMemoryOwner > row_set_mem_owner)