summaryrefslogtreecommitdiff
path: root/configs/ruby/Ruby.py
diff options
context:
space:
mode:
authorNilay Vaish <nilay@cs.wisc.edu>2013-03-22 15:53:23 -0500
committerNilay Vaish <nilay@cs.wisc.edu>2013-03-22 15:53:23 -0500
commit5aa43e130acec02bc616008a8758cf5096025c19 (patch)
treef1277ef0002aadfb911f126ec0537afa572f3789 /configs/ruby/Ruby.py
parent2d501276429ab674c146a86802e62538892fc500 (diff)
downloadgem5-5aa43e130acec02bc616008a8758cf5096025c19.tar.xz
ruby: convert Topology to regular class
The Topology class in Ruby does not need to inherit from SimObject class. This patch turns it into a regular class. The topology object is now created in the constructor of the Network class. All the parameters for the topology class have been moved to the network class.
Diffstat (limited to 'configs/ruby/Ruby.py')
-rw-r--r--configs/ruby/Ruby.py13
1 files changed, 3 insertions, 10 deletions
diff --git a/configs/ruby/Ruby.py b/configs/ruby/Ruby.py
index 6859b044e..a11ff53c3 100644
--- a/configs/ruby/Ruby.py
+++ b/configs/ruby/Ruby.py
@@ -142,19 +142,12 @@ def create_system(options, system, piobus = None, dma_ports = []):
# the controllers. Hence the separation between topology definition and
# instantiation.
#
- # gem5 SimObject defined in src/mem/ruby/network/Network.py
- net_topology = Topology()
- net_topology.description = topology.description
routers, int_links, ext_links = topology.makeTopology(options,
IntLinkClass, ExtLinkClass, RouterClass)
-
- net_topology.num_routers = len(routers)
- net_topology.int_links = int_links
- net_topology.ext_links = ext_links
-
- network = NetworkClass(ruby_system = ruby, topology = net_topology,
- routers = routers)
+ network = NetworkClass(ruby_system = ruby, routers = routers,
+ int_links = int_links, ext_links = ext_links,
+ topology = topology.description)
if options.network_fault_model:
assert(options.garnet_network == "fixed")