37#include "debug/GPUSched.hh"
54 stats.numTransActiveIdle = 0;
69 stats.numCyclesWithNoInstrTypeIssued[unitId]++;
73 stats.numCyclesWithInstrTypeIssued[unitId]++;
80 ++
stats.numTransActiveIdle;
94 stats.numCyclesWithInstrIssued++;
96 stats.numCyclesWithNoIssue++;
113 std::string
s(
"INVALID");
131 std::stringstream
ss;
139 Wavefront *wf = gpu_dyn_inst->wavefront();
147 DPRINTF(GPUSched,
"Dispatch List:\n%s",
ss.str());
155 if (debug::GPUSched) {
158 for (
int unitId = 0; unitId <
computeUnit.numExeUnits(); ++unitId) {
170 assert(gpu_dyn_inst);
171 Wavefront *wf = gpu_dyn_inst->wavefront();
172 DPRINTF(GPUSched,
"Exec[%d]: SIMD[%d] WV[%d]: %s\n",
174 gpu_dyn_inst->disassemble());
175 DPRINTF(GPUSched,
"dispatchList[%d] EXREADY->EMPTY\n", unitId);
186 assert(gpu_dyn_inst);
187 Wavefront *wf = gpu_dyn_inst->wavefront();
188 DPRINTF(GPUSched,
"dispatchList[%d] SKIP->EMPTY\n", unitId);
194 panic(
"Unknown dispatch status in exec()\n");
204 "number of CU transitions from active to idle"),
207 "number of cycles the CU issued at least one instruction"),
209 "Execution units active per cycle (Exec unit=SIMD,MemPipe)"),
212 "instruction issued to execution resource type"),
214 " issued to execution resource type")
225 std::string
s =
"VectorALU" + std::to_string(
i);
230 std::string
s =
"ScalarALU" + std::to_string(
i);
const std::string & name() const
bool thisTimeInstExecuted
ScheduleToExecute & fromSchedule
ComputeUnit & computeUnit
int executionResourcesUsed
bool lastTimeInstExecuted
void collectStatistics(enum STAT_STATUS stage, int unitId)
gem5::ExecStage::ExecStageStats stats
std::string dispStatusToStr(int j)
ExecStage(const ComputeUnitParams &p, ComputeUnit &cu, ScheduleToExecute &from_schedule)
Communication interface between Schedule and Execute stages.
std::deque< GPUDynInstPtr > instructionBuffer
#define ADD_STAT(n,...)
Convenience macro to add a stat to a statistics group.
#define panic(...)
This implements a cprintf based panic() function.
Copyright (c) 2024 Arm Limited All rights reserved.
std::shared_ptr< GPUDynInst > GPUDynInstPtr
statistics::Distribution idleDur
statistics::Scalar numCyclesWithInstrIssued
statistics::Distribution spc
statistics::Scalar numCyclesWithNoIssue
statistics::Scalar numTransActiveIdle
statistics::Vector numCyclesWithNoInstrTypeIssued
statistics::Vector numCyclesWithInstrTypeIssued
ExecStageStats(statistics::Group *parent)