The MemoryObject tha owns a port should delete it if it so chooses when deletePortRefs() is called on it with that port as a parameter.
In this way a MemoryObject can keep a functional port around and give it to anyone who wants to do functional accesses rather
than creating a new one each time.
src/mem/bus.cc:
src/mem/bus.hh:
src/mem/cache/cache_impl.hh:
only keep around one func port we give to anyone who wants it. Otherwise we can run out of port ids reasonably quickly if
a lot of functional accesses are happening (e.g. remote debugging, dprintk, etc)
--HG--
extra : convert_revision : 6a9e3e96f51cedaab6de1b36cf317203899a3716
This commit is contained in:
3
src/mem/cache/cache_impl.hh
vendored
3
src/mem/cache/cache_impl.hh
vendored
@@ -1183,7 +1183,8 @@ Cache<TagStore,Coherence>::deletePortRefs(Port *p)
|
||||
{
|
||||
if (cpuSidePort == p || memSidePort == p)
|
||||
panic("Can only delete functional ports\n");
|
||||
// nothing else to do
|
||||
|
||||
delete p;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user