#include "jit-typeinfo.h"
Public Types | |
typedef std::vector< llvm::Value * > | arg_vec |
Public Member Functions | |
jit_function (const jit_function &fn) | |
jit_function (const jit_function &fn, jit_type *aresult, const std::vector< jit_type * > &aargs) | |
jit_function (const jit_module *amodule, jit_convention::type acall_conv, const llvm::Twine &aname, jit_type *aresult, const std::vector< jit_type * > &aargs) | |
jit_function (void) | |
llvm::Value * | argument (llvm::IRBuilderD &builder, size_t idx) const |
jit_type * | argument_type (size_t idx) const |
const std::vector< jit_type * > & | arguments (void) const |
template<typename ... Args> | |
llvm::Value * | call (llvm::IRBuilderD &builder, arg_vec &in_args, llvm::Value *arg1, Args... other_args) const |
template<typename T , typename ... Args> | |
llvm::Value * | call (llvm::IRBuilderD &builder, arg_vec &in_args, T *arg1, Args... other_args) const |
llvm::Value * | call (llvm::IRBuilderD &builder, const arg_vec &in_args=arg_vec()) const |
llvm::Value * | call (llvm::IRBuilderD &builder, const std::vector< jit_value * > &in_args) const |
template<typename ... Args> | |
llvm::Value * | call (llvm::IRBuilderD &builder, llvm::Value *arg1, Args... other_args) const |
template<typename T , typename ... Args> | |
llvm::Value * | call (llvm::IRBuilderD &builder, T *arg1, Args... other_args) const |
bool | can_error (void) const |
void | do_return (llvm::IRBuilderD &builder, llvm::Value *rval=nullptr, bool verify=true) |
void | erase (void) |
void | mark_can_error (void) |
std::string | name (void) const |
llvm::BasicBlock * | new_block (const std::string &aname="body", llvm::BasicBlock *insert_before=nullptr) |
jit_type * | result (void) const |
bool | sret (void) const |
llvm::Function * | to_llvm (void) const |
bool | valid (void) const |
Private Attributes | |
std::vector< jit_type * > | m_args |
jit_convention::type | m_call_conv |
bool | m_can_error |
llvm::Function * | m_llvm_function |
const jit_module * | m_module |
jit_type * | m_result |
Friends | |
std::ostream & | operator<< (std::ostream &os, const jit_function &fn) |
Definition at line 238 of file jit-typeinfo.h.
typedef std::vector<llvm::Value *> octave::jit_function::arg_vec |
Definition at line 269 of file jit-typeinfo.h.
octave::jit_function::jit_function | ( | void | ) |
Definition at line 561 of file jit-typeinfo.cc.
octave::jit_function::jit_function | ( | const jit_module * | amodule, |
jit_convention::type | acall_conv, | ||
const llvm::Twine & | aname, | ||
jit_type * | aresult, | ||
const std::vector< jit_type * > & | aargs | ||
) |
Definition at line 566 of file jit-typeinfo.cc.
References octave::context, octave::jit_module::create_llvm_function(), octave::jit_convention::internal, m_args, m_call_conv, m_llvm_function, m_module, m_result, octave::jit_type::packed_type(), octave::jit_type::pointer_arg(), and sret().
octave::jit_function::jit_function | ( | const jit_function & | fn, |
jit_type * | aresult, | ||
const std::vector< jit_type * > & | aargs | ||
) |
Definition at line 620 of file jit-typeinfo.cc.
octave::jit_function::jit_function | ( | const jit_function & | fn | ) |
Definition at line 627 of file jit-typeinfo.cc.
llvm::Value * octave::jit_function::argument | ( | llvm::IRBuilderD & | builder, |
size_t | idx | ||
) | const |
Definition at line 743 of file jit-typeinfo.cc.
References octave::builder, m_args, m_call_conv, m_llvm_function, and sret().
Referenced by octave::jit_function_info::jit_function_info(), octave::jit_typeinfo::jit_typeinfo(), octave::jit_typeinfo::add_binary_fcmp(), octave::jit_typeinfo::add_binary_icmp(), octave::jit_typeinfo::add_binary_op(), octave::jit_convert_llvm::convert_function(), octave::jit_index_operation::create_arg_array(), octave::jit_typeinfo::create_identity(), octave::jit_typeinfo::mirror_binary(), octave::jit_typeinfo::register_generic(), and octave::jit_typeinfo::register_intrinsic().
|
inline |
Definition at line 329 of file jit-typeinfo.h.
Referenced by octave::jit_typeinfo::mirror_binary().
|
inline |
Definition at line 335 of file jit-typeinfo.h.
Referenced by octave::jit_operation::add_overload().
|
inline |
Definition at line 278 of file jit-typeinfo.h.
References octave::builder.
|
inline |
Definition at line 286 of file jit-typeinfo.h.
References octave::builder.
llvm::Value* octave::jit_function::call | ( | llvm::IRBuilderD & | builder, |
const arg_vec & | in_args = arg_vec() |
||
) | const |
Referenced by octave::jit_function_info::jit_function_info(), octave::jit_typeinfo::jit_typeinfo(), call(), octave::jit_paren_subsref::generate_matrix(), octave::jit_paren_subsasgn::generate_matrix(), octave::jit_typeinfo::mirror_binary(), octave::jit_typeinfo::register_generic(), and octave::jit_convert_llvm::visit().
llvm::Value * octave::jit_function::call | ( | llvm::IRBuilderD & | builder, |
const std::vector< jit_value * > & | in_args | ||
) | const |
Definition at line 658 of file jit-typeinfo.cc.
References octave::builder, call(), m_args, to_llvm(), and valid().
|
inline |
Definition at line 294 of file jit-typeinfo.h.
References octave::builder.
|
inline |
Definition at line 304 of file jit-typeinfo.h.
References octave::builder.
|
inline |
Definition at line 323 of file jit-typeinfo.h.
Referenced by octave::jit_typeinfo::mirror_binary().
void octave::jit_function::do_return | ( | llvm::IRBuilderD & | builder, |
llvm::Value * | rval = nullptr , |
||
bool | verify = true |
||
) |
Definition at line 763 of file jit-typeinfo.cc.
References octave::builder, convert(), m_call_conv, m_llvm_function, m_result, octave::jit_type::pack(), and sret().
Referenced by octave::jit_function_info::jit_function_info(), octave::jit_typeinfo::jit_typeinfo(), octave::jit_typeinfo::add_binary_fcmp(), octave::jit_typeinfo::add_binary_icmp(), octave::jit_typeinfo::add_binary_op(), octave::jit_typeinfo::create_identity(), octave::jit_typeinfo::mirror_binary(), octave::jit_typeinfo::register_generic(), octave::jit_typeinfo::register_intrinsic(), and octave::jit_convert_llvm::visit().
void octave::jit_function::erase | ( | void | ) |
Definition at line 634 of file jit-typeinfo.cc.
References m_llvm_function.
Referenced by octave::jit_function_info::jit_function_info().
|
inline |
Definition at line 325 of file jit-typeinfo.h.
Referenced by octave::jit_typeinfo::jit_typeinfo(), octave::jit_paren_subsref::init_paren_scalar(), octave::jit_paren_subsasgn::init_paren_scalar(), octave::jit_typeinfo::mirror_binary(), and octave::jit_typeinfo::register_generic().
std::string octave::jit_function::name | ( | void | ) | const |
Definition at line 644 of file jit-typeinfo.cc.
References m_llvm_function.
Referenced by octave::jit_typeinfo::mirror_binary().
llvm::BasicBlock * octave::jit_function::new_block | ( | const std::string & | aname = "body" , |
llvm::BasicBlock * | insert_before = nullptr |
||
) |
Definition at line 650 of file jit-typeinfo.cc.
References octave::context, and m_llvm_function.
Referenced by octave::jit_function_info::jit_function_info(), octave::jit_typeinfo::jit_typeinfo(), octave::jit_typeinfo::add_binary_fcmp(), octave::jit_typeinfo::add_binary_icmp(), octave::jit_typeinfo::add_binary_op(), octave::jit_convert_llvm::convert_function(), octave::jit_typeinfo::create_identity(), octave::jit_typeinfo::mirror_binary(), octave::jit_typeinfo::register_generic(), and octave::jit_typeinfo::register_intrinsic().
|
inline |
Definition at line 327 of file jit-typeinfo.h.
Referenced by octave::jit_call::jit_call(), octave::jit_function_info::jit_function_info(), octave::jit_magic_end::infer(), octave::jit_typeinfo::mirror_binary(), and octave::jit_operation::result().
|
inline |
Definition at line 321 of file jit-typeinfo.h.
Referenced by jit_function(), argument(), and do_return().
|
inline |
Definition at line 318 of file jit-typeinfo.h.
Referenced by octave::jit_function_info::jit_function_info(), call(), and octave::jit_convert_llvm::convert_function().
|
inline |
Definition at line 262 of file jit-typeinfo.h.
Referenced by octave::jit_call::jit_call(), call(), octave::jit_typeinfo::register_generic(), and octave::jit_convert_llvm::visit().
|
friend |
Definition at line 789 of file jit-typeinfo.cc.
|
private |
Definition at line 342 of file jit-typeinfo.h.
Referenced by jit_function(), argument(), and call().
|
private |
Definition at line 343 of file jit-typeinfo.h.
Referenced by jit_function(), argument(), and do_return().
|
private |
Definition at line 344 of file jit-typeinfo.h.
|
private |
Definition at line 340 of file jit-typeinfo.h.
Referenced by jit_function(), argument(), do_return(), erase(), name(), and new_block().
|
private |
Definition at line 339 of file jit-typeinfo.h.
Referenced by jit_function().
|
private |
Definition at line 341 of file jit-typeinfo.h.
Referenced by jit_function(), and do_return().