gem5
|
#include <Topology.hh>
Public Member Functions | |
Topology (uint32_t num_routers, const std::vector< BasicExtLink * > &ext_links, const std::vector< BasicIntLink * > &int_links) | |
uint32_t | numSwitches () const |
void | createLinks (Network *net) |
void | print (std::ostream &out) const |
Private Member Functions | |
void | addLink (SwitchID src, SwitchID dest, BasicLink *link, PortDirection src_outport_dirn="", PortDirection dest_inport_dirn="") |
void | makeLink (Network *net, SwitchID src, SwitchID dest, const NetDest &routing_table_entry) |
void | extend_shortest_path (Matrix ¤t_dist, Matrix &latencies, Matrix &inter_switches) |
std::vector< std::vector< int > > | shortest_path (const Matrix &weights, Matrix &latencies, Matrix &inter_switches) |
bool | link_is_shortest_path_to_node (SwitchID src, SwitchID next, SwitchID final, const Matrix &weights, const Matrix &dist) |
NetDest | shortest_path_to_node (SwitchID src, SwitchID next, const Matrix &weights, const Matrix &dist) |
Private Attributes | |
const uint32_t | m_nodes |
const uint32_t | m_number_of_switches |
std::vector< BasicExtLink * > | m_ext_link_vector |
std::vector< BasicIntLink * > | m_int_link_vector |
LinkMap | m_link_map |
Definition at line 66 of file Topology.hh.
Topology::Topology | ( | uint32_t | num_routers, |
const std::vector< BasicExtLink * > & | ext_links, | ||
const std::vector< BasicIntLink * > & | int_links | ||
) |
Definition at line 51 of file Topology.cc.
References addLink(), AbstractController::getType(), AbstractController::getVersion(), ArmISA::i, m_int_link_vector, m_nodes, BasicRouter::params(), BasicExtLink::params(), and BasicIntLink::params().
|
private |
Definition at line 161 of file Topology.cc.
References LinkEntry::dst_inport_dirn, LinkEntry::link, m_link_map, m_nodes, m_number_of_switches, and LinkEntry::src_outport_dirn.
Referenced by Topology().
void Topology::createLinks | ( | Network * | net | ) |
Definition at line 108 of file Topology.cc.
References Stats::dist, ArmISA::i, INFINITE_LATENCY, ArmISA::j, BasicLink::m_latency, m_link_map, BasicLink::m_weight, makeLink(), shortest_path(), and shortest_path_to_node().
Referenced by SimpleNetwork::init(), and GarnetNetwork::init().
|
private |
Definition at line 220 of file Topology.cc.
References ArmISA::i, ArmISA::j, MipsISA::k, and X86ISA::size().
Referenced by shortest_path().
|
private |
Definition at line 267 of file Topology.cc.
Referenced by shortest_path_to_node().
|
private |
Definition at line 180 of file Topology.cc.
References LinkEntry::dst_inport_dirn, LinkEntry::link, m_link_map, m_nodes, Network::makeExtInLink(), Network::makeExtOutLink(), Network::makeInternalLink(), and LinkEntry::src_outport_dirn.
Referenced by createLinks().
|
inline |
Definition at line 72 of file Topology.hh.
References m_number_of_switches.
|
inline |
Definition at line 74 of file Topology.hh.
Referenced by operator<<().
|
private |
Definition at line 258 of file Topology.cc.
References Stats::dist, and extend_shortest_path().
Referenced by createLinks().
|
private |
Definition at line 275 of file Topology.cc.
References NetDest::add(), ArmISA::d, DPRINTF, ArmISA::i, link_is_shortest_path_to_node(), and ArmISA::m.
Referenced by createLinks().
|
private |
Definition at line 99 of file Topology.hh.
|
private |
Definition at line 100 of file Topology.hh.
Referenced by Topology().
|
private |
Definition at line 102 of file Topology.hh.
Referenced by addLink(), createLinks(), and makeLink().
|
private |
Definition at line 96 of file Topology.hh.
Referenced by addLink(), makeLink(), and Topology().
|
private |
Definition at line 97 of file Topology.hh.
Referenced by addLink(), and numSwitches().