diff options
author | Nilay Vaish <nilay@cs.wisc.edu> | 2013-06-28 21:36:11 -0500 |
---|---|---|
committer | Nilay Vaish <nilay@cs.wisc.edu> | 2013-06-28 21:36:11 -0500 |
commit | 62a93f0bf03385c5ed298b740162b06022f2e2ee (patch) | |
tree | 43bde41c745f95c98f37ed7d64a55bb58f27b3ae /configs/ruby | |
parent | 5a15909bac241dc795c691d49c4e2c68cab745f4 (diff) | |
download | gem5-62a93f0bf03385c5ed298b740162b06022f2e2ee.tar.xz |
ruby: check for compatibility between mem size and num dirs
The configuration scripts provided for ruby assume that the available
physical memory is equally distributed amongst the directory controllers.
But there is no check to ensure this assumption has been adhered to. This
patch adds the required check.
Diffstat (limited to 'configs/ruby')
-rw-r--r-- | configs/ruby/MESI_CMP_directory.py | 1 | ||||
-rw-r--r-- | configs/ruby/MI_example.py | 1 | ||||
-rw-r--r-- | configs/ruby/MOESI_CMP_directory.py | 1 | ||||
-rw-r--r-- | configs/ruby/MOESI_CMP_token.py | 1 | ||||
-rw-r--r-- | configs/ruby/MOESI_hammer.py | 1 | ||||
-rw-r--r-- | configs/ruby/Network_test.py | 1 |
6 files changed, 6 insertions, 0 deletions
diff --git a/configs/ruby/MESI_CMP_directory.py b/configs/ruby/MESI_CMP_directory.py index 4128f87ad..e263b4e5a 100644 --- a/configs/ruby/MESI_CMP_directory.py +++ b/configs/ruby/MESI_CMP_directory.py @@ -142,6 +142,7 @@ def create_system(options, system, piobus, dma_ports, ruby_system): phys_mem_size = sum(map(lambda mem: mem.range.size(), system.memories.unproxy(system))) + assert(phys_mem_size % options.num_dirs == 0) mem_module_size = phys_mem_size / options.num_dirs # Run each of the ruby memory controllers at a ratio of the frequency of diff --git a/configs/ruby/MI_example.py b/configs/ruby/MI_example.py index 6bbd35ea7..896a01a61 100644 --- a/configs/ruby/MI_example.py +++ b/configs/ruby/MI_example.py @@ -107,6 +107,7 @@ def create_system(options, system, piobus, dma_ports, ruby_system): phys_mem_size = sum(map(lambda mem: mem.range.size(), system.memories.unproxy(system))) + assert(phys_mem_size % options.num_dirs == 0) mem_module_size = phys_mem_size / options.num_dirs # Run each of the ruby memory controllers at a ratio of the frequency of diff --git a/configs/ruby/MOESI_CMP_directory.py b/configs/ruby/MOESI_CMP_directory.py index 81d04914c..bc1f7d641 100644 --- a/configs/ruby/MOESI_CMP_directory.py +++ b/configs/ruby/MOESI_CMP_directory.py @@ -137,6 +137,7 @@ def create_system(options, system, piobus, dma_ports, ruby_system): phys_mem_size = sum(map(lambda mem: mem.range.size(), system.memories.unproxy(system))) + assert(phys_mem_size % options.num_dirs == 0) mem_module_size = phys_mem_size / options.num_dirs # Run each of the ruby memory controllers at a ratio of the frequency of diff --git a/configs/ruby/MOESI_CMP_token.py b/configs/ruby/MOESI_CMP_token.py index 9c2598a1d..4ede788a8 100644 --- a/configs/ruby/MOESI_CMP_token.py +++ b/configs/ruby/MOESI_CMP_token.py @@ -158,6 +158,7 @@ def create_system(options, system, piobus, dma_ports, ruby_system): phys_mem_size = sum(map(lambda mem: mem.range.size(), system.memories.unproxy(system))) + assert(phys_mem_size % options.num_dirs == 0) mem_module_size = phys_mem_size / options.num_dirs # Run each of the ruby memory controllers at a ratio of the frequency of diff --git a/configs/ruby/MOESI_hammer.py b/configs/ruby/MOESI_hammer.py index 11ea579ea..da8b004ee 100644 --- a/configs/ruby/MOESI_hammer.py +++ b/configs/ruby/MOESI_hammer.py @@ -133,6 +133,7 @@ def create_system(options, system, piobus, dma_ports, ruby_system): phys_mem_size = sum(map(lambda mem: mem.range.size(), system.memories.unproxy(system))) + assert(phys_mem_size % options.num_dirs == 0) mem_module_size = phys_mem_size / options.num_dirs # diff --git a/configs/ruby/Network_test.py b/configs/ruby/Network_test.py index c4df4dddb..d7b04cd31 100644 --- a/configs/ruby/Network_test.py +++ b/configs/ruby/Network_test.py @@ -105,6 +105,7 @@ def create_system(options, system, piobus, dma_ports, ruby_system): phys_mem_size = sum(map(lambda mem: mem.range.size(), system.memories.unproxy(system))) + assert(phys_mem_size % options.num_dirs == 0) mem_module_size = phys_mem_size / options.num_dirs # Run each of the ruby memory controllers at a ratio of the frequency of |