Page tree
Skip to end of metadata
Go to start of metadata

mpiP is a lightweight profiling library for MPI applications. In addition to the MPI summary profiling provided by IPM, mpiP can provide “call site” statistics showing which calls in the code are dominating MPI execution time.   

Usage

Using mpiP does not require code recompilation. Instead, LD_PRELOAD is used to dynamically load the mpiP library (libmpiP.so) as a wrapper to the MPI runtime.   

A sample PBS job script using mpiP profiler with MPI executable (prog.exe) is as shown below:

#!/bin/bash
#PBS -l ncpus=2
module load openmpi
module load mpiP
mpirun prog.exe > output

Currently, mpiP is available for openmpi version 1.3.3 and above.   

Profile Data

The mpiP profiler generates a text based output file named something like:   

prog.exe.${np}.25972.1.mpiP  

Graphical Viewer

To visualise the mpiP profile data on Raijin, you need to login to Raijin with a X display, eg. using ssh -X or ssh -Y, or with VNC. The detailed sample instruction on raijin is listed below.

ssh -X raijin
module load openmpi
module load mpiP
mpirun prog.exe
mpipview prog.exe.${np}.XXXXX.1.mpiP

mpipview is able to map MPI callsites in the profile data to source code. This requires the MPI program to be compiled with -g option and linked with libunwind, as follows.

module load openmpi
module load mpiP
mpicc -g -o prog.exe prog.c -lmpiP -lm -lbfd -liberty -lunwind
mpirun prog.exe