changeset d61a59beb670 in /z/repo/gem5 details: http://repo.gem5.org/gem5?cmd=changeset;node=d61a59beb670 description: config: ruby: remove piobus from protocols This patch removes the piobus from the protocol config files. The ports are now connected to the piobus in the Ruby.py file.
diffstat: configs/ruby/MESI_Three_Level.py | 7 +------ configs/ruby/MESI_Two_Level.py | 8 +------- configs/ruby/MI_example.py | 9 ++------- configs/ruby/MOESI_CMP_directory.py | 9 ++------- configs/ruby/MOESI_CMP_token.py | 9 ++------- configs/ruby/MOESI_hammer.py | 8 +------- configs/ruby/Network_test.py | 3 +-- configs/ruby/Ruby.py | 12 +++++++++++- 8 files changed, 21 insertions(+), 44 deletions(-) diffs (204 lines): diff -r 0e0a0dd558db -r d61a59beb670 configs/ruby/MESI_Three_Level.py --- a/configs/ruby/MESI_Three_Level.py Mon Mar 17 17:40:14 2014 -0500 +++ b/configs/ruby/MESI_Three_Level.py Mon Mar 17 17:40:15 2014 -0500 @@ -56,7 +56,7 @@ caches private to clusters") return -def create_system(options, system, piobus, dma_ports, ruby_system): +def create_system(options, system, dma_ports, ruby_system): if buildEnv['PROTOCOL'] != 'MESI_Three_Level': fatal("This script requires the MESI_Three_Level protocol to be built.") @@ -116,11 +116,6 @@ cache = l1_cache, l2_select_num_bits = l2_bits, cluster_id = i, ruby_system = ruby_system) - if piobus != None: - cpu_seq.pio_master_port = piobus.slave - cpu_seq.mem_master_port = piobus.slave - cpu_seq.pio_slave_port = piobus.master - exec("ruby_system.l0_cntrl%d = l0_cntrl" % ( i*num_cpus_per_cluster+j)) exec("ruby_system.l1_cntrl%d = l1_cntrl" % ( diff -r 0e0a0dd558db -r d61a59beb670 configs/ruby/MESI_Two_Level.py --- a/configs/ruby/MESI_Two_Level.py Mon Mar 17 17:40:14 2014 -0500 +++ b/configs/ruby/MESI_Two_Level.py Mon Mar 17 17:40:15 2014 -0500 @@ -48,7 +48,7 @@ def define_options(parser): return -def create_system(options, system, piobus, dma_ports, ruby_system): +def create_system(options, system, dma_ports, ruby_system): if buildEnv['PROTOCOL'] != 'MESI_Two_Level': fatal("This script requires the MESI_Two_Level protocol to be built.") @@ -104,12 +104,6 @@ ruby_system = ruby_system) l1_cntrl.sequencer = cpu_seq - - if piobus != None: - cpu_seq.pio_master_port = piobus.slave - cpu_seq.mem_master_port = piobus.slave - cpu_seq.pio_slave_port = piobus.master - exec("ruby_system.l1_cntrl%d = l1_cntrl" % i) # diff -r 0e0a0dd558db -r d61a59beb670 configs/ruby/MI_example.py --- a/configs/ruby/MI_example.py Mon Mar 17 17:40:14 2014 -0500 +++ b/configs/ruby/MI_example.py Mon Mar 17 17:40:15 2014 -0500 @@ -42,7 +42,7 @@ def define_options(parser): return -def create_system(options, system, piobus, dma_ports, ruby_system): +def create_system(options, system, dma_ports, ruby_system): if buildEnv['PROTOCOL'] != 'MI_example': panic("This script requires the MI_example protocol to be built.") @@ -90,13 +90,8 @@ ruby_system = ruby_system) l1_cntrl.sequencer = cpu_seq + exec("ruby_system.l1_cntrl%d = l1_cntrl" % i) - if piobus != None: - cpu_seq.pio_master_port = piobus.slave - cpu_seq.mem_master_port = piobus.slave - cpu_seq.pio_slave_port = piobus.master - - exec("ruby_system.l1_cntrl%d = l1_cntrl" % i) # # Add controllers and sequencers to the appropriate lists # diff -r 0e0a0dd558db -r d61a59beb670 configs/ruby/MOESI_CMP_directory.py --- a/configs/ruby/MOESI_CMP_directory.py Mon Mar 17 17:40:14 2014 -0500 +++ b/configs/ruby/MOESI_CMP_directory.py Mon Mar 17 17:40:15 2014 -0500 @@ -48,7 +48,7 @@ def define_options(parser): return -def create_system(options, system, piobus, dma_ports, ruby_system): +def create_system(options, system, dma_ports, ruby_system): if buildEnv['PROTOCOL'] != 'MOESI_CMP_directory': panic("This script requires the MOESI_CMP_directory protocol to be built.") @@ -100,13 +100,8 @@ ruby_system = ruby_system) l1_cntrl.sequencer = cpu_seq + exec("ruby_system.l1_cntrl%d = l1_cntrl" % i) - if piobus != None: - cpu_seq.pio_master_port = piobus.slave - cpu_seq.mem_master_port = piobus.slave - cpu_seq.pio_slave_port = piobus.master - - exec("ruby_system.l1_cntrl%d = l1_cntrl" % i) # # Add controllers and sequencers to the appropriate lists # diff -r 0e0a0dd558db -r d61a59beb670 configs/ruby/MOESI_CMP_token.py --- a/configs/ruby/MOESI_CMP_token.py Mon Mar 17 17:40:14 2014 -0500 +++ b/configs/ruby/MOESI_CMP_token.py Mon Mar 17 17:40:15 2014 -0500 @@ -55,7 +55,7 @@ parser.add_option("--allow-atomic-migration", action="store_true", help="allow migratory sharing for atomic only accessed blocks") -def create_system(options, system, piobus, dma_ports, ruby_system): +def create_system(options, system, dma_ports, ruby_system): if buildEnv['PROTOCOL'] != 'MOESI_CMP_token': panic("This script requires the MOESI_CMP_token protocol to be built.") @@ -120,13 +120,8 @@ ruby_system = ruby_system) l1_cntrl.sequencer = cpu_seq + exec("ruby_system.l1_cntrl%d = l1_cntrl" % i) - if piobus != None: - cpu_seq.pio_master_port = piobus.slave - cpu_seq.mem_master_port = piobus.slave - cpu_seq.pio_slave_port = piobus.master - - exec("ruby_system.l1_cntrl%d = l1_cntrl" % i) # # Add controllers and sequencers to the appropriate lists # diff -r 0e0a0dd558db -r d61a59beb670 configs/ruby/MOESI_hammer.py --- a/configs/ruby/MOESI_hammer.py Mon Mar 17 17:40:14 2014 -0500 +++ b/configs/ruby/MOESI_hammer.py Mon Mar 17 17:40:15 2014 -0500 @@ -59,7 +59,7 @@ parser.add_option("--dir-on", action="store_true", help="Hammer: enable Full-bit Directory") -def create_system(options, system, piobus, dma_ports, ruby_system): +def create_system(options, system, dma_ports, ruby_system): if buildEnv['PROTOCOL'] != 'MOESI_hammer': panic("This script requires the MOESI_hammer protocol to be built.") @@ -113,12 +113,6 @@ ruby_system = ruby_system) l1_cntrl.sequencer = cpu_seq - - if piobus != None: - cpu_seq.pio_master_port = piobus.slave - cpu_seq.mem_master_port = piobus.slave - cpu_seq.pio_slave_port = piobus.master - if options.recycle_latency: l1_cntrl.recycle_latency = options.recycle_latency diff -r 0e0a0dd558db -r d61a59beb670 configs/ruby/Network_test.py --- a/configs/ruby/Network_test.py Mon Mar 17 17:40:14 2014 -0500 +++ b/configs/ruby/Network_test.py Mon Mar 17 17:40:15 2014 -0500 @@ -42,7 +42,7 @@ def define_options(parser): return -def create_system(options, system, piobus, dma_ports, ruby_system): +def create_system(options, system, dma_ports, ruby_system): if buildEnv['PROTOCOL'] != 'Network_test': panic("This script requires the Network_test protocol to be built.") @@ -52,7 +52,6 @@ # # The Garnet tester protocol does not support fs nor dma # - assert(piobus == None) assert(dma_ports == []) # diff -r 0e0a0dd558db -r d61a59beb670 configs/ruby/Ruby.py --- a/configs/ruby/Ruby.py Mon Mar 17 17:40:14 2014 -0500 +++ b/configs/ruby/Ruby.py Mon Mar 17 17:40:15 2014 -0500 @@ -107,7 +107,7 @@ exec "import %s" % protocol try: (cpu_sequencers, dir_cntrls, topology) = \ - eval("%s.create_system(options, system, piobus, dma_ports, ruby)" + eval("%s.create_system(options, system, dma_ports, ruby)" % protocol) except: print "Error: could not create sytem for ruby protocol %s" % protocol @@ -187,6 +187,16 @@ ruby.network = network ruby.mem_size = total_mem_size + + # Connect the cpu sequencers and the piobus + if piobus != None: + for cpu_seq in cpu_sequencers: + cpu_seq.pio_master_port = piobus.slave + cpu_seq.mem_master_port = piobus.slave + + if buildEnv['TARGET_ISA'] == "x86": + cpu_seq.pio_slave_port = piobus.master + ruby._cpu_ruby_ports = cpu_sequencers ruby.num_of_sequencers = len(cpu_sequencers) ruby.random_seed = options.random_seed _______________________________________________ gem5-dev mailing list gem5-dev@gem5.org http://m5sim.org/mailman/listinfo/gem5-dev