You must use --gres=gpu:2 to tell the job to use the node's GPUs.
We will also use NVprof, NVIDIA's built-in profiler. It will show you that your code is running on the GPU and also give you performance information about the code.
To use nvprof issue:
```
mpirun nvprof ./vecAdd.o
```
### Challenge 2 Submit a GPU Job with SLRUM
...
...
@@ -157,8 +151,7 @@ vi gpu.sbatch and fill in the missing parts of the script as described below.
module purge
module load pgi/19.4
mpirun nvprof ./vecAdd.o
./vecAdd.o
```
When you code runs open your output files and see if the code ran on the GPU.
How long did it spend copying data to the GPU?
When you code runs open your output files and see if the vectors summed to 1.0.