diff options
author | Nathan Binkert <nate@binkert.org> | 2010-06-10 23:17:07 -0700 |
---|---|---|
committer | Nathan Binkert <nate@binkert.org> | 2010-06-10 23:17:07 -0700 |
commit | 006818aeea6176c4500c5f7414e9f2a822c77062 (patch) | |
tree | 74adbd6cc14951943bd6eafc4aba2fb98be7a526 /src/mem/ruby/network/simple/Throttle.hh | |
parent | bc87fa30d72df7db6265be50b2c39dc218076f9f (diff) | |
download | gem5-006818aeea6176c4500c5f7414e9f2a822c77062.tar.xz |
ruby: get rid of Vector and use STL
add a couple of helper functions to base for deleteing all pointers in
a container and outputting containers to a stream
Diffstat (limited to 'src/mem/ruby/network/simple/Throttle.hh')
-rw-r--r-- | src/mem/ruby/network/simple/Throttle.hh | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/mem/ruby/network/simple/Throttle.hh b/src/mem/ruby/network/simple/Throttle.hh index 74cd7b356..c80f24d77 100644 --- a/src/mem/ruby/network/simple/Throttle.hh +++ b/src/mem/ruby/network/simple/Throttle.hh @@ -39,8 +39,8 @@ #define __MEM_RUBY_NETWORK_SIMPLE_THROTTLE_HH__ #include <iostream> +#include <vector> -#include "mem/gems_common/Vector.hh" #include "mem/ruby/common/Consumer.hh" #include "mem/ruby/common/Global.hh" #include "mem/ruby/network/Network.hh" @@ -57,8 +57,8 @@ class Throttle : public Consumer Throttle(NodeID node, int link_latency, int link_bandwidth_multiplier); ~Throttle() {} - void addLinks(const Vector<MessageBuffer*>& in_vec, - const Vector<MessageBuffer*>& out_vec); + void addLinks(const std::vector<MessageBuffer*>& in_vec, + const std::vector<MessageBuffer*>& out_vec); void wakeup(); void printStats(std::ostream& out) const; @@ -74,7 +74,7 @@ class Throttle : public Consumer } int getLatency() const { return m_link_latency; } - const Vector<Vector<int> >& + const std::vector<std::vector<int> >& getCounters() const { return m_message_counters; @@ -93,11 +93,11 @@ class Throttle : public Consumer Throttle(const Throttle& obj); Throttle& operator=(const Throttle& obj); - Vector<MessageBuffer*> m_in; - Vector<MessageBuffer*> m_out; - Vector<Vector<int> > m_message_counters; + std::vector<MessageBuffer*> m_in; + std::vector<MessageBuffer*> m_out; + std::vector<std::vector<int> > m_message_counters; int m_vnets; - Vector<int> m_units_remaining; + std::vector<int> m_units_remaining; int m_sID; NodeID m_node; int m_link_bandwidth_multiplier; |