Otawa  0.10
otawa::hard::FunctionalUnit Class Reference

A functional unit is specialized in the computation of some kinds of instructions. More...

#include <otawa/hard/Processor.h>

Inheritance diagram for otawa::hard::FunctionalUnit:
otawa::hard::PipelineUnit

Public Member Functions

 FunctionalUnit (void)
 
virtual ~FunctionalUnit (void)
 
bool isPipelined (void) const
 
elm::String getName (void) const
 
int getLatency (void) const
 
int getWidth (void) const
 
bool isBranch (void) const
 
bool isMem (void) const
 

Protected Attributes

string name
 
int latency
 
int width
 
bool branch
 
bool mem
 

Private Member Functions

 SERIALIZABLE (otawa::hard::FunctionalUnit, BASE(otawa::hard::PipelineUnit)&FIELD(pipelined))
 

Private Attributes

bool pipelined
 

Friends

class FunctionalUnitBuilder
 

Detailed Description

A functional unit is specialized in the computation of some kinds of instructions.

They are contained in a stage (otawa::hard::Stage) of type EXEC. The selection of a functional unit is performed thanks to the otawa::hard::Dispatch objects provided in the execution stage.

A functional unit is defined by:

  • its latency (computation time in cycles),
  • its width (number of instructions traversing the functional unit in parallel),
  • pipeline property indicating that the function unit is pipelined or not (that is it may chain instruction execution cycles after cycles).

Constructor & Destructor Documentation

otawa::hard::FunctionalUnit::FunctionalUnit ( void  )
inline
virtual otawa::hard::FunctionalUnit::~FunctionalUnit ( void  )
inlinevirtual

Member Function Documentation

int otawa::hard::PipelineUnit::getLatency ( void  ) const
inlineinherited
elm::String otawa::hard::PipelineUnit::getName ( void  ) const
inlineinherited

References name.

Referenced by otawa::ParExeProc::ParExeProc().

int otawa::hard::PipelineUnit::getWidth ( void  ) const
inlineinherited

References width().

Referenced by otawa::ParExeProc::ParExeProc().

bool otawa::hard::PipelineUnit::isBranch ( void  ) const
inlineinherited

References otawa::sem::branch().

bool otawa::hard::PipelineUnit::isMem ( void  ) const
inlineinherited
bool otawa::hard::FunctionalUnit::isPipelined ( void  ) const
inline
otawa::hard::FunctionalUnit::SERIALIZABLE ( otawa::hard::FunctionalUnit  ,
BASE(otawa::hard::PipelineUnit)&FIELD(pipelined  
)
private

Friends And Related Function Documentation

friend class FunctionalUnitBuilder
friend

Member Data Documentation

bool otawa::hard::PipelineUnit::branch
protectedinherited
int otawa::hard::PipelineUnit::latency
protectedinherited
bool otawa::hard::PipelineUnit::mem
protectedinherited
string otawa::hard::PipelineUnit::name
protectedinherited
bool otawa::hard::FunctionalUnit::pipelined
private
int otawa::hard::PipelineUnit::width
protectedinherited

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