PandA-2024.02
|
This class specifies the characteristic of a particular functional unit. More...
#include <technology_node.hpp>
Public Types | |
using | type_t = enum { UNKNOWN=0, COMBINATIONAL, STATETABLE, FF, LATCH, PHYSICAL } |
using | operation_vec = std::vector< technology_nodeRef > |
Type definition of a vector of functional_unit. More... | |
Public Member Functions | |
functional_unit () | |
Constructor. More... | |
functional_unit (const xml_nodeRef XML_description) | |
Constructor. More... | |
~functional_unit () override | |
Destructor. More... | |
void | add (const technology_nodeRef &curr) |
Add the given operation to the current functional_unit. More... | |
void | set_clock_period (double _clock_period) |
Sets the clock period adopted for the synthesis (0 means that it has been generated with unconstrained synthesis) (in ns) More... | |
double | get_clock_period () const |
Returns the clock period adopted for the synthesis (0 means that it has been generated with unconstrained synthesis) (in ns) More... | |
void | set_clock_period_resource_fraction (double _clock_period_resource_fraction) |
Sets the clock period resource fraction adopted for the synthesis. More... | |
double | get_clock_period_resource_fraction () const |
Returns the clock period resource fraction adopted for the synthesis. More... | |
const operation_vec & | get_operations () const |
Return the operations that the functional unit can handle. More... | |
size_t | get_operations_num () const |
Return the number of the operations that the functional unit can handle. More... | |
technology_nodeRef | get_operation (const std::string &op_name) const |
This method returns the operationRef from its name if the functional unit contains an operation of type op_name. More... | |
const std::string & | get_name () const override |
Return the name of the operation. More... | |
void | xload (const xml_element *node, const technology_nodeRef fu, const ParameterConstRef Param) override |
Load a functional unit starting from an xml file. More... | |
void | xwrite (xml_element *rootnode, const technology_nodeRef tn, const ParameterConstRef Param) override |
Add a functional unit to an xml tree. More... | |
void | print (std::ostream &os) const override |
function that prints the class functional_unit. More... | |
Public Member Functions inherited from technology_node | |
technology_node () | |
Constructor. More... | |
virtual | ~technology_node () |
Destructor. More... | |
virtual std::string | get_kind_text () const =0 |
Virtual function used to get the string name of a technology_node instance. More... | |
virtual enum tec_kind | get_kind () const =0 |
Virtual function used to find the real type of a technology_nodeinstance. More... | |
Data Fields | |
type_t | logical_type |
return the logical type of the cell More... | |
std::string | functional_unit_name |
name of the functional unit. More... | |
std::vector< std::string > | ordered_attributes |
list of attributes associated to the components More... | |
std::map< std::string, attributeRef > | attributes |
map between the attribute keys and the corresponding values More... | |
double | clock_period |
clock period adopted for the synthesis (in ns) More... | |
double | clock_period_resource_fraction |
clock period resource fraction More... | |
area_infoRef | area_m |
This variable stores the resource information of the component. More... | |
xml_nodeRef | XML_description |
pointer to the XML description of the cell More... | |
std::string | fu_template_name |
Name of the template. More... | |
std::string | fu_template_parameters |
Template parameters. More... | |
std::string | characterizing_constant_value |
Value used during the characterization of this instance. More... | |
std::string | memory_type |
Specify the type of memory the functional unit is compliant with. More... | |
std::string | channels_type |
Specify the type of the channel the functional unit is compliant with. More... | |
std::string | memory_ctrl_type |
Specify the type of memory controller the functional unit is compliant with. More... | |
std::string | bram_load_latency |
Specify the bram load latency the functional unit is compliant with. More... | |
std::string | component_timing_alias |
Specify that the functional unit has the same timing per operation it has the one specified by this field. More... | |
TimeStamp | characterization_timestamp |
The timestamp of the characterization of this functional unit. More... | |
Private Attributes | |
std::map< std::string, technology_nodeRef > | op_name_to_op |
Redefinition of get_kind_text() More... | |
operation_vec | list_of_operation |
At each functional unit can be associate several operations with different performances. More... | |
Friends | |
class | technology_manager |
Additional Inherited Members | |
Static Protected Attributes inherited from technology_node | |
static simple_indent | PP |
pretty print functor object used by all print members to indent the output of the print function. More... | |
This class specifies the characteristic of a particular functional unit.
Definition at line 487 of file technology_node.hpp.
using functional_unit::operation_vec = std::vector<technology_nodeRef> |
Type definition of a vector of functional_unit.
Definition at line 492 of file technology_node.hpp.
using functional_unit::type_t = enum { UNKNOWN = 0, COMBINATIONAL, STATETABLE, FF, LATCH, PHYSICAL } |
Definition at line 489 of file technology_node.hpp.
functional_unit::functional_unit | ( | ) |
Constructor.
Definition at line 344 of file technology_node.cpp.
|
explicit |
Constructor.
Definition at line 349 of file technology_node.cpp.
References ~functional_unit().
|
overridedefault |
|
inline |
Add the given operation to the current functional_unit.
curr | is the added element |
Definition at line 573 of file technology_node.hpp.
References technology_node::get_name().
Referenced by xload(), and xwrite().
|
inline |
Returns the clock period adopted for the synthesis (0 means that it has been generated with unconstrained synthesis) (in ns)
Definition at line 597 of file technology_node.hpp.
|
inline |
Returns the clock period resource fraction adopted for the synthesis.
Definition at line 610 of file technology_node.hpp.
|
inlineoverridevirtual |
Return the name of the operation.
Implements technology_node.
Definition at line 642 of file technology_node.hpp.
References GET_TEC_KIND, GET_TEC_KIND_TEXT, technology_node::print(), technology_node::xload(), and technology_node::xwrite().
Referenced by GenerateFuList::AnalyzeCell(), RTLCharacterization::AnalyzeCell(), and FunctionalUnitStep::AnalyzeFu().
technology_nodeRef functional_unit::get_operation | ( | const std::string & | op_name | ) | const |
This method returns the operationRef from its name if the functional unit contains an operation of type op_name.
Definition at line 413 of file technology_node.cpp.
References op_name_to_op.
Referenced by allocation::get_compliant_pipelined_unit(), AllocationInformation::get_correction_time(), AllocationInformation::InitializeMuxDB(), AllocationInformation::is_operation_bounded(), and AllocationInformation::is_operation_PI_registered().
|
inline |
Return the operations that the functional unit can handle.
Definition at line 619 of file technology_node.hpp.
Referenced by RTLCharacterization::AnalyzeCell(), allocation::BuildProxyFunctionVerilog(), allocation::BuildProxyFunctionVHDL(), allocation::BuildProxyWrapper(), and AllocationInformation::get_correction_time().
|
inline |
Return the number of the operations that the functional unit can handle.
Definition at line 628 of file technology_node.hpp.
Referenced by xload().
|
overridevirtual |
function that prints the class functional_unit.
os | is the output stream. |
Implements technology_node.
Definition at line 386 of file technology_node.cpp.
References area_m, functional_unit_name, area_info::get_area_value(), list_of_operation, memory_type, and technology_node::PP.
void functional_unit::set_clock_period | ( | double | _clock_period | ) |
Sets the clock period adopted for the synthesis (0 means that it has been generated with unconstrained synthesis) (in ns)
Definition at line 360 of file technology_node.cpp.
References attributes, clock_period, ordered_attributes, STR, and THROW_ASSERT.
void functional_unit::set_clock_period_resource_fraction | ( | double | _clock_period_resource_fraction | ) |
Sets the clock period resource fraction adopted for the synthesis.
Definition at line 373 of file technology_node.cpp.
References attributes, clock_period_resource_fraction, ordered_attributes, and STR.
|
overridevirtual |
Load a functional unit starting from an xml file.
node | is a node of the xml tree. |
owner | is the refcount version of this. |
to be analyzed after all the other information
Implements technology_node.
Definition at line 423 of file technology_node.cpp.
References add(), area_m, attributes, bram_load_latency, channels_type, characterization_timestamp, characterizing_constant_value, clock_period, clock_period_resource_fraction, component_timing_alias, DesignFlowStep::debug_level, DEBUG_LEVEL_VERY_PEDANTIC, area_info::factory(), fu_template_name, fu_template_parameters, functional_unit_name, xml_child::get_children(), GET_CLASS, GET_CLASS_NAME, xml_text_node::get_content(), get_operations_num(), logical_type, memory_ctrl_type, memory_type, ordered_attributes, PRINT_DBG_MEX, area_info::set_area_value(), area_info::set_resource_value(), THROW_ERROR, UNKNOWN, attribute::xload(), and technology_node::xload().
|
overridevirtual |
Add a functional unit to an xml tree.
rootnode | is the root node at which the xml representation of the functional unit is attached. |
functional unit name
add the operation related to the unit name if there is not anything else
area attributes
dumping of attributes
template stuff
operation stuff
circuit stuff
Implements technology_node.
Definition at line 682 of file technology_node.cpp.
References add(), xml_child::add_child_element(), xml_child::add_child_text(), area_m, attributes, bram_load_latency, channels_type, characterization_timestamp, characterizing_constant_value, component_timing_alias, fu_template_name, fu_template_parameters, functional_unit_name, area_info::get_area_value(), GET_CLASS_NAME, area_info::get_resource_value(), list_of_operation, memory_ctrl_type, memory_type, ordered_attributes, STR, and WRITE_XNVM2.
|
friend |
Definition at line 683 of file technology_node.hpp.
area_infoRef functional_unit::area_m |
This variable stores the resource information of the component.
Definition at line 513 of file technology_node.hpp.
Referenced by RTLCharacterization::AnalyzeCell(), AllocationInformation::InitializeMuxDB(), print(), xload(), and xwrite().
std::map<std::string, attributeRef> functional_unit::attributes |
map between the attribute keys and the corresponding values
Definition at line 504 of file technology_node.hpp.
Referenced by set_clock_period(), set_clock_period_resource_fraction(), xload(), and xwrite().
std::string functional_unit::bram_load_latency |
Specify the bram load latency the functional unit is compliant with.
non-null only in case the functional unit is a memory or a memory controller.
Definition at line 545 of file technology_node.hpp.
std::string functional_unit::channels_type |
Specify the type of the channel the functional unit is compliant with.
Definition at line 537 of file technology_node.hpp.
Referenced by RTLCharacterization::AnalyzeCell(), xload(), and xwrite().
TimeStamp functional_unit::characterization_timestamp |
The timestamp of the characterization of this functional unit.
Definition at line 552 of file technology_node.hpp.
Referenced by technology_manager::CGetSetupHoldTimeStamp(), xload(), and xwrite().
std::string functional_unit::characterizing_constant_value |
Value used during the characterization of this instance.
Definition at line 530 of file technology_node.hpp.
Referenced by RTLCharacterization::AnalyzeCell(), xload(), and xwrite().
double functional_unit::clock_period |
clock period adopted for the synthesis (in ns)
Definition at line 507 of file technology_node.hpp.
Referenced by set_clock_period(), and xload().
double functional_unit::clock_period_resource_fraction |
clock period resource fraction
Definition at line 510 of file technology_node.hpp.
Referenced by set_clock_period_resource_fraction(), and xload().
std::string functional_unit::component_timing_alias |
Specify that the functional unit has the same timing per operation it has the one specified by this field.
Definition at line 549 of file technology_node.hpp.
std::string functional_unit::fu_template_name |
Name of the template.
Definition at line 524 of file technology_node.hpp.
Referenced by RTLCharacterization::AnalyzeCell(), xload(), and xwrite().
std::string functional_unit::fu_template_parameters |
Template parameters.
Definition at line 527 of file technology_node.hpp.
Referenced by RTLCharacterization::AnalyzeCell(), FunctionalUnitStep::AnalyzeFu(), xload(), and xwrite().
std::string functional_unit::functional_unit_name |
name of the functional unit.
Definition at line 498 of file technology_node.hpp.
Referenced by RTLCharacterization::AnalyzeCell(), FunctionalUnitStep::create_template_instance(), print(), xload(), and xwrite().
|
private |
At each functional unit can be associate several operations with different performances.
Definition at line 681 of file technology_node.hpp.
type_t functional_unit::logical_type |
return the logical type of the cell
Definition at line 495 of file technology_node.hpp.
Referenced by xload().
std::string functional_unit::memory_ctrl_type |
Specify the type of memory controller the functional unit is compliant with.
non-null only in case the functional unit is a memory controller.
Definition at line 541 of file technology_node.hpp.
std::string functional_unit::memory_type |
Specify the type of memory the functional unit is compliant with.
non-null only in case the functional unit is a memory.
Definition at line 534 of file technology_node.hpp.
Referenced by RTLCharacterization::AnalyzeCell(), print(), xload(), and xwrite().
|
private |
Redefinition of get_kind_text()
Redefinition of get_kind()This varibale maps the name of the op with its reference.
Definition at line 678 of file technology_node.hpp.
Referenced by get_operation().
std::vector<std::string> functional_unit::ordered_attributes |
list of attributes associated to the components
Definition at line 501 of file technology_node.hpp.
Referenced by set_clock_period(), set_clock_period_resource_fraction(), xload(), and xwrite().
xml_nodeRef functional_unit::XML_description |
pointer to the XML description of the cell
Definition at line 521 of file technology_node.hpp.