From b0856ab3b17e15ff1a6fb329abe87f3434bfe81a Mon Sep 17 00:00:00 2001 From: Jieming Yin Date: Mon, 21 Nov 2016 15:41:30 -0500 Subject: [PATCH] ruby: Fix potential bugs in garnet2.0 1. Delete unused variable from struct LinkEntry 2. Correct GarnetExtLink and GarnetIntLink inheritance --- src/mem/ruby/network/Topology.hh | 1 - src/mem/ruby/network/garnet2.0/GarnetLink.cc | 4 ++-- src/mem/ruby/network/garnet2.0/GarnetLink.hh | 4 ++-- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/mem/ruby/network/Topology.hh b/src/mem/ruby/network/Topology.hh index 1a5f4b19d..71faf4182 100644 --- a/src/mem/ruby/network/Topology.hh +++ b/src/mem/ruby/network/Topology.hh @@ -57,7 +57,6 @@ typedef std::string PortDirection; struct LinkEntry { BasicLink *link; - LinkDirection direction; PortDirection src_outport_dirn; PortDirection dst_inport_dirn; }; diff --git a/src/mem/ruby/network/garnet2.0/GarnetLink.cc b/src/mem/ruby/network/garnet2.0/GarnetLink.cc index ac5386a52..7cf4c6fde 100644 --- a/src/mem/ruby/network/garnet2.0/GarnetLink.cc +++ b/src/mem/ruby/network/garnet2.0/GarnetLink.cc @@ -37,7 +37,7 @@ #include "mem/ruby/network/garnet2.0/NetworkLink.hh" GarnetIntLink::GarnetIntLink(const Params *p) - : BasicLink(p) + : BasicIntLink(p) { // Uni-directional @@ -63,7 +63,7 @@ GarnetIntLinkParams::create() } GarnetExtLink::GarnetExtLink(const Params *p) - : BasicLink(p) + : BasicExtLink(p) { // Bi-directional diff --git a/src/mem/ruby/network/garnet2.0/GarnetLink.hh b/src/mem/ruby/network/garnet2.0/GarnetLink.hh index d7c582950..7311e9379 100644 --- a/src/mem/ruby/network/garnet2.0/GarnetLink.hh +++ b/src/mem/ruby/network/garnet2.0/GarnetLink.hh @@ -44,7 +44,7 @@ #include "params/GarnetExtLink.hh" #include "params/GarnetIntLink.hh" -class GarnetIntLink : public BasicLink +class GarnetIntLink : public BasicIntLink { public: typedef GarnetIntLinkParams Params; @@ -69,7 +69,7 @@ operator<<(std::ostream& out, const GarnetIntLink& obj) return out; } -class GarnetExtLink : public BasicLink +class GarnetExtLink : public BasicExtLink { public: typedef GarnetExtLinkParams Params; -- 2.30.2