OpenASIP
2.0
|
#include <ReservationTable.hh>
Public Types | |
typedef int | ResourceID |
Public Member Functions | |
ReservationTable (const TTAMachine::FunctionUnit &fu) | |
ReservationTable (const TTAMachine::HWOperation &operation) | |
virtual | ~ReservationTable () |
void | init (const TTAMachine::FunctionUnit &fu) |
bool | conflictsWith (const ReservationTable &anotherReservationTable, int cycle) const |
void | issueOperation (ReservationTable &anotherReservationTable) |
void | advanceCycle () |
bool | isReserved (ResourceID resource, int cycle) const |
bool | conflictsWith (const BitMatrix &another) const |
Public Member Functions inherited from BitMatrix | |
BitMatrix (int width, int height, bool initialValue) | |
BitMatrix (const BitMatrix &another) | |
virtual | ~BitMatrix () |
bool | bitAt (int column, int row) const |
void | setBit (int column, int row, bool value) |
void | setAllToZero () |
void | setAllToOne () |
void | shiftLeft () |
void | orWith (const BitMatrix &another) |
bool | conflictsWith (const BitMatrix &another) const |
int | rowCount () const |
int | columnCount () const |
std::string | toString () const |
std::string | toDotString () const |
bool | operator== (const BitMatrix &other) const |
bool | operator< (const BitMatrix &rightHand) const |
Models pipeline resources using a Conventional Reservation Table (CRT).
An efficient implementation to avoid all kinds of function overheads etc. All simulation operations can be done by calling inline methods.
Definition at line 49 of file ReservationTable.hh.
typedef int ReservationTable::ResourceID |
Definition at line 52 of file ReservationTable.hh.
ReservationTable::ReservationTable | ( | const TTAMachine::FunctionUnit & | fu | ) |
Builds an empty reservation table of given width for the given function unit.
fu | The function unit of which resources to build the reservation table of. |
cycleCount | The count of cycle columns. |
Definition at line 51 of file ReservationTable.cc.
ReservationTable::ReservationTable | ( | const TTAMachine::HWOperation & | operation | ) |
Builds a reservation table for the given operation.
Also includes empty resource rows so the reservation table is compatible with the global reservation table for the whole function unit.
operation | The operation of which resources to use. |
Definition at line 66 of file ReservationTable.cc.
References BitMatrix::columnCount(), TTAMachine::ExecutionPipeline::isPortUsed(), TTAMachine::ExecutionPipeline::isResourceUsed(), TTAMachine::PipelineElement::name(), TTAMachine::FunctionUnit::operationPort(), TTAMachine::FunctionUnit::operationPortCount(), TTAMachine::HWOperation::parentUnit(), TTAMachine::HWOperation::pipeline(), TTAMachine::FunctionUnit::pipelineElement(), TTAMachine::FunctionUnit::pipelineElementCount(), and BitMatrix::setBit().
|
virtual |
void ReservationTable::advanceCycle | ( | ) |
bool BitMatrix::conflictsWith |
bool ReservationTable::conflictsWith | ( | const ReservationTable & | anotherReservationTable, |
int | cycle | ||
) | const |
Referenced by CollisionMatrix::CollisionMatrix().
void ReservationTable::init | ( | const TTAMachine::FunctionUnit & | fu | ) |
bool ReservationTable::isReserved | ( | ResourceID | resource, |
int | cycle | ||
) | const |
void ReservationTable::issueOperation | ( | ReservationTable & | anotherReservationTable | ) |