SimpleNetwork.hh (8257:7226aebb77b4) | SimpleNetwork.hh (8259:36987780169e) |
---|---|
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; --- 39 unchanged lines hidden (view full) --- 48{ 49 public: 50 typedef SimpleNetworkParams Params; 51 SimpleNetwork(const Params *p); 52 ~SimpleNetwork(); 53 54 void init(); 55 | 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; --- 39 unchanged lines hidden (view full) --- 48{ 49 public: 50 typedef SimpleNetworkParams Params; 51 SimpleNetwork(const Params *p); 52 ~SimpleNetwork(); 53 54 void init(); 55 |
56 int getBufferSize() { return m_buffer_size; } 57 int getEndpointBandwidth() { return m_endpoint_bandwidth; } 58 bool getAdaptiveRouting() {return m_adaptive_routing; } 59 |
|
56 void printStats(std::ostream& out) const; 57 void clearStats(); 58 void printConfig(std::ostream& out) const; 59 60 void reset(); 61 62 // returns the queue requested for the given component 63 MessageBuffer* getToNetQueue(NodeID id, bool ordered, int network_num); --- 38 unchanged lines hidden (view full) --- 102 std::vector<std::vector<MessageBuffer*> > m_toNetQueues; 103 std::vector<std::vector<MessageBuffer*> > m_fromNetQueues; 104 105 std::vector<bool> m_in_use; 106 std::vector<bool> m_ordered; 107 std::vector<Switch*> m_switch_ptr_vector; 108 std::vector<MessageBuffer*> m_buffers_to_free; 109 std::vector<Switch*> m_endpoint_switches; | 60 void printStats(std::ostream& out) const; 61 void clearStats(); 62 void printConfig(std::ostream& out) const; 63 64 void reset(); 65 66 // returns the queue requested for the given component 67 MessageBuffer* getToNetQueue(NodeID id, bool ordered, int network_num); --- 38 unchanged lines hidden (view full) --- 106 std::vector<std::vector<MessageBuffer*> > m_toNetQueues; 107 std::vector<std::vector<MessageBuffer*> > m_fromNetQueues; 108 109 std::vector<bool> m_in_use; 110 std::vector<bool> m_ordered; 111 std::vector<Switch*> m_switch_ptr_vector; 112 std::vector<MessageBuffer*> m_buffers_to_free; 113 std::vector<Switch*> m_endpoint_switches; |
114 115 int m_buffer_size; 116 int m_endpoint_bandwidth; 117 bool m_adaptive_routing; |
|
110}; 111 112inline std::ostream& 113operator<<(std::ostream& out, const SimpleNetwork& obj) 114{ 115 obj.print(out); 116 out << std::flush; 117 return out; 118} 119 120#endif // __MEM_RUBY_NETWORK_SIMPLE_SIMPLENETWORK_HH__ | 118}; 119 120inline std::ostream& 121operator<<(std::ostream& out, const SimpleNetwork& obj) 122{ 123 obj.print(out); 124 out << std::flush; 125 return out; 126} 127 128#endif // __MEM_RUBY_NETWORK_SIMPLE_SIMPLENETWORK_HH__ |