Switch.hh (9863:9483739f83ee) | Switch.hh (9866:94dac7d7bb88) |
---|---|
1/* 2 * Copyright (c) 1999-2008 Mark D. Hill and David A. Wood 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions are 7 * met: redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer; --- 29 unchanged lines hidden (view full) --- 38 39#ifndef __MEM_RUBY_NETWORK_SIMPLE_SWITCH_HH__ 40#define __MEM_RUBY_NETWORK_SIMPLE_SWITCH_HH__ 41 42#include <iostream> 43#include <vector> 44 45#include "mem/packet.hh" | 1/* 2 * Copyright (c) 1999-2008 Mark D. Hill and David A. Wood 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions are 7 * met: redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer; --- 29 unchanged lines hidden (view full) --- 38 39#ifndef __MEM_RUBY_NETWORK_SIMPLE_SWITCH_HH__ 40#define __MEM_RUBY_NETWORK_SIMPLE_SWITCH_HH__ 41 42#include <iostream> 43#include <vector> 44 45#include "mem/packet.hh" |
46#include "mem/protocol/MessageSizeType.hh" |
|
46#include "mem/ruby/common/TypeDefines.hh" 47#include "mem/ruby/network/BasicRouter.hh" 48#include "params/Switch.hh" 49 50class MessageBuffer; 51class PerfectSwitch; 52class NetDest; 53class SimpleNetwork; --- 33 unchanged lines hidden (view full) --- 87 88 PerfectSwitch* m_perfect_switch; 89 SimpleNetwork* m_network_ptr; 90 std::vector<Throttle*> m_throttles; 91 std::vector<MessageBuffer*> m_buffers_to_free; 92 93 // Statistical variables 94 Stats::Formula m_avg_utilization; | 47#include "mem/ruby/common/TypeDefines.hh" 48#include "mem/ruby/network/BasicRouter.hh" 49#include "params/Switch.hh" 50 51class MessageBuffer; 52class PerfectSwitch; 53class NetDest; 54class SimpleNetwork; --- 33 unchanged lines hidden (view full) --- 88 89 PerfectSwitch* m_perfect_switch; 90 SimpleNetwork* m_network_ptr; 91 std::vector<Throttle*> m_throttles; 92 std::vector<MessageBuffer*> m_buffers_to_free; 93 94 // Statistical variables 95 Stats::Formula m_avg_utilization; |
95 std::vector<Stats::Formula> m_msg_counts; 96 std::vector<Stats::Formula> m_msg_bytes; | 96 Stats::Formula m_msg_counts[MessageSizeType_NUM]; 97 Stats::Formula m_msg_bytes[MessageSizeType_NUM]; |
97}; 98 99inline std::ostream& 100operator<<(std::ostream& out, const Switch& obj) 101{ 102 obj.print(out); 103 out << std::flush; 104 return out; 105} 106 107#endif // __MEM_RUBY_NETWORK_SIMPLE_SWITCH_HH__ | 98}; 99 100inline std::ostream& 101operator<<(std::ostream& out, const Switch& obj) 102{ 103 obj.print(out); 104 out << std::flush; 105 return out; 106} 107 108#endif // __MEM_RUBY_NETWORK_SIMPLE_SWITCH_HH__ |