| ... | @@ -15,6 +15,7 @@ title: Profilage de Code |
... | @@ -15,6 +15,7 @@ title: Profilage de Code |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Code profilers
|
|
# Code profilers
|
|
|
|
|
|
|
|
In this Wiki, we will provide a methodology to install and run some code profilers. This has been tested on a specific Conda environment.
|
|
In this Wiki, we will provide a methodology to install and run some code profilers. This has been tested on a specific Conda environment.
|
| ... | @@ -65,6 +66,16 @@ export PATH=$PROFILER_PATH/bin:$PATH |
... | @@ -65,6 +66,16 @@ export PATH=$PROFILER_PATH/bin:$PATH |
|
|
export PATH=$PROFILER_PATH/x86_64/bin/:$PATH
|
|
export PATH=$PROFILER_PATH/x86_64/bin/:$PATH
|
|
|
```
|
|
```
|
|
|
|
|
|
|
|
|
### Manual modification of the Conda library
|
|
|
|
|
|
|
|
Go to the `$CONDA_PREFIX/lib` folder and type:
|
|
|
|
|
|
|
|
```
|
|
|
|
mv libbfd.a save-libbfd.a
|
|
|
|
```
|
|
|
|
|
|
|
|
This will allow the compilation of Score-P and TAU with an automatic compile of the BFD library
|
|
|
|
|
|
|
### Compilation PDT
|
|
### Compilation PDT
|
|
|
|
|
|
|
|
In the PDT folder, type:
|
|
In the PDT folder, type:
|
| ... | @@ -90,12 +101,6 @@ make install |
... | @@ -90,12 +101,6 @@ make install |
|
|
|
|
|
|
|
### Compilation Score-P
|
|
### Compilation Score-P
|
|
|
|
|
|
|
|
Go to the `$CONDA_PREFIX/lib` folder and type:
|
|
|
|
|
|
|
|
|
|
```
|
|
|
|
|
mv libbfd.a save-libbfd.a
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
**This trick allows to avoid the use of the Conda `BFD` library and will force the use of the Score-P BFD library**
|
|
**This trick allows to avoid the use of the Conda `BFD` library and will force the use of the Score-P BFD library**
|
|
|
|
|
|
|
|
Go the Score-P folder, activate the `profilers` environment and type:
|
|
Go the Score-P folder, activate the `profilers` environment and type:
|
| ... | @@ -106,12 +111,6 @@ make |
... | @@ -106,12 +111,6 @@ make |
|
|
make install
|
|
make install
|
|
|
```
|
|
```
|
|
|
|
|
|
|
|
Go to the `$CONDA_PREFIX/lib` folder and type:
|
|
|
|
|
|
|
|
|
|
```
|
|
|
|
|
mv save-libbfd.a libbfd.a
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
This will restore the Conda environment
|
|
This will restore the Conda environment
|
|
|
|
|
|
|
|
### Compilation TAU
|
|
### Compilation TAU
|
| ... | @@ -119,13 +118,21 @@ This will restore the Conda environment |
... | @@ -119,13 +118,21 @@ This will restore the Conda environment |
|
|
In the TAU folder, activate the `profilers` environment and type
|
|
In the TAU folder, activate the `profilers` environment and type
|
|
|
|
|
|
|
|
```
|
|
```
|
|
|
./configure -prefix=$PROFILER_PATH/ -papi=$PROFILER_PATH/ -pdt=$PROFILER_PATH/ -scorep=$PROFILER_PATH -mpi -c++=g++ -cc=gcc -fortran=gfortran
|
|
./configure -prefix=$PROFILER_PATH/ -papi=$PROFILER_PATH/ -pdt=$PROFILER_PATH/ -scorep=$PROFILER_PATH -mpi -c++=g++ -cc=gcc -fortran=gfortran -bfd=download
|
|
|
make install
|
|
make install
|
|
|
```
|
|
```
|
|
|
|
|
|
|
|
> **CAUTION**
|
|
> **CAUTION**
|
|
|
> In TAU, each set of compile options generate a specific Makefile. In the above, the generated Makefile will include PAPI, PDT, Score-P and MPI. To compile a non-MPI program, re-compile TAU without the `-mpi` option
|
|
> In TAU, each set of compile options generate a specific Makefile. In the above, the generated Makefile will include PAPI, PDT, Score-P and MPI. To compile a non-MPI program, re-compile TAU without the `-mpi` option
|
|
|
|
|
|
|
|
|
### Restoring the Conda library
|
|
|
|
|
|
|
|
Go to the `$CONDA_PREFIX/lib` folder and type:
|
|
|
|
|
|
|
|
```
|
|
|
|
mv save-libbfd.a libbfd.a
|
|
|
|
```
|
|
|
|
|
|
|
## Profile
|
|
## Profile
|
|
|
|
|
|
|
|
### Profile with TAU
|
|
### Profile with TAU
|
| ... | |
... | |
| ... | | ... | |