gem5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Private Attributes | List of all members
InputUnit Class Reference

#include <InputUnit.hh>

Inheritance diagram for InputUnit:
Consumer

Public Member Functions

 InputUnit (int id, PortDirection direction, Router *router)
 
 ~InputUnit ()
 
void wakeup ()
 
void print (std::ostream &out) const
 
PortDirection get_direction ()
 
void set_vc_idle (int vc, Cycles curTime)
 
void set_vc_active (int vc, Cycles curTime)
 
void grant_outport (int vc, int outport)
 
void grant_outvc (int vc, int outvc)
 
int get_outport (int invc)
 
int get_outvc (int invc)
 
Cycles get_enqueue_time (int invc)
 
void increment_credit (int in_vc, bool free_signal, Cycles curTime)
 
flitpeekTopFlit (int vc)
 
flitgetTopFlit (int vc)
 
bool need_stage (int vc, flit_stage stage, Cycles time)
 
bool isReady (int invc, Cycles curTime)
 
flitBuffergetCreditQueue ()
 
void set_in_link (NetworkLink *link)
 
int get_inlink_id ()
 
void set_credit_link (CreditLink *credit_link)
 
double get_buf_read_activity (unsigned int vnet) const
 
double get_buf_write_activity (unsigned int vnet) const
 
uint32_t functionalWrite (Packet *pkt)
 
void resetStats ()
 
- Public Member Functions inherited from Consumer
 Consumer (ClockedObject *_em)
 
virtual ~Consumer ()
 
virtual void storeEventInfo (int info)
 
bool alreadyScheduled (Tick time)
 
void insertScheduledWakeupTime (Tick time)
 
void scheduleEventAbsolute (Tick timeAbs)
 

Private Attributes

int m_id
 
PortDirection m_direction
 
int m_num_vcs
 
int m_vc_per_vnet
 
Routerm_router
 
NetworkLinkm_in_link
 
CreditLinkm_credit_link
 
flitBuffercreditQueue
 
std::vector< VirtualChannel * > m_vcs
 
std::vector< double > m_num_buffer_writes
 
std::vector< double > m_num_buffer_reads
 

Additional Inherited Members

- Protected Member Functions inherited from Consumer
void scheduleEvent (Cycles timeDelta)
 

Detailed Description

Definition at line 48 of file InputUnit.hh.

Constructor & Destructor Documentation

InputUnit::InputUnit ( int  id,
PortDirection  direction,
Router router 
)
InputUnit::~InputUnit ( )

Definition at line 68 of file InputUnit.cc.

References creditQueue, m5::stl_helpers::deletePointers(), and m_vcs.

Member Function Documentation

uint32_t InputUnit::functionalWrite ( Packet pkt)

Definition at line 154 of file InputUnit.cc.

References ArmISA::i, m_num_vcs, and m_vcs.

double InputUnit::get_buf_read_activity ( unsigned int  vnet) const
inline

Definition at line 143 of file InputUnit.hh.

References m_num_buffer_reads.

double InputUnit::get_buf_write_activity ( unsigned int  vnet) const
inline

Definition at line 145 of file InputUnit.hh.

References m_num_buffer_writes.

PortDirection InputUnit::get_direction ( )
inline

Definition at line 57 of file InputUnit.hh.

References m_direction.

Cycles InputUnit::get_enqueue_time ( int  invc)
inline

Definition at line 96 of file InputUnit.hh.

References m_vcs.

int InputUnit::get_inlink_id ( )
inline

Definition at line 135 of file InputUnit.hh.

References NetworkLink::get_id(), and m_in_link.

int InputUnit::get_outport ( int  invc)
inline

Definition at line 84 of file InputUnit.hh.

References m_vcs.

int InputUnit::get_outvc ( int  invc)
inline

Definition at line 90 of file InputUnit.hh.

References m_vcs.

flitBuffer* InputUnit::getCreditQueue ( )
inline

Definition at line 127 of file InputUnit.hh.

References creditQueue.

Referenced by Router::addInPort().

flit* InputUnit::getTopFlit ( int  vc)
inline

Definition at line 110 of file InputUnit.hh.

References m_vcs.

void InputUnit::grant_outport ( int  vc,
int  outport 
)
inline

Definition at line 72 of file InputUnit.hh.

References m_vcs.

Referenced by wakeup().

void InputUnit::grant_outvc ( int  vc,
int  outvc 
)
inline

Definition at line 78 of file InputUnit.hh.

References m_vcs.

void InputUnit::increment_credit ( int  in_vc,
bool  free_signal,
Cycles  curTime 
)
bool InputUnit::isReady ( int  invc,
Cycles  curTime 
)
inline

Definition at line 122 of file InputUnit.hh.

References m_vcs.

bool InputUnit::need_stage ( int  vc,
flit_stage  stage,
Cycles  time 
)
inline

Definition at line 116 of file InputUnit.hh.

References m_vcs.

flit* InputUnit::peekTopFlit ( int  vc)
inline

Definition at line 104 of file InputUnit.hh.

References m_vcs.

void InputUnit::print ( std::ostream &  out) const
inlinevirtual

Implements Consumer.

Definition at line 55 of file InputUnit.hh.

void InputUnit::resetStats ( )

Definition at line 165 of file InputUnit.cc.

References ArmISA::j, m_num_buffer_reads, and m_num_buffer_writes.

void InputUnit::set_credit_link ( CreditLink credit_link)
inline

Definition at line 138 of file InputUnit.hh.

References m_credit_link.

Referenced by Router::addInPort().

void InputUnit::set_in_link ( NetworkLink link)
inline

Definition at line 130 of file InputUnit.hh.

References m_in_link.

Referenced by Router::addInPort().

void InputUnit::set_vc_active ( int  vc,
Cycles  curTime 
)
inline

Definition at line 66 of file InputUnit.hh.

References m_vcs.

Referenced by wakeup().

void InputUnit::set_vc_idle ( int  vc,
Cycles  curTime 
)
inline

Definition at line 60 of file InputUnit.hh.

References m_vcs.

void InputUnit::wakeup ( )
virtual

Member Data Documentation

flitBuffer* InputUnit::creditQueue
private

Definition at line 160 of file InputUnit.hh.

Referenced by getCreditQueue(), increment_credit(), InputUnit(), and ~InputUnit().

CreditLink* InputUnit::m_credit_link
private

Definition at line 159 of file InputUnit.hh.

Referenced by increment_credit(), and set_credit_link().

PortDirection InputUnit::m_direction
private

Definition at line 153 of file InputUnit.hh.

Referenced by get_direction(), InputUnit(), and wakeup().

int InputUnit::m_id
private

Definition at line 152 of file InputUnit.hh.

Referenced by InputUnit(), and wakeup().

NetworkLink* InputUnit::m_in_link
private

Definition at line 158 of file InputUnit.hh.

Referenced by get_inlink_id(), set_in_link(), and wakeup().

std::vector<double> InputUnit::m_num_buffer_reads
private

Definition at line 167 of file InputUnit.hh.

Referenced by get_buf_read_activity(), InputUnit(), resetStats(), and wakeup().

std::vector<double> InputUnit::m_num_buffer_writes
private

Definition at line 166 of file InputUnit.hh.

Referenced by get_buf_write_activity(), InputUnit(), resetStats(), and wakeup().

int InputUnit::m_num_vcs
private

Definition at line 154 of file InputUnit.hh.

Referenced by functionalWrite(), and InputUnit().

Router* InputUnit::m_router
private

Definition at line 157 of file InputUnit.hh.

Referenced by increment_credit(), InputUnit(), and wakeup().

int InputUnit::m_vc_per_vnet
private

Definition at line 155 of file InputUnit.hh.

Referenced by InputUnit(), and wakeup().

std::vector<VirtualChannel *> InputUnit::m_vcs
private

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

Generated on Fri Jun 9 2017 13:04:13 for gem5 by doxygen 1.8.6