pinapa Namespace Reference


Classes

struct  event_assoc_unit
class  st_backend
class  st_basic_slave_method_handle
class  st_c_value
class  st_c_int
class  st_c_bool
class  key_assoc_tree_module
struct  equal_to_key_assoc_tree_module
struct  hash_key_assoc_tree_module
class  st_tree_instance_module_deco_t
class  st_deco_b
class  st_deco_first
class  st_deco
class  st_event_deco_t
class  slave_method_as_process
 Constructor for a pseudo process highlighting a remarkable method. More...
class  get_initial_values
class  st_module_deco_t
class  st_port_deco_t
class  port_to_port_hook
struct  port_assoc_unit
class  sc_interface_list_hook
class  st_systemc_deco_t
class  st_deco_first< st_systemc_deco_t, sc_object >
class  st_deco_first< st_systemc_deco_t, sc_event >
class  st_deco_first< st_systemc_deco_t, void >
class  st_process_deco_t
class  sensitive_hook
class  st_sensitivity
class  st_time_sensitivity
class  st_sensitivity_list
class  st_signal_deco_t
class  simcontext
class  st_tac_slave_method_handle
class  st_deco_first< deco, tree_node >
class  key_assoc_tree_handle
struct  equal_to_key_assoc_tree_handle
struct  hash_key_assoc_tree_handle
class  st_tree_instance_deco_t
class  st_tree_deco_t
class  st_dependant_deco
class  st_read_deco
class  st_write_deco
class  st_func_decl_deco
class  st_tlm_write_deco
class  st_type_deco
class  st_data_member_decl_deco
class  st_inst_dependant_deco
class  st_event_tree_deco
class  st_wait_deco
class  treeFacade
class  treeVisitor
class  resizeable_array
class  analysis_set
class  function_body_visitor
class  st_hook_param
class  st_hooked_function
class  hook
class  sensitive_param

Namespaces

namespace  parser_flags

Typedefs

typedef vector< event_assoc_unitevent_assoc
typedef st_basic_slave_method_handlebasic_slave_method_handle
typedef st_c_valuec_value
typedef st_deco_first< st_tree_instance_module_deco_t,
key_assoc_tree_module
st_tree_instance_module_deco
typedef st_tree_instance_module_decotree_instance_module_deco
typedef hash_map< key_assoc_tree_module,
tree_instance_module_deco,
hash_key_assoc_tree_module,
equal_to_key_assoc_tree_module
assoc_tree_module
typedef st_deco_bdeco_b
typedef st_deco_first< st_event_deco_t,
sc_event
st_event_deco
typedef st_event_decoevent_deco
typedef slave_method_as_processslave_method_handle
typedef st_deco_first< st_module_deco_t,
sc_module
st_module_deco
typedef st_module_decomodule_deco
typedef st_deco_first< st_port_deco_t,
sc_port_base
st_port_deco
typedef st_port_decoport_deco
typedef st_deco_first< st_port_deco_t,
sc_export_base
st_export_deco
typedef st_export_decoexport_deco
typedef vector< port_assoc_unitport_assoc
typedef st_deco_first< st_systemc_deco_t,
sc_object
st_scobject_deco_t
typedef st_deco_first< st_systemc_deco_t,
sc_event
st_scevent_deco_t
typedef st_deco_first< st_systemc_deco_t,
void > 
st_scdummy_deco_t
typedef st_deco_first< st_process_deco_t,
sc_process_b
st_process_deco
typedef st_process_decoprocess_deco
typedef st_sensitivitysensitivity
typedef st_sensitivity_listsensitivity_list
typedef st_time_sensitivitytime_sensitivity
typedef st_deco_first< st_signal_deco_t,
sc_interface
st_signal_deco
typedef st_signal_decosignal_deco
typedef st_tac_slave_method_handletac_slave_method_handle
typedef st_tree_deco_ttree_deco_t
typedef st_dependant_decodependant_deco
typedef st_type_decotype_deco
typedef st_data_member_decl_decodata_member_decl_deco
typedef st_event_tree_decoevent_tree_deco
typedef st_inst_dependant_decoinst_dependant_deco
typedef st_deco_first< st_tree_deco_t,
tree_node > 
st_tree_deco
typedef st_tree_decotree_deco
typedef st_deco_first< st_tree_deco_t,
tree_node > 
st_tree_deco
typedef st_tree_decotree_deco
typedef st_deco_first< st_tree_instance_deco_t,
key_assoc_tree_handle
st_tree_instance_deco
typedef st_tree_instance_decotree_instance_deco
typedef hash_map< key_assoc_tree_handle,
tree_instance_deco, hash_key_assoc_tree_handle,
equal_to_key_assoc_tree_handle
assoc_tree_handle
typedef st_wait_decowait_deco
typedef hash_set< treefunction_set_t
typedef st_hook_paramhook_param
typedef st_hooked_functionhooked_function

Enumerations

enum  rw { read, write }
enum  type_of_function {
  CPP_STANDARD_FUNC, SC_PROCESS, BASIC_READ_TARGET, BASIC_WRITE_TARGET,
  TAC_READ_TARGET, TAC_READ_BYTE_ENABLE_TARGET, TAC_READ_BLOCK_TARGET, TAC_WRITE_TARGET,
  TAC_WRITE_BYTE_ENABLE_TARGET, TAC_WRITE_BLOCK_TARGET, USER_HIGHLIGHT_TARGET
}
enum  sc_primitive_t {
  CPP_STANDARD, CPP_FUNC_DECL, CPP_DATA_MEMBER, SC_VARIABLE_DECL,
  PINAPA_TYPE, SC_PORT, SC_WRITE, SC_READ,
  SC_MODULE, SC_WAIT, PINAPA_BASIC_SEQ_WRITE, PINAPA_BASIC_ARBITER_WRITE,
  PINAPA_BASIC_SEQ_READ, PINAPA_BASIC_ARBITER_READ, PINAPA_TAC_ROUTER_READ, PINAPA_TAC_ARBITER_READ,
  PINAPA_TAC_SEQ_READ, PINAPA_TAC_ROUTER_WRITE, PINAPA_TAC_ARBITER_WRITE, PINAPA_TAC_SEQ_WRITE,
  PINAPA_TAC_SET_ACCESS_ERROR, TLM_IS_ERROR, TLM_IS_OK, TLM_IS_OVERLAP,
  TLM_IS_NO_RESPONSE, TLM_SET_OK, TLM_SET_ERROR, SC_NOTIFY,
  SC_NEXT_TRIGGER, PINAPA_TLM_BASIC_READ, PINAPA_TLM_BASIC_WRITE, PINAPA_TLM_TAC_READ,
  PINAPA_TLM_TAC_WRITE, TLM_PV_WAIT, TLM_PV_NEXT_TRIGGER, TLM_IS_SYNCHRO
}
enum  type_of_type { PINAPA_TLM_ADDRESS_TYPE, PINAPA_TLM_DATA_TYPE, PINAPA_STANDARD_TYPE }

Functions

void process_type (tree body, tree value)
void get_value_at_end_of_elaboration (tree body, const vector< sc_process_b * > &vh)
void get_value_at_address (tree type, int address)
void analyze_function_body (tree body, tree module, const vector< sc_process_b * > &vh)
void mark_function_calls (tree body, tree module)
void finish_proc_analysisses ()
string build_gcc_command (const string &tmpfilename, const string &libfilename)
template<>
void * get_decoration< key_assoc_tree_module > (key_assoc_tree_module &th)
template<>
void set_decoration< key_assoc_tree_module > (key_assoc_tree_module &th, void *d)
template<class parent>
void * get_decoration (parent &p)
template<class parent>
void set_decoration (parent &p, void *c)
void finalize ()
template<typename T>
size_t hash_ptr_fct (const void *ptr)
void initialize ()
void connect_interfaces_to_slave ()
int main (int argc, char *argv[], pinapa::st_backend *destination)
int sc_main_in_parser (int argc, char *argv[])
string parser_getopt_file_to_parse ()
string parser_getopt_lib_to_load ()
bool parser_getopt_retrieve_source_locations ()
bool parser_getopt_enable_process_analysis ()
bool parser_getopt_gcc_permissive ()
set< pair< string, string > > parser_getopt_hightlight_slaves ()
void parser_initialize_parse_file (const string &parser_file_to_parse)
void parser_initialize_lib_to_load (const string &lib_to_load)
void parser_retrieve_source_locations (const bool flag=true)
void parser_enable_process_analysis (const bool flag=true)
void parser_gcc_permissive (const bool flag=true)
void parser_highlight_slave (const string &slave_base, const string &slave_method)
void parser_highlight_slaves_include (const string &file_name)
void analyze_read_or_write (rw rw, tree function, tree module, vector< sc_process_b * > vh)
template<typename sc_type_of_object>
inst_dependant_deco decoration_for (sc_type_of_object *obj)
template<>
inst_dependant_deco decoration_for< sc_event > (sc_event *obj)
template<>
inst_dependant_deco decoration_for< sc_port_base > (sc_port_base *obj)
template<typename sc_type_of_object, typename assoc_unit>
vector< assoc_unit > this_one_may_be_a (tree port, tree module, const vector< sc_process_b * > &vh)
void replace (string &Source, const string &Find, const string &Replacement)
bool end_with (string &Source, const string &End)
void end_with__test ()
void push_split (const string &str, const string &sep, vector< string > &dest)
void push_split__test ()
template<class T>
string string_from (const T &val, ios_base &(*f)(ios_base &)=dec)
template<class T>
to (const std::string &s, std::ios_base &(*f)(std::ios_base &)=std::dec)
string defensive_getenv (const char *variable)
char * get_name (sc_primitive_t prim)
char * get_doc (sc_primitive_t prim)
template<>
void * get_decoration< key_assoc_tree_handle > (key_assoc_tree_handle &th)
template<>
void set_decoration< key_assoc_tree_handle > (key_assoc_tree_handle &th, void *d)
void gdb_dump_instance_deco ()
void print_primitive (sc_primitive_t sc_primitive)
template<typename T, typename P>
bool instance_of (P p)
void process_type (tree body, tree value)
void get_value_at_end_of_elaboration (tree body, const vector< sc_process_b * > &vh)
void get_value_at_address (tree type, int address)
tree_deco analyze_wait_or_nt_arguments (sc_primitive_t primitive, tree list_args, tree module, const vector< sc_process_b * > &vh, tree to_be_decorated)
void analyze_notify (tree function, tree module, vector< sc_process_b * > vh)
void __do_analyze_function (tree body, tree module, const vector< sc_process_b * > &vh)
void __do_analyze_function (tree body, tree module, const vector< sc_process_b * > &vh)
void analyze_function_body (tree body, tree module, const vector< sc_process_b * > &vh)
void mark_function_calls (tree body, tree module)
void finish_proc_analysisses ()
tree_deco analyze_wait_or_nt_arguments (sc_primitive_t primitive, tree list_args, tree module, const vector< sc_process_b * > &vh, tree to_be_decorated)
void analyze_notify (tree function, tree module, vector< sc_process_b * > vh)
string build_gcc_command (const string &tmpfilename, const string &libfilename)
int call_gcc ()
void parser_start ()
int call_gcc ()
void parser_start ()
void finalize ()
void initialize ()
void connect_interfaces_to_slave ()
int main (int argc, char *argv[], st_backend *destination)
string parser_getopt_file_to_parse ()
string parser_getopt_lib_to_load ()
bool parser_getopt_retrieve_source_locations ()
bool parser_getopt_enable_process_analysis ()
bool parser_getopt_gcc_permissive ()
void parser_initialize_parse_file (const string &parser_file_to_parse)
void parser_initialize_lib_to_load (const string &lib_to_load)
void parser_retrieve_source_locations (const bool flag)
void parser_enable_process_analysis (const bool flag)
void parser_gcc_permissive (const bool flag)
set< pair< string, string > > parser_getopt_hightlight_slaves ()
void parser_highlight_slave (const string &slave_base, const string &slave_method)
void parser_highlight_slaves_include (const string &file_name)
void analyze_read_or_write (rw rw, tree function, tree module, vector< sc_process_b * > vh)
char * get_name (sc_primitive_t prim)
char * get_doc (sc_primitive_t prim)

Variables

assoc_tree_module instances_module_deco
pinapa::st_backendgo_back_to
hash_map< tree, tree_decotree_decoration_map
assoc_tree_handle instances_deco
static vector< analysis_sets_process_analyzed
function_set_t global_function_set
tree current_function
tree pinapa_current_function_return_value
bool named_return_value_attach_it = false


Typedef Documentation

typedef hash_map<key_assoc_tree_handle, tree_instance_deco, hash_key_assoc_tree_handle, equal_to_key_assoc_tree_handle > pinapa::assoc_tree_handle

typedef hash_map<key_assoc_tree_module, tree_instance_module_deco, hash_key_assoc_tree_module, equal_to_key_assoc_tree_module > pinapa::assoc_tree_module

typedef st_basic_slave_method_handle* pinapa::basic_slave_method_handle

typedef st_c_value* pinapa::c_value

typedef st_data_member_decl_deco* pinapa::data_member_decl_deco

typedef st_deco_b* pinapa::deco_b

typedef st_dependant_deco* pinapa::dependant_deco

typedef vector<event_assoc_unit> pinapa::event_assoc

association (sc_process -> sc_event). This could have been done with a hashtable, but is probably more efficient like this.

typedef st_event_deco* pinapa::event_deco

typedef st_event_tree_deco* pinapa::event_tree_deco

typedef st_export_deco* pinapa::export_deco

typedef hash_set<tree> pinapa::function_set_t

typedef st_hook_param* pinapa::hook_param

typedef st_hooked_function* pinapa::hooked_function

typedef st_inst_dependant_deco* pinapa::inst_dependant_deco

typedef st_module_deco* pinapa::module_deco

typedef vector<port_assoc_unit> pinapa::port_assoc

association (sc_process -> sc_port). This could have been done with a hashtable, but is probably more efficient like this.

typedef st_port_deco* pinapa::port_deco

typedef st_process_deco* pinapa::process_deco

typedef st_sensitivity* pinapa::sensitivity

typedef st_sensitivity_list* pinapa::sensitivity_list

typedef st_signal_deco* pinapa::signal_deco

typedef slave_method_as_process* pinapa::slave_method_handle

typedef st_deco_first<st_event_deco_t, sc_event> pinapa::st_event_deco

typedef st_deco_first<st_port_deco_t, sc_export_base> pinapa::st_export_deco

typedef st_deco_first<st_module_deco_t, sc_module> pinapa::st_module_deco

typedef st_deco_first<st_port_deco_t, sc_port_base> pinapa::st_port_deco

typedef st_deco_first<st_process_deco_t, sc_process_b> pinapa::st_process_deco

typedef st_deco_first<st_systemc_deco_t,void> pinapa::st_scdummy_deco_t

typedef st_deco_first<st_systemc_deco_t,sc_event> pinapa::st_scevent_deco_t

typedef st_deco_first<st_systemc_deco_t,sc_object> pinapa::st_scobject_deco_t

typedef st_deco_first<st_signal_deco_t, sc_interface> pinapa::st_signal_deco

typedef st_deco_first<st_tree_deco_t, tree_node> pinapa::st_tree_deco

typedef st_deco_first<st_tree_deco_t, tree_node> pinapa::st_tree_deco

typedef st_deco_first<st_tree_instance_deco_t, key_assoc_tree_handle> pinapa::st_tree_instance_deco

typedef st_deco_first<st_tree_instance_module_deco_t, key_assoc_tree_module> pinapa::st_tree_instance_module_deco

typedef st_tac_slave_method_handle* pinapa::tac_slave_method_handle

typedef st_time_sensitivity* pinapa::time_sensitivity

typedef st_tree_deco* pinapa::tree_deco

typedef st_tree_deco* pinapa::tree_deco

typedef st_tree_deco_t* pinapa::tree_deco_t

typedef st_tree_instance_deco* pinapa::tree_instance_deco

typedef st_tree_instance_module_deco* pinapa::tree_instance_module_deco

typedef st_type_deco* pinapa::type_deco

typedef st_wait_deco* pinapa::wait_deco


Enumeration Type Documentation

enum pinapa::rw

Enumerator:
read 
write 

enum pinapa::sc_primitive_t

Type of statement or object in SystemC.

Enumerator:
CPP_STANDARD  C++ code unrelated to SystemC
CPP_FUNC_DECL  C++ function declaration
CPP_DATA_MEMBER  A variable which is a data-member of a class
SC_VARIABLE_DECL  Declaration of a variable which is of a SC or TLM primitive time
PINAPA_TYPE  Type. (decoration of TREE_TYPE field in the tree)
SC_PORT  An object of type sc_in sc_out or sc_inout
SC_WRITE  A function call port.write(value)
SC_READ  A function call port.read(value)
SC_MODULE  A module in SystemC
SC_WAIT  A function call wait(...)
PINAPA_BASIC_SEQ_WRITE  Obsolete
PINAPA_BASIC_ARBITER_WRITE  Obsolete
PINAPA_BASIC_SEQ_READ  Obsolete
PINAPA_BASIC_ARBITER_READ  Obsolete
PINAPA_TAC_ROUTER_READ  Obsolete
PINAPA_TAC_ARBITER_READ  Obsolete
PINAPA_TAC_SEQ_READ  Obsolete
PINAPA_TAC_ROUTER_WRITE  Obsolete
PINAPA_TAC_ARBITER_WRITE  Obsolete
PINAPA_TAC_SEQ_WRITE  Obsolete
PINAPA_TAC_SET_ACCESS_ERROR  set_access_error in a TAC slave method
TLM_IS_ERROR  tlm_status::is_error()
TLM_IS_OK  tlm_status::is_ok()
TLM_IS_OVERLAP  Obsolete
TLM_IS_NO_RESPONSE  tlm_status::is_no_response()
TLM_SET_OK  tlm_status::set_ok()
TLM_SET_ERROR  tlm_status::set_error()
SC_NOTIFY  Event notification in SystemC
SC_NEXT_TRIGGER  Call to a next_trigger() function in SystemC
PINAPA_TLM_BASIC_READ  A function call port.read(value) on a TLM Basic port
PINAPA_TLM_BASIC_WRITE  A function call port.write(value) on a TLM Basic port
PINAPA_TLM_TAC_READ  A function call port.read(value) on a TLM Tac port
PINAPA_TLM_TAC_WRITE  A function call port.write(value) on a TLM Tac port
TLM_PV_WAIT  A function call module.pv_wait() on a TLM module
TLM_PV_NEXT_TRIGGER  A function call module.pv_next_trigger() on a TLM module
TLM_IS_SYNCHRO  tlm_status::is_synchro()

enum pinapa::type_of_function

Enumerator:
CPP_STANDARD_FUNC  C++ standard function of method
SC_PROCESS  function implementing a SystemC process
BASIC_READ_TARGET  Overloaded read function in a BASIC target module.
BASIC_WRITE_TARGET  Overloaded write function in a BASIC target module.
TAC_READ_TARGET  Overloaded read function in a TAC target module.
TAC_READ_BYTE_ENABLE_TARGET  Overloaded read function in a TAC target module with byte enable.
TAC_READ_BLOCK_TARGET  Overloaded read block function in a TAC target module.
TAC_WRITE_TARGET  Overloaded write function in a TAC target module.
TAC_WRITE_BYTE_ENABLE_TARGET  Overloaded write function in a TAC target module with byte enable.
TAC_WRITE_BLOCK_TARGET  Overloaded write block function in a TAC target module.
USER_HIGHLIGHT_TARGET  Overloaded method module (hightlighted upon user's request)

enum pinapa::type_of_type

Types in the source code can be primitive types of SystemC or TLM. This enumeration lists the primitive types.

Enumerator:
PINAPA_TLM_ADDRESS_TYPE  Type of an address in the basic protocol
PINAPA_TLM_DATA_TYPE  Type of a data in the basic protocol
PINAPA_STANDARD_TYPE  C++ standard type.


Function Documentation

void pinapa::__do_analyze_function ( tree  body,
tree  module,
const vector< sc_process_b * > &  vh 
)

void pinapa::__do_analyze_function ( tree  body,
tree  module,
const vector< sc_process_b * > &  vh 
)

void pinapa::analyze_function_body ( tree  body,
tree  module,
const vector< sc_process_b * > &  vh 
)

top-level function to call to analyze the body of the function.

void pinapa::analyze_function_body ( tree  body,
tree  module,
const vector< sc_process_b * > &  vh 
)

top-level function to call to analyze the body of the function.

void pinapa::analyze_notify ( tree  function,
tree  module,
vector< sc_process_b * >  vh 
)

void pinapa::analyze_notify ( tree  function,
tree  module,
vector< sc_process_b * >  vh 
)

void pinapa::analyze_read_or_write ( rw  rw,
tree  function,
tree  module,
vector< sc_process_b * >  vh 
)

Analyze a call to a function whose name is "write".

This is mostly BASIC and TAC write, but could be extended later.

void pinapa::analyze_read_or_write ( rw  rw,
tree