Appears in the solution, but isn't mentioned in the lab sheet or handout code (see below).
|
// Ex 1.3, cudaGetDeviceProperties() returns information about the selected cuda device |
|
// See documentation of cudaDeviceProp struct here: https://docs.nvidia.com/cuda/cuda-runtime-api/structcudaDeviceProp.html#structcudaDeviceProp |
|
cudaDeviceProp deviceProp; |
|
cudaGetDeviceProperties(&deviceProp, 0); |
|
theoretical_BW = deviceProp.memoryClockRate * PUMP_RATE * (deviceProp.memoryBusWidth / 8.0) / 1e6; //convert to GB/s |
https://github.com/RSE-Sheffield/COMCUDA_lab_sheets/blob/master/lab05%20-%20CUDA%20Memory.md?plain=1#L35-L43
Pump rate is the number of memory transactions per cycle.
This depends on the type of memory used in the VRAM? (typically 2 for DDR and 4 for GDDR5, GDDR6, and HBM memory)
But isn't available via cudaGetDeviceProperties()?
It really needs to be explained better in the lab sheet if students are expected to recognise it in the solution (two students asked what it was this week)
Appears in the solution, but isn't mentioned in the lab sheet or handout code (see below).
COMCUDA_labs/Lab05_Exercise01/exercise01_sln.cu
Line 10 in d55808c
COMCUDA_labs/Lab05_Exercise01/exercise01_sln.cu
Lines 42 to 46 in d55808c
https://github.com/RSE-Sheffield/COMCUDA_lab_sheets/blob/master/lab05%20-%20CUDA%20Memory.md?plain=1#L35-L43
Pump rate is the number of memory transactions per cycle.
This depends on the type of memory used in the VRAM? (typically 2 for DDR and 4 for GDDR5, GDDR6, and HBM memory)
But isn't available via cudaGetDeviceProperties()?
It really needs to be explained better in the lab sheet if students are expected to recognise it in the solution (two students asked what it was this week)