summaryrefslogtreecommitdiff
path: root/src/mem/ruby
diff options
context:
space:
mode:
authorMatthew Poremba <Matthew.Poremba@amd.com>2016-07-01 10:31:37 -0500
committerMatthew Poremba <Matthew.Poremba@amd.com>2016-07-01 10:31:37 -0500
commit134824e84725fca8d9e46c012e674e551babef28 (patch)
treed1d42a438ae81a12c5dc6839ef53793521137106 /src/mem/ruby
parent86e9a6ffecbeb1ba743c71786e934cf290bab7ff (diff)
downloadgem5-134824e84725fca8d9e46c012e674e551babef28.tar.xz
ruby: Fix double statistic registration in garnet
Currently garnet will not run due to double statistic registration of new stats in ClockedObject. This occurs because a temporary array named 'cls' is being added as a child to garnet internal and external link SimObjects. This patch simply renames the temporary array which prevents it from being added as a child object and avoids the assertion that a statistic was already registered. Committed by Jason Lowe-Power <jason@lowepower.com>
Diffstat (limited to 'src/mem/ruby')
-rw-r--r--src/mem/ruby/network/garnet/fixed-pipeline/GarnetLink_d.py34
1 files changed, 18 insertions, 16 deletions
diff --git a/src/mem/ruby/network/garnet/fixed-pipeline/GarnetLink_d.py b/src/mem/ruby/network/garnet/fixed-pipeline/GarnetLink_d.py
index c7833ee96..5a4f3026e 100644
--- a/src/mem/ruby/network/garnet/fixed-pipeline/GarnetLink_d.py
+++ b/src/mem/ruby/network/garnet/fixed-pipeline/GarnetLink_d.py
@@ -53,19 +53,20 @@ class GarnetIntLink_d(BasicIntLink):
cxx_header = "mem/ruby/network/garnet/fixed-pipeline/GarnetLink_d.hh"
# The detailed fixed pipeline bi-directional link include two main
# forward links and two backward flow-control links, one per direction
- nls = []
+ _nls = []
# In uni-directional link
- nls.append(NetworkLink_d());
+ _nls.append(NetworkLink_d());
# Out uni-directional link
- nls.append(NetworkLink_d());
- network_links = VectorParam.NetworkLink_d(nls, "forward links")
+ _nls.append(NetworkLink_d());
+ network_links = VectorParam.NetworkLink_d(_nls, "forward links")
- cls = []
+ _cls = []
# In uni-directional link
- cls.append(CreditLink_d());
+ _cls.append(CreditLink_d());
# Out uni-directional link
- cls.append(CreditLink_d());
- credit_links = VectorParam.CreditLink_d(cls, "backward flow-control links")
+ _cls.append(CreditLink_d());
+ credit_links = VectorParam.CreditLink_d(_cls,
+ "backward flow-control links")
# Exterior fixed pipeline links between a router and a controller
class GarnetExtLink_d(BasicExtLink):
@@ -73,16 +74,17 @@ class GarnetExtLink_d(BasicExtLink):
cxx_header = "mem/ruby/network/garnet/fixed-pipeline/GarnetLink_d.hh"
# The detailed fixed pipeline bi-directional link include two main
# forward links and two backward flow-control links, one per direction
- nls = []
+ _nls = []
# In uni-directional link
- nls.append(NetworkLink_d());
+ _nls.append(NetworkLink_d());
# Out uni-directional link
- nls.append(NetworkLink_d());
- network_links = VectorParam.NetworkLink_d(nls, "forward links")
+ _nls.append(NetworkLink_d());
+ network_links = VectorParam.NetworkLink_d(_nls, "forward links")
- cls = []
+ _cls = []
# In uni-directional link
- cls.append(CreditLink_d());
+ _cls.append(CreditLink_d());
# Out uni-directional link
- cls.append(CreditLink_d());
- credit_links = VectorParam.CreditLink_d(cls, "backward flow-control links")
+ _cls.append(CreditLink_d());
+ credit_links = VectorParam.CreditLink_d(_cls,
+ "backward flow-control links")