PandA-2024.02
|
This class describes a port associated with a component or a channel. More...
#include <structural_objects.hpp>
Public Types | |
enum | port_direction |
Enumerative type describing the direction of a port. More... | |
enum | port_endianess { LITTLE = 0, BIG, NONE } |
Enumerative type describing the endianess of a port; NONE means that it has not been specified yet. More... | |
enum | port_interface : int |
Enum type describing if the port is associated with a specific interface type. More... | |
Public Member Functions | |
port_o (int debug_level, const structural_objectRef o, port_direction dir, so_kind _port_type) | |
Constructor. More... | |
~port_o () override=default | |
Destructor. More... | |
void | add_connection (structural_objectRef s) |
Bind this port with a signal/port. More... | |
void | remove_connection (structural_objectRef s) |
remove a connection (signal/port) from this More... | |
bool | is_connected (structural_objectRef s) const |
void | substitute_connection (structural_objectRef old_conn, structural_objectRef new_conn) |
const structural_objectRef | get_connection (unsigned int n) const |
Return connection bounded to this port. More... | |
unsigned int | get_connections_size () const |
Return the number of connections bounded to this port. More... | |
port_direction | get_port_direction () const |
Return the direction of the port. More... | |
void | set_port_direction (port_direction dir) |
Set the direction of the port. More... | |
port_endianess | get_port_endianess () const |
Return the endianess of the port. More... | |
void | set_port_endianess (port_endianess end) |
Set the endianess of the port. More... | |
port_interface | get_port_interface () const |
Return the port interface type of the port. More... | |
void | set_port_interface (port_interface pi) |
Set the port interface type of the port. More... | |
unsigned int | get_port_alignment () const |
Return the port interface alignment. More... | |
void | set_port_alignment (unsigned int algn) |
Set the port interface alignment. More... | |
structural_objectRef | get_connected_signal () const |
Return the connected signal, if any. More... | |
void | set_port_size (unsigned int dim) |
Set port size. More... | |
unsigned long long | get_port_size () const |
Get port size. More... | |
void | set_is_var_args (bool c) |
set the is var_args attribute. More... | |
bool | get_is_var_args () const |
return true if the port is a var_args More... | |
void | set_is_clock (bool c) |
set the is clock attribute. More... | |
bool | get_is_clock () const |
return true if the port is a clock More... | |
void | set_is_extern (bool c) |
set the is_extern attribute. More... | |
bool | get_is_extern () const |
return true if the port is extern More... | |
void | set_bus_bundle (const std::string &name) |
Sets the bus bundle identifier. More... | |
std::string | get_bus_bundle () const |
Returns the bus bundle identifier, if any. More... | |
void | set_is_global (bool c) |
set the is_global attribute. More... | |
bool | get_is_global () const |
return true if the port is global More... | |
void | set_is_memory (bool c) |
set the is_memory attribute. More... | |
bool | get_is_memory () const |
return true if the port is a memory port More... | |
void | set_is_slave (bool c) |
set the is_slave attribute. More... | |
bool | get_is_slave () const |
return true if the port works as slave memory port More... | |
void | set_is_master (bool c) |
set the is_master attribute. More... | |
bool | get_is_master () const |
return true if the port works as master memory port More... | |
void | set_is_data_bus (bool c) |
set the is_data attribute. More... | |
bool | get_is_data_bus () const |
return true if the port works as a data bus More... | |
void | set_is_addr_bus (bool c) |
set the is_addr_bus attribute. More... | |
bool | get_is_addr_bus () const |
return true if the port works as an address bus More... | |
void | set_is_size_bus (bool c) |
set the is_size_bus attribute. More... | |
bool | get_is_size_bus () const |
return true if the port works as a size bus More... | |
void | set_is_tag_bus (bool c) |
set the is_tag_bus attribute. More... | |
bool | get_is_tag_bus () const |
return true if the port works as an tag bus More... | |
void | set_is_doubled (bool c) |
set the is_doubled attribute. More... | |
bool | get_is_doubled () const |
return true if the port has a doubled size w.r.t the precision More... | |
void | set_is_halved (bool c) |
set the is_halved attribute. More... | |
bool | get_is_halved () const |
return true if the port has a halved size w.r.t the precision More... | |
structural_objectRef | find_bounded_object (const structural_objectConstRef f_owner=structural_objectConstRef()) const |
Find the object bounded to the port. More... | |
void | set_critical () |
set the port as critical with respect to the timing path More... | |
bool | get_critical () const |
return if the component is critical or not More... | |
void | set_reverse () |
Sets the port as reverse. More... | |
bool | get_reverse () const |
Returns if the port as to be printed in a reverse mode. More... | |
void | copy (structural_objectRef dest) const override |
Perform a copy of the port. More... | |
structural_objectRef | find_member (const std::string &id, so_kind type, const structural_objectRef owner) const override |
Return the object named id of a given type which belongs to or it is associated with the object. More... | |
structural_objectRef | find_isomorphic (const structural_objectRef key) const override |
Find key in this object. More... | |
void | xload (const xml_element *Enode, structural_objectRef owner, structural_managerRef const &CM) override |
Load a structural_object starting from an xml file. More... | |
void | xwrite (xml_element *rootnode) override |
Add a structural_object to an xml tree. More... | |
void | add_n_ports (unsigned int n_ports, structural_objectRef owner) |
Specify the number of ports of a generic port_vector object and add its corresponding ports. More... | |
const structural_objectRef | get_port (unsigned int n) const |
Return the ith port of the vector. More... | |
unsigned int | get_ports_size () const |
Return the number of ports. More... | |
unsigned int | get_lsb () const |
return the index of the least significant port More... | |
void | print (std::ostream &os) const override |
Print the port (for debug purpose) More... | |
std::string | get_kind_text () const override |
return the name of the class as a string. More... | |
enum so_kind | get_kind () const override |
return the type of the class More... | |
Public Member Functions inherited from structural_object | |
structural_object (int debug_level, const structural_objectRef o) | |
Constructor for the structural_object. More... | |
virtual | ~structural_object ()=default |
virtual destructor More... | |
const structural_objectRef | get_owner () const |
Return the owner. More... | |
void | set_owner (const structural_objectRef new_owner) |
set the owner of the structural object More... | |
void | set_treenode (unsigned int n) |
Set the treenode id associated with the structural_object. More... | |
unsigned int | get_treenode () const |
Return the treenode id associated with the structural_object. More... | |
void | set_id (const std::string &s) |
Set the identifier associated with the structural_object. More... | |
const std::string & | get_id () const |
Return the identifier associated with the structural_object. More... | |
void | set_type (const structural_type_descriptorRef &s) |
Set the type of the structural_object. More... | |
const structural_type_descriptorRef & | get_typeRef () const |
Return the type descriptor of the structural_object. More... | |
void | type_resize (unsigned long long new_bit_size) |
Just resize the size of the bits of the object. More... | |
void | type_resize (unsigned long long new_bit_size, unsigned long long new_vec_size) |
resizing of vector objects More... | |
void | set_black_box (bool bb) |
Set the black box property associated with the structural_object. More... | |
bool | get_black_box () const |
Return the black box property. More... | |
void | SetParameter (const std::string &name, const std::string &value) |
Set a parameter value. More... | |
bool | ExistsParameter (std::string name) const |
Check if a parameter has been specified. More... | |
std::string | GetParameter (std::string name) const |
Get the value associated to parameter if it has been associated; if it has not specified returns the default. More... | |
std::string | GetDefaultParameter (std::string name) const |
Get the value associated to parameter if it has been associate; It throws an exception if it has not been associated. More... | |
CustomMap< std::string, std::string > | GetParameters () const |
return the whole set of parameters More... | |
virtual void | AddParameter (const std::string &name, const std::string &default_value) |
Add a parameter. More... | |
const std::string | get_path () const |
Return a unique identifier of the structural object. More... | |
Static Public Member Functions | |
static std::string | GetString (enum port_direction) |
static std::string | GetString (enum port_interface) |
static port_direction | to_port_direction (const std::string &val) |
Convert a string into the corresponding port_direction enumerative type. More... | |
static port_interface | to_port_interface (const std::string &val) |
Convert a string into the corresponding port_interface enumerative type. More... | |
static bool | resize_if_busport (unsigned long long bus_size_bitsize, unsigned long long bus_addr_bitsize, unsigned long long bus_data_bitsize, unsigned long long bus_tag_bitsize, structural_objectRef port) |
auxiliary function used to resize the bus ports with respect to their associated bus size More... | |
static void | resize_std_port (unsigned long long bitsize_variable, unsigned long long n_elements, int debug_level, structural_objectRef port) |
auxiliary function used to resize the standard ports More... | |
static void | fix_port_properties (structural_objectRef port_i, structural_objectRef cir_port) |
copy the port properties from port_i to cir_port More... | |
Data Fields | |
std::string | size_parameter |
custom size parameter More... | |
Static Public Attributes | |
static const unsigned int | PARAMETRIC_PORT = static_cast<unsigned int>(-1) |
Private Attributes | |
std::vector< Wrefcount< structural_object > > | connected_objects |
The list of connections associated with the port. More... | |
port_direction | dir |
direction of a port More... | |
port_endianess | end |
endianess of a port More... | |
port_interface | pi |
port interface type of a port More... | |
unsigned int | aligment |
bool | is_var_args |
when true the port must be specialized at runtime depending on the number of input More... | |
bool | is_clock |
when true the port is a clock port and has to be attached to a clock object More... | |
bool | is_extern |
when true the port is an extern port More... | |
bool | is_global |
when true the port is a global port More... | |
bool | is_reverse |
when true the port is dumped as [0:msb-1] instead of [msb-1:0] More... | |
bool | is_memory |
when true the port is a memory port More... | |
bool | is_slave |
when true the port is a slave port More... | |
bool | is_master |
when true the port is a master port More... | |
bool | is_data_bus |
when true the port is a data bus More... | |
bool | is_addr_bus |
when true the port is an address bus More... | |
bool | is_size_bus |
when true the port is a size bus More... | |
bool | is_tag_bus |
when true the port is a tag bus More... | |
bool | is_doubled |
when true the port has a doubled size More... | |
bool | is_halved |
when true the port has a halfed size More... | |
bool | is_critical |
when true the port is involved into the critical path of the netlist More... | |
std::string | bus_bundle |
bus bundle More... | |
unsigned int | lsb |
least significant bit More... | |
std::vector< structural_objectRef > | ports |
The list of ports associated with the port. More... | |
so_kind | port_type |
port type More... | |
Static Private Attributes | |
default values associated with the members of the port_o class. | |
static const bool | is_clock_DEFAULT = false |
static const bool | is_extern_DEFAULT = false |
static const bool | is_global_DEFAULT = false |
static const bool | is_memory_DEFAULT = false |
static const bool | is_slave_DEFAULT = false |
static const bool | is_master_DEFAULT = false |
static const bool | is_data_bus_DEFAULT = false |
static const bool | is_addr_bus_DEFAULT = false |
static const bool | is_tag_bus_DEFAULT = false |
static const bool | is_size_bus_DEFAULT = false |
static const bool | is_doubled_DEFAULT = false |
static const bool | is_halved_DEFAULT = false |
static const bool | is_critical_DEFAULT = false |
static const bool | is_reverse_DEFAULT = false |
static const bool | is_var_args_DEFAULT = false |
static const unsigned | port_interface_alignment_DEFAULT = 0 |
Additional Inherited Members | |
Protected Member Functions inherited from structural_object | |
std::string | convert_so_short (so_kind in) const |
Convert a so_kind in a short string. More... | |
Protected Attributes inherited from structural_object | |
friend | structural_manager |
int | debug_level |
debug level for the object More... | |
Static Protected Attributes inherited from structural_object | |
static simple_indent | PP |
pretty print functor object used by all print members to indent the output of the print function. More... | |
This class describes a port associated with a component or a channel.
A port can be in relation with:
Definition at line 622 of file structural_objects.hpp.
Enumerative type describing the direction of a port.
Definition at line 626 of file structural_objects.hpp.
Enumerative type describing the endianess of a port; NONE means that it has not been specified yet.
Enumerator | |
---|---|
LITTLE | |
BIG | |
NONE |
Definition at line 634 of file structural_objects.hpp.
enum port_o::port_interface : int |
Enum type describing if the port is associated with a specific interface type.
Definition at line 642 of file structural_objects.hpp.
port_o::port_o | ( | int | debug_level, |
const structural_objectRef | o, | ||
port_direction | dir, | ||
so_kind | _port_type | ||
) |
Constructor.
o | is the owner of the port |
dir | defines the direction of the port. |
Definition at line 1003 of file structural_objects.cpp.
Referenced by copy(), and xload().
|
overridedefault |
Destructor.
void port_o::add_connection | ( | structural_objectRef | s | ) |
Bind this port with a signal/port.
s | is the connection |
Definition at line 1042 of file structural_objects.cpp.
References connected_objects, constant_o_K, structural_object::get_kind(), get_kind(), structural_object::get_kind_text(), structural_object::get_owner(), structural_object::get_path(), port_o_K, port_vector_o_K, signal_o_K, signal_vector_o_K, and THROW_ASSERT.
void port_o::add_n_ports | ( | unsigned int | n_ports, |
structural_objectRef | owner | ||
) |
Specify the number of ports of a generic port_vector object and add its corresponding ports.
It can be done only on port_vectors not yet specialized. The type of the port is equal to the type descriptor of the port_vector.
n_ports | is the number of the ports. |
owner | is the reference version of "this". |
Definition at line 5092 of file structural_objects.cpp.
References structural_object::debug_level, refcount< T >::get(), structural_object::get_path(), structural_object::get_typeRef(), port_o_K, port_vector_o_K, structural_object::set_id(), structural_object::set_type(), and THROW_ASSERT.
|
overridevirtual |
Perform a copy of the port.
dest | destination object. |
connected_objects has to be updated outside!!!
Reimplemented from structural_object.
Definition at line 1526 of file structural_objects.cpp.
References aligment, bus_bundle, structural_object::copy(), structural_object::debug_level, DEBUG_LEVEL_VERY_PEDANTIC, dir, end, structural_object::get_path(), get_port(), index, is_addr_bus, is_clock, is_critical, is_data_bus, is_doubled, is_extern, is_global, is_halved, is_master, is_memory, is_reverse, is_size_bus, is_slave, is_tag_bus, is_var_args, lsb, pi, port_o(), port_o_K, ports, PRINT_DBG_MEX, size_parameter, STR, and THROW_ERROR.
structural_objectRef port_o::find_bounded_object | ( | const structural_objectConstRef | f_owner = structural_objectConstRef() | ) | const |
Find the object bounded to the port.
The object searched has the same owner of the port.
Definition at line 1352 of file structural_objects.cpp.
References connected_objects, constant_o_K, structural_object::get_id(), get_kind(), structural_object::get_owner(), structural_object::get_path(), INDENT_DBG_MEX, port_o_K, port_vector_o_K, signal_o_K, signal_vector_o_K, THROW_ASSERT, and THROW_UNREACHABLE.
Referenced by structural_manager::build_graph().
|
overridevirtual |
Find key in this object.
key | is the object searched. |
Implements structural_object.
Definition at line 1438 of file structural_objects.cpp.
References action_o_K, bus_connection_o_K, channel_o_K, component_o_K, constant_o_K, data_o_K, event_o_K, structural_object::get_id(), structural_object::get_kind(), structural_object::get_owner(), k, key, port_o_K, port_vector_o_K, ports, signal_o_K, signal_vector_o_K, THROW_ASSERT, and THROW_ERROR.
|
overridevirtual |
Return the object named id of a given type which belongs to or it is associated with the object.
id | is the identifier of the object we are looking for. |
type | is the type of the object we are looking for. |
owner | is the owner of the object named id. |
Implements structural_object.
Definition at line 1486 of file structural_objects.cpp.
References action_o_K, bus_connection_o_K, channel_o_K, component_o_K, connected_objects, constant_o_K, data_o_K, event_o_K, port_o_K, port_type, port_vector_o_K, ports, signal_o_K, signal_vector_o_K, THROW_ASSERT, and THROW_ERROR.
|
static |
copy the port properties from port_i to cir_port
port_i | is the source port |
cir_port | is the created port |
Definition at line 5193 of file structural_objects.cpp.
Referenced by top_entity::add_ports(), minimal_interface::build_wrapper(), fu_binding::manage_extern_global_port(), datapath_parallel_cs::manage_extern_global_port_parallel(), cs_interface::manage_extern_global_port_top(), fu_binding_cs::manage_memory_port_hierarchical(), fu_binding_cs::manage_memory_port_kernel(), fu_binding::manage_memory_ports_chained(), and fu_binding::manage_memory_ports_parallel_chained().
std::string port_o::get_bus_bundle | ( | ) | const |
Returns the bus bundle identifier, if any.
Definition at line 1247 of file structural_objects.cpp.
References bus_bundle.
structural_objectRef port_o::get_connected_signal | ( | ) | const |
Return the connected signal, if any.
Null pointer otherwise.
Definition at line 1101 of file structural_objects.cpp.
References connected_objects, structural_object::get_owner(), structural_object::get_path(), signal_o_K, signal_vector_o_K, and THROW_ASSERT.
const structural_objectRef port_o::get_connection | ( | unsigned int | n | ) | const |
Return connection bounded to this port.
n | is the index of the connection |
Definition at line 1157 of file structural_objects.cpp.
References connected_objects, and THROW_ASSERT.
unsigned int port_o::get_connections_size | ( | ) | const |
Return the number of connections bounded to this port.
Definition at line 1163 of file structural_objects.cpp.
References connected_objects.
bool port_o::get_critical | ( | ) | const |
return if the component is critical or not
Definition at line 1584 of file structural_objects.cpp.
References is_critical.
Referenced by structural_manager::build_graph().
bool port_o::get_is_addr_bus | ( | ) | const |
return true if the port works as an address bus
Definition at line 1307 of file structural_objects.cpp.
References is_addr_bus.
bool port_o::get_is_clock | ( | ) | const |
return true if the port is a clock
Definition at line 1227 of file structural_objects.cpp.
References is_clock.
bool port_o::get_is_data_bus | ( | ) | const |
return true if the port works as a data bus
Definition at line 1297 of file structural_objects.cpp.
References is_data_bus.
bool port_o::get_is_doubled | ( | ) | const |
return true if the port has a doubled size w.r.t the precision
Definition at line 1337 of file structural_objects.cpp.
References is_doubled.
bool port_o::get_is_extern | ( | ) | const |
return true if the port is extern
Definition at line 1237 of file structural_objects.cpp.
References is_extern.
bool port_o::get_is_global | ( | ) | const |
return true if the port is global
Definition at line 1257 of file structural_objects.cpp.
References is_global.
bool port_o::get_is_halved | ( | ) | const |
return true if the port has a halved size w.r.t the precision
Definition at line 1347 of file structural_objects.cpp.
References is_halved.
bool port_o::get_is_master | ( | ) | const |
return true if the port works as master memory port
Definition at line 1287 of file structural_objects.cpp.
References is_master.
bool port_o::get_is_memory | ( | ) | const |
return true if the port is a memory port
Definition at line 1267 of file structural_objects.cpp.
References is_memory.
bool port_o::get_is_size_bus | ( | ) | const |
return true if the port works as a size bus
Definition at line 1317 of file structural_objects.cpp.
References is_size_bus.
bool port_o::get_is_slave | ( | ) | const |
return true if the port works as slave memory port
Definition at line 1277 of file structural_objects.cpp.
References is_slave.
bool port_o::get_is_tag_bus | ( | ) | const |
return true if the port works as an tag bus
Definition at line 1327 of file structural_objects.cpp.
References is_tag_bus.
bool port_o::get_is_var_args | ( | ) | const |
return true if the port is a var_args
Definition at line 1217 of file structural_objects.cpp.
References is_var_args.
|
inlineoverridevirtual |
return the type of the class
Implements structural_object.
Definition at line 1057 of file structural_objects.hpp.
Referenced by add_connection(), and find_bounded_object().
|
inlineoverridevirtual |
return the name of the class as a string.
Implements structural_object.
Definition at line 1043 of file structural_objects.hpp.
References port_vector_o_K.
Referenced by xwrite().
|
inline |
return the index of the least significant port
Definition at line 999 of file structural_objects.hpp.
References structural_type_descriptor::print().
const structural_objectRef port_o::get_port | ( | unsigned int | n | ) | const |
Return the ith port of the vector.
It checks that a port exists at position n.
n | is the index of the port |
Definition at line 5110 of file structural_objects.cpp.
References structural_object::get_path(), port_vector_o_K, STR, and THROW_ASSERT.
Referenced by copy().
unsigned int port_o::get_port_alignment | ( | ) | const |
Return the port interface alignment.
Definition at line 1202 of file structural_objects.cpp.
References aligment.
port_o::port_direction port_o::get_port_direction | ( | ) | const |
Return the direction of the port.
Definition at line 1168 of file structural_objects.cpp.
References dir.
port_o::port_endianess port_o::get_port_endianess | ( | ) | const |
Return the endianess of the port.
Definition at line 1182 of file structural_objects.cpp.
References end.
port_o::port_interface port_o::get_port_interface | ( | ) | const |
Return the port interface type of the port.
Definition at line 1192 of file structural_objects.cpp.
References pi.
unsigned long long port_o::get_port_size | ( | ) | const |
Get port size.
Definition at line 5128 of file structural_objects.cpp.
References structural_object::get_typeRef(), and structural_type_descriptor::size.
unsigned int port_o::get_ports_size | ( | ) | const |
Return the number of ports.
When the port_vector has not yet specialized 0 is returned.
Definition at line 5117 of file structural_objects.cpp.
References structural_object::get_path(), port_vector_o_K, and THROW_ASSERT.
bool port_o::get_reverse | ( | ) | const |
Returns if the port as to be printed in a reverse mode.
Definition at line 1594 of file structural_objects.cpp.
References is_reverse.
|
static |
Referenced by TestbenchGeneration::Exec(), InterfaceInfer::Exec(), TestbenchFifoModuleGenerator::InternalExec(), TestbenchAxisModuleGenerator::InternalExec(), print(), to_port_direction(), to_port_interface(), and xwrite().
|
static |
bool port_o::is_connected | ( | structural_objectRef | s | ) | const |
Definition at line 1083 of file structural_objects.cpp.
References connected_objects, and THROW_ASSERT.
|
overridevirtual |
Print the port (for debug purpose)
os | is an output stream |
Reimplemented from structural_object.
Definition at line 1871 of file structural_objects.cpp.
References aligment, connected_objects, structural_object::convert_so_short(), dir, GetString(), pi, port_interface_alignment_DEFAULT, ports, structural_object::PP, structural_object::print(), and STR.
void port_o::remove_connection | ( | structural_objectRef | s | ) |
remove a connection (signal/port) from this
s | is the connection to be removed |
Definition at line 1066 of file structural_objects.cpp.
References connected_objects, structural_object::get_path(), and THROW_ASSERT.
|
static |
auxiliary function used to resize the bus ports with respect to their associated bus size
bus_size_bitsize | bitsize of sizes |
bus_addr_bitsize | bitsize of addresses |
bus_data_bitsize | bitsize of data |
bus_tag_bitsize | bitsize of tag |
port | is the port to be resized |
Definition at line 5133 of file structural_objects.cpp.
References structural_object::get_kind(), pi(), port_vector_o_K, structural_object::type_resize(), and U.
Referenced by fu_binding::add_to_SM(), TasteInterfaceGeneration::InternalExec(), TopEntityMemoryMapped::resizing_IO(), fu_binding::specialise_fu(), and RTLCharacterization::specialize_fu().
|
static |
auxiliary function used to resize the standard ports
bitsize_variable | is the bitsize |
n_elements | is the number of elements |
debug_level | is the debug level |
port | is the port to be resized |
Definition at line 5157 of file structural_objects.cpp.
References structural_object::debug_level, DEBUG_LEVEL_PEDANTIC, structural_object::get_kind(), structural_object::get_path(), INDENT_DBG_MEX, pi(), port_vector_o_K, STR, THROW_ASSERT, and structural_object::type_resize().
Referenced by classic_datapath::InternalExec(), fu_binding::join_merge_split(), fu_binding::manage_extern_global_port(), RTLCharacterization::resize_port(), and fu_binding::specialise_fu().
void port_o::set_bus_bundle | ( | const std::string & | name | ) |
Sets the bus bundle identifier.
Definition at line 1242 of file structural_objects.cpp.
References bus_bundle.
void port_o::set_critical | ( | ) |
set the port as critical with respect to the timing path
Definition at line 1579 of file structural_objects.cpp.
References is_critical.
void port_o::set_is_addr_bus | ( | bool | c | ) |
set the is_addr_bus attribute.
c | when true the port is a port used as an address bus |
Definition at line 1302 of file structural_objects.cpp.
References is_addr_bus.
void port_o::set_is_clock | ( | bool | c | ) |
set the is clock attribute.
c | when true the port is a clock port and has to be attached to a clock object |
Definition at line 1222 of file structural_objects.cpp.
References is_clock.
void port_o::set_is_data_bus | ( | bool | c | ) |
set the is_data attribute.
c | when true the port is a port used as a data bus |
Definition at line 1292 of file structural_objects.cpp.
References is_data_bus.
void port_o::set_is_doubled | ( | bool | c | ) |
set the is_doubled attribute.
c | when true the port has a doubled size w.r.t the precision |
Definition at line 1332 of file structural_objects.cpp.
References is_doubled.
void port_o::set_is_extern | ( | bool | c | ) |
set the is_extern attribute.
c | when true the port is a extern port and has to be attached to an extern object |
Definition at line 1232 of file structural_objects.cpp.
References is_extern.
void port_o::set_is_global | ( | bool | c | ) |
set the is_global attribute.
c | when true the port is a global port and has to be attached to a global object |
Definition at line 1252 of file structural_objects.cpp.
References is_global.
void port_o::set_is_halved | ( | bool | c | ) |
set the is_halved attribute.
c | when true the port has a halved size w.r.t the precision |
Definition at line 1342 of file structural_objects.cpp.
References is_halved.
void port_o::set_is_master | ( | bool | c | ) |
set the is_master attribute.
c | when true the port is a port used to interact with the onchip or offchip memory as master |
Definition at line 1282 of file structural_objects.cpp.
References is_master.
void port_o::set_is_memory | ( | bool | c | ) |
set the is_memory attribute.
c | when true the port is a port used to interact with the onchip or offchip memory |
Definition at line 1262 of file structural_objects.cpp.
References is_memory.
void port_o::set_is_size_bus | ( | bool | c | ) |
set the is_size_bus attribute.
c | when true the port is a port used as a size bus |
Definition at line 1312 of file structural_objects.cpp.
References is_size_bus.
void port_o::set_is_slave | ( | bool | c | ) |
set the is_slave attribute.
c | when true the port is a port used to interact with the onchip or offchip memory as slave |
Definition at line 1272 of file structural_objects.cpp.
References is_slave.
void port_o::set_is_tag_bus | ( | bool | c | ) |
set the is_tag_bus attribute.
c | when true the port is a port used as an tag bus |
Definition at line 1322 of file structural_objects.cpp.
References is_tag_bus.
void port_o::set_is_var_args | ( | bool | c | ) |
set the is var_args attribute.
c | when true the port has a variable numbers of inputs |
Definition at line 1212 of file structural_objects.cpp.
References is_var_args.
void port_o::set_port_alignment | ( | unsigned int | algn | ) |
Set the port interface alignment.
Definition at line 1207 of file structural_objects.cpp.
References aligment.
void port_o::set_port_direction | ( | port_direction | dir | ) |
Set the direction of the port.
Definition at line 1173 of file structural_objects.cpp.
void port_o::set_port_endianess | ( | port_endianess | end | ) |
Set the endianess of the port.
Definition at line 1187 of file structural_objects.cpp.
References end.
void port_o::set_port_interface | ( | port_interface | pi | ) |
Set the port interface type of the port.
Definition at line 1197 of file structural_objects.cpp.
References pi.
void port_o::set_port_size | ( | unsigned int | dim | ) |
Set port size.
dim | is the new dimension of the port |
Definition at line 5123 of file structural_objects.cpp.
References structural_object::get_typeRef(), and structural_type_descriptor::size.
void port_o::set_reverse | ( | ) |
Sets the port as reverse.
Definition at line 1589 of file structural_objects.cpp.
References is_reverse.
void port_o::substitute_connection | ( | structural_objectRef | old_conn, |
structural_objectRef | new_conn | ||
) |
Definition at line 1116 of file structural_objects.cpp.
References connected_objects, structural_object::get_kind(), structural_object::get_path(), signal_o_K, and THROW_ERROR.
|
static |
Convert a string into the corresponding port_direction enumerative type.
val | is the string version of the enum. |
Definition at line 1720 of file structural_objects.cpp.
References GetString().
Referenced by TestbenchAcknowledgeModuleGenerator::InternalExec(), TestbenchValidModuleGenerator::InternalExec(), TestbenchOvalidModuleGenerator::InternalExec(), TestbenchArrayModuleGenerator::InternalExec(), TestbenchHandshakeModuleGenerator::InternalExec(), TestbenchNoneModuleGenerator::InternalExec(), TestbenchAxisModuleGenerator::InternalExec(), TestbenchFifoModuleGenerator::InternalExec(), xload(), and module::xload().
|
static |
Convert a string into the corresponding port_interface enumerative type.
val | is the string version of the enum. |
Definition at line 1733 of file structural_objects.cpp.
References GetString().
Referenced by xload().
|
overridevirtual |
Load a structural_object starting from an xml file.
node | is a node of the xml tree. |
owner | is the refcount version of this. |
CM | is the circuit manager. |
the field connected_objects has to be updated outside!!!
Reimplemented from structural_object.
Definition at line 1599 of file structural_objects.cpp.
References aligment, CE_XVM, dir, xml_child::get_children(), GET_CLASS_NAME, structural_manager::get_debug_level(), structural_object::get_id(), is_addr_bus, is_clock, is_critical, is_data_bus, is_doubled, is_extern, is_global, is_halved, is_master, is_memory, is_reverse, is_size_bus, is_slave, is_tag_bus, is_var_args, LOAD_XVFM, LOAD_XVM, lsb, max, min, pi, port_o(), port_o_K, port_type, port_vector_o_K, ports, size_parameter, THROW_ASSERT, to_port_direction(), to_port_interface(), and structural_object::xload().
|
overridevirtual |
Add a structural_object to an xml tree.
rootnode | is the root node at which the xml representation of the structural object is attached. |
Reimplemented from structural_object.
Definition at line 1746 of file structural_objects.cpp.
References xml_child::add_child_element(), xml_child::add_child_text(), aligment, connected_objects, dir, structural_object::get_id(), get_kind_text(), structural_object::get_path(), structural_object::get_typeRef(), GetString(), structural_type_descriptor::id_type, is_addr_bus, is_addr_bus_DEFAULT, is_clock, is_clock_DEFAULT, is_critical, is_critical_DEFAULT, is_data_bus, is_data_bus_DEFAULT, is_doubled, is_doubled_DEFAULT, is_extern, is_extern_DEFAULT, is_global, is_global_DEFAULT, is_halved, is_halved_DEFAULT, is_master, is_master_DEFAULT, is_memory, is_memory_DEFAULT, is_reverse, is_reverse_DEFAULT, is_size_bus, is_size_bus_DEFAULT, is_slave, is_slave_DEFAULT, is_tag_bus, is_tag_bus_DEFAULT, is_var_args, is_var_args_DEFAULT, test_panda::lock, pi, port_interface_alignment_DEFAULT, ports, WRITE_XNVM, WRITE_XNVM2, WRITE_XVM, and structural_object::xwrite().
|
private |
Definition at line 1075 of file structural_objects.hpp.
Referenced by copy(), get_port_alignment(), print(), set_port_alignment(), xload(), and xwrite().
|
private |
bus bundle
Definition at line 1123 of file structural_objects.hpp.
Referenced by copy(), get_bus_bundle(), and set_bus_bundle().
|
private |
The list of connections associated with the port.
Definition at line 1064 of file structural_objects.hpp.
Referenced by add_connection(), find_bounded_object(), find_member(), get_connected_signal(), get_connection(), get_connections_size(), is_connected(), print(), remove_connection(), substitute_connection(), and xwrite().
|
private |
direction of a port
Definition at line 1067 of file structural_objects.hpp.
Referenced by copy(), get_port_direction(), print(), set_port_direction(), xload(), and xwrite().
|
private |
endianess of a port
Definition at line 1070 of file structural_objects.hpp.
Referenced by copy(), get_port_endianess(), and set_port_endianess().
|
private |
when true the port is an address bus
Definition at line 1105 of file structural_objects.hpp.
Referenced by copy(), get_is_addr_bus(), set_is_addr_bus(), xload(), and xwrite().
Definition at line 1145 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port is a clock port and has to be attached to a clock object
Definition at line 1081 of file structural_objects.hpp.
Referenced by copy(), get_is_clock(), set_is_clock(), xload(), and xwrite().
Definition at line 1138 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port is involved into the critical path of the netlist
Definition at line 1120 of file structural_objects.hpp.
Referenced by copy(), get_critical(), set_critical(), xload(), and xwrite().
Definition at line 1150 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port is a data bus
Definition at line 1102 of file structural_objects.hpp.
Referenced by copy(), get_is_data_bus(), set_is_data_bus(), xload(), and xwrite().
Definition at line 1144 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port has a doubled size
Definition at line 1114 of file structural_objects.hpp.
Referenced by copy(), get_is_doubled(), set_is_doubled(), xload(), and xwrite().
Definition at line 1148 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port is an extern port
Definition at line 1084 of file structural_objects.hpp.
Referenced by copy(), get_is_extern(), set_is_extern(), xload(), and xwrite().
Definition at line 1139 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port is a global port
Definition at line 1087 of file structural_objects.hpp.
Referenced by copy(), get_is_global(), set_is_global(), xload(), and xwrite().
Definition at line 1140 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port has a halfed size
Definition at line 1117 of file structural_objects.hpp.
Referenced by copy(), get_is_halved(), set_is_halved(), xload(), and xwrite().
Definition at line 1149 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port is a master port
Definition at line 1099 of file structural_objects.hpp.
Referenced by copy(), get_is_master(), set_is_master(), xload(), and xwrite().
Definition at line 1143 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port is a memory port
Definition at line 1093 of file structural_objects.hpp.
Referenced by copy(), get_is_memory(), set_is_memory(), xload(), and xwrite().
Definition at line 1141 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port is dumped as [0:msb-1] instead of [msb-1:0]
Definition at line 1090 of file structural_objects.hpp.
Referenced by copy(), get_reverse(), set_reverse(), xload(), and xwrite().
Definition at line 1151 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port is a size bus
Definition at line 1108 of file structural_objects.hpp.
Referenced by copy(), get_is_size_bus(), set_is_size_bus(), xload(), and xwrite().
Definition at line 1147 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port is a slave port
Definition at line 1096 of file structural_objects.hpp.
Referenced by copy(), get_is_slave(), set_is_slave(), xload(), and xwrite().
Definition at line 1142 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port is a tag bus
Definition at line 1111 of file structural_objects.hpp.
Referenced by copy(), get_is_tag_bus(), set_is_tag_bus(), xload(), and xwrite().
Definition at line 1146 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
when true the port must be specialized at runtime depending on the number of input
Definition at line 1078 of file structural_objects.hpp.
Referenced by copy(), get_is_var_args(), set_is_var_args(), xload(), and xwrite().
Definition at line 1152 of file structural_objects.hpp.
Referenced by xwrite().
|
private |
least significant bit
Definition at line 1126 of file structural_objects.hpp.
|
static |
Definition at line 649 of file structural_objects.hpp.
Referenced by structural_manager::add_port_vector(), allocation::add_proxy_function_module(), allocation::add_proxy_function_wrapper(), and LoadBuiltinTechnology::Exec().
|
private |
port interface type of a port
Definition at line 1073 of file structural_objects.hpp.
Referenced by copy(), get_port_interface(), print(), set_port_interface(), xload(), and xwrite().
|
staticprivate |
Definition at line 1153 of file structural_objects.hpp.
|
private |
port type
Definition at line 1132 of file structural_objects.hpp.
Referenced by find_member(), and xload().
|
private |
The list of ports associated with the port.
Definition at line 1129 of file structural_objects.hpp.
Referenced by copy(), find_isomorphic(), find_member(), print(), set_port_direction(), xload(), and xwrite().
std::string port_o::size_parameter |
custom size parameter
Definition at line 674 of file structural_objects.hpp.