GNU Octave  4.0.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
jit_function Class Reference

#include "jit-typeinfo.h"

Collaboration diagram for jit_function:
Collaboration graph
[legend]

Public Member Functions

 jit_function ()
 
 jit_function (llvm::Module *amodule, jit_convention::type acall_conv, const llvm::Twine &aname, jit_type *aresult, const std::vector< jit_type * > &aargs)
 
 jit_function (const jit_function &fn, jit_type *aresult, const std::vector< jit_type * > &aargs)
 
 jit_function (const jit_function &fn)
 
template<typename T >
void add_mapping (llvm::ExecutionEngine *engine, T fn)
 
llvm::Value * argument (llvm::IRBuilderD &builder, size_t idx) const
 
jit_typeargument_type (size_t idx) const
 
const std::vector< jit_type * > & arguments (void) const
 
llvm::Value * call (llvm::IRBuilderD &builder, const std::vector< jit_value * > &in_args) const
 
llvm::Value * call (llvm::IRBuilderD &builder, const std::vector< llvm::Value * > &in_args=std::vector< llvm::Value * >()) const
 
llvm::Value * call (llvm::IRBuilderD &builder, llvm::Value *arg0, llvm::Value *arg1, llvm::Value *arg2, llvm::Value *arg3, llvm::Value *arg4) const
 
llvm::Value * call (llvm::IRBuilderD &builder, llvm::Value *arg0) const
 
llvm::Value * call (llvm::IRBuilderD &builder, llvm::Value *arg0, llvm::Value *arg1) const
 
llvm::Value * call (llvm::IRBuilderD &builder, llvm::Value *arg0, llvm::Value *arg1, llvm::Value *arg2) const
 
llvm::Value * call (llvm::IRBuilderD &builder, llvm::Value *arg0, llvm::Value *arg1, llvm::Value *arg2, llvm::Value *arg3) const
 
llvm::Value * call (llvm::IRBuilderD &builder, llvm::Value *arg0) const
 
llvm::Value * call (llvm::IRBuilderD &builder, llvm::Value *arg0, llvm::Value *arg1) const
 
llvm::Value * call (llvm::IRBuilderD &builder, llvm::Value *arg0, llvm::Value *arg1, llvm::Value *arg2) const
 
bool can_error (void) const
 
void do_return (llvm::IRBuilderD &builder, llvm::Value *rval=0, 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=0)
 
jit_typeresult (void) const
 
bool sret (void) const
 
llvm::Function * to_llvm (void) const
 
bool valid (void) const
 

Private Member Functions

void do_add_mapping (llvm::ExecutionEngine *engine, void *fn)
 

Private Attributes

std::vector< jit_type * > args
 
jit_convention::type call_conv
 
llvm::Function * llvm_function
 
bool mcan_error
 
llvm::Module * module
 
jit_typemresult
 

Friends

std::ostream & operator<< (std::ostream &os, const jit_function &fn)
 

Detailed Description

Definition at line 222 of file jit-typeinfo.h.

Constructor & Destructor Documentation

jit_function::jit_function ( )

Definition at line 560 of file jit-typeinfo.cc.

jit_function::jit_function ( llvm::Module *  amodule,
jit_convention::type  acall_conv,
const llvm::Twine &  aname,
jit_type aresult,
const std::vector< jit_type * > &  aargs 
)
jit_function::jit_function ( const jit_function fn,
jit_type aresult,
const std::vector< jit_type * > &  aargs 
)

Definition at line 623 of file jit-typeinfo.cc.

jit_function::jit_function ( const jit_function fn)

Definition at line 630 of file jit-typeinfo.cc.

Member Function Documentation

template<typename T >
void jit_function::add_mapping ( llvm::ExecutionEngine *  engine,
fn 
)
inline
llvm::Value * jit_function::argument ( llvm::IRBuilderD builder,
size_t  idx 
) const
jit_type* jit_function::argument_type ( size_t  idx) const
inline

Definition at line 296 of file jit-typeinfo.h.

Referenced by jit_typeinfo::mirror_binary().

const std::vector<jit_type *>& jit_function::arguments ( void  ) const
inline

Definition at line 302 of file jit-typeinfo.h.

llvm::Value * jit_function::call ( llvm::IRBuilderD builder,
const std::vector< jit_value * > &  in_args 
) const
llvm::Value * jit_function::call ( llvm::IRBuilderD builder,
const std::vector< llvm::Value * > &  in_args = std::vector<llvm::Value *> () 
) const
llvm::Value* jit_function::call ( llvm::IRBuilderD builder,
llvm::Value *  arg0 
) const
inline

Definition at line 268 of file jit-typeinfo.h.

llvm::Value* jit_function::call ( llvm::IRBuilderD builder,
llvm::Value *  arg0,
llvm::Value *  arg1 
) const
inline

Definition at line 268 of file jit-typeinfo.h.

llvm::Value* jit_function::call ( llvm::IRBuilderD builder,
llvm::Value *  arg0,
llvm::Value *  arg1,
llvm::Value *  arg2 
) const
inline

Definition at line 268 of file jit-typeinfo.h.

llvm::Value* jit_function::call ( llvm::IRBuilderD builder,
llvm::Value *  arg0,
llvm::Value *  arg1,
llvm::Value *  arg2,
llvm::Value *  arg3 
) const
inline

Definition at line 268 of file jit-typeinfo.h.

llvm::Value* jit_function::call ( llvm::IRBuilderD builder,
llvm::Value *  arg0,
llvm::Value *  arg1,
llvm::Value *  arg2,
llvm::Value *  arg3,
llvm::Value *  arg4 
) const
inline

Definition at line 268 of file jit-typeinfo.h.

llvm::Value* jit_function::call ( llvm::IRBuilderD builder,
llvm::Value *  arg0 
) const
inline

Definition at line 272 of file jit-typeinfo.h.

llvm::Value* jit_function::call ( llvm::IRBuilderD builder,
llvm::Value *  arg0,
llvm::Value *  arg1 
) const
inline

Definition at line 273 of file jit-typeinfo.h.

llvm::Value* jit_function::call ( llvm::IRBuilderD builder,
llvm::Value *  arg0,
llvm::Value *  arg1,
llvm::Value *  arg2 
) const
inline

Definition at line 274 of file jit-typeinfo.h.

bool jit_function::can_error ( void  ) const
inline

Definition at line 290 of file jit-typeinfo.h.

Referenced by jit_typeinfo::mirror_binary().

void jit_function::do_add_mapping ( llvm::ExecutionEngine *  engine,
void *  fn 
)
private

Definition at line 792 of file jit-typeinfo.cc.

References llvm_function, and valid().

void jit_function::do_return ( llvm::IRBuilderD builder,
llvm::Value *  rval = 0,
bool  verify = true 
)
void jit_function::erase ( void  )

Definition at line 636 of file jit-typeinfo.cc.

References llvm_function.

Referenced by jit_function_info::jit_function_info().

void jit_function::mark_can_error ( void  )
inline
std::string jit_function::name ( void  ) const

Definition at line 646 of file jit-typeinfo.cc.

References llvm_function.

Referenced by jit_typeinfo::mirror_binary().

llvm::BasicBlock * jit_function::new_block ( const std::string &  aname = "body",
llvm::BasicBlock *  insert_before = 0 
)
jit_type* jit_function::result ( void  ) const
inline
bool jit_function::sret ( void  ) const
inline

Definition at line 288 of file jit-typeinfo.h.

Referenced by argument(), call(), do_return(), and jit_function().

llvm::Function* jit_function::to_llvm ( void  ) const
inline
bool jit_function::valid ( void  ) const
inline

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  os,
const jit_function fn 
)
friend

Definition at line 799 of file jit-typeinfo.cc.

Member Data Documentation

std::vector<jit_type *> jit_function::args
private

Definition at line 309 of file jit-typeinfo.h.

Referenced by argument(), call(), and jit_function().

jit_convention::type jit_function::call_conv
private

Definition at line 310 of file jit-typeinfo.h.

Referenced by argument(), call(), do_return(), jit_function(), and operator<<().

llvm::Function* jit_function::llvm_function
private
bool jit_function::mcan_error
private

Definition at line 311 of file jit-typeinfo.h.

llvm::Module* jit_function::module
private

Definition at line 306 of file jit-typeinfo.h.

Referenced by jit_function().

jit_type* jit_function::mresult
private

Definition at line 308 of file jit-typeinfo.h.

Referenced by call(), do_return(), and jit_function().


The documentation for this class was generated from the following files: