MESI_Three_Level.py (10311:ad9c042dce54) | MESI_Three_Level.py (10519:7a3ad4b09ce4) |
---|---|
1# Copyright (c) 2006-2007 The Regents of The University of Michigan 2# Copyright (c) 2009 Advanced Micro Devices, Inc. 3# Copyright (c) 2013 Mark D. Hill and David A. Wood 4# All rights reserved. 5# 6# Redistribution and use in source and binary forms, with or without 7# modification, are permitted provided that the following conditions are 8# met: redistributions of source code must retain the above copyright --- 42 unchanged lines hidden (view full) --- 51 latency = 15 52 53def define_options(parser): 54 parser.add_option("--num-clusters", type="int", default=1, 55 help="number of clusters in a design in which there are shared\ 56 caches private to clusters") 57 return 58 | 1# Copyright (c) 2006-2007 The Regents of The University of Michigan 2# Copyright (c) 2009 Advanced Micro Devices, Inc. 3# Copyright (c) 2013 Mark D. Hill and David A. Wood 4# All rights reserved. 5# 6# Redistribution and use in source and binary forms, with or without 7# modification, are permitted provided that the following conditions are 8# met: redistributions of source code must retain the above copyright --- 42 unchanged lines hidden (view full) --- 51 latency = 15 52 53def define_options(parser): 54 parser.add_option("--num-clusters", type="int", default=1, 55 help="number of clusters in a design in which there are shared\ 56 caches private to clusters") 57 return 58 |
59def create_system(options, system, dma_ports, ruby_system): | 59def create_system(options, full_system, system, dma_ports, ruby_system): |
60 61 if buildEnv['PROTOCOL'] != 'MESI_Three_Level': 62 fatal("This script requires the MESI_Three_Level protocol to be built.") 63 64 cpu_sequencers = [] 65 66 # 67 # The ruby network creation expects the list of nodes in the system to be --- 158 unchanged lines hidden (view full) --- 226 dma_cntrl_nodes.append(dma_cntrl) 227 228 all_cntrls = l0_cntrl_nodes + \ 229 l1_cntrl_nodes + \ 230 l2_cntrl_nodes + \ 231 dir_cntrl_nodes + \ 232 dma_cntrl_nodes 233 | 60 61 if buildEnv['PROTOCOL'] != 'MESI_Three_Level': 62 fatal("This script requires the MESI_Three_Level protocol to be built.") 63 64 cpu_sequencers = [] 65 66 # 67 # The ruby network creation expects the list of nodes in the system to be --- 158 unchanged lines hidden (view full) --- 226 dma_cntrl_nodes.append(dma_cntrl) 227 228 all_cntrls = l0_cntrl_nodes + \ 229 l1_cntrl_nodes + \ 230 l2_cntrl_nodes + \ 231 dir_cntrl_nodes + \ 232 dma_cntrl_nodes 233 |
234 # Create the io controller and the sequencer 235 if full_system: 236 io_seq = DMASequencer(version=len(dma_ports), ruby_system=ruby_system) 237 ruby_system._io_port = io_seq 238 io_controller = DMA_Controller(version = len(dma_ports), 239 dma_sequencer = io_seq, 240 ruby_system = ruby_system) 241 ruby_system.io_controller = io_controller 242 243 # Connect the dma controller to the network 244 io_controller.responseFromDir = ruby_system.network.master 245 io_controller.requestToDir = ruby_system.network.slave 246 247 all_cntrls = all_cntrls + [io_controller] 248 |
|
234 topology = create_topology(all_cntrls, options) 235 return (cpu_sequencers, dir_cntrl_nodes, topology) | 249 topology = create_topology(all_cntrls, options) 250 return (cpu_sequencers, dir_cntrl_nodes, topology) |