... | ... | @@ -75,26 +75,26 @@ unset CUDA_VISIBLE_DEVICES |
|
|
```
|
|
|
|
|
|
### Profiling CUDA code ###
|
|
|
Il passe par l'utilisation de l'outil Nvidia Visual Profiler (`nvvp`).
|
|
|
It's done with the use of the Nvidia Visual Profiler (`nvvp`) tool.
|
|
|
|
|
|
![nvvp](/uploads/cbc3413dbb2068feb9058f688f4b6197/Screenshot_from_2016-04-12_16-02-06.png).
|
|
|
|
|
|
### Monitoring ###
|
|
|
Si l'on souhaite une sorte de `top` pour les gpu :
|
|
|
In order to have a sort of `top` for GPUs :
|
|
|
```bash
|
|
|
nvidia-smi --loop=2
|
|
|
```
|
|
|
Pour plus d'informations :
|
|
|
For more informations :
|
|
|
```bash
|
|
|
nvidia-smi -q -d MEMORY,UTILIZATION,TEMPERATURE,POWER,CLOCK,COMPUTE,PIDS,PERFORMANCE -l
|
|
|
```
|
|
|
### Utilisation de OpenCL ###
|
|
|
[OpenCL](https://www.khronos.org/opencl/) est un standard de programmation des architectures GPU s’appuyant sur des extensions de C++.
|
|
|
Pour utiliser OpenCL :
|
|
|
* les fichiers d’include se trouvent dans `/usr/local/cuda/include/CL`, il vous faut donc utiliser `-I/usr/local/cuda/include` à la compilation ;
|
|
|
* la bibliothèque OpenCL se trouve dans `/usr/lib64`, il vous suffit donc de préciser `-lOpenCL` à l’édition de liens.
|
|
|
### Using OpenCL ###
|
|
|
[OpenCL](https://www.khronos.org/opencl/) is a programming standard of GPU architectures based on C++ extensions.
|
|
|
To use OpenCL :
|
|
|
* include files are located at `/usr/local/cuda/include/CL`; one should use `-I/usr/local/cuda/include` option for compiling ;
|
|
|
* the OpenCL library is located at `/usr/lib64`; then just add the `-lOpenCL` option for linking.
|
|
|
|
|
|
### Quelques références sur le web ###
|
|
|
### Some references on the web (mainly in french) ###
|
|
|
* [La lettre IN2P3 informatique](http://informatique.in2p3.fr/li/spip.php?article128)
|
|
|
* http://www.info.univ-angers.fr/~richer/cuda_crs2.php
|
|
|
* http://blogs.msdn.com/b/devpara/archive/2011/11/18/introduction-224-la-programmation-gpu-part-3.aspx
|
... | ... | |