Represents a microGPUThe MicroGPU class encapsulates the state and behavior of a microGPU, which consists of multiple compute units (CUs) that execute warps of threads. In this project miroGPU has 16 compute units, each capable of executing one warp at a time. MicroGPU schedules warps from its global warp collection to the compute units and then Compute Units execute the warps in a simple round-robin fashion.
More...
#include <ugpu.hh>
Represents a microGPU
The MicroGPU class encapsulates the state and behavior of a microGPU, which consists of multiple compute units (CUs) that execute warps of threads. In this project miroGPU has 16 compute units, each capable of executing one warp at a time. MicroGPU schedules warps from its global warp collection to the compute units and then Compute Units execute the warps in a simple round-robin fashion.
◆ MicroGPU()
◆ addWarpToGlobalCollection()
| void MicroGPU::addWarpToGlobalCollection |
( |
const Warp & |
warp | ) |
|
Add a warp to the global warp collection.
- Parameters
-
| warp | The warp to be added to the global collection |
◆ allComputeUnitsDone()
| bool MicroGPU::allComputeUnitsDone |
( |
| ) |
const |
◆ allWarpsCompleted()
| bool MicroGPU::allWarpsCompleted |
( |
| ) |
const |
◆ assignWarpToSM()
| void MicroGPU::assignWarpToSM |
( |
int |
smId, |
|
|
const Warp & |
warp |
|
) |
| |
◆ createGlobalWarpCollectionTest()
| void MicroGPU::createGlobalWarpCollectionTest |
( |
| ) |
|
Create a Global Warp Collection Test object This method creates a set of test warps with simple instructions and adds them to the global warp collection for testing purposes. Each warp is initialized with a simple ADD instruction and all threads in the warp are set to active. Additionally, one warp with a branch instruction is added to test divergence handling in the compute units.
◆ executeComputeUnits()
| void MicroGPU::executeComputeUnits |
( |
| ) |
|
Execute all compute units for one cycle.
◆ executeGPU()
| void MicroGPU::executeGPU |
( |
| ) |
|
Execute the entire GPU until all warps are completed.
◆ getCurrentCycle()
| int MicroGPU::getCurrentCycle |
( |
| ) |
const |
|
inline |
◆ getGlobalWarpCollectionSize()
| int MicroGPU::getGlobalWarpCollectionSize |
( |
| ) |
const |
◆ incrementCycle()
| void MicroGPU::incrementCycle |
( |
| ) |
|
|
inline |
◆ init()
◆ performWarpScheduling()
| void MicroGPU::performWarpScheduling |
( |
| ) |
|
◆ performWarpSchedulingSimple()
| void MicroGPU::performWarpSchedulingSimple |
( |
| ) |
|
Perform simple warp scheduling This function assigns alternating warps from the global collection to the first two compute units in a round-robin fashion. Just for testing purposes to verify that warps are being scheduled and executed correctly. In real life, all Compute Units would be utilized.
◆ printComputeUnitStatus()
| void MicroGPU::printComputeUnitStatus |
( |
| ) |
const |
◆ setMaxCycles()
| void MicroGPU::setMaxCycles |
( |
int |
cycles | ) |
|
|
inline |
◆ computeUnit
◆ currentCycle
| int MicroGPU::currentCycle |
|
private |
◆ globalWarpCollection
| std::vector<Warp> MicroGPU::globalWarpCollection |
|
private |
◆ maxCycles
The documentation for this class was generated from the following files: