Commit a6fb4d63 authored by William Gropp's avatar William Gropp
Browse files

[svn-r3177] Switch to the new macro for the global thread critical section...

[svn-r3177] Switch to the new macro for the global thread critical section (most of this is an automated change, tested against the MPICH2 test suite)
parent 07f99dbc
......@@ -59,7 +59,7 @@ int MPI_Type_hvector(int count,
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("datatype");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_TYPE_HVECTOR);
# ifdef HAVE_ERROR_CHECKING
......@@ -111,7 +111,7 @@ int MPI_Type_hvector(int count,
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_TYPE_HVECTOR);
MPIU_THREAD_SINGLE_CS_EXIT("datatype");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -88,7 +88,7 @@ int MPI_Type_indexed(int count,
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("datatype");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_TYPE_INDEXED);
/* Validate parameters and objects (post conversion) */
......@@ -161,7 +161,7 @@ int MPI_Type_indexed(int count,
fn_exit:
MPIU_CHKLMEM_FREEALL();
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_TYPE_INDEXED);
MPIU_THREAD_SINGLE_CS_EXIT("datatype");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -76,7 +76,7 @@ int MPI_Type_match_size(int typeclass, int size, MPI_Datatype *datatype)
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("datatype");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_TYPE_MATCH_SIZE);
MPIU_THREADPRIV_GET;
......@@ -174,7 +174,7 @@ int MPI_Type_match_size(int typeclass, int size, MPI_Datatype *datatype)
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_TYPE_MATCH_SIZE);
MPIU_THREAD_SINGLE_CS_EXIT("datatype");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -107,7 +107,7 @@ int MPI_Type_struct(int count,
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("datatype");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_TYPE_STRUCT);
/* Validate parameters, especially handles needing to be converted */
......@@ -181,7 +181,7 @@ int MPI_Type_struct(int count,
fn_exit:
MPIU_CHKLMEM_FREEALL();
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_TYPE_STRUCT);
MPIU_THREAD_SINGLE_CS_EXIT("datatype");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -60,7 +60,7 @@ int MPI_Type_vector(int count,
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("datatype");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_TYPE_VECTOR);
/* Validate parameters, especially handles needing to be converted */
......@@ -118,7 +118,7 @@ int MPI_Type_vector(int count,
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_TYPE_VECTOR);
MPIU_THREAD_SINGLE_CS_EXIT("datatype");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -52,7 +52,7 @@ int MPI_Add_error_class(int *errorclass)
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("errhan");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_ADD_ERROR_CLASS);
/* Validate parameters, especially handles needing to be converted */
......@@ -79,7 +79,7 @@ int MPI_Add_error_class(int *errorclass)
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_ADD_ERROR_CLASS);
MPIU_THREAD_SINGLE_CS_EXIT("errhan");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -55,7 +55,7 @@ int MPI_Add_error_code(int errorclass, int *errorcode)
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("errhan");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_ADD_ERROR_CODE);
/* Validate parameters, especially handles needing to be converted */
......@@ -82,7 +82,7 @@ int MPI_Add_error_code(int errorclass, int *errorcode)
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_ADD_ERROR_CODE);
MPIU_THREAD_SINGLE_CS_EXIT("errhan");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -64,7 +64,7 @@ int MPI_Add_error_string(int errorcode, char *string)
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("errhan");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_ADD_ERROR_STRING);
/* Validate parameters, especially handles needing to be converted */
......@@ -88,7 +88,7 @@ int MPI_Add_error_string(int errorcode, char *string)
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_ADD_ERROR_STRING);
MPIU_THREAD_SINGLE_CS_EXIT("errhan");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -56,7 +56,7 @@ int MPI_Comm_create_errhandler(MPI_Comm_errhandler_fn *function,
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("errhan");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_COMM_CREATE_ERRHANDLER);
/* Validate parameters, especially handles needing to be converted */
......@@ -87,7 +87,7 @@ int MPI_Comm_create_errhandler(MPI_Comm_errhandler_fn *function,
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_COMM_CREATE_ERRHANDLER);
MPIU_THREAD_SINGLE_CS_EXIT("errhan");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -56,7 +56,7 @@ int MPI_Comm_get_errhandler(MPI_Comm comm, MPI_Errhandler *errhandler)
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("errhan");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_COMM_GET_ERRHANDLER);
/* Validate parameters, especially handles needing to be converted */
......@@ -105,7 +105,7 @@ int MPI_Comm_get_errhandler(MPI_Comm comm, MPI_Errhandler *errhandler)
fn_exit:
#endif
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_COMM_GET_ERRHANDLER);
MPIU_THREAD_SINGLE_CS_EXIT("errhan");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
/* --BEGIN ERROR HANDLING-- */
......
......@@ -68,7 +68,7 @@ int MPI_Errhandler_create(MPI_Handler_function *function,
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("errhan");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_ERRHANDLER_CREATE);
/* Validate parameters, especially handles needing to be converted */
......@@ -96,7 +96,7 @@ int MPI_Errhandler_create(MPI_Handler_function *function,
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_ERRHANDLER_CREATE);
MPIU_THREAD_SINGLE_CS_EXIT("errhan");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -55,7 +55,7 @@ int MPI_Errhandler_free(MPI_Errhandler *errhandler)
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("errhan");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_ERRHANDLER_FREE);
/* Validate parameters, especially handles needing to be converted */
......@@ -101,7 +101,7 @@ int MPI_Errhandler_free(MPI_Errhandler *errhandler)
fn_exit:
#endif
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_ERRHANDLER_FREE);
MPIU_THREAD_SINGLE_CS_EXIT("errhan");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
/* --BEGIN ERROR HANDLING-- */
......
......@@ -68,7 +68,7 @@ int MPI_Errhandler_get(MPI_Comm comm, MPI_Errhandler *errhandler)
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("errhan");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_ERRHANDLER_GET);
MPIU_THREADPRIV_GET;
......@@ -113,7 +113,7 @@ int MPI_Errhandler_get(MPI_Comm comm, MPI_Errhandler *errhandler)
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_ERRHANDLER_GET);
MPIU_THREAD_SINGLE_CS_EXIT("errhan");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -59,7 +59,7 @@ int MPI_Errhandler_set(MPI_Comm comm, MPI_Errhandler errhandler)
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("errhan");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_ERRHANDLER_SET);
MPIU_THREADPRIV_GET;
......@@ -110,7 +110,7 @@ int MPI_Errhandler_set(MPI_Comm comm, MPI_Errhandler errhandler)
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_ERRHANDLER_SET);
MPIU_THREAD_SINGLE_CS_EXIT("errhan");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -54,7 +54,7 @@ int MPI_File_create_errhandler(MPI_File_errhandler_fn *function,
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("errhan");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_FILE_CREATE_ERRHANDLER);
/* Validate parameters, especially handles needing to be converted */
......@@ -84,7 +84,7 @@ int MPI_File_create_errhandler(MPI_File_errhandler_fn *function,
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_FILE_CREATE_ERRHANDLER);
MPIU_THREAD_SINGLE_CS_EXIT("errhan");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -62,7 +62,7 @@ int MPI_File_get_errhandler(MPI_File file, MPI_Errhandler *errhandler)
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("errhan");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_FILE_GET_ERRHANDLER);
#ifdef MPI_MODE_RDONLY
......@@ -106,7 +106,7 @@ int MPI_File_get_errhandler(MPI_File file, MPI_Errhandler *errhandler)
fn_exit:
#endif
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_FILE_GET_ERRHANDLER);
MPIU_THREAD_SINGLE_CS_EXIT("errhan");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
/* --BEGIN ERROR HANDLING-- */
......
......@@ -56,7 +56,7 @@ int MPI_Win_create_errhandler(MPI_Win_errhandler_fn *function,
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("errhan");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_WIN_CREATE_ERRHANDLER);
/* Validate parameters, especially handles needing to be converted */
......@@ -87,7 +87,7 @@ int MPI_Win_create_errhandler(MPI_Win_errhandler_fn *function,
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_WIN_CREATE_ERRHANDLER);
MPIU_THREAD_SINGLE_CS_EXIT("errhan");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
......@@ -57,7 +57,7 @@ int MPI_Win_get_errhandler(MPI_Win win, MPI_Errhandler *errhandler)
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("errhan");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_WIN_GET_ERRHANDLER);
/* Validate parameters, especially handles needing to be converted */
......@@ -107,7 +107,7 @@ int MPI_Win_get_errhandler(MPI_Win win, MPI_Errhandler *errhandler)
fn_exit:
#endif
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_WIN_GET_ERRHANDLER);
MPIU_THREAD_SINGLE_CS_EXIT("errhan");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
/* --BEGIN ERROR HANDLING-- */
......
......@@ -67,7 +67,7 @@ int MPI_Group_compare(MPI_Group group1, MPI_Group group2, int *result)
/* The routines that setup the group data structures must be executed
within a mutex. As most of the group routines are not performance
critical, we simple run these routines within the SINGLE_CS */
MPIU_THREAD_SINGLE_CS_ENTER("group");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_GROUP_COMPARE);
/* Validate parameters, especially handles needing to be converted */
......@@ -151,7 +151,7 @@ int MPI_Group_compare(MPI_Group group1, MPI_Group group2, int *result)
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_GROUP_COMPARE);
MPIU_THREAD_SINGLE_CS_EXIT("group");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
/* --BEGIN ERROR HANDLING-- */
......
......@@ -66,7 +66,7 @@ int MPI_Group_difference(MPI_Group group1, MPI_Group group2, MPI_Group *newgroup
MPIR_ERRTEST_INITIALIZED_ORDIE();
MPIU_THREAD_SINGLE_CS_ENTER("group");
MPIU_THREAD_CS_ENTER(ALLFUNC,);
MPID_MPI_FUNC_ENTER(MPID_STATE_MPI_GROUP_DIFFERENCE);
/* Validate parameters, especially handles needing to be converted */
......@@ -169,7 +169,7 @@ int MPI_Group_difference(MPI_Group group1, MPI_Group group2, MPI_Group *newgroup
fn_exit:
MPID_MPI_FUNC_EXIT(MPID_STATE_MPI_GROUP_DIFFERENCE);
MPIU_THREAD_SINGLE_CS_EXIT("group");
MPIU_THREAD_CS_EXIT(ALLFUNC,);
return mpi_errno;
fn_fail:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment