GNU Octave
3.8.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
|
#include "pt-jit.h"
Public Member Functions | |
jit_function | convert_function (llvm::Module *module, const jit_block_list &blocks, const std::list< jit_value * > &constants, octave_user_function &fcn, const std::vector< jit_type * > &args) |
llvm::Function * | convert_loop (llvm::Module *module, const jit_block_list &blocks, const std::list< jit_value * > &constants) |
const std::vector< std::pair < std::string, bool > > & | get_arguments (void) const |
virtual void | visit (jit_const_index &) |
virtual void | visit (jit_const_complex &) |
virtual void | visit (jit_const_scalar &) |
virtual void | visit (jit_const_bool &) |
virtual void | visit (jit_magic_end &) |
virtual void | visit (jit_argument &) |
virtual void | visit (jit_assign &) |
virtual void | visit (jit_error_check &) |
virtual void | visit (jit_variable &) |
virtual void | visit (jit_phi &) |
virtual void | visit (jit_return &) |
virtual void | visit (jit_store_argument &) |
virtual void | visit (jit_extract_argument &) |
virtual void | visit (jit_call &) |
virtual void | visit (jit_cond_branch &) |
virtual void | visit (jit_branch &) |
virtual void | visit (jit_block &) |
virtual void | visit (jit_const_string &) |
virtual void | visit (jit_const_range &) |
Private Member Functions | |
void | convert (const jit_block_list &blocks, const std::list< jit_value * > &constants) |
void | finish_phi (jit_phi *phi) |
void | visit (jit_value *jvalue) |
void | visit (jit_value &jvalue) |
Private Attributes | |
std::map< std::string, int > | argument_index |
std::vector< std::pair < std::string, bool > > | argument_vec |
std::map< std::string, llvm::Value * > | arguments |
bool | converting_function |
jit_function | creating |
llvm::Function * | function |
llvm::BasicBlock * | prelude |
|
private |
Definition at line 1219 of file pt-jit.cc.
References jit_block_list::begin(), jit_block::begin(), builder(), jit_block_list::end(), jit_block::end(), finish_phi(), jit_block::name(), jit_value::stash_llvm(), jit_block::to_llvm(), and visit().
Referenced by convert_function(), and convert_loop().
jit_function jit_convert_llvm::convert_function | ( | llvm::Module * | module, |
const jit_block_list & | blocks, | ||
const std::list< jit_value * > & | constants, | ||
octave_user_function & | fcn, | ||
const std::vector< jit_type * > & | args | ||
) |
Definition at line 1173 of file pt-jit.cc.
References jit_function::argument(), arguments, jit_block_list::back(), jit_block::back(), octave_base_list< elt_type >::begin(), builder(), convert(), converting_function, creating, octave_base_list< elt_type >::end(), jit_convention::internal, tree_decl_elt::name(), jit_function::new_block(), octave_user_function::parameter_list(), prelude, jit_return::result_type(), and jit_function::to_llvm().
Referenced by jit_function_info::jit_function_info().
llvm::Function * jit_convert_llvm::convert_loop | ( | llvm::Module * | module, |
const jit_block_list & | blocks, | ||
const std::list< jit_value * > & | constants | ||
) |
Definition at line 1121 of file pt-jit.cc.
References arg(), argument_vec, arguments, jit_block::begin(), builder(), convert(), converting_function, jit_block::end(), jit_block_list::front(), jit_typeinfo::get_any(), prelude, and jit_type::to_llvm().
Referenced by jit_info::compile().
Definition at line 1259 of file pt-jit.cc.
References jit_instruction::argument_count(), jit_instruction::argument_llvm(), jit_phi::incomming_llvm(), and jit_phi::to_llvm().
Referenced by convert().
|
inline |
Definition at line 259 of file pt-jit.h.
Referenced by jit_info::compile().
|
virtual |
Implements jit_ir_walker.
|
virtual |
Implements jit_ir_walker.
Implements jit_ir_walker.
Definition at line 1323 of file pt-jit.cc.
References jit_block::begin(), builder(), jit_block::end(), and jit_block::to_llvm().
Referenced by convert().
|
virtual |
Implements jit_ir_walker.
|
virtual |
Implements jit_ir_walker.
|
virtual |
Implements jit_ir_walker.
Definition at line 1361 of file pt-jit.cc.
References arg(), arguments, builder(), jit_function::call(), converting_function, jit_extract_argument::name(), jit_extract_argument::overload(), and jit_value::stash_llvm().
|
virtual |
Implements jit_ir_walker.
Definition at line 1464 of file pt-jit.cc.
References builder(), jit_function::call(), jit_magic_end::context::count, jit_magic_end::context::index, jit_magic_end::overload(), jit_magic_end::resolve_context(), jit_value::stash_llvm(), and jit_magic_end::context::value.
|
virtual |
Implements jit_ir_walker.
|
virtual |
Implements jit_ir_walker.
Definition at line 1442 of file pt-jit.cc.
References jit_assign::artificial(), builder(), jit_function::call(), jit_typeinfo::get_release(), jit_assign::overwrite(), jit_assign::src(), jit_value::stash_llvm(), jit_value::to_llvm(), jit_value::type(), and jit_function::valid().
|
virtual |
Implements jit_ir_walker.
Definition at line 1420 of file pt-jit.cc.
References builder(), jit_error_check::check_variable(), jit_typeinfo::insert_error_check(), jit_typeinfo::insert_interrupt_check(), panic_impossible, jit_value::stash_llvm(), jit_terminator::successor_llvm(), jit_error_check::var_error_state, and jit_error_check::var_interrupt.
|
virtual |
Implements jit_ir_walker.
Definition at line 1338 of file pt-jit.cc.
References builder(), jit_cond_branch::cond_llvm(), jit_value::stash_llvm(), and jit_terminator::successor_llvm().
|
virtual |
Implements jit_ir_walker.
Definition at line 1332 of file pt-jit.cc.
References builder(), jit_value::stash_llvm(), and jit_terminator::successor_llvm().
|
virtual |
Implements jit_ir_walker.
|
virtual |
Implements jit_ir_walker.
Definition at line 1270 of file pt-jit.cc.
References builder(), jit_value::stash_llvm(), and jit_const< T, EXTRACT_T, PASS_T, QUOTE >::value().
|
virtual |
Implements jit_ir_walker.
Definition at line 1378 of file pt-jit.cc.
References arg(), arguments, builder(), jit_function::call(), jit_store_argument::name(), jit_store_argument::overload(), jit_store_argument::result(), and jit_value::stash_llvm().
Implements jit_ir_walker.
Definition at line 1348 of file pt-jit.cc.
References jit_instruction::argument(), jit_instruction::arguments(), builder(), jit_function::call(), jit_call::overload(), and jit_value::stash_llvm().
|
virtual |
Implements jit_ir_walker.
|
virtual |
Implements jit_ir_walker.
Definition at line 1387 of file pt-jit.cc.
References builder(), converting_function, creating, jit_function::do_return(), jit_return::result(), and jit_value::to_llvm().
Implements jit_ir_walker.
Definition at line 1403 of file pt-jit.cc.
References jit_instruction::argument_count(), builder(), jit_value::stash_llvm(), and jit_value::type_llvm().
Definition at line 295 of file pt-jit.h.
References jit_value::accept().
|
private |
|
private |
Definition at line 272 of file pt-jit.h.
Referenced by convert_loop().
|
private |
Definition at line 275 of file pt-jit.h.
Referenced by convert_function(), convert_loop(), and visit().
|
private |
Definition at line 277 of file pt-jit.h.
Referenced by convert_function(), convert_loop(), and visit().
|
private |
Definition at line 280 of file pt-jit.h.
Referenced by convert_function(), and visit().
|
private |
Definition at line 283 of file pt-jit.h.
Referenced by convert_function(), and convert_loop().