OpenASIP  2.0
Public Member Functions | List of all members
CostEstimator::FUCostEstimationPlugin Class Reference

#include <FUCostEstimationPlugin.hh>

Inheritance diagram for CostEstimator::FUCostEstimationPlugin:
Inheritance graph
Collaboration diagram for CostEstimator::FUCostEstimationPlugin:
Collaboration graph

Public Member Functions

 FUCostEstimationPlugin (const std::string &name)
 
virtual ~FUCostEstimationPlugin ()
 
virtual bool estimateArea (const TTAMachine::FunctionUnit &architecture, const IDF::FUImplementationLocation &implementation, AreaInGates &area, HDB::HDBManager &hdb)
 
virtual bool estimateEnergy (const TTAMachine::FunctionUnit &architecture, const IDF::FUImplementationLocation &implementation, const TTAProgram::Program &program, const ExecutionTrace &traceDB, EnergyInMilliJoules &energy, HDB::HDBManager &hdb)
 
virtual bool estimatePortWriteDelay (const TTAMachine::FUPort &port, const IDF::FUImplementationLocation &implementation, DelayInNanoSeconds &inputDelay, HDB::HDBManager &hdb)
 
virtual bool estimatePortReadDelay (const TTAMachine::FUPort &port, const IDF::FUImplementationLocation &implementation, DelayInNanoSeconds &outputDelay, HDB::HDBManager &hdb)
 
virtual bool estimateMaximumComputationDelay (const TTAMachine::FunctionUnit &architecture, const IDF::FUImplementationLocation &implementation, DelayInNanoSeconds &computationDelay, HDB::HDBManager &hdb)
 
- Public Member Functions inherited from CostEstimator::CostEstimationPlugin
 CostEstimationPlugin (const std::string &name)
 
virtual ~CostEstimationPlugin ()
 
virtual std::string name () const
 
virtual std::string description () const
 

Additional Inherited Members

- Protected Attributes inherited from CostEstimator::CostEstimationPlugin
std::string name_
 the name of the plugin class in the HDB; used to identify cost data More...
 

Detailed Description

An interface for classes that implement pluggable function unit cost estimation algorithms.

Definition at line 66 of file FUCostEstimationPlugin.hh.

Constructor & Destructor Documentation

◆ FUCostEstimationPlugin()

CostEstimator::FUCostEstimationPlugin::FUCostEstimationPlugin ( const std::string &  name)

Constructor.

Parameters
nameThe name of the created plugin in HDB.
dataThe HDB the plugin's data is stored in.

Definition at line 44 of file FUCostEstimationPlugin.cc.

45  :
47 }

◆ ~FUCostEstimationPlugin()

CostEstimator::FUCostEstimationPlugin::~FUCostEstimationPlugin ( )
virtual

Destructor.

Definition at line 52 of file FUCostEstimationPlugin.cc.

52  {
53 }

Member Function Documentation

◆ estimateArea()

bool CostEstimator::FUCostEstimationPlugin::estimateArea ( const TTAMachine::FunctionUnit architecture,
const IDF::FUImplementationLocation implementation,
AreaInGates area,
HDB::HDBManager hdb 
)
virtual

Estimates the area of the given function unit.

Parameters
architectureThe FU architecture of which area to estimate.
implementation(The location of) the implementation of FU. Can be an instance of NullFUImplementationLocation.
areaThe variable to store the area estimate into.
Returns
True only if area could be estimated successfully.

Reimplemented in InterpolatingFUEstimator, and StrictMatchFUEstimator.

Definition at line 65 of file FUCostEstimationPlugin.cc.

69  {
70 
71  return false;
72 }

◆ estimateEnergy()

bool CostEstimator::FUCostEstimationPlugin::estimateEnergy ( const TTAMachine::FunctionUnit architecture,
const IDF::FUImplementationLocation implementation,
const TTAProgram::Program program,
const ExecutionTrace traceDB,
EnergyInMilliJoules energy,
HDB::HDBManager hdb 
)
virtual

Estimates the energy consumed by the given function unit when running the given program.

Parameters
architectureThe FU architecture of which area to estimate.
implementation(The location of) the implementation of FU. Can be an instance of NullFUImplementationLocation.
programThe program of which energy to calculate.
traceDBThe simulation trace database of the program running in the target architecture.
energyThe variable to store the energy estimate into.
Returns
True only if energy could be estimated successfully.

Reimplemented in InterpolatingFUEstimator, and StrictMatchFUEstimator.

Definition at line 88 of file FUCostEstimationPlugin.cc.

94  {
95 
96  return false;
97 }

◆ estimateMaximumComputationDelay()

bool CostEstimator::FUCostEstimationPlugin::estimateMaximumComputationDelay ( const TTAMachine::FunctionUnit architecture,
const IDF::FUImplementationLocation implementation,
DelayInNanoSeconds computationDelay,
HDB::HDBManager hdb 
)
virtual

Estimates the maximum computation delay of the given function unit.

The maximum computation delay is the longest stage in the FU unit's pipeline. It's used mainly for calculating the maximum clock frequency of target architecture.

Parameters
architectureThe FU architecture of which area to estimate.
implementation(The location of) the implementation of FU. Can be an instance of NullFUImplementationLocation.
computationDelayThe variable to store the delay estimate into.
Returns
True only if computation delay could be estimated successfully.

Reimplemented in InterpolatingFUEstimator, and StrictMatchFUEstimator.

Definition at line 151 of file FUCostEstimationPlugin.cc.

155  {
156 
157  return false;
158 }

◆ estimatePortReadDelay()

bool CostEstimator::FUCostEstimationPlugin::estimatePortReadDelay ( const TTAMachine::FUPort port,
const IDF::FUImplementationLocation implementation,
DelayInNanoSeconds outputDelay,
HDB::HDBManager hdb 
)
virtual

Estimates the output delay of the given function unit port.

Parameters
portThe FU port of which output delay to estimate.
implementation(The location of) the implementation of FU. Can be an instance of NullFUImplementationLocation.
outputDelayThe variable to store the delay estimate into.
Returns
True only if output delay could be estimated successfully.

Reimplemented in InterpolatingFUEstimator, and StrictMatchFUEstimator.

Definition at line 128 of file FUCostEstimationPlugin.cc.

132  {
133 
134  return false;
135 }

◆ estimatePortWriteDelay()

bool CostEstimator::FUCostEstimationPlugin::estimatePortWriteDelay ( const TTAMachine::FUPort port,
const IDF::FUImplementationLocation implementation,
DelayInNanoSeconds inputDelay,
HDB::HDBManager hdb 
)
virtual

Estimates the input delay of the given function unit port.

Parameters
portThe FU port of which input delay to estimate.
implementation(The location of) the implementation of FU. Can be an instance of NullFUImplementationLocation.
inputDelayThe variable to store the delay estimate into.
Returns
True only if input delay could be estimated successfully.

Reimplemented in InterpolatingFUEstimator, and StrictMatchFUEstimator.

Definition at line 109 of file FUCostEstimationPlugin.cc.

113  {
114 
115  return false;
116 }

The documentation for this class was generated from the following files:
CostEstimator::CostEstimationPlugin::name
virtual std::string name() const
Definition: CostEstimationPlugin.cc:63
CostEstimator::CostEstimationPlugin::CostEstimationPlugin
CostEstimationPlugin(const std::string &name)
Definition: CostEstimationPlugin.cc:46