OpenASIP
2.0
|
#include <CostDBEntryStatsFU.hh>
Public Member Functions | |
CostDBEntryStatsFU (double areaData, double delayData) | |
virtual | ~CostDBEntryStatsFU () |
CostDBEntryStatsFU (const CostDBEntryStatsFU &stats1, const CostDBEntryStatsFU &stats2, double coefficient) | |
virtual double | energyActive () const |
virtual double | energyOperation (const std::string &name) const |
virtual bool | hasEnergyOperation (const std::string &name) const |
virtual void | setEnergyActive (double energy) |
virtual void | setEnergyOperation (const std::string &name, double energy) |
Public Member Functions inherited from CostDBEntryStats | |
CostDBEntryStats (double areaData, double internalDelayData) | |
virtual | ~CostDBEntryStats () |
CostDBEntryStats (const CostDBEntryStats &stats1, const CostDBEntryStats &stats2, double coefficient) | |
virtual CostDBEntryStats * | copy () const |
virtual double | area () const |
virtual double | delay () const |
virtual double | delayPort (const std::string &port) const |
virtual void | setDelay (const std::string &port, double delay) |
virtual double | energyIdle () const |
virtual double | energyRead () const |
virtual double | energyWrite () const |
virtual double | energyReadWrite (int reads, int writes) const |
virtual void | setEnergyIdle (double energy) |
virtual void | setEnergyRead (double energy) |
virtual void | setEnergyWrite (double energy) |
virtual void | setEnergyReadWrite (int reads, int writes, double energy) |
Protected Member Functions | |
virtual CostDBEntryStats * | createStats () const |
Protected Member Functions inherited from CostDBEntryStats | |
virtual bool | hasEnergy (const std::string &key) const |
virtual double | findEnergy (const std::string &key) const |
virtual void | addEnergy (const std::string &name, double energy) |
virtual bool | hasDelay (const std::string &key) const |
virtual double | findDelay (const std::string &key) const |
virtual void | addDelay (const std::string &name, double delay) |
Private Member Functions | |
CostDBEntryStatsFU (const CostDBEntryStatsFU &) | |
Copying not allowed. More... | |
CostDBEntryStatsFU & | operator= (const CostDBEntryStatsFU &) |
Assignment not allowed. More... | |
Additional Inherited Members | |
Static Protected Attributes inherited from CostDBEntryStats | |
static const std::string | ENERGY_ACTIVE = "(active)" |
String for active energy. More... | |
static const std::string | ENERGY_IDLE = "(idle)" |
String for idle energy. More... | |
static const std::string | ENERGY_READ = "(read)" |
String for read energy. More... | |
static const std::string | ENERGY_WRITE = "(write)" |
String for write energy. More... | |
static const std::string | ENERGY_READ_WRITE = "(rd,wr)" |
String for reads and writes energy. More... | |
Stores area, delay and energy statistics of function units.
Definition at line 44 of file CostDBEntryStatsFU.hh.
CostDBEntryStatsFU::CostDBEntryStatsFU | ( | double | areaData, |
double | delayData | ||
) |
Constructor.
areaData | area. |
delayData | delay. |
Definition at line 48 of file CostDBEntryStatsFU.cc.
Referenced by createStats().
|
virtual |
CostDBEntryStatsFU::CostDBEntryStatsFU | ( | const CostDBEntryStatsFU & | stats1, |
const CostDBEntryStatsFU & | stats2, | ||
double | coefficient | ||
) |
Constructor.
Combines two statistics into one using coefficient as a weighting factor on interpolating the statistics. For example, if weighting factor is 0.4, the first area 100 and the second 200, area of new statistics will be 140. delay and energy will be handled similarly.
stats1 | First statistics. |
stats2 | Second statistics. |
coefficient | Weighting factor. |
Definition at line 64 of file CostDBEntryStatsFU.cc.
|
private |
Copying not allowed.
|
protectedvirtual |
Create correct type of statistics.
Reimplemented from CostDBEntryStats.
Definition at line 84 of file CostDBEntryStatsFU.cc.
References CostDBEntryStats::area(), CostDBEntryStatsFU(), and CostDBEntryStats::delay().
|
virtual |
Returns the energy of an entry in an active cycle.
The function will fail since function units do not have unambiguous energy for the whole unit but separately for each operation.
WrongSubclass | An illegal function was called for this instance. |
KeyNotFound | Never thrown by this function. |
Reimplemented from CostDBEntryStats.
Definition at line 100 of file CostDBEntryStatsFU.cc.
|
virtual |
Returns the energy of an entry when given operation is executed.
name | name of the operation. |
WrongSubclass | Never thrown by this function. |
KeyNotFound | No energy matching the string found. |
Reimplemented from CostDBEntryStats.
Definition at line 115 of file CostDBEntryStatsFU.cc.
References CostDBEntryStats::findEnergy().
|
virtual |
Checks whether the energy exists for the given operation.
name | name of the operation. |
WrongSubclass | Never thrown by this function. |
Reimplemented from CostDBEntryStats.
Definition at line 127 of file CostDBEntryStatsFU.cc.
References CostDBEntryStats::hasEnergy().
|
private |
Assignment not allowed.
|
virtual |
Set the energy of an entry in an active cycle.
The function will fail since function units do not have unambiguous energy for the whole unit but separately for each operation.
energy | The energy of an entry in an active cycle. |
WrongSubclass | An illegal function was called for this instance. |
Reimplemented from CostDBEntryStats.
Definition at line 142 of file CostDBEntryStatsFU.cc.
|
virtual |
Set the energy of an entry when given operation is executed.
name | name of the operation. |
energy | The energy of an entry when given operation is executed. |
WrongSubclass | Never thrown by this function. |
Reimplemented from CostDBEntryStats.
Definition at line 155 of file CostDBEntryStatsFU.cc.
References CostDBEntryStats::addEnergy().
Referenced by CostDatabase::buildFunctionUnits().