DPRINTF(IEW, "[tid:%i]: Squashing from a specific instruction, PC: %s "
"[sn:%i].\n", tid, inst->pcState(), inst->seqNum);
- toCommit->squash[tid] = true;
- toCommit->squashedSeqNum[tid] = inst->seqNum;
- toCommit->mispredPC[tid] = inst->instAddr();
- toCommit->branchMispredict[tid] = true;
- toCommit->mispredictInst[tid] = inst;
+ if (toCommit->squash[tid] == false ||
+ inst->seqNum < toCommit->squashedSeqNum[tid]) {
+ toCommit->squash[tid] = true;
+ toCommit->squashedSeqNum[tid] = inst->seqNum;
+ toCommit->mispredPC[tid] = inst->instAddr();
+ toCommit->branchMispredict[tid] = true;
+ toCommit->branchTaken[tid] = inst->pcState().branching();
- toCommit->branchTaken[tid] = inst->pcState().branching();
- TheISA::PCState pc = inst->pcState();
- TheISA::advancePC(pc, inst->staticInst);
- toCommit->pc[tid] = pc;
+ TheISA::PCState pc = inst->pcState();
+ TheISA::advancePC(pc, inst->staticInst);
- toCommit->includeSquashInst[tid] = false;
+ toCommit->pc[tid] = pc;
+ toCommit->mispredictInst[tid] = inst;
+ toCommit->includeSquashInst[tid] = false;
+
+ wroteToTimeBuffer = true;
+ }
- wroteToTimeBuffer = true;
}
template<class Impl>
DPRINTF(IEW, "[tid:%i]: Squashing from a specific instruction, "
"PC: %s [sn:%i].\n", tid, inst->pcState(), inst->seqNum);
- toCommit->squash[tid] = true;
- toCommit->squashedSeqNum[tid] = inst->seqNum;
- TheISA::PCState pc = inst->pcState();
- TheISA::advancePC(pc, inst->staticInst);
- toCommit->pc[tid] = pc;
- toCommit->branchMispredict[tid] = false;
+ if (toCommit->squash[tid] == false ||
+ inst->seqNum < toCommit->squashedSeqNum[tid]) {
+ toCommit->squash[tid] = true;
+ toCommit->squashedSeqNum[tid] = inst->seqNum;
+ TheISA::PCState pc = inst->pcState();
+ TheISA::advancePC(pc, inst->staticInst);
+ toCommit->pc[tid] = pc;
+ toCommit->branchMispredict[tid] = false;
- toCommit->includeSquashInst[tid] = false;
+ toCommit->includeSquashInst[tid] = false;
- wroteToTimeBuffer = true;
+ wroteToTimeBuffer = true;
+ }
}
template<class Impl>
{
DPRINTF(IEW, "[tid:%i]: Memory blocked, squashing load and younger insts, "
"PC: %s [sn:%i].\n", tid, inst->pcState(), inst->seqNum);
+ if (toCommit->squash[tid] == false ||
+ inst->seqNum < toCommit->squashedSeqNum[tid]) {
+ toCommit->squash[tid] = true;
- toCommit->squash[tid] = true;
- toCommit->squashedSeqNum[tid] = inst->seqNum;
- toCommit->pc[tid] = inst->pcState();
- toCommit->branchMispredict[tid] = false;
+ toCommit->squashedSeqNum[tid] = inst->seqNum;
+ toCommit->pc[tid] = inst->pcState();
+ toCommit->branchMispredict[tid] = false;
- // Must include the broadcasted SN in the squash.
- toCommit->includeSquashInst[tid] = true;
+ // Must include the broadcasted SN in the squash.
+ toCommit->includeSquashInst[tid] = true;
- ldstQueue.setLoadBlockedHandled(tid);
+ ldstQueue.setLoadBlockedHandled(tid);
- wroteToTimeBuffer = true;
+ wroteToTimeBuffer = true;
+ }
}
template<class Impl>
}
dispatchStatus[tid] = Squashing;
-
fetchRedirect[tid] = false;
return;
}
DPRINTF(IEW, "[tid:%i]: ROB is still squashing.\n", tid);
dispatchStatus[tid] = Squashing;
-
emptyRenameInsts(tid);
wroteToTimeBuffer = true;
return;
ThreadID tid = inst->threadNumber;
if (!fetchRedirect[tid] ||
+ !toCommit->squash[tid] ||
toCommit->squashedSeqNum[tid] > inst->seqNum) {
if (inst->mispredicted()) {
// iew queue. That way the writeback event will write into the correct
// spot in the queue.
wbNumInst = 0;
+
}
template <class Impl>
ThreadID tid = inst->threadNumber;
if (!fetchRedirect[tid] ||
+ !toCommit->squash[tid] ||
toCommit->squashedSeqNum[tid] > inst->seqNum) {
if (inst->mispredicted()) {