diff options
Diffstat (limited to 'configs/ruby/MOESI_CMP_directory.py')
-rw-r--r-- | configs/ruby/MOESI_CMP_directory.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/configs/ruby/MOESI_CMP_directory.py b/configs/ruby/MOESI_CMP_directory.py index b238b7675..dbe814977 100644 --- a/configs/ruby/MOESI_CMP_directory.py +++ b/configs/ruby/MOESI_CMP_directory.py @@ -132,10 +132,9 @@ def create_system(options, system, piobus, dma_ports, ruby_system): l2_cntrl_nodes.append(l2_cntrl) cntrl_count += 1 - - phys_mem_size = 0 - for mem in system.memories.unproxy(system): - phys_mem_size += long(mem.range.second) - long(mem.range.first) + 1 + + phys_mem_size = sum(map(lambda mem: mem.range.size(), + system.memories.unproxy(system))) mem_module_size = phys_mem_size / options.num_dirs for i in xrange(options.num_dirs): |