PandA-2024.02
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions
HLSFunctionStep Class Referenceabstract

Superclass include. More...

#include <hls_function_step.hpp>

Inheritance diagram for HLSFunctionStep:
Inheritance graph
[legend]
Collaboration diagram for HLSFunctionStep:
Collaboration graph
[legend]

Public Member Functions

 HLSFunctionStep (const ParameterConstRef Param, const HLS_managerRef HLSMgr, unsigned int funId, const DesignFlowManagerConstRef design_flow_manager, const HLSFlowStep_Type hls_flow_step_type, const HLSFlowStepSpecializationConstRef hls_flow_step_specialization=HLSFlowStepSpecializationConstRef())
 Constructor. More...
 
 ~HLSFunctionStep () override
 Destructor. More...
 
bool HasToBeExecuted () const override
 Check if this step has actually to be executed. More...
 
void Initialize () override
 Initialize the step (i.e., like a constructor, but executed just before exec. More...
 
std::string GetSignature () const final
 Return a unified identifier of this design step. More...
 
std::string GetName () const final
 Return the name of this design step. More...
 
DesignFlowStep_Status Exec () final
 Execute the step. More...
 
- Public Member Functions inherited from HLS_step
 HLS_step (const ParameterConstRef _parameters, const HLS_managerRef HLSMgr, const DesignFlowManagerConstRef design_flow_manager, const HLSFlowStep_Type hls_flow_step_type, const HLSFlowStepSpecializationConstRef hls_flow_step_specialization=HLSFlowStepSpecializationConstRef())
 Constructor. More...
 
 ~HLS_step () override
 Destructor. More...
 
std::string GetSignature () const override
 Return a unified identifier of this design step. More...
 
std::string GetName () const override
 Return the name of this design step. More...
 
virtual std::string GetKindText () const
 Return the name of the type of this frontend flow step. More...
 
DesignFlowStepFactoryConstRef CGetDesignFlowStepFactory () const final
 Return the factory to create this type of steps. More...
 
void ComputeRelationships (DesignFlowStepSet &design_flow_step_set, const DesignFlowStep::RelationshipType relationship_type) override
 Compute the relationships of a step with other steps. More...
 
- Public Member Functions inherited from DesignFlowStep
 DesignFlowStep (const DesignFlowManagerConstRef design_flow_manager, const ParameterConstRef parameters)
 Constructor. More...
 
virtual ~DesignFlowStep ()
 Destructor. More...
 
DesignFlowStep_Status GetStatus () const
 Return the status of this design step. More...
 
virtual void WriteDot (std::ostream &out) const
 Write the label for a dot graph. More...
 
bool IsComposed () const
 Returns if this step is composed. More...
 
int CGetDebugLevel () const
 Return the debug level of the step. More...
 
virtual void PrintInitialIR () const
 Dump the initial intermediate representation. More...
 
virtual void PrintFinalIR () const
 Dump the final intermediate representation. More...
 

Static Public Member Functions

static std::string ComputeSignature (const HLSFlowStep_Type hls_flow_step_type, const HLSFlowStepSpecializationConstRef hls_flow_step_specialization, const unsigned int function_id)
 Compute the signature of a hls flow step. More...
 
- Static Public Member Functions inherited from HLS_step
static std::string EnumToName (const HLSFlowStep_Type hls_flow_step_type)
 Given a HLS flow step type, return the name of the type. More...
 
static const std::string ComputeSignature (const HLSFlowStep_Type hls_flow_step_type, const HLSFlowStepSpecializationConstRef hls_flow_step_specialization)
 Compute the signature of a hls flow step. More...
 

Protected Member Functions

void ComputeRelationships (DesignFlowStepSet &design_flow_step_set, const DesignFlowStep::RelationshipType relationship_type) override
 Compute the relationships of a step with other steps. More...
 
virtual DesignFlowStep_Status InternalExec ()=0
 Execute the step. More...
 
- Protected Member Functions inherited from HLS_step
virtual const CustomUnorderedSet< std::tuple< HLSFlowStep_Type, HLSFlowStepSpecializationConstRef, HLSFlowStep_Relationship > > ComputeHLSRelationships (const DesignFlowStep::RelationshipType relationship_type) const
 Return the set of analyses in relationship with this design step. More...
 

Protected Attributes

std::map< unsigned int, unsigned int > last_bb_ver
 last bb version of the called functions More...
 
std::map< unsigned int, unsigned int > last_bitvalue_ver
 The version of bit value IR representation on which this step was applied. More...
 
const unsigned int funId
 identifier of the function to be processed (0 means that it is a global step) More...
 
hlsRef HLS
 HLS data structure of the function to be analyzed. More...
 
unsigned int bb_version
 The version of bb intermediate representation on which this step was applied. More...
 
unsigned int bitvalue_version
 The version of bitvalue on which this step was applied. More...
 
unsigned int memory_version
 The version of memory representation on which this step was applied. More...
 
- Protected Attributes inherited from HLS_step
const HLS_managerRef HLSMgr
 information about all the HLS synthesis More...
 
const HLSFlowStep_Type hls_flow_step_type
 The type of this step. More...
 
const HLSFlowStepSpecializationConstRef hls_flow_step_specialization
 The information about specialization. More...
 
- Protected Attributes inherited from DesignFlowStep
bool composed
 True if this step represents a composition of design flow steps (e.g., a flow); must be set by specialized constructors. More...
 
const Wrefcount< const DesignFlowManagerdesign_flow_manager
 The design flow manager. More...
 
const ParameterConstRef parameters
 Set of input parameters. More...
 
int debug_level
 The debug level. More...
 
const int output_level
 The output level. More...
 

Private Member Functions

bool HasToBeExecuted0 () const
 

Additional Inherited Members

- Public Types inherited from DesignFlowStep
enum  RelationshipType { DEPENDENCE_RELATIONSHIP, INVALIDATION_RELATIONSHIP, PRECEDENCE_RELATIONSHIP }
 The relationship type. More...
 
- Static Protected Attributes inherited from HLS_step
static CustomUnorderedMap< std::string, HLSFlowStep_Typecommand_line_name_to_enum
 Map hls step name to enum. More...
 

Detailed Description

Superclass include.

Definition at line 47 of file hls_function_step.hpp.

Constructor & Destructor Documentation

◆ HLSFunctionStep()

HLSFunctionStep::HLSFunctionStep ( const ParameterConstRef  Param,
const HLS_managerRef  HLSMgr,
unsigned int  funId,
const DesignFlowManagerConstRef  design_flow_manager,
const HLSFlowStep_Type  hls_flow_step_type,
const HLSFlowStepSpecializationConstRef  hls_flow_step_specialization = HLSFlowStepSpecializationConstRef() 
)

Constructor.

Parameters
Paramclass containing all the parameters
HLSclass containing all the HLS data structures
design_flow_manageris the design flow manager
hls_flow_step_typeis the type of this hls flow step

Definition at line 57 of file hls_function_step.cpp.

References ~HLSFunctionStep().

Here is the call graph for this function:

◆ ~HLSFunctionStep()

HLSFunctionStep::~HLSFunctionStep ( )
overridedefault

Destructor.

Referenced by HLSFunctionStep().

Here is the caller graph for this function:

Member Function Documentation

◆ ComputeRelationships()

void HLSFunctionStep::ComputeRelationships ( DesignFlowStepSet relationship,
const DesignFlowStep::RelationshipType  relationship_type 
)
overrideprotectedvirtual

◆ ComputeSignature()

std::string HLSFunctionStep::ComputeSignature ( const HLSFlowStep_Type  hls_flow_step_type,
const HLSFlowStepSpecializationConstRef  hls_flow_step_specialization,
const unsigned int  function_id 
)
static

Compute the signature of a hls flow step.

Parameters
hls_flow_step_typeis the type of the step
hls_flow_step_specializationis how the step has to be specialized
function_idis the index of the function
Returns
the corresponding signature

Definition at line 123 of file hls_function_step.cpp.

References HLS_step::ComputeSignature(), and STR.

Referenced by ComputeRelationships(), TasteInterfaceGeneration::ComputeRelationships(), CBackend::ComputeRelationships(), HLS_step::ComputeRelationships(), HLSFlowStepFactory::CreateHLSFlowStep(), dead_code_elimination::fix_sdc_motion(), GetSignature(), and SDCCodeMotion::InternalExec().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Exec()

DesignFlowStep_Status HLSFunctionStep::Exec ( )
finalvirtual

Execute the step.

Returns
the exit status of this step

Implements DesignFlowStep.

Definition at line 207 of file hls_function_step.cpp.

References bb_version, bitvalue_version, funId, FunctionBehavior::GetBBVersion(), FunctionBehavior::GetBitValueVersion(), HLS_step::HLSMgr, InternalExec(), last_bb_ver, last_bitvalue_ver, memory_version, and THROW_ASSERT.

Here is the call graph for this function:

◆ GetName()

std::string HLSFunctionStep::GetName ( ) const
finalvirtual

Return the name of this design step.

Returns
the name of the pass (for debug purpose)

Implements DesignFlowStep.

Definition at line 130 of file hls_function_step.cpp.

References bb_version, bitvalue_version, funId, HLS_step::GetKindText(), HLS_step::HLSMgr, memory_version, and STR.

Referenced by ComputeRelationships(), and allocation::PrintInitialIR().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetSignature()

std::string HLSFunctionStep::GetSignature ( ) const
finalvirtual

Return a unified identifier of this design step.

Returns
the signature of the design step

Implements DesignFlowStep.

Definition at line 118 of file hls_function_step.cpp.

References ComputeSignature(), funId, HLS_step::hls_flow_step_specialization, and HLS_step::hls_flow_step_type.

Here is the call graph for this function:

◆ HasToBeExecuted()

bool HLSFunctionStep::HasToBeExecuted ( ) const
overridevirtual

Check if this step has actually to be executed.

Returns
true if the step has to be executed

Implements DesignFlowStep.

Reimplemented in SDCScheduling, and TasteInterfaceGeneration.

Definition at line 71 of file hls_function_step.cpp.

References bb_version, bitvalue_version, funId, FunctionBehavior::GetBBVersion(), FunctionBehavior::GetBitValueVersion(), HLS_step::HLSMgr, last_bb_ver, last_bitvalue_ver, memory_version, and THROW_ASSERT.

Referenced by TasteInterfaceGeneration::HasToBeExecuted(), and SDCScheduling::HasToBeExecuted().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ HasToBeExecuted0()

bool HLSFunctionStep::HasToBeExecuted0 ( ) const
private

◆ Initialize()

void HLSFunctionStep::Initialize ( )
overridevirtual

◆ InternalExec()

virtual DesignFlowStep_Status HLSFunctionStep::InternalExec ( )
protectedpure virtual

Field Documentation

◆ bb_version

unsigned int HLSFunctionStep::bb_version
protected

The version of bb intermediate representation on which this step was applied.

Definition at line 63 of file hls_function_step.hpp.

Referenced by Exec(), GetName(), HasToBeExecuted(), SDCScheduling::HasToBeExecuted(), and allocation::InternalExec().

◆ bitvalue_version

unsigned int HLSFunctionStep::bitvalue_version
protected

The version of bitvalue on which this step was applied.

Definition at line 66 of file hls_function_step.hpp.

Referenced by Exec(), GetName(), and HasToBeExecuted().

◆ funId

const unsigned int HLSFunctionStep::funId
protected

identifier of the function to be processed (0 means that it is a global step)

Definition at line 57 of file hls_function_step.hpp.

Referenced by ControllerCreatorBaseStep::add_command_ports(), controller_cs::add_common_ports(), controller_cs::add_correct_transition_memory(), conn_binding_creator::add_parameter_ports(), datapath_cs::add_ports(), top_entity::add_ports(), classic_datapath::add_ports(), SDCScheduling::AddDelayConstraints(), TopEntityMemoryMapped::allocate_parameters(), WB4_interface::build_WB4_complete_logic(), minimal_interface::build_wrapper(), top_entity_parallel_cs::BW_loop_iter(), BB_based_stg::check_data_dependency(), allocation::check_for_memory_compliancy(), allocation::check_proxies(), BB_based_stg::compute_EPP_edge_increments(), parametric_list_based::compute_function_topological_order(), HLSSynthesisFlow::ComputeHLSRelationships(), standard_hls::ComputeHLSRelationships(), virtual_hls::ComputeHLSRelationships(), easy_module_binding::ComputeHLSRelationships(), fu_binding_creator::ComputeHLSRelationships(), storage_value_insertion::ComputeHLSRelationships(), reg_binding_creator::ComputeHLSRelationships(), top_entity::ComputeHLSRelationships(), port_swapping::ComputeHLSRelationships(), add_library::ComputeHLSRelationships(), conn_binding_creator::ComputeHLSRelationships(), module_interface::ComputeHLSRelationships(), parametric_list_based::ComputeHLSRelationships(), HLSFunctionBitValue::ComputeRelationships(), ComputeRelationships(), TasteInterfaceGeneration::ComputeRelationships(), SDCScheduling::ComputeRelationships(), allocation::ComputeRelationships(), top_entity_parallel_cs::connect_loop_iter(), datapath_parallel_cs::connect_module_kernel(), mux_connection_binding::connect_to_registers(), mux_connection_binding::create_connections(), mux_connection_binding::create_single_conn(), fsm_controller::create_state_machine(), cs_interface::cs_interface(), mux_connection_binding::determine_connection(), Exec(), parametric_list_based::exec(), allocation::extract_bambu_provided(), GetName(), GetSignature(), TasteInterfaceGeneration::HasToBeExecuted(), HasToBeExecuted(), sched_based_chaining_computation::Initialize(), easy_module_binding::Initialize(), fu_binding_creator::Initialize(), values_scheme::Initialize(), Initialize(), TopEntityMemoryMapped::Initialize(), SDCScheduling::Initialize(), Scheduling::Initialize(), allocation::Initialize(), parametric_list_based::Initialize(), mux_connection_binding::input_logic(), TopEntityMemoryMapped::insertMemoryMappedRegister(), OmpAllocation::IntegrateTechnologyLibraries(), allocation::IntegrateTechnologyLibraries(), InitializeHLS::InternalExec(), pipeline_controller::InternalExec(), BB_based_stg::InternalExec(), FSM_NI_SSA_liveness::InternalExec(), unique_binding::InternalExec(), fsm_controller::InternalExec(), sched_based_chaining_computation::InternalExec(), standard_hls::InternalExec(), top_entity_cs::InternalExec(), minimal_interface::InternalExec(), easy_module_binding::InternalExec(), TasteInterfaceGeneration::InternalExec(), top_entity_parallel_cs::InternalExec(), values_scheme::InternalExec(), classic_datapath::InternalExec(), TopEntityMemoryMapped::InternalExec(), HLSFunctionBitValue::InternalExec(), ControlFlowChecker::InternalExec(), top_entity::InternalExec(), add_library::InternalExec(), datapath_parallel_cs::InternalExec(), port_swapping::InternalExec(), mux_connection_binding::InternalExec(), SDCScheduling::InternalExec(), allocation::InternalExec(), parametric_list_based::InternalExec(), cdfc_module_binding::InternalExec(), BB_based_stg::is_instantaneous_operation(), allocation::is_ram_not_timing_compliant(), minimal_interface::minimal_interface(), BB_based_stg::optimize_cycles(), vertex_coloring_register::RegisterBinding(), unique_binding_register::RegisterBinding(), chordal_coloring_register::RegisterBinding(), and weighted_clique_register::RegisterBinding().

◆ HLS

hlsRef HLSFunctionStep::HLS
protected

HLS data structure of the function to be analyzed.

Definition at line 60 of file hls_function_step.hpp.

Referenced by classic_datapath::add_clock_reset(), ControlFlowChecker::add_clock_reset(), ControllerCreatorBaseStep::add_command_ports(), top_entity::add_command_signals(), top_entity_cs::add_context_switch_port(), top_entity_cs::add_context_switch_port_kernel(), mux_connection_binding::add_conversion(), ControlFlowChecker::add_done_port(), top_entity_cs::add_input_register(), top_entity::add_input_register(), ControlFlowChecker::add_notifiers(), conn_binding_creator::add_parameter_ports(), datapath_cs::add_ports(), top_entity::add_ports(), classic_datapath::add_ports(), datapath_parallel_cs::add_ports(), ControlFlowChecker::add_present_state(), ControlFlowChecker::add_start_port(), parametric_list_based::add_to_priority_queues(), SDCScheduling::AddDelayConstraints(), mux_connection_binding::address_precision(), TopEntityMemoryMapped::allocate_parameters(), parametric_list_based::BB_update_resources_use(), WB4_interface::build_WB4_bus_interface(), WB4_interface::build_WB4_complete_logic(), minimal_interface::build_wrapper(), allocation::BuildProxyWrapper(), cdfc_module_binding::can_be_clustered(), parametric_list_based::check_direct_operation_chaining(), parametric_list_based::check_non_direct_operation_chaining(), parametric_list_based::CheckSchedulabilityConditions(), BB_based_stg::compute_EPP_edge_increments(), parametric_list_based::compute_exec_stage_time(), parametric_list_based::compute_starting_ending_time_asap(), datapath_parallel_cs::connect_i_module_kernel(), datapath_parallel_cs::connect_module_kernel(), top_entity_parallel_cs::connect_port_parallel(), mux_connection_binding::connect_to_registers(), compatibility_based_register::create_compatibility_graph(), conflict_based_register::create_conflict_graph(), mux_connection_binding::create_connections(), mux_connection_binding::create_single_conn(), fsm_controller::create_state_machine(), mux_connection_binding::determine_connection(), parametric_list_based::exec(), WB4_interface::get_data_bus_bitsize(), sched_based_chaining_computation::Initialize(), chaining::Initialize(), BB_based_stg::Initialize(), FSM_NI_SSA_liveness::Initialize(), storage_value_insertion::Initialize(), easy_module_binding::Initialize(), fu_binding_creator::Initialize(), weighted_clique_register::Initialize(), values_scheme::Initialize(), ControllerCreatorBaseStep::Initialize(), Initialize(), SDCScheduling::Initialize(), Scheduling::Initialize(), mux_connection_binding::Initialize(), allocation::Initialize(), mux_connection_binding::input_logic(), TopEntityMemoryMapped::insertMemoryMappedRegister(), TopEntityMemoryMapped::insertStartDoneLogic(), TopEntityMemoryMapped::insertStatusRegister(), datapath_parallel_cs::instantiate_component_parallel(), cs_interface::instantiate_component_parallel(), allocation::IntegrateTechnologyLibraries(), InitializeHLS::InternalExec(), pipeline_controller::InternalExec(), cs_interface::InternalExec(), BB_based_stg::InternalExec(), FSM_NI_SSA_liveness::InternalExec(), unique_binding::InternalExec(), fsm_controller::InternalExec(), sched_based_chaining_computation::InternalExec(), minimal_interface::InternalExec(), top_entity_cs::InternalExec(), easy_module_binding::InternalExec(), TasteInterfaceGeneration::InternalExec(), values_scheme::InternalExec(), top_entity_parallel_cs::InternalExec(), classic_datapath::InternalExec(), TopEntityMemoryMapped::InternalExec(), ControlFlowChecker::InternalExec(), top_entity::InternalExec(), add_library::InternalExec(), WB4_interface::InternalExec(), datapath_parallel_cs::InternalExec(), port_swapping::InternalExec(), mux_connection_binding::InternalExec(), SDCScheduling::InternalExec(), allocation::InternalExec(), parametric_list_based::InternalExec(), cdfc_module_binding::InternalExec(), BB_based_stg::move_with_duplication(), BB_based_stg::move_without_duplication(), mux_connection_binding::mux_interconnection(), BB_based_stg::optimize_cycles(), vertex_coloring_register::RegisterBinding(), unique_binding_register::RegisterBinding(), chordal_coloring_register::RegisterBinding(), weighted_clique_register::RegisterBinding(), BB_based_stg::res_const_operation(), TopEntityMemoryMapped::resizing_IO(), cdfc_module_binding::update_slack_starting_time(), WB4Intercon_interface::WB4Intercon_interface(), and cdfc_module_binding::weight_computation().

◆ last_bb_ver

std::map<unsigned int, unsigned int> HLSFunctionStep::last_bb_ver
protected

last bb version of the called functions

Definition at line 51 of file hls_function_step.hpp.

Referenced by Exec(), and HasToBeExecuted().

◆ last_bitvalue_ver

std::map<unsigned int, unsigned int> HLSFunctionStep::last_bitvalue_ver
protected

The version of bit value IR representation on which this step was applied.

Definition at line 54 of file hls_function_step.hpp.

Referenced by Exec(), and HasToBeExecuted().

◆ memory_version

unsigned int HLSFunctionStep::memory_version
protected

The version of memory representation on which this step was applied.

Definition at line 69 of file hls_function_step.hpp.

Referenced by Exec(), GetName(), and HasToBeExecuted().


The documentation for this class was generated from the following files:

Generated on Mon Feb 12 2024 13:03:55 for PandA-2024.02 by doxygen 1.8.13