00001
00002
00003
00004
00005
00006
00007
00008 #include "mpioimpl.h"
00009
00010 #ifdef HAVE_WEAK_SYMBOLS
00011
00012 #if defined(HAVE_PRAGMA_WEAK)
00013 #pragma weak MPI_File_write_all_end = PMPI_File_write_all_end
00014 #elif defined(HAVE_PRAGMA_HP_SEC_DEF)
00015 #pragma _HP_SECONDARY_DEF PMPI_File_write_all_end MPI_File_write_all_end
00016 #elif defined(HAVE_PRAGMA_CRI_DUP)
00017 #pragma _CRI duplicate MPI_File_write_all_end as PMPI_File_write_all_end
00018
00019 #endif
00020
00021
00022 #define MPIO_BUILD_PROFILING
00023 #include "mpioprof.h"
00024 #endif
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038 int MPI_File_write_all_end(MPI_File mpi_fh, void *buf, MPI_Status *status)
00039 {
00040 int error_code;
00041 static char myname[] = "MPI_FILE_WRITE_ALL_END";
00042
00043 error_code = MPIOI_File_write_all_end(mpi_fh, buf, myname, status);
00044
00045 return error_code;
00046 }
00047
00048
00049
00050 int MPIOI_File_write_all_end(MPI_File mpi_fh,
00051 void *buf,
00052 char *myname,
00053 MPI_Status *status)
00054 {
00055 int error_code;
00056 ADIO_File fh;
00057
00058 MPIU_UNREFERENCED_ARG(buf);
00059
00060 MPIU_THREAD_CS_ENTER(ALLFUNC,);
00061
00062 fh = MPIO_File_resolve(mpi_fh);
00063
00064
00065 MPIO_CHECK_FILE_HANDLE(fh, myname, error_code);
00066
00067 if (!(fh->split_coll_count))
00068 {
00069 error_code = MPIO_Err_create_code(MPI_SUCCESS, MPIR_ERR_RECOVERABLE,
00070 myname, __LINE__, MPI_ERR_IO,
00071 "**iosplitcollnone", 0);
00072 error_code = MPIO_Err_return_file(fh, error_code);
00073 goto fn_exit;
00074 }
00075
00076
00077 #ifdef HAVE_STATUS_SET_BYTES
00078
00079
00080
00081 if (status != MPI_STATUS_IGNORE)
00082 *status = fh->split_status;
00083 #endif
00084 fh->split_coll_count = 0;
00085
00086 error_code = MPI_SUCCESS;
00087
00088 fn_exit:
00089 MPIU_THREAD_CS_EXIT(ALLFUNC,);
00090
00091 return error_code;
00092 }
00093