mem: fix bug in 3-level cache (#265)
The L3 cache did not work due to argument type mismatch in the call to the constructor `DMAController`. The second argument is expecting a `RubySystem` type but the code passes in a `cache_line_size` variable. After I change the second argument to `self.ruby_system` everything works.
This commit is contained in:
@@ -193,10 +193,10 @@ class MESIThreeLevelCacheHierarchy(
|
||||
if board.has_dma_ports():
|
||||
dma_ports = board.get_dma_ports()
|
||||
for i, port in enumerate(dma_ports):
|
||||
ctrl = DMAController(self.ruby_system.network, cache_line_size)
|
||||
ctrl.dma_sequencer = DMASequencer(version=i, in_ports=port)
|
||||
ctrl = DMAController(
|
||||
DMASequencer(version=i, in_ports=port), self.ruby_system
|
||||
)
|
||||
self._dma_controllers.append(ctrl)
|
||||
ctrl.ruby_system = self.ruby_system
|
||||
|
||||
self.ruby_system.num_of_sequencers = len(self._l1_controllers) + len(
|
||||
self._dma_controllers
|
||||
|
||||
Reference in New Issue
Block a user