* @brief Illustrates how to initialise the MPI environment with multithreading
* support and ask for the MPI_THREAD_FUNNELED level.
* @details This application initialised MPI and asks for the
* MPI_THREAD_FUNNELED thread support level. It then compares it with the
* thread support level provided by the MPI implementation.
int main(int argc, char* argv)
// Initilialise MPI and ask for thread support
MPI_Init_thread(NULL, NULL, MPI_THREAD_FUNNELED, &provided);
if(provided < MPI_THREAD_FUNNELED)
printf("The threading support level is lesser than that demanded.\n");
printf("The threading support level corresponds to that demanded.\n");
// Tell MPI to shut down.