inorder: stall signal handling
remove stall only when necessary add debugging printfs
This commit is contained in:
parent
7695d4c63f
commit
39ac4dce04
|
@ -233,8 +233,21 @@ PipelineStage::checkStall(ThreadID tid) const
|
||||||
void
|
void
|
||||||
PipelineStage::removeStalls(ThreadID tid)
|
PipelineStage::removeStalls(ThreadID tid)
|
||||||
{
|
{
|
||||||
for (int stNum = 0; stNum < NumStages; stNum++) {
|
for (int st_num = 0; st_num < NumStages; st_num++) {
|
||||||
stalls[tid].stage[stNum] = false;
|
if (stalls[tid].stage[st_num] == true) {
|
||||||
|
DPRINTF(InOrderStage, "Removing stall from stage %i.\n", st_num);
|
||||||
|
stalls[tid].stage[st_num] = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (toPrevStages->stageBlock[st_num][tid] == true) {
|
||||||
|
DPRINTF(InOrderStage, "Removing pending block from stage %i.\n", st_num);
|
||||||
|
toPrevStages->stageBlock[st_num][tid] = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (fromNextStages->stageBlock[st_num][tid] == true) {
|
||||||
|
DPRINTF(InOrderStage, "Removing pending block from stage %i.\n", st_num);
|
||||||
|
fromNextStages->stageBlock[st_num][tid] = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
stalls[tid].resources.clear();
|
stalls[tid].resources.clear();
|
||||||
}
|
}
|
||||||
|
@ -626,12 +639,15 @@ PipelineStage::readStallSignals(ThreadID tid)
|
||||||
|
|
||||||
// Check for Stage Blocking Signal
|
// Check for Stage Blocking Signal
|
||||||
if (fromNextStages->stageBlock[stage_idx][tid]) {
|
if (fromNextStages->stageBlock[stage_idx][tid]) {
|
||||||
|
DPRINTF(InOrderStage, "[tid:%i] Stall from stage %i set.\n", tid,
|
||||||
|
stage_idx);
|
||||||
stalls[tid].stage[stage_idx] = true;
|
stalls[tid].stage[stage_idx] = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check for Stage Unblocking Signal
|
// Check for Stage Unblocking Signal
|
||||||
if (fromNextStages->stageUnblock[stage_idx][tid]) {
|
if (fromNextStages->stageUnblock[stage_idx][tid]) {
|
||||||
//assert(fromNextStages->stageBlock[stage_idx][tid]);
|
DPRINTF(InOrderStage, "[tid:%i] Stall from stage %i unset.\n", tid,
|
||||||
|
stage_idx);
|
||||||
stalls[tid].stage[stage_idx] = false;
|
stalls[tid].stage[stage_idx] = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue