From e0a021005d4765e22b8c026b6a66fda4a0b17c00 Mon Sep 17 00:00:00 2001 From: Korey Sewell Date: Wed, 23 Feb 2011 16:30:45 -0500 Subject: inorder: cache packet handling -use a pointer to CacheReqPacket instead of PacketPtr so correct destructors get called on packet deletion - make sure to delete the packet if the cache blocks the sendTiming request or for some reason we dont use the packet - dont overwrite memory requests since in the worst case an instruction will be replaying a request so no need to keep allocating a new request - we dont use retryPkt so delete it - fetch code was split out already, so just assert that this is a memory reference inst. and that the staticInst is available --- src/cpu/inorder/inorder_dyn_inst.cc | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'src/cpu/inorder/inorder_dyn_inst.cc') diff --git a/src/cpu/inorder/inorder_dyn_inst.cc b/src/cpu/inorder/inorder_dyn_inst.cc index e9deb7625..b1751c0ae 100644 --- a/src/cpu/inorder/inorder_dyn_inst.cc +++ b/src/cpu/inorder/inorder_dyn_inst.cc @@ -195,14 +195,17 @@ InOrderDynInst::~InOrderDynInst() dataMemReq = NULL; } - if (traceData) { - delete traceData; + if (splitMemReq != 0x0) { + delete dataMemReq; + dataMemReq = NULL; } - if (splitMemData) { + if (traceData) + delete traceData; + + if (splitMemData) delete [] splitMemData; - } - + fault = NoFault; --instcount; -- cgit v1.2.3