diff options
Diffstat (limited to 'src/mem/ruby/network/simple/Switch.hh')
-rw-r--r-- | src/mem/ruby/network/simple/Switch.hh | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/mem/ruby/network/simple/Switch.hh b/src/mem/ruby/network/simple/Switch.hh index f60a31ab3..47f4c0858 100644 --- a/src/mem/ruby/network/simple/Switch.hh +++ b/src/mem/ruby/network/simple/Switch.hh @@ -67,12 +67,13 @@ class Switch : public BasicRouter int bw_multiplier); const Throttle* getThrottle(LinkID link_number) const; const std::vector<Throttle*>* getThrottles() const; - void clearRoutingTables(); - void clearBuffers(); - void reconfigureOutPort(const NetDest& routing_table_entry); - void printStats(std::ostream& out) const; - void clearStats(); + void resetStats(); + void collateStats(); + void regStats(); + const Stats::Formula & getMsgCount(unsigned int type) const + { return m_msg_counts[type]; } + void print(std::ostream& out) const; void init_net_ptr(SimpleNetwork* net_ptr) { m_network_ptr = net_ptr; } @@ -88,6 +89,11 @@ class Switch : public BasicRouter SimpleNetwork* m_network_ptr; std::vector<Throttle*> m_throttles; std::vector<MessageBuffer*> m_buffers_to_free; + + // Statistical variables + Stats::Formula m_avg_utilization; + std::vector<Stats::Formula> m_msg_counts; + std::vector<Stats::Formula> m_msg_bytes; }; inline std::ostream& |