From: Korey Sewell Date: Mon, 20 Jun 2011 01:43:42 +0000 (-0400) Subject: inorder:tracing: fix fault tracing bug X-Git-Tag: stable_2012_02_02~210 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=3cb23bd3a21a50577aaaa12db41d2203f4a9d6eb;p=gem5.git inorder:tracing: fix fault tracing bug --- 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; }