summaryrefslogtreecommitdiff
path: root/src/mem/port.cc
diff options
context:
space:
mode:
authorAli Saidi <saidi@eecs.umich.edu>2007-04-04 13:56:38 -0400
committerAli Saidi <saidi@eecs.umich.edu>2007-04-04 13:56:38 -0400
commitd0ea8ff08849f45196fa6c8d69d5a408d9cbbafd (patch)
tree5fba9c44fb5e1072524963b82aabf0ef1cd51632 /src/mem/port.cc
parentc46e946c94cf730bd2c22de27d3af43955b63ba9 (diff)
downloadgem5-d0ea8ff08849f45196fa6c8d69d5a408d9cbbafd.tar.xz
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
Diffstat (limited to 'src/mem/port.cc')
-rw-r--r--src/mem/port.cc1
1 files changed, 0 insertions, 1 deletions
diff --git a/src/mem/port.cc b/src/mem/port.cc
index e75e50e4d..e6ea773f2 100644
--- a/src/mem/port.cc
+++ b/src/mem/port.cc
@@ -51,7 +51,6 @@ Port::removeConn()
{
if (peer->getOwner())
peer->getOwner()->deletePortRefs(peer);
- delete peer;
peer = NULL;
}