Thread support limitations
Linaro MAP and Linaro Performance Reports provide limited support for programs when threading support is set
to MPI_THREAD_SERIALIZED
or MPI_THREAD_MULTIPLE
in the call to MPI_Init_thread
.
MPI activity on non-main threads contributes towards the MPI-time of the program, but not the MPI metric graphs.
Additionally, MPI activity on a non-main thread can result in additional profiling overhead due to the mechanism employed by Linaro MAP and Linaro Performance Reports for detecting MPI activity.
Solution
Linaro recommends using the threads view mode for interpreting MPI activity instead of the OpenMP view mode, because OpenMP view mode scales MPI-time depending on the resources requested. As a result, non-main thread MPI activity might provide non-intuitive results when detected outside of OpenMP regions.
Warnings display when the user initiates and completes profiling a
program that sets MPI_THREAD_SERIALIZED
or MPI_THREAD_MULTIPLE
as the required thread support.
Linaro MAP and Linaro Performance Reports both fully support making calls to MPI_Init_thread
using either MPI_THREAD_SINGLE
or MPI_THREAD_FUNNELED
to specify the
required thread support.
Note
The MPI specification requirements for programs using MPI_THREAD_FUNNELED
are the same
as the Linaro MAP and Linaro Performance Reports requirements: all MPI calls must be made on the thread that is called MPI_Init_thread
.
In many cases, multi-threaded MPI programs can be refactored so that they comply with this restriction.