OmniSciDB
a5dc49c757
|
Classes | |
class | CaseExprDetector |
Functions | |
void | throw_parseIR_error (const llvm::SMDiagnostic &parse_error, std::string src="", const bool is_gpu=false) |
template<typename T = void> | |
void | show_defined (llvm::Module &llvm_module) |
template<typename T = void> | |
void | show_defined (llvm::Module *llvm_module) |
template<typename T = void> | |
void | show_defined (std::unique_ptr< llvm::Module > &llvm_module) |
template<typename T = void> | |
void | scan_function_calls (llvm::Function &F, std::unordered_set< std::string > &defined, std::unordered_set< std::string > &undefined, const std::unordered_set< std::string > &ignored) |
template<typename T = void> | |
void | scan_function_calls (llvm::Module &llvm_module, std::unordered_set< std::string > &defined, std::unordered_set< std::string > &undefined, const std::unordered_set< std::string > &ignored) |
template<typename T = void> | |
std::tuple< std::unordered_set < std::string > , std::unordered_set < std::string > > | scan_function_calls (llvm::Module &llvm_module, const std::unordered_set< std::string > &ignored={}) |
void | eliminate_dead_self_recursive_funcs (llvm::Module &M, const std::unordered_set< llvm::Function * > &live_funcs) |
void | optimize_ir (llvm::Function *query_func, llvm::Module *llvm_module, llvm::legacy::PassManager &pass_manager, const std::unordered_set< llvm::Function * > &live_funcs, const bool is_gpu_smem_used, const CompilationOptions &co) |
std::string | assemblyForCPU (ExecutionEngineWrapper &execution_engine, llvm::Module *llvm_module) |
ExecutionEngineWrapper | create_execution_engine (llvm::Module *llvm_module, llvm::EngineBuilder &eb, const CompilationOptions &co) |
std::string | cpp_to_llvm_name (const std::string &s) |
std::string | gen_array_any_all_sigs () |
std::string | gen_translate_null_key_sigs () |
void | bind_pos_placeholders (const std::string &pos_fn_name, const bool use_resume_param, llvm::Function *query_func, llvm::Module *llvm_module) |
void | set_row_func_argnames (llvm::Function *row_func, const size_t in_col_count, const size_t agg_col_count, const bool hoist_literals) |
llvm::Function * | create_row_function (const size_t in_col_count, const size_t agg_col_count, const bool hoist_literals, llvm::Module *llvm_module, llvm::LLVMContext &context) |
void | bind_query (llvm::Function *query_func, const std::string &query_fname, llvm::Function *multifrag_query_func, llvm::Module *llvm_module) |
std::vector< std::string > | get_agg_fnames (const std::vector< Analyzer::Expr * > &target_exprs, const bool is_group_by) |
template<typename InstType > | |
llvm::Value * | find_variable_in_basic_block (llvm::Function *func, std::string bb_name, std::string variable_name) |
size_t | get_shared_memory_size (const bool shared_mem_used, const QueryMemoryDescriptor *query_mem_desc_ptr) |
bool | has_count_expr (RelAlgExecutionUnit const &ra_exe_unit) |
bool | has_case_expr_within_groupby_expr (RelAlgExecutionUnit const &ra_exe_unit) |
bool | is_gpu_shared_mem_supported (const QueryMemoryDescriptor *query_mem_desc_ptr, const RelAlgExecutionUnit &ra_exe_unit, const CudaMgr_Namespace::CudaMgr *cuda_mgr, const ExecutorDeviceType device_type, const unsigned cuda_blocksize, const unsigned num_blocks_per_mp) |
std::string | serialize_llvm_metadata_footnotes (llvm::Function *query_func, CgenState *cgen_state) |
Variables | |
const std::string | cuda_rt_decls |
std::string anonymous_namespace{NativeCodegen.cpp}::assemblyForCPU | ( | ExecutionEngineWrapper & | execution_engine, |
llvm::Module * | llvm_module | ||
) |
Definition at line 402 of file NativeCodegen.cpp.
References CHECK.
Referenced by create_execution_engine().
void anonymous_namespace{NativeCodegen.cpp}::bind_pos_placeholders | ( | const std::string & | pos_fn_name, |
const bool | use_resume_param, | ||
llvm::Function * | query_func, | ||
llvm::Module * | llvm_module | ||
) |
Definition at line 1656 of file NativeCodegen.cpp.
void anonymous_namespace{NativeCodegen.cpp}::bind_query | ( | llvm::Function * | query_func, |
const std::string & | query_fname, | ||
llvm::Function * | multifrag_query_func, | ||
llvm::Module * | llvm_module | ||
) |
Definition at line 1806 of file NativeCodegen.cpp.
std::string anonymous_namespace{NativeCodegen.cpp}::cpp_to_llvm_name | ( | const std::string & | s | ) |
Definition at line 595 of file NativeCodegen.cpp.
References CHECK.
Referenced by gen_array_any_all_sigs(), and gen_translate_null_key_sigs().
ExecutionEngineWrapper anonymous_namespace{NativeCodegen.cpp}::create_execution_engine | ( | llvm::Module * | llvm_module, |
llvm::EngineBuilder & | eb, | ||
const CompilationOptions & | co | ||
) |
Definition at line 420 of file NativeCodegen.cpp.
References logger::ASM, assemblyForCPU(), CHECK, DEBUG_TIMER, and LOG.
Referenced by CodeGenerator::generateNativeCPUCode().
llvm::Function* anonymous_namespace{NativeCodegen.cpp}::create_row_function | ( | const size_t | in_col_count, |
const size_t | agg_col_count, | ||
const bool | hoist_literals, | ||
llvm::Module * | llvm_module, | ||
llvm::LLVMContext & | context | ||
) |
Definition at line 1737 of file NativeCodegen.cpp.
void anonymous_namespace{NativeCodegen.cpp}::eliminate_dead_self_recursive_funcs | ( | llvm::Module & | M, |
const std::unordered_set< llvm::Function * > & | live_funcs | ||
) |
Definition at line 246 of file NativeCodegen.cpp.
Referenced by optimize_ir().
llvm::Value* anonymous_namespace{NativeCodegen.cpp}::find_variable_in_basic_block | ( | llvm::Function * | func, |
std::string | bb_name, | ||
std::string | variable_name | ||
) |
Definition at line 2003 of file NativeCodegen.cpp.
std::string anonymous_namespace{NativeCodegen.cpp}::gen_array_any_all_sigs | ( | ) |
Definition at line 612 of file NativeCodegen.cpp.
References cpp_to_llvm_name(), and run_benchmark_import::result.
std::string anonymous_namespace{NativeCodegen.cpp}::gen_translate_null_key_sigs | ( | ) |
Definition at line 630 of file NativeCodegen.cpp.
References cpp_to_llvm_name(), and run_benchmark_import::result.
std::vector<std::string> anonymous_namespace{NativeCodegen.cpp}::get_agg_fnames | ( | const std::vector< Analyzer::Expr * > & | target_exprs, |
const bool | is_group_by | ||
) |
Definition at line 1833 of file NativeCodegen.cpp.
size_t anonymous_namespace{NativeCodegen.cpp}::get_shared_memory_size | ( | const bool | shared_mem_used, |
const QueryMemoryDescriptor * | query_mem_desc_ptr | ||
) |
Definition at line 2580 of file NativeCodegen.cpp.
bool anonymous_namespace{NativeCodegen.cpp}::has_case_expr_within_groupby_expr | ( | RelAlgExecutionUnit const & | ra_exe_unit | ) |
Definition at line 2617 of file NativeCodegen.cpp.
bool anonymous_namespace{NativeCodegen.cpp}::has_count_expr | ( | RelAlgExecutionUnit const & | ra_exe_unit | ) |
Definition at line 2587 of file NativeCodegen.cpp.
bool anonymous_namespace{NativeCodegen.cpp}::is_gpu_shared_mem_supported | ( | const QueryMemoryDescriptor * | query_mem_desc_ptr, |
const RelAlgExecutionUnit & | ra_exe_unit, | ||
const CudaMgr_Namespace::CudaMgr * | cuda_mgr, | ||
const ExecutorDeviceType | device_type, | ||
const unsigned | cuda_blocksize, | ||
const unsigned | num_blocks_per_mp | ||
) |
To simplify the implementation for practical purposes, we initially provide shared memory support for cases where there are at most as many entries in the output buffer as there are threads within each GPU device. In order to relax this assumption later, we need to add a for loop in generated codes such that each thread loops over multiple entries. TODO: relax this if necessary
Definition at line 2630 of file NativeCodegen.cpp.
void anonymous_namespace{NativeCodegen.cpp}::optimize_ir | ( | llvm::Function * | query_func, |
llvm::Module * | llvm_module, | ||
llvm::legacy::PassManager & | pass_manager, | ||
const std::unordered_set< llvm::Function * > & | live_funcs, | ||
const bool | is_gpu_smem_used, | ||
const CompilationOptions & | co | ||
) |
Definition at line 308 of file NativeCodegen.cpp.
References DEBUG_TIMER, and eliminate_dead_self_recursive_funcs().
Referenced by CodeGenerator::generateNativeCPUCode().
void anonymous_namespace{NativeCodegen.cpp}::scan_function_calls | ( | llvm::Function & | F, |
std::unordered_set< std::string > & | defined, | ||
std::unordered_set< std::string > & | undefined, | ||
const std::unordered_set< std::string > & | ignored | ||
) |
Definition at line 195 of file NativeCodegen.cpp.
Referenced by scan_function_calls().
void anonymous_namespace{NativeCodegen.cpp}::scan_function_calls | ( | llvm::Module & | llvm_module, |
std::unordered_set< std::string > & | defined, | ||
std::unordered_set< std::string > & | undefined, | ||
const std::unordered_set< std::string > & | ignored | ||
) |
Definition at line 225 of file NativeCodegen.cpp.
References scan_function_calls().
std::tuple<std::unordered_set<std::string>, std::unordered_set<std::string> > anonymous_namespace{NativeCodegen.cpp}::scan_function_calls | ( | llvm::Module & | llvm_module, |
const std::unordered_set< std::string > & | ignored = {} |
||
) |
Definition at line 238 of file NativeCodegen.cpp.
std::string anonymous_namespace{NativeCodegen.cpp}::serialize_llvm_metadata_footnotes | ( | llvm::Function * | query_func, |
CgenState * | cgen_state | ||
) |
Definition at line 2746 of file NativeCodegen.cpp.
void anonymous_namespace{NativeCodegen.cpp}::set_row_func_argnames | ( | llvm::Function * | row_func, |
const size_t | in_col_count, | ||
const size_t | agg_col_count, | ||
const bool | hoist_literals | ||
) |
Definition at line 1684 of file NativeCodegen.cpp.
References SQLTypeInfo::is_fp().
void anonymous_namespace{NativeCodegen.cpp}::show_defined | ( | llvm::Module & | llvm_module | ) |
Definition at line 156 of file NativeCodegen.cpp.
References f().
Referenced by show_defined().
void anonymous_namespace{NativeCodegen.cpp}::show_defined | ( | llvm::Module * | llvm_module | ) |
Definition at line 167 of file NativeCodegen.cpp.
References show_defined().
void anonymous_namespace{NativeCodegen.cpp}::show_defined | ( | std::unique_ptr< llvm::Module > & | llvm_module | ) |
Definition at line 176 of file NativeCodegen.cpp.
References show_defined().
void anonymous_namespace{NativeCodegen.cpp}::throw_parseIR_error | ( | const llvm::SMDiagnostic & | parse_error, |
std::string | src = "" , |
||
const bool | is_gpu = false |
||
) |
Definition at line 124 of file NativeCodegen.cpp.
const std::string anonymous_namespace{NativeCodegen.cpp}::cuda_rt_decls |
Definition at line 640 of file NativeCodegen.cpp.