gem5
v20.1.0.0
|
#include <Throttle.hh>
Public Member Functions | |
Throttle (int sID, RubySystem *rs, NodeID node, Cycles link_latency, int link_bandwidth_multiplier, int endpoint_bandwidth, Switch *em) | |
~Throttle () | |
std::string | name () |
void | addLinks (const std::vector< MessageBuffer * > &in_vec, const std::vector< MessageBuffer * > &out_vec) |
void | wakeup () |
const Stats::Scalar & | getUtilization () const |
const Stats::Vector & | getMsgCount (unsigned int type) const |
int | getLinkBandwidth () const |
Cycles | getLatency () const |
void | clearStats () |
void | collateStats () |
void | regStats (std::string name) |
void | print (std::ostream &out) const |
Public Member Functions inherited from Consumer | |
Consumer (ClockedObject *_em) | |
virtual | ~Consumer () |
virtual void | storeEventInfo (int info) |
bool | alreadyScheduled (Tick time) |
void | insertScheduledWakeupTime (Tick time) |
ClockedObject * | getObject () |
void | scheduleEventAbsolute (Tick timeAbs) |
void | scheduleEvent (Cycles timeDelta) |
Private Member Functions | |
void | init (NodeID node, Cycles link_latency, int link_bandwidth_multiplier, int endpoint_bandwidth) |
void | operateVnet (int vnet, int &bw_remainin, bool &schedule_wakeup, MessageBuffer *in, MessageBuffer *out) |
Throttle (const Throttle &obj) | |
Throttle & | operator= (const Throttle &obj) |
Private Attributes | |
std::vector< MessageBuffer * > | m_in |
std::vector< MessageBuffer * > | m_out |
unsigned int | m_vnets |
std::vector< int > | m_units_remaining |
const int | m_switch_id |
Switch * | m_switch |
NodeID | m_node |
int | m_link_bandwidth_multiplier |
Cycles | m_link_latency |
int | m_wakeups_wo_switch |
int | m_endpoint_bandwidth |
RubySystem * | m_ruby_system |
Stats::Scalar | m_link_utilization |
Stats::Vector | m_msg_counts [MessageSizeType_NUM] |
Stats::Formula | m_msg_bytes [MessageSizeType_NUM] |
double | m_link_utilization_proxy |
Definition at line 52 of file Throttle.hh.
Throttle::Throttle | ( | int | sID, |
RubySystem * | rs, | ||
NodeID | node, | ||
Cycles | link_latency, | ||
int | link_bandwidth_multiplier, | ||
int | endpoint_bandwidth, | ||
Switch * | em | ||
) |
Definition at line 51 of file Throttle.cc.
References m_endpoint_bandwidth, m_link_bandwidth_multiplier, m_link_latency, m_link_utilization_proxy, m_vnets, and m_wakeups_wo_switch.
|
inline |
Definition at line 58 of file Throttle.hh.
|
private |
void Throttle::addLinks | ( | const std::vector< MessageBuffer * > & | in_vec, |
const std::vector< MessageBuffer * > & | out_vec | ||
) |
Definition at line 70 of file Throttle.cc.
References m_in, m_node, m_out, m_switch_id, m_units_remaining, m_vnets, MessageBuffer::setConsumer(), and sc_dt::to_string().
void Throttle::clearStats | ( | ) |
Definition at line 228 of file Throttle.cc.
References m_link_utilization_proxy.
void Throttle::collateStats | ( | ) |
Definition at line 234 of file Throttle.cc.
References Clocked::curCycle(), RubySystem::getStartCycle(), m_link_utilization, m_link_utilization_proxy, and m_ruby_system.
|
inline |
Definition at line 76 of file Throttle.hh.
References m_link_latency.
|
inline |
Definition at line 73 of file Throttle.hh.
References m_endpoint_bandwidth, and m_link_bandwidth_multiplier.
Referenced by operateVnet(), print(), and wakeup().
|
inline |
Definition at line 70 of file Throttle.hh.
References m_msg_counts, and type.
|
inline |
Definition at line 68 of file Throttle.hh.
References m_link_utilization.
|
private |
Referenced by regStats().
|
inline |
Definition at line 60 of file Throttle.hh.
References csprintf(), and m_switch_id.
Referenced by regStats().
|
private |
Definition at line 92 of file Throttle.cc.
References MessageBuffer::areNSlotsAvailable(), Clocked::clockEdge(), Clocked::curCycle(), Clocked::cyclesToTicks(), MessageBuffer::dequeue(), DPRINTF, MessageBuffer::enqueue(), getLinkBandwidth(), Message::getMessageSize(), MessageBuffer::isReady(), m_link_latency, m_msg_counts, m_node, m_ruby_system, m_switch, m_units_remaining, network_message_to_size(), and MessageBuffer::peekMsgPtr().
Referenced by wakeup().
|
virtual |
Implements Consumer.
Definition at line 243 of file Throttle.cc.
References ccprintf(), getLinkBandwidth(), and m_node.
Referenced by operator<<().
void Throttle::regStats | ( | std::string | name | ) |
Definition at line 203 of file Throttle.cc.
References Stats::constant(), csprintf(), Network::getNumberOfVirtualNetworks(), init(), m_link_utilization, m_msg_bytes, m_msg_counts, m_node, Network::MessageSizeType_to_int(), name(), Stats::DataWrap< Derived, InfoProxyType >::name(), Stats::nozero, and type.
|
virtual |
Implements Consumer.
Definition at line 147 of file Throttle.cc.
References DPRINTF, getLinkBandwidth(), m_in, m_link_utilization_proxy, m_out, m_vnets, m_wakeups_wo_switch, operateVnet(), PRIORITY_SWITCH_LIMIT, and Consumer::scheduleEvent().
|
private |
Definition at line 105 of file Throttle.hh.
Referenced by getLinkBandwidth(), and Throttle().
|
private |
Definition at line 93 of file Throttle.hh.
Referenced by addLinks(), and wakeup().
|
private |
Definition at line 102 of file Throttle.hh.
Referenced by getLinkBandwidth(), and Throttle().
|
private |
Definition at line 103 of file Throttle.hh.
Referenced by getLatency(), operateVnet(), and Throttle().
|
private |
Definition at line 109 of file Throttle.hh.
Referenced by collateStats(), getUtilization(), and regStats().
|
private |
Definition at line 113 of file Throttle.hh.
Referenced by clearStats(), collateStats(), Throttle(), and wakeup().
|
private |
Definition at line 111 of file Throttle.hh.
Referenced by regStats().
|
private |
Definition at line 110 of file Throttle.hh.
Referenced by getMsgCount(), operateVnet(), and regStats().
|
private |
Definition at line 100 of file Throttle.hh.
Referenced by addLinks(), operateVnet(), print(), and regStats().
|
private |
Definition at line 94 of file Throttle.hh.
Referenced by addLinks(), and wakeup().
|
private |
Definition at line 106 of file Throttle.hh.
Referenced by collateStats(), and operateVnet().
|
private |
Definition at line 99 of file Throttle.hh.
Referenced by operateVnet().
|
private |
Definition at line 98 of file Throttle.hh.
Referenced by addLinks(), and name().
|
private |
Definition at line 96 of file Throttle.hh.
Referenced by addLinks(), and operateVnet().
|
private |
Definition at line 95 of file Throttle.hh.
Referenced by addLinks(), Throttle(), and wakeup().
|
private |
Definition at line 104 of file Throttle.hh.
Referenced by Throttle(), and wakeup().