From 3cb23bd3a21a50577aaaa12db41d2203f4a9d6eb Mon Sep 17 00:00:00 2001 From: Korey Sewell Date: Sun, 19 Jun 2011 21:43:42 -0400 Subject: [PATCH] inorder:tracing: fix fault tracing bug --- src/cpu/inorder/resource.cc | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/cpu/inorder/resource.cc b/src/cpu/inorder/resource.cc index 8bc355f5c..dfca83a8f 100644 --- a/src/cpu/inorder/resource.cc +++ b/src/cpu/inorder/resource.cc @@ -348,10 +348,14 @@ Resource::squashThenTrap(int stage_num, DynInstPtr inst) inst->setSquashInfo(stage_num); setupSquash(inst, stage_num, tid); - if (inst->traceData && DTRACE(ExecFaulting)) { - inst->traceData->setStageCycle(stage_num, curTick()); - inst->traceData->setFetchSeq(inst->seqNum); - inst->traceData->dump(); + if (inst->traceData) { + if (inst->staticInst && + inst->fault != NoFault && DTRACE(ExecFaulting)) { + inst->traceData->setStageCycle(stage_num, curTick()); + inst->traceData->setFetchSeq(inst->seqNum); + inst->traceData->dump(); + } + delete inst->traceData; inst->traceData = NULL; } -- 2.30.2