GNU Octave
4.0.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
|
#include "pt-jit.h"
Public Types | |
typedef jit_convert::variable_map | variable_map |
Public Member Functions | |
jit_infer (jit_factory &afactory, jit_block_list &ablocks, const variable_map &avmap) | |
jit_block_list & | get_blocks (void) const |
jit_factory & | get_factory (void) const |
void | infer (void) |
Private Member Functions | |
void | append_users (jit_value *v) |
void | append_users_term (jit_terminator *term) |
void | construct_ssa (void) |
void | do_construct_ssa (jit_block &block, size_t avisit_count) |
jit_block & | entry_block (void) |
jit_block & | final_block (void) |
void | place_releases (void) |
void | push_worklist (jit_instruction *instr) |
void | release_dead_phi (jit_block &ablock) |
void | release_temp (jit_block &ablock, std::set< jit_value * > &temp) |
void | remove_dead () |
void | simplify_phi (void) |
void | simplify_phi (jit_phi &phi) |
Private Attributes | |
jit_block_list & | blocks |
jit_factory & | factory |
const variable_map & | vmap |
std::list< jit_instruction * > | worklist |
jit_infer::jit_infer | ( | jit_factory & | afactory, |
jit_block_list & | ablocks, | ||
const variable_map & | avmap | ||
) |
|
private |
Definition at line 1696 of file pt-jit.cc.
References jit_internal_list< LIST_T, NODE_T >::first_use(), jit_internal_node< LIST_T, NODE_T >::next(), and push_worklist().
Referenced by infer().
|
private |
Definition at line 1703 of file pt-jit.cc.
References jit_terminator::alive(), jit_block::begin(), jit_block::end(), push_worklist(), jit_terminator::successor(), jit_terminator::successor_count(), and jit_block::terminator().
Referenced by infer().
|
private |
Definition at line 1722 of file pt-jit.cc.
References blocks, jit_block::compute_df(), jit_block::compute_idom(), jit_factory::create(), jit_block::create_dom_tree(), jit_block::df_begin(), jit_block::df_end(), do_construct_ssa(), entry_block(), factory, final_block(), jit_block_list::label(), jit_block::prepend(), jit_block::use_count(), and vmap.
Referenced by infer().
Definition at line 1769 of file pt-jit.cc.
References jit_phi::add_incomming(), jit_block::begin(), jit_instruction::construct_ssa(), jit_assign_base::dest(), jit_block::dom_successor(), jit_block::dom_successor_count(), jit_block::end(), jit_variable::has_top(), jit_variable::name(), jit_block::pop_all(), jit_instruction::push_variable(), jit_instruction::remove(), jit_block::successor(), jit_block::successor_count(), jit_variable::top(), jit_internal_list< LIST_T, NODE_T >::use_count(), and jit_block::visited().
Referenced by construct_ssa().
|
inlineprivate |
Definition at line 327 of file pt-jit.h.
Referenced by construct_ssa(), and infer().
|
inlineprivate |
Definition at line 329 of file pt-jit.h.
Referenced by construct_ssa(), and release_temp().
|
inline |
|
inline |
void jit_infer::infer | ( | void | ) |
Definition at line 1658 of file pt-jit.cc.
References append_users(), append_users_term(), blocks, jit_factory::constants(), construct_ssa(), entry_block(), factory, jit_instruction::infer(), jit_block_list::label(), next, place_releases(), push_worklist(), remove_dead(), simplify_phi(), jit_value::stash_in_worklist(), jit_block::terminator(), and worklist.
Referenced by jit_info::compile(), and jit_function_info::jit_function_info().
|
private |
Definition at line 1814 of file pt-jit.cc.
References jit_block_list::begin(), blocks, jit_block_list::end(), jit_block::id(), jit_block::NO_ID, release_dead_phi(), and release_temp().
Referenced by infer().
|
private |
Definition at line 1830 of file pt-jit.cc.
References jit_value::in_worklist(), jit_value::stash_in_worklist(), and worklist.
Referenced by append_users(), append_users_term(), and infer().
|
private |
Definition at line 1890 of file pt-jit.cc.
References arg(), jit_instruction::argument(), jit_instruction::argument_count(), jit_block::begin(), blocks, jit_factory::create(), jit_block::end(), factory, jit_internal_list< LIST_T, NODE_T >::first_use(), jit_phi::incomming(), jit_call::infer(), jit_block::insert_before(), jit_block::maybe_split(), jit_value::needs_release(), jit_typeinfo::release(), jit_instruction::remove(), jit_value::replace_with(), jit_block::terminator(), jit_internal_list< LIST_T, NODE_T >::use_count(), and jit_use::user().
Referenced by place_releases().
Definition at line 1925 of file pt-jit.cc.
References arg(), jit_instruction::argument(), jit_instruction::argument_count(), jit_block::begin(), blocks, jit_factory::create(), jit_block::end(), factory, final_block(), jit_value::first_use_block(), jit_call::infer(), jit_block::insert_after(), jit_block::insert_before(), jit_block::maybe_split(), jit_value::needs_release(), jit_typeinfo::release(), and jit_block::terminator().
Referenced by place_releases().
|
private |
Definition at line 1840 of file pt-jit.cc.
References jit_block::alive(), jit_terminator::alive(), jit_block::append(), jit_block_list::begin(), jit_block::begin(), blocks, jit_factory::create(), jit_block_list::end(), jit_block::end(), jit_block_list::erase(), factory, jit_terminator::infer(), jit_phi::prune(), jit_instruction::remove(), jit_block::remove(), jit_terminator::successor(), jit_terminator::successor_count(), and jit_block::terminator().
Referenced by infer().
|
private |
Definition at line 1979 of file pt-jit.cc.
References jit_block_list::begin(), jit_block::begin(), blocks, jit_block_list::end(), and jit_block::end().
Referenced by infer().
|
private |
Definition at line 1992 of file pt-jit.cc.
References arg(), jit_instruction::argument(), jit_instruction::argument_count(), blocks, jit_typeinfo::cast(), jit_factory::create(), jit_assign_base::dest(), factory, jit_phi::incomming(), jit_instruction::infer(), jit_block::insert_before(), jit_block::maybe_split(), jit_instruction::parent(), jit_instruction::stash_argument(), jit_block::terminator(), and jit_value::type().
|
private |
Definition at line 314 of file pt-jit.h.
Referenced by construct_ssa(), infer(), place_releases(), release_dead_phi(), release_temp(), remove_dead(), and simplify_phi().
|
private |
Definition at line 315 of file pt-jit.h.
Referenced by construct_ssa(), infer(), release_dead_phi(), release_temp(), remove_dead(), and simplify_phi().
|
private |
Definition at line 316 of file pt-jit.h.
Referenced by construct_ssa().
|
private |
Definition at line 317 of file pt-jit.h.
Referenced by infer(), and push_worklist().