MOESI_hammer.py (13731:67cd980cb20f) | MOESI_hammer.py (13885:d10ea5e56cb0) |
---|---|
1# Copyright (c) 2006-2007 The Regents of The University of Michigan 2# Copyright (c) 2009 Advanced Micro Devices, Inc. 3# All rights reserved. 4# 5# Redistribution and use in source and binary forms, with or without 6# modification, are permitted provided that the following conditions are 7# met: redistributions of source code must retain the above copyright 8# notice, this list of conditions and the following disclaimer; --- 19 unchanged lines hidden (view full) --- 28# Authors: Brad Beckmann 29 30import math 31import m5 32from m5.objects import * 33from m5.defines import buildEnv 34from Ruby import create_topology, create_directories 35from Ruby import send_evicts | 1# Copyright (c) 2006-2007 The Regents of The University of Michigan 2# Copyright (c) 2009 Advanced Micro Devices, Inc. 3# All rights reserved. 4# 5# Redistribution and use in source and binary forms, with or without 6# modification, are permitted provided that the following conditions are 7# met: redistributions of source code must retain the above copyright 8# notice, this list of conditions and the following disclaimer; --- 19 unchanged lines hidden (view full) --- 28# Authors: Brad Beckmann 29 30import math 31import m5 32from m5.objects import * 33from m5.defines import buildEnv 34from Ruby import create_topology, create_directories 35from Ruby import send_evicts |
36import FileSystemConfig |
|
36 37# 38# Declare caches used by the protocol 39# 40class L1Cache(RubyCache): pass 41class L2Cache(RubyCache): pass 42# 43# Probe filter is a cache --- 206 unchanged lines hidden (view full) --- 250 # Connect the dma controller to the network 251 io_controller.responseFromDir = MessageBuffer(ordered = True) 252 io_controller.responseFromDir.slave = ruby_system.network.master 253 io_controller.requestToDir = MessageBuffer() 254 io_controller.requestToDir.master = ruby_system.network.slave 255 io_controller.mandatoryQueue = MessageBuffer() 256 257 all_cntrls = all_cntrls + [io_controller] | 37 38# 39# Declare caches used by the protocol 40# 41class L1Cache(RubyCache): pass 42class L2Cache(RubyCache): pass 43# 44# Probe filter is a cache --- 206 unchanged lines hidden (view full) --- 251 # Connect the dma controller to the network 252 io_controller.responseFromDir = MessageBuffer(ordered = True) 253 io_controller.responseFromDir.slave = ruby_system.network.master 254 io_controller.requestToDir = MessageBuffer() 255 io_controller.requestToDir.master = ruby_system.network.slave 256 io_controller.mandatoryQueue = MessageBuffer() 257 258 all_cntrls = all_cntrls + [io_controller] |
259 # Register configuration with filesystem 260 else: 261 FileSystemConfig.config_filesystem(options) |
|
258 | 262 |
263 for i in xrange(options.num_cpus): 264 FileSystemConfig.register_cpu(physical_package_id = 0, 265 core_siblings = [], 266 core_id = i, 267 thread_siblings = []) 268 269 FileSystemConfig.register_cache(level = 1, 270 idu_type = 'Instruction', 271 size = options.l1i_size, 272 line_size = options.cacheline_size, 273 assoc = options.l1i_assoc, 274 cpus = [i]) 275 FileSystemConfig.register_cache(level = 1, 276 idu_type = 'Data', 277 size = options.l1d_size, 278 line_size = options.cacheline_size, 279 assoc = options.l1d_assoc, 280 cpus = [i]) 281 282 FileSystemConfig.register_cache(level = 2, 283 idu_type = 'Unified', 284 size = options.l2_size, 285 line_size = options.cacheline_size, 286 assoc = options.l2_assoc, 287 cpus = [i]) 288 |
|
259 ruby_system.network.number_of_virtual_networks = 6 260 topology = create_topology(all_cntrls, options) 261 return (cpu_sequencers, mem_dir_cntrl_nodes, topology) | 289 ruby_system.network.number_of_virtual_networks = 6 290 topology = create_topology(all_cntrls, options) 291 return (cpu_sequencers, mem_dir_cntrl_nodes, topology) |