MOESI_CMP_directory.py (9694:692776126391) MOESI_CMP_directory.py (9793:6e6cefc1db1f)
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;

--- 125 unchanged lines hidden (view full) ---

134 l2_cntrl_nodes.append(l2_cntrl)
135
136 cntrl_count += 1
137
138 phys_mem_size = sum(map(lambda mem: mem.range.size(),
139 system.memories.unproxy(system)))
140 mem_module_size = phys_mem_size / options.num_dirs
141
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;

--- 125 unchanged lines hidden (view full) ---

134 l2_cntrl_nodes.append(l2_cntrl)
135
136 cntrl_count += 1
137
138 phys_mem_size = sum(map(lambda mem: mem.range.size(),
139 system.memories.unproxy(system)))
140 mem_module_size = phys_mem_size / options.num_dirs
141
142 # Run each of the ruby memory controllers at a ratio of the frequency of
143 # the ruby system.
144 # clk_divider value is a fix to pass regression.
145 ruby_system.memctrl_clk_domain = DerivedClockDomain(
146 clk_domain=ruby_system.clk_domain,
147 clk_divider=3)
148
142 for i in xrange(options.num_dirs):
143 #
144 # Create the Ruby objects associated with the directory controller
145 #
146
149 for i in xrange(options.num_dirs):
150 #
151 # Create the Ruby objects associated with the directory controller
152 #
153
147 mem_cntrl = RubyMemoryControl(version = i,
148 ruby_system = ruby_system)
154 mem_cntrl = RubyMemoryControl(
155 clk_domain = ruby_system.memctrl_clk_domain,
156 version = i,
157 ruby_system = ruby_system)
149
150 dir_size = MemorySize('0B')
151 dir_size.value = mem_module_size
152
153 dir_cntrl = Directory_Controller(version = i,
154 cntrl_id = cntrl_count,
155 directory = \
156 RubyDirectoryMemory(version = i,

--- 35 unchanged lines hidden ---
158
159 dir_size = MemorySize('0B')
160 dir_size.value = mem_module_size
161
162 dir_cntrl = Directory_Controller(version = i,
163 cntrl_id = cntrl_count,
164 directory = \
165 RubyDirectoryMemory(version = i,

--- 35 unchanged lines hidden ---