From: Gabe Black Date: Tue, 7 Aug 2007 22:27:54 +0000 (-0700) Subject: Statetrace: Make statetrace do string instructions all at once like m5 does. X-Git-Tag: m5_2.0_beta4~157^2~16 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=e85144bff21445ef19864c38be87055045d95c35;p=gem5.git Statetrace: Make statetrace do string instructions all at once like m5 does. --HG-- extra : convert_revision : 2103029077450e46f70077066708255310963d9d --- diff --git a/util/statetrace/arch/tracechild_amd64.cc b/util/statetrace/arch/tracechild_amd64.cc index 222923972..112ee793e 100644 --- a/util/statetrace/arch/tracechild_amd64.cc +++ b/util/statetrace/arch/tracechild_amd64.cc @@ -317,7 +317,15 @@ bool AMD64TraceChild::step() ptrace(PTRACE_POKEDATA, pid, ripAfterSyscall, buf); } else - ptraceSingleStep(); + { + //Get all the way past repe and repne string instructions in one shot. + uint64_t newPC, origPC = getPC(); + do + { + ptraceSingleStep(); + newPC = getPC(); + } while(newPC == origPC); + } } TraceChild * genTraceChild()