The following MMMMPPPPIIII____TTTThhhhrrrreeeeaaaadddd routines return MPI thread information:
MMMMPPPPIIII____IIIInnnniiiitttt____tttthhhhrrrreeeeaaaadddd The MMMMPPPPIIII____IIIInnnniiiitttt____tttthhhhrrrreeeeaaaadddd routine initializes the MPI
execution environment in the same way that a call to
MMMMPPPPIIII____IIIINNNNIIIITTTT would. In addition, it initializes the
thread environment.
This routine accepts the following parameters:
* _a_r_g_c, which specifies a pointer to the
number of arguments.
* _a_r_g_v, which specifies a pointer to the
argument vector.
* _r_e_q_u_i_r_e_d, which specifies the desired level
MMMMPPPPIIII____TTTTHHHHRRRREEEEAAAADDDD____SSSSIIIINNNNGGGGLLLLEEEE: Only one thread will
execute.
MMMMPPPPIIII____TTTTHHHHRRRREEEEAAAADDDD____FFFFUUUUNNNNNNNNEEEELLLLEEEEDDDD: The process can be
multithreaded, but only the main thread
will make MPI calls.
MMMMPPPPIIII____TTTTHHHHRRRREEEEAAAADDDD____SSSSEEEERRRRIIIIAAAALLLLIIIIZZZZEEEEDDDD: The process can be
multithreaded, and multiple threads can
make MPI calls, but only one at a time.
MPI calls are not made concurrently from
two distinct threads.
MMMMPPPPIIII____TTTTHHHHRRRREEEEAAAADDDD____MMMMUUUULLLLTTTTIIIIPPPPLLLLEEEE: Multiple threads can
call MPI.
* _p_r_o_v_i_d_e_d, which specifies the actual level
of thread support provided by MPI. It can
have one of the four values in the previous
option list.
MMMMPPPPIIII____QQQQuuuueeeerrrryyyy____tttthhhhrrrreeeeaaaadddd The MMMMPPPPIIII____QQQQuuuueeeerrrryyyy____tttthhhhrrrreeeeaaaadddd routine returns, in _p_r_o_v_i_d_e_d,
the current level of thread support.
MMMMPPPPIIII____IIIIssss____tttthhhhrrrreeeeaaaadddd____mmmmaaaaiiiinnnn The MMMMPPPPIIII____IIIIssss____tttthhhhrrrreeeeaaaadddd____mmmmaaaaiiiinnnn routine can be called by a
thread to find out whether it is the main thread. The
main thread is the thread that called MMMMPPPPIIII____IIIInnnniiiitttt or
MMMMPPPPIIII____IIIInnnniiiitttt____tttthhhhrrrreeeeaaaadddd. The answer is returned in _f_l_a_g.
NNNNOOOOTTTTEEEESSSS
MPI statistics (see the MMMMPPPPIIII____SSSSGGGGIIII____ssssttttaaaatttt man page) are not thread safe.