summaryrefslogtreecommitdiff
path: root/src/mem
diff options
context:
space:
mode:
authorAndreas Hansson <andreas.hansson@arm.com>2013-03-18 05:22:45 -0400
committerAndreas Hansson <andreas.hansson@arm.com>2013-03-18 05:22:45 -0400
commitc01c5e971b020f106fa528bc2e41d4d3bd2cf640 (patch)
treec95785b1318305f3599317d4042e4794205488bf /src/mem
parentdc37b034391ab7f65c19641bbae477ba7ede2eb1 (diff)
downloadgem5-c01c5e971b020f106fa528bc2e41d4d3bd2cf640.tar.xz
mem: Fix missing delete of packet in DRAM access
This patch fixes a memory leak caused by not deleting packets that require no response.
Diffstat (limited to 'src/mem')
-rw-r--r--src/mem/simple_dram.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mem/simple_dram.cc b/src/mem/simple_dram.cc
index 90517ec62..0b24b4056 100644
--- a/src/mem/simple_dram.cc
+++ b/src/mem/simple_dram.cc
@@ -739,6 +739,9 @@ SimpleDRAM::accessAndRespond(PacketPtr pkt)
// next tick
port.schedTimingResp(pkt, curTick() + 1);
} else {
+ // @todo the packet is going to be deleted, and the DRAMPacket
+ // is still having a pointer to it
+ pendingDelete.push_back(pkt);
}
DPRINTF(DRAM, "Done\n");