Index: mpid/ch2/req.h =================================================================== RCS file: /MPIhome/mpich/mpid/ch2/req.h,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 232c232 < #define MPID_SendRequestCancelled(r) (r)->shandle.s.MPI_TAG == MPIR_MSG_CANCELLED --- > #define MPID_SendRequestCancelled(r) ((r)->shandle.s.MPI_TAG == MPIR_MSG_CANCELLED) Index: romio/adio/ad_pvfs/ad_pvfs.c =================================================================== RCS file: /MPIhome/romio/adio/ad_pvfs/ad_pvfs.c,v retrieving revision 1.3 retrieving revision 1.4 diff -r1.3 -r1.4 3c3 < * $Id: ad_pvfs.c,v 1.3 2002/10/24 17:00:57 gropp Exp $ --- > * $Id: ad_pvfs.c,v 1.4 2003/04/15 22:21:37 robl Exp $ 23c23 < ADIOI_GEN_ReadStrided, /* ReadStrided */ --- > ADIOI_PVFS_ReadStrided, /* ReadStrided */ Index: romio/adio/ad_pvfs/ad_pvfs_open.c =================================================================== RCS file: /MPIhome/romio/adio/ad_pvfs/ad_pvfs_open.c,v retrieving revision 1.11 retrieving revision 1.16 diff -r1.11 -r1.16 3c3 < * $Id: ad_pvfs_open.c,v 1.11 2002/10/24 17:00:58 gropp Exp $ --- > * $Id: ad_pvfs_open.c,v 1.16 2003/05/01 17:33:11 robl Exp $ 15a16,20 > /* some really old versions of pvfs may not have a release nr */ > /* we changed the structure of pvfs_filestat in pvfs-1.5.7 */ > #if defined(PVFS_RELEASE_NR) && PVFS_RELEASE_NR > 10506 > struct pvfs_filestat pstat = {-1,-1,-1}; > #else 16a22,23 > #endif > 71,73d77 < #ifdef PRINT_ERR_MSG < *error_code = (fd->fd_sys == -1) ? MPI_ERR_UNKNOWN : MPI_SUCCESS; < #else 74a79,84 > #ifdef MPICH2 > *error_code = MPIR_Err_create_code(MPI_SUCCESS, MPIR_ERR_RECOVERABLE, myname, __LINE__, MPI_ERR_IO, "**io", > "**io %s", strerror(errno)); > #elif defined(PRINT_ERR_MSG) > *error_code = MPI_ERR_UNKNOWN; > #else /* MPICH-1 */ 77a88 > #endif 80d90 < #endif Index: romio/adio/ad_pvfs/ad_pvfs_read.c =================================================================== RCS file: /MPIhome/romio/adio/ad_pvfs/ad_pvfs_read.c,v retrieving revision 1.8 retrieving revision 1.13 diff -r1.8 -r1.13 3c3 < * $Id: ad_pvfs_read.c,v 1.8 2002/10/24 17:00:58 gropp Exp $ --- > * $Id: ad_pvfs_read.c,v 1.13 2003/04/18 20:15:01 David Exp $ 51,53d50 < #ifdef PRINT_ERR_MSG < *error_code = (err == -1) ? MPI_ERR_UNKNOWN : MPI_SUCCESS; < #else 54a52,57 > #ifdef MPICH2 > *error_code = MPIR_Err_create_code(MPI_SUCCESS, MPIR_ERR_RECOVERABLE, myname, __LINE__, MPI_ERR_IO, "**io", > "**io %s", strerror(errno)); > #elif defined(PRINT_ERR_MSG) > *error_code = MPI_ERR_UNKNOWN; > #else /* MPICH-1 */ 57a61 > #endif 60d63 < #endif 119c122 < #define MAX_ARRAY_SIZE 11 --- > #define MAX_ARRAY_SIZE 1024 Index: romio/adio/ad_pvfs/ad_pvfs_write.c =================================================================== RCS file: /MPIhome/romio/adio/ad_pvfs/ad_pvfs_write.c,v retrieving revision 1.10 retrieving revision 1.15 diff -r1.10 -r1.15 3c3 < * $Id: ad_pvfs_write.c,v 1.10 2002/10/24 17:01:00 gropp Exp $ --- > * $Id: ad_pvfs_write.c,v 1.15 2003/04/23 00:45:15 rross Exp $ 50,52d49 < #ifdef PRINT_ERR_MSG < *error_code = (err == -1) ? MPI_ERR_UNKNOWN : MPI_SUCCESS; < #else 53a51,56 > #ifdef MPICH2 > *error_code = MPIR_Err_create_code(MPI_SUCCESS, MPIR_ERR_RECOVERABLE, myname, __LINE__, MPI_ERR_IO, "**io", > "**io %s", strerror(errno)); > #elif defined(PRINT_ERR_MSG) > *error_code = MPI_ERR_UNKNOWN; > #else /* MPICH-1 */ 56a60 > #endif 59d62 < #endif 75d77 < struct iovec *iov; 120c122,123 < --- > char *combine_buf, *combine_buf_ptr; > ADIO_Offset combine_buf_remain; 127,129c130,133 < /* There is a limit of 16 on the number of iovecs for readv/writev! */ < < iov = (struct iovec *) ADIOI_Malloc(16*sizeof(struct iovec)); --- > /* allocate our "combine buffer" to pack data into before writing */ > combine_buf = (char *) ADIOI_Malloc(fd->hints->ind_wr_buffer_size); > combine_buf_ptr = combine_buf; > combine_buf_remain = fd->hints->ind_wr_buffer_size; 130a135 > /* seek to the right spot in the file */ 137,138c142,148 < k = 0; < for (j=0; j /* loop through all the flattened pieces. combine into buffer until > * no more will fit, then write. > * > * special case of a given piece being bigger than the combine buffer > * is also handled. > */ > for (j=0; jindices[i]; < iov[k].iov_len = flat_buf->blocklens[i]; < /*FPRINTF(stderr, "%d %d\n", iov[k].iov_base, iov[k].iov_len);*/ --- > if (flat_buf->blocklens[i] > combine_buf_remain && combine_buf != combine_buf_ptr) { > /* there is data in the buffer; write out the buffer so far */ > err = pvfs_write(fd->fd_sys, > combine_buf, > fd->hints->ind_wr_buffer_size - combine_buf_remain); > if (err == -1) err_flag = 1; 145,146c157,160 < off += flat_buf->blocklens[i]; < k = (k+1)%16; --- > /* reset our buffer info */ > combine_buf_ptr = combine_buf; > combine_buf_remain = fd->hints->ind_wr_buffer_size; > } 148,149c162,169 < if (!k) { < err = pvfs_writev(fd->fd_sys, iov, 16); --- > /* TODO: heuristic for when to not bother to use combine buffer? */ > if (flat_buf->blocklens[i] >= combine_buf_remain) { > /* special case: blocklen is as big as or bigger than the combine buf; > * write directly > */ > err = pvfs_write(fd->fd_sys, > ((char *) buf) + j*buftype_extent + flat_buf->indices[i], > flat_buf->blocklens[i]); 150a171,180 > off += flat_buf->blocklens[i]; /* keep up with the final file offset too */ > } > else { > /* copy more data into combine buffer */ > memcpy(combine_buf_ptr, > ((char *) buf) + j*buftype_extent + flat_buf->indices[i], > flat_buf->blocklens[i]); > combine_buf_ptr += flat_buf->blocklens[i]; > combine_buf_remain -= flat_buf->blocklens[i]; > off += flat_buf->blocklens[i]; /* keep up with the final file offset too */ 152a183 > } 154,155c185,189 < if (k) { < err = pvfs_writev(fd->fd_sys, iov, k); --- > if (combine_buf_ptr != combine_buf) { > /* data left in buffer to write */ > err = pvfs_write(fd->fd_sys, > combine_buf, > fd->hints->ind_wr_buffer_size - combine_buf_remain); 161,164c195,196 < ADIOI_Free(iov); < #ifdef PRINT_ERR_MSG < *error_code = (err_flag) ? MPI_ERR_UNKNOWN : MPI_SUCCESS; < #else --- > ADIOI_Free(combine_buf); > 165a198,203 > #ifdef MPICH2 > *error_code = MPIR_Err_create_code(MPI_SUCCESS, MPIR_ERR_RECOVERABLE, myname, __LINE__, MPI_ERR_IO, "**io", > "**io %s", strerror(errno)); > #elif defined(PRINT_ERR_MSG) > *error_code = MPI_ERR_UNKNOWN; > #else /* MPICH-1 */ 168a207 > #endif 171,172c210 < #endif < } --- > } /* if (!buftype_is_contig && filetype_is_contig) ... */ 345,347d382 < #ifdef PRINT_ERR_MSG < *error_code = (err_flag) ? MPI_ERR_UNKNOWN : MPI_SUCCESS; < #else 348a384,389 > #ifdef MPICH2 > *error_code = MPIR_Err_create_code(MPI_SUCCESS, MPIR_ERR_RECOVERABLE, myname, __LINE__, MPI_ERR_IO, "**io", > "**io %s", strerror(errno)); > #elif defined(PRINT_ERR_MSG) > *error_code = MPI_ERR_UNKNOWN; > #else /* MPICH-1 */ 351a393 > #endif 354d395 < #endif 511,513d551 < #ifdef PRINT_ERR_MSG < *error_code = (err_flag) ? MPI_ERR_UNKNOWN : MPI_SUCCESS; < #else 514a553,558 > #ifdef MPICH2 > *error_code = MPIR_Err_create_code(MPI_SUCCESS, MPIR_ERR_RECOVERABLE, myname, __LINE__, MPI_ERR_IO, "**io", > "**io %s", strerror(errno)); > #elif defined(PRINT_ERR_MSG) > *error_code = MPI_ERR_UNKNOWN; > #else 517a562 > #endif 519a565,571 > > fd->fp_sys_posn = -1; /* clear this. */ > > #ifdef HAVE_STATUS_SET_BYTES > MPIR_Status_set_bytes(status, datatype, bufsize); > /* This is a temporary way of filling in status. The right way is to > keep track of how much data was actually written by ADIOI_BUFFERED_WRITE. */ 520a573 > 1046,1048d1098 < #ifdef PRINT_ERR_MSG < *error_code = (err_flag) ? MPI_ERR_UNKNOWN : MPI_SUCCESS; < #else 1049a1100,1105 > #ifdef MPICH2 > *error_code = MPIR_Err_create_code(MPI_SUCCESS, MPIR_ERR_RECOVERABLE, myname, __LINE__, MPI_ERR_IO, "**io", > "**io %s", strerror(errno)); > #elif defined(PRINT_ERR_MSG) > *error_code = MPI_ERR_UNKNOWN; > #else /* MPICH-1 */ 1053a1110 > #endif 1056d1112 < #endif Index: romio/adio/common/ad_hints.c =================================================================== RCS file: /MPIhome/romio/adio/common/ad_hints.c,v retrieving revision 1.12 retrieving revision 1.18 diff -r1.12 -r1.18 3c3 < * $Id: ad_hints.c,v 1.12 2002/11/20 13:58:29 gropp Exp $ --- > * $Id: ad_hints.c,v 1.18 2003/10/01 14:40:28 robl Exp $ 21c21 < int flag, intval, tmp_val, nprocs; --- > int flag, intval, tmp_val, nprocs, nprocs_is_valid = 0; 54a55 > nprocs_is_valid = 1; 61a63,64 > /* deferred_open derrived from no_indep_rw and cb_{read,write} */ > fd->hints->deferred_open = 0; 108a112 > /* romio_cb_read overrides no_indep_rw */ 109a114 > MPI_Info_set(info, "romio_no_indep_rw", "false"); 110a116 > fd->hints->no_indep_rw = ADIOI_HINT_DISABLE; 131a138 > /* romio_cb_write overrides no_indep_rw, too */ 132a140 > MPI_Info_set(info, "romio_no_indep_rw", "false"); 133a142 > fd->hints->no_indep_rw = ADIOI_HINT_DISABLE; 153a163,165 > /* if 'no_indep_rw' set, also hint that we will do > * collective buffering: if we aren't doing independent io, > * then we have to do collective */ 154a167,168 > MPI_Info_set(info, "romio_cb_write", "enable"); > MPI_Info_set(info, "romio_cb_read", "enable"); 155a170,171 > fd->hints->cb_read = 1; > fd->hints->cb_write = 1; 222a239,245 > if (!nprocs_is_valid) { > /* if hints were already initialized, we might not > * have already gotten this? > */ > MPI_Comm_size(fd->comm, &nprocs); > nprocs_is_valid = 1; > } 277a301,317 > /* deferred_open won't be set by callers, but if the user doesn't > * explicitly disable collecitve buffering (two-phase) and does hint that > * io w/o independent io is going on, we'll set this internal hint as a > * convenience */ > if ( ( (fd->hints->cb_read != ADIOI_HINT_DISABLE) \ > && (fd->hints->cb_write != ADIOI_HINT_DISABLE)\ > && fd->hints->no_indep_rw ) ) { > fd->hints->deferred_open = 1; > } else { > /* setting romio_no_indep_rw enable and romio_cb_{read,write} > * disable at the same time doesn't make sense. honor > * romio_cb_{read,write} and force the no_indep_rw hint to > * 'disable' */ > MPI_Info_set(info, "romio_no_indep_rw", "false"); > fd->hints->no_indep_rw = 0; > fd->hints->deferred_open = 0; > } 288c328,330 < fd->hints->ind_wr_buffer_size = -1; --- > /* note: leave ind_wr_buffer_size alone; used for other cases > * as well. -- Rob Ross, 04/22/2003 > */ Index: romio/mpi-io/fortran/.cvsignore =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/.cvsignore,v retrieving revision 1.3 retrieving revision 1.4 diff -r1.3 -r1.4 5a6 > .deps Index: romio/mpi-io/fortran/closef.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/closef.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: closef.c,v 1.13 2002/10/24 17:01:19 gropp Exp $ --- > * $Id: closef.c,v 1.14 2003/07/08 22:25:41 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_CLOSE( MPI_File*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_close__( MPI_File*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_close( MPI_File*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_close_( MPI_File*, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_close_(MPI_Fint *fh, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_close_(MPI_Fint *fh, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_close_(MPI_Fint *fh, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_close_(MPI_Fint *fh, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/deletef.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/deletef.c,v retrieving revision 1.14 retrieving revision 1.15 diff -r1.14 -r1.15 3c3 < * $Id: deletef.c,v 1.14 2002/10/24 17:01:19 gropp Exp $ --- > * $Id: deletef.c,v 1.15 2003/07/08 22:25:42 thakur Exp $ 20a21 > extern FORTRAN_API void FORT_CALL MPI_FILE_DELETE( char * FORT_MIXED_LEN_DECL, MPI_Fint *, MPI_Fint * FORT_END_LEN_DECL ); 22a24 > extern FORTRAN_API void FORT_CALL mpi_file_delete__( char * FORT_MIXED_LEN_DECL, MPI_Fint *, MPI_Fint * FORT_END_LEN_DECL ); 24a27 > extern FORTRAN_API void FORT_CALL mpi_file_delete( char * FORT_MIXED_LEN_DECL, MPI_Fint *, MPI_Fint * FORT_END_LEN_DECL ); 26a30 > extern FORTRAN_API void FORT_CALL mpi_file_delete_( char * FORT_MIXED_LEN_DECL, MPI_Fint *, MPI_Fint * FORT_END_LEN_DECL ); 105c109 < FORTRAN_API void FORT_CALL mpi_file_delete_(char *filename FORT_MIXED_LEN_DECL, MPI_Fint *info, int *ierr FORT_END_LEN_DECL); --- > FORTRAN_API void FORT_CALL mpi_file_delete_(char *filename FORT_MIXED_LEN_DECL, MPI_Fint *info, MPI_Fint *ierr FORT_END_LEN_DECL); 108c112 < void mpi_file_delete_(_fcd filename_fcd, MPI_Fint *info, int *ierr) --- > void mpi_file_delete_(_fcd filename_fcd, MPI_Fint *info, MPI_Fint *ierr) 113c117 < FORTRAN_API void FORT_CALL mpi_file_delete_(char *filename FORT_MIXED_LEN(str_len), MPI_Fint *info, int *ierr FORT_END_LEN(str_len)) --- > FORTRAN_API void FORT_CALL mpi_file_delete_(char *filename FORT_MIXED_LEN(str_len), MPI_Fint *info, MPI_Fint *ierr FORT_END_LEN(str_len)) Index: romio/mpi-io/fortran/fsyncf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/fsyncf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: fsyncf.c,v 1.13 2002/10/24 17:01:19 gropp Exp $ --- > * $Id: fsyncf.c,v 1.14 2003/07/08 22:25:42 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_SYNC( MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_sync__( MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_sync( MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_sync_( MPI_Fint *, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_sync_(MPI_Fint *fh, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_sync_(MPI_Fint *fh, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_sync_(MPI_Fint *fh, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_sync_(MPI_Fint *fh, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/get_amodef.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/get_amodef.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: get_amodef.c,v 1.13 2002/10/24 17:01:19 gropp Exp $ --- > * $Id: get_amodef.c,v 1.14 2003/07/08 22:25:42 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_GET_AMODE( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_get_amode__( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_get_amode( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_get_amode_( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_get_amode_(MPI_Fint *fh,int *amode, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_get_amode_(MPI_Fint *fh, MPI_Fint *amode, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_get_amode_(MPI_Fint *fh,int *amode, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_get_amode_(MPI_Fint *fh, MPI_Fint *amode, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/get_atomf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/get_atomf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: get_atomf.c,v 1.13 2002/10/24 17:01:19 gropp Exp $ --- > * $Id: get_atomf.c,v 1.14 2003/07/08 22:25:42 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_GET_ATOMICITY( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_get_atomicity__( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_get_atomicity( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_get_atomicity_( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_get_atomicity_(MPI_Fint *fh,int *flag, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_get_atomicity_(MPI_Fint *fh, MPI_Fint *flag, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_get_atomicity_(MPI_Fint *fh,int *flag, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_get_atomicity_(MPI_Fint *fh, MPI_Fint *flag, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/get_bytofff.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/get_bytofff.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: get_bytofff.c,v 1.13 2002/10/24 17:01:19 gropp Exp $ --- > * $Id: get_bytofff.c,v 1.14 2003/07/08 22:25:42 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_GET_BYTE_OFFSET( MPI_Fint *, MPI_Offset *, MPI_Offset*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_get_byte_offset__( MPI_Fint *, MPI_Offset *, MPI_Offset*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_get_byte_offset( MPI_Fint *, MPI_Offset *, MPI_Offset*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_get_byte_offset_( MPI_Fint *, MPI_Offset *, MPI_Offset*, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_get_byte_offset_(MPI_Fint *fh,MPI_Offset *offset,MPI_Offset *disp, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_get_byte_offset_(MPI_Fint *fh, MPI_Offset *offset, MPI_Offset *disp, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_get_byte_offset_(MPI_Fint *fh,MPI_Offset *offset,MPI_Offset *disp, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_get_byte_offset_(MPI_Fint *fh,MPI_Offset *offset, MPI_Offset *disp, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/get_errhf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/get_errhf.c,v retrieving revision 1.8 retrieving revision 1.9 diff -r1.8 -r1.9 3c3 < * $Id: get_errhf.c,v 1.8 2002/10/24 17:01:19 gropp Exp $ --- > * $Id: get_errhf.c,v 1.9 2003/07/08 22:25:42 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_GET_ERRHANDLER( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_get_errhandler__( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_get_errhandler( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_get_errhandler_( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_get_errhandler_(MPI_Fint *fh, MPI_Fint *err_handler, int *ierr); --- > FORTRAN_API void FORT_CALL mpi_file_get_errhandler_(MPI_Fint *fh, MPI_Fint *err_handler, MPI_Fint *ierr); 92c96 < FORTRAN_API void FORT_CALL mpi_file_get_errhandler_(MPI_Fint *fh, MPI_Fint *err_handler, int *ierr) --- > FORTRAN_API void FORT_CALL mpi_file_get_errhandler_(MPI_Fint *fh, MPI_Fint *err_handler, MPI_Fint *ierr) Index: romio/mpi-io/fortran/get_extentf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/get_extentf.c,v retrieving revision 1.14 retrieving revision 1.15 diff -r1.14 -r1.15 3c3 < * $Id: get_extentf.c,v 1.14 2002/10/24 17:01:20 gropp Exp $ --- > * $Id: get_extentf.c,v 1.15 2003/07/08 22:25:43 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_GET_TYPE_EXTENT( MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_get_type_extent__( MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_get_type_extent( MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_get_type_extent_( MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 111c115 < MPI_Fint *extent, int *ierr ); --- > MPI_Fint *extent, MPI_Fint *ierr ); 114c118 < MPI_Fint *extent, int *ierr ) --- > MPI_Fint *extent, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/get_groupf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/get_groupf.c,v retrieving revision 1.15 retrieving revision 1.16 diff -r1.15 -r1.16 3c3 < * $Id: get_groupf.c,v 1.15 2002/10/24 17:01:20 gropp Exp $ --- > * $Id: get_groupf.c,v 1.16 2003/07/08 22:25:43 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_GET_GROUP( MPI_Fint *, MPI_Group*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_get_group__( MPI_Fint *, MPI_Group*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_get_group( MPI_Fint *, MPI_Group*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_get_group_( MPI_Fint *, MPI_Group*, MPI_Fint * ); 91c95 < void mpi_file_get_group_(MPI_Fint *fh,MPI_Fint *group, int *ierr ); --- > void mpi_file_get_group_(MPI_Fint *fh, MPI_Fint *group, MPI_Fint *ierr ); 93c97 < void mpi_file_get_group_(MPI_Fint *fh,MPI_Fint *group, int *ierr ) --- > void mpi_file_get_group_(MPI_Fint *fh, MPI_Fint *group, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/get_infof.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/get_infof.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: get_infof.c,v 1.13 2002/10/24 17:01:20 gropp Exp $ --- > * $Id: get_infof.c,v 1.14 2003/07/08 22:25:43 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_GET_INFO( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_get_info__( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_get_info( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_get_info_( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_get_info_(MPI_Fint *fh, MPI_Fint *info_used, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_get_info_(MPI_Fint *fh, MPI_Fint *info_used, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_get_info_(MPI_Fint *fh, MPI_Fint *info_used, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_get_info_(MPI_Fint *fh, MPI_Fint *info_used, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/get_posn_shf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/get_posn_shf.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: get_posn_shf.c,v 1.12 2002/10/24 17:01:20 gropp Exp $ --- > * $Id: get_posn_shf.c,v 1.13 2003/07/08 22:25:43 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_GET_POSITION_SHARED( MPI_Fint *, MPI_Offset*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_get_position_shared__( MPI_Fint *, MPI_Offset*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_get_position_shared( MPI_Fint *, MPI_Offset*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_get_position_shared_( MPI_Fint *, MPI_Offset*, MPI_Fint * ); 91c95 < int *ierr ); --- > MPI_Fint *ierr ); 93c97 < FORTRAN_API void FORT_CALL mpi_file_get_position_shared_(MPI_Fint *fh, MPI_Offset *offset, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_get_position_shared_(MPI_Fint *fh, MPI_Offset *offset, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/get_posnf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/get_posnf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: get_posnf.c,v 1.13 2002/10/24 17:01:20 gropp Exp $ --- > * $Id: get_posnf.c,v 1.14 2003/07/08 22:25:43 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_GET_POSITION( MPI_Fint *, MPI_Offset*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_get_position__( MPI_Fint *, MPI_Offset*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_get_position( MPI_Fint *, MPI_Offset*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_get_position_( MPI_Fint *, MPI_Offset*, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_get_position_(MPI_Fint *fh, MPI_Offset *offset, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_get_position_(MPI_Fint *fh, MPI_Offset *offset, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_get_position_(MPI_Fint *fh, MPI_Offset *offset, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_get_position_(MPI_Fint *fh, MPI_Offset *offset, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/get_sizef.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/get_sizef.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: get_sizef.c,v 1.13 2002/10/24 17:01:20 gropp Exp $ --- > * $Id: get_sizef.c,v 1.14 2003/07/08 22:25:43 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_GET_SIZE( MPI_Fint *, MPI_Offset*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_get_size__( MPI_Fint *, MPI_Offset*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_get_size( MPI_Fint *, MPI_Offset*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_get_size_( MPI_Fint *, MPI_Offset*, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_get_size_(MPI_Fint *fh,MPI_Offset *size, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_get_size_(MPI_Fint *fh, MPI_Offset *size, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_get_size_(MPI_Fint *fh,MPI_Offset *size, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_get_size_(MPI_Fint *fh, MPI_Offset *size, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/get_viewf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/get_viewf.c,v retrieving revision 1.15 retrieving revision 1.16 diff -r1.15 -r1.16 3c3 < * $Id: get_viewf.c,v 1.15 2002/10/24 17:01:20 gropp Exp $ --- > * $Id: get_viewf.c,v 1.16 2003/07/08 22:25:44 thakur Exp $ 20a21 > extern FORTRAN_API void FORT_CALL MPI_FILE_GET_VIEW( MPI_Fint *, MPI_Offset*, MPI_Fint*, MPI_Fint*, char * FORT_MIXED_LEN_DECL, MPI_Fint * FORT_END_LEN_DECL ); 22a24 > extern FORTRAN_API void FORT_CALL mpi_file_get_view__( MPI_Fint *, MPI_Offset*, MPI_Fint*, MPI_Fint*, char * FORT_MIXED_LEN_DECL, MPI_Fint * FORT_END_LEN_DECL ); 24a27 > extern FORTRAN_API void FORT_CALL mpi_file_get_view( MPI_Fint *, MPI_Offset*, MPI_Fint*, MPI_Fint*, char * FORT_MIXED_LEN_DECL, MPI_Fint * FORT_END_LEN_DECL ); 26a30 > extern FORTRAN_API void FORT_CALL mpi_file_get_view_( MPI_Fint *, MPI_Offset*, MPI_Fint*, MPI_Fint*, char * FORT_MIXED_LEN_DECL, MPI_Fint * FORT_END_LEN_DECL ); 136,137c140,141 < void mpi_file_get_view_(MPI_Fint *fh,MPI_Offset *disp,MPI_Datatype *etype, < MPI_Datatype *filetype, _fcd datarep_fcd, int *ierr) --- > void mpi_file_get_view_(MPI_Fint *fh,MPI_Offset *disp,MPI_Fint *etype, > MPI_Fint *filetype, _fcd datarep_fcd, int *ierr) 143,144c147 < FORTRAN_API void FORT_CALL mpi_file_get_view_(MPI_Fint *fh,MPI_Offset *disp,MPI_Datatype *etype, < MPI_Datatype *filetype,char *datarep, int *ierr, int str_len ); --- > FORTRAN_API void FORT_CALL mpi_file_get_view_( MPI_Fint *fh, MPI_Offset *disp, MPI_Fint *etype, MPI_Fint *filetype, char *datarep FORT_MIXED_LEN_DECL, MPI_Fint *ierr FORT_END_LEN_DECL ); 146,147c149 < FORTRAN_API void FORT_CALL mpi_file_get_view_(MPI_Fint *fh,MPI_Offset *disp,MPI_Datatype *etype, < MPI_Datatype *filetype,char *datarep, int *ierr, int str_len ) --- > FORTRAN_API void FORT_CALL mpi_file_get_view_( MPI_Fint *fh, MPI_Offset *disp, MPI_Fint *etype, MPI_Fint *filetype, char *datarep FORT_MIXED_LEN(str_len), MPI_Fint *ierr FORT_END_LEN(str_len) ) Index: romio/mpi-io/fortran/iotestf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/iotestf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: iotestf.c,v 1.13 2002/10/24 17:01:21 gropp Exp $ --- > * $Id: iotestf.c,v 1.14 2003/07/08 22:25:44 thakur Exp $ 16a17 > FORTRAN_API void FORT_CALL MPIO_TEST(MPI_Fint *request,int *flag,MPI_Status *status, int *ierr ); 18a20 > FORTRAN_API void FORT_CALL mpio_test__(MPI_Fint *request,int *flag,MPI_Status *status, int *ierr ); 20a23 > FORTRAN_API void FORT_CALL mpio_test(MPI_Fint *request,int *flag,MPI_Status *status, int *ierr ); 22a26 > FORTRAN_API void FORT_CALL mpio_test_(MPI_Fint *request,int *flag,MPI_Status *status, int *ierr ); 89c93 < FORTRAN_API void FORT_CALL mpio_test_(MPI_Fint *request,int *flag,MPI_Status *status, int *ierr ); --- > FORTRAN_API void FORT_CALL mpio_test_(MPI_Fint *request,MPI_Fint *flag,MPI_Status *status, MPI_Fint *ierr ); 91c95 < FORTRAN_API void FORT_CALL mpio_test_(MPI_Fint *request,int *flag,MPI_Status *status, int *ierr ) --- > FORTRAN_API void FORT_CALL mpio_test_(MPI_Fint *request,MPI_Fint *flag,MPI_Status *status, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/iowaitf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/iowaitf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: iowaitf.c,v 1.13 2002/10/24 17:01:21 gropp Exp $ --- > * $Id: iowaitf.c,v 1.14 2003/07/08 22:25:44 thakur Exp $ 16a17 > FORTRAN_API void FORT_CALL MPIO_WAIT(MPI_Fint *request,MPI_Status *status, MPI_Fint *ierr ); 18a20 > FORTRAN_API void FORT_CALL mpio_wait__(MPI_Fint *request,MPI_Status *status, MPI_Fint *ierr ); 20a23 > FORTRAN_API void FORT_CALL mpio_wait(MPI_Fint *request,MPI_Status *status, MPI_Fint *ierr ); 22a26 > FORTRAN_API void FORT_CALL mpio_wait_(MPI_Fint *request,MPI_Status *status, MPI_Fint *ierr ); 89c93 < FORTRAN_API void FORT_CALL mpio_wait_(MPI_Fint *request,MPI_Status *status, int *ierr ); --- > FORTRAN_API void FORT_CALL mpio_wait_(MPI_Fint *request,MPI_Status *status, MPI_Fint *ierr ); 91c95 < FORTRAN_API void FORT_CALL mpio_wait_(MPI_Fint *request,MPI_Status *status, int *ierr ) --- > FORTRAN_API void FORT_CALL mpio_wait_(MPI_Fint *request,MPI_Status *status, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/iread_atf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/iread_atf.c,v retrieving revision 1.14 retrieving revision 1.15 diff -r1.14 -r1.15 3c3 < * $Id: iread_atf.c,v 1.14 2002/10/24 17:01:21 gropp Exp $ --- > * $Id: iread_atf.c,v 1.15 2003/07/08 22:25:44 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_IREAD_AT( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_iread_at__( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_iread_at( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_iread_at_( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 92,93c96,97 < int *count,MPI_Fint *datatype, < MPI_Fint *request, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Fint *request, MPI_Fint *ierr ); 96,97c100,101 < int *count,MPI_Fint *datatype, < MPI_Fint *request, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Fint *request, MPI_Fint *ierr ) 114c118 < MPI_Fint *request, int *ierr ); --- > MPI_Fint *request, MPI_Fint *ierr ); 117,118c121,122 < int *count,MPI_Datatype *datatype, < MPI_Fint *request, int *ierr ) --- > MPI_Fint *count,MPI_Datatype *datatype, > MPI_Fint *request, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/iread_shf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/iread_shf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: iread_shf.c,v 1.13 2002/10/24 17:01:21 gropp Exp $ --- > * $Id: iread_shf.c,v 1.14 2003/07/08 22:25:44 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_IREAD_SHARED( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_iread_shared__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_iread_shared( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_iread_shared_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 92c96 < MPI_Fint *datatype,MPI_Fint *request, int *ierr ); --- > MPI_Fint *datatype,MPI_Fint *request, MPI_Fint *ierr ); 95c99 < MPI_Fint *datatype,MPI_Fint *request, int *ierr ) --- > MPI_Fint *datatype,MPI_Fint *request, MPI_Fint *ierr ) 109c113 < MPI_Datatype *datatype,MPI_Fint *request, int *ierr ); --- > MPI_Datatype *datatype,MPI_Fint *request, MPI_Fint *ierr ); 112c116 < MPI_Datatype *datatype,MPI_Fint *request, int *ierr ) --- > MPI_Datatype *datatype,MPI_Fint *request, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/ireadf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/ireadf.c,v retrieving revision 1.14 retrieving revision 1.15 diff -r1.14 -r1.15 3c3 < * $Id: ireadf.c,v 1.14 2002/10/24 17:01:21 gropp Exp $ --- > * $Id: ireadf.c,v 1.15 2003/07/08 22:25:44 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_IREAD( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_iread__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_iread( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_iread_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 92c96 < MPI_Fint *datatype,MPI_Fint *request, int *ierr ); --- > MPI_Fint *datatype,MPI_Fint *request, MPI_Fint *ierr ); 95c99 < MPI_Fint *datatype,MPI_Fint *request, int *ierr ) --- > MPI_Fint *datatype,MPI_Fint *request, MPI_Fint *ierr ) 109c113 < MPI_Datatype *datatype,MPI_Fint *request, int *ierr ); --- > MPI_Datatype *datatype,MPI_Fint *request, MPI_Fint *ierr ); 112c116 < MPI_Datatype *datatype,MPI_Fint *request, int *ierr ) --- > MPI_Datatype *datatype,MPI_Fint *request, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/iwrite_atf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/iwrite_atf.c,v retrieving revision 1.14 retrieving revision 1.15 diff -r1.14 -r1.15 3c3 < * $Id: iwrite_atf.c,v 1.14 2002/10/24 17:01:21 gropp Exp $ --- > * $Id: iwrite_atf.c,v 1.15 2003/07/08 22:25:44 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_IWRITE_AT( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_iwrite_at__( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_iwrite_at( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_iwrite_at_( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 92,93c96,97 < int *count,MPI_Fint *datatype, < MPI_Fint *request, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Fint *request, MPI_Fint *ierr ); 96,97c100,101 < int *count,MPI_Fint *datatype, < MPI_Fint *request, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Fint *request, MPI_Fint *ierr ) 112,113c116,117 < int *count,MPI_Datatype *datatype, < MPI_Fint *request, int *ierr ); --- > MPI_Fint *count,MPI_Datatype *datatype, > MPI_Fint *request, MPI_Fint *ierr ); 116,117c120,121 < int *count,MPI_Datatype *datatype, < MPI_Fint *request, int *ierr ) --- > MPI_Fint *count,MPI_Datatype *datatype, > MPI_Fint *request, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/iwrite_shf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/iwrite_shf.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: iwrite_shf.c,v 1.12 2002/10/24 17:01:22 gropp Exp $ --- > * $Id: iwrite_shf.c,v 1.13 2003/07/08 22:25:45 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_IWRITE_SHARED( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_iwrite_shared__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_iwrite_shared( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_iwrite_shared_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 92c96 < MPI_Fint *datatype,MPI_Fint *request, int *ierr ); --- > MPI_Fint *datatype,MPI_Fint *request, MPI_Fint *ierr ); 94c98 < MPI_Fint *datatype,MPI_Fint *request, int *ierr ) --- > MPI_Fint *datatype,MPI_Fint *request, MPI_Fint *ierr ) 109c113 < MPI_Datatype *datatype,MPI_Fint *request, int *ierr ); --- > MPI_Datatype *datatype,MPI_Fint *request, MPI_Fint *ierr ); 112c116 < MPI_Datatype *datatype,MPI_Fint *request, int *ierr ) --- > MPI_Datatype *datatype,MPI_Fint *request, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/iwritef.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/iwritef.c,v retrieving revision 1.14 retrieving revision 1.15 diff -r1.14 -r1.15 3c3 < * $Id: iwritef.c,v 1.14 2002/10/24 17:01:22 gropp Exp $ --- > * $Id: iwritef.c,v 1.15 2003/07/08 22:25:45 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_IWRITE( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_iwrite__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_iwrite( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_iwrite_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint*, MPI_Fint * ); 92c96 < MPI_Fint *datatype,MPI_Fint *request, int *ierr ); --- > MPI_Fint *datatype,MPI_Fint *request, MPI_Fint *ierr ); 95c99 < MPI_Fint *datatype,MPI_Fint *request, int *ierr ) --- > MPI_Fint *datatype,MPI_Fint *request, MPI_Fint *ierr ) 110c114 < MPI_Datatype *datatype,MPI_Fint *request, int *ierr ); --- > MPI_Datatype *datatype,MPI_Fint *request, MPI_Fint *ierr ); 113c117 < MPI_Datatype *datatype,MPI_Fint *request, int *ierr ) --- > MPI_Datatype *datatype,MPI_Fint *request, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/openf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/openf.c,v retrieving revision 1.15 retrieving revision 1.16 diff -r1.15 -r1.16 3c3 < * $Id: openf.c,v 1.15 2002/10/24 17:01:22 gropp Exp $ --- > * $Id: openf.c,v 1.16 2003/07/08 22:25:45 thakur Exp $ 20a21 > extern FORTRAN_API void FORT_CALL MPI_FILE_OPEN( MPI_Fint *, char * FORT_MIXED_LEN_DECL, MPI_Fint *, MPI_Fint *, MPI_File*, MPI_Fint * FORT_END_LEN_DECL ); 22a24 > extern FORTRAN_API void FORT_CALL mpi_file_open__( MPI_Fint *, char * FORT_MIXED_LEN_DECL, MPI_Fint *, MPI_Fint *, MPI_File*, MPI_Fint * FORT_END_LEN_DECL ); 24a27 > extern FORTRAN_API void FORT_CALL mpi_file_open( MPI_Fint *, char * FORT_MIXED_LEN_DECL, MPI_Fint *, MPI_Fint *, MPI_File*, MPI_Fint * FORT_END_LEN_DECL ); 26a30 > extern FORTRAN_API void FORT_CALL mpi_file_open_( MPI_Fint *, char * FORT_MIXED_LEN_DECL, MPI_Fint *, MPI_Fint *, MPI_File*, MPI_Fint * FORT_END_LEN_DECL ); 94,95c98,99 < void mpi_file_open_(MPI_Fint *comm,char *filename,int *amode, < MPI_Fint *info, MPI_Fint *fh, int *ierr, int str_len ); --- > void mpi_file_open_(MPI_Fint *comm,char *filename,MPI_Fint *amode, > MPI_Fint *info, MPI_Fint *fh, MPI_Fint *ierr, int str_len ); 97,98c101,102 < void mpi_file_open_(MPI_Fint *comm,char *filename,int *amode, < MPI_Fint *info, MPI_Fint *fh, int *ierr, int str_len ) --- > void mpi_file_open_(MPI_Fint *comm,char *filename,MPI_Fint *amode, > MPI_Fint *info, MPI_Fint *fh, MPI_Fint *ierr, int str_len ) 134,135c138,139 < void mpi_file_open_(MPI_Comm *comm,_fcd filename_fcd,int *amode, < MPI_Fint *info, MPI_Fint *fh, int *ierr) --- > void mpi_file_open_(MPI_Fint *comm,_fcd filename_fcd,MPI_Fint *amode, > MPI_Fint *info, MPI_Fint *fh, MPI_Fint *ierr) 149,150c153,154 < FORTRAN_API void FORT_CALL mpi_file_open_(MPI_Comm *comm,char *filename FORT_MIXED_LEN_DECL,int *amode, < MPI_Fint *info, MPI_Fint *fh, int *ierr FORT_END_LEN_DECL); --- > FORTRAN_API void FORT_CALL mpi_file_open_(MPI_Fint *comm,char *filename FORT_MIXED_LEN_DECL,MPI_Fint *amode, > MPI_Fint *info, MPI_Fint *fh, MPI_Fint *ierr FORT_END_LEN_DECL); 152,153c156,157 < FORTRAN_API void FORT_CALL mpi_file_open_(MPI_Comm *comm,char *filename FORT_MIXED_LEN(str_len),int *amode, < MPI_Fint *info, MPI_Fint *fh, int *ierr FORT_END_LEN(str_len)) --- > FORTRAN_API void FORT_CALL mpi_file_open_(MPI_Fint *comm,char *filename FORT_MIXED_LEN(str_len),MPI_Fint *amode, > MPI_Fint *info, MPI_Fint *fh, MPI_Fint *ierr FORT_END_LEN(str_len)) 179c183 < *ierr = MPI_File_open(*comm, newfname, *amode, info_c, &fh_c); --- > *ierr = MPI_File_open((MPI_Comm)(*comm), newfname, *amode, info_c, &fh_c); Index: romio/mpi-io/fortran/preallocf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/preallocf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: preallocf.c,v 1.13 2002/10/24 17:01:22 gropp Exp $ --- > * $Id: preallocf.c,v 1.14 2003/07/08 22:25:45 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_PREALLOCATE( MPI_Fint *, MPI_Offset *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_preallocate__( MPI_Fint *, MPI_Offset *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_preallocate( MPI_Fint *, MPI_Offset *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_preallocate_( MPI_Fint *, MPI_Offset *, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_preallocate_(MPI_Fint *fh,MPI_Offset *size, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_preallocate_(MPI_Fint *fh,MPI_Offset *size, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_preallocate_(MPI_Fint *fh,MPI_Offset *size, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_preallocate_(MPI_Fint *fh,MPI_Offset *size, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/rd_atallbf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/rd_atallbf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: rd_atallbf.c,v 1.13 2002/10/24 17:01:22 gropp Exp $ --- > * $Id: rd_atallbf.c,v 1.14 2003/07/08 22:25:45 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_READ_AT_ALL_BEGIN( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_read_at_all_begin__( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_read_at_all_begin( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_read_at_all_begin_( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 92c96 < int *count,MPI_Fint *datatype, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype, MPI_Fint *ierr ); 95c99 < int *count,MPI_Fint *datatype, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype, MPI_Fint *ierr ) 108c112 < int *count,MPI_Datatype *datatype, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype, MPI_Fint *ierr ); 111c115 < int *count,MPI_Datatype *datatype, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype, MPI_Fint *ierr ) 116c120 < *ierr = MPI_File_read_at_all_begin(fh_c,*offset,buf,*count,*datatype); --- > *ierr = MPI_File_read_at_all_begin(fh_c,*offset,buf,*count,(MPI_Datatype) *datatype); Index: romio/mpi-io/fortran/rd_atallef.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/rd_atallef.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: rd_atallef.c,v 1.12 2002/10/24 17:01:22 gropp Exp $ --- > * $Id: rd_atallef.c,v 1.13 2003/07/08 22:25:45 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_READ_AT_ALL_END( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_read_at_all_end__( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_read_at_all_end( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_read_at_all_end_( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_read_at_all_end_(MPI_Fint *fh,void *buf,MPI_Status *status, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_read_at_all_end_(MPI_Fint *fh,void *buf,MPI_Status *status, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_read_at_all_end_(MPI_Fint *fh,void *buf,MPI_Status *status, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_read_at_all_end_(MPI_Fint *fh,void *buf,MPI_Status *status, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/read_allbf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/read_allbf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: read_allbf.c,v 1.13 2002/10/24 17:01:22 gropp Exp $ --- > * $Id: read_allbf.c,v 1.14 2003/07/08 22:25:46 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_READ_ALL_BEGIN( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_read_all_begin__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_read_all_begin( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_read_all_begin_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 91,92c95,96 < void mpi_file_read_all_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype, int *ierr ); --- > void mpi_file_read_all_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype, MPI_Fint *ierr ); 94,95c98,99 < void mpi_file_read_all_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,int *ierr ) --- > void mpi_file_read_all_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Fint *ierr ) 107,108c111,112 < FORTRAN_API void FORT_CALL mpi_file_read_all_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_read_all_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype, MPI_Fint *ierr ); 110,111c114,115 < FORTRAN_API void FORT_CALL mpi_file_read_all_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype, int *ierr ){ --- > FORTRAN_API void FORT_CALL mpi_file_read_all_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype, MPI_Fint *ierr ){ 115c119 < *ierr = MPI_File_read_all_begin(fh_c,buf,*count,*datatype); --- > *ierr = MPI_File_read_all_begin(fh_c,buf,*count,(MPI_Datatype) *datatype); Index: romio/mpi-io/fortran/read_allef.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/read_allef.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: read_allef.c,v 1.12 2002/10/24 17:01:23 gropp Exp $ --- > * $Id: read_allef.c,v 1.13 2003/07/08 22:25:46 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_READ_ALL_END( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_read_all_end__( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_read_all_end( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_read_all_end_( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 91c95 < int *ierr ); --- > MPI_Fint *ierr ); 93c97 < FORTRAN_API void FORT_CALL mpi_file_read_all_end_(MPI_Fint *fh,void *buf,MPI_Status *status, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_read_all_end_(MPI_Fint *fh,void *buf,MPI_Status *status, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/read_allf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/read_allf.c,v retrieving revision 1.15 retrieving revision 1.16 diff -r1.15 -r1.16 3c3 < * $Id: read_allf.c,v 1.15 2002/10/24 17:01:23 gropp Exp $ --- > * $Id: read_allf.c,v 1.16 2003/07/08 22:25:46 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_READ_ALL( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_read_all__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_read_all( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_read_all_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 91,92c95,96 < void mpi_file_read_all_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ); --- > void mpi_file_read_all_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 94,95c98,99 < void mpi_file_read_all_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ) --- > void mpi_file_read_all_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ) 107,108c111,112 < FORTRAN_API void FORT_CALL mpi_file_read_all_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_read_all_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 110,111c114,115 < FORTRAN_API void FORT_CALL mpi_file_read_all_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ){ --- > FORTRAN_API void FORT_CALL mpi_file_read_all_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ){ 115c119 < *ierr = MPI_File_read_all(fh_c,buf,*count,*datatype,status); --- > *ierr = MPI_File_read_all(fh_c,buf,*count,(MPI_Datatype)*datatype,status); Index: romio/mpi-io/fortran/read_atallf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/read_atallf.c,v retrieving revision 1.14 retrieving revision 1.15 diff -r1.14 -r1.15 3c3 < * $Id: read_atallf.c,v 1.14 2002/10/24 17:01:23 gropp Exp $ --- > * $Id: read_atallf.c,v 1.15 2003/07/08 22:25:46 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_READ_AT_ALL( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_read_at_all__( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_read_at_all( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_read_at_all_( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 92,93c96,97 < int *count,MPI_Fint *datatype, < MPI_Status *status, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Status *status, MPI_Fint *ierr ); 96,97c100,101 < int *count,MPI_Fint *datatype, < MPI_Status *status, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Status *status, MPI_Fint *ierr ) 110,111c114,115 < int *count,MPI_Datatype *datatype, < MPI_Status *status, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Status *status, MPI_Fint *ierr ); 114,115c118,119 < int *count,MPI_Datatype *datatype, < MPI_Status *status, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Status *status, MPI_Fint *ierr ) 120c124 < *ierr = MPI_File_read_at_all(fh_c,*offset,buf,*count,*datatype,status); --- > *ierr = MPI_File_read_at_all(fh_c,*offset,buf,*count,(MPI_Datatype)*datatype,status); Index: romio/mpi-io/fortran/read_atf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/read_atf.c,v retrieving revision 1.14 retrieving revision 1.15 diff -r1.14 -r1.15 3c3 < * $Id: read_atf.c,v 1.14 2002/10/24 17:01:23 gropp Exp $ --- > * $Id: read_atf.c,v 1.15 2003/07/08 22:25:46 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_READ_AT( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_read_at__( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_read_at( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_read_at_( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 92c96 < int *count,MPI_Fint *datatype,MPI_Status *status, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 95c99 < int *count,MPI_Fint *datatype,MPI_Status *status, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ) 108c112 < int *count,MPI_Datatype *datatype,MPI_Status *status, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 111c115 < int *count,MPI_Datatype *datatype,MPI_Status *status, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ) 116c120 < *ierr = MPI_File_read_at(fh_c,*offset,buf,*count,*datatype,status); --- > *ierr = MPI_File_read_at(fh_c,*offset,buf,*count,(MPI_Datatype)*datatype,status); Index: romio/mpi-io/fortran/read_ordbf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/read_ordbf.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: read_ordbf.c,v 1.12 2002/10/24 17:01:23 gropp Exp $ --- > * $Id: read_ordbf.c,v 1.13 2003/07/08 22:25:46 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_READ_ORDERED_BEGIN( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_read_ordered_begin__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_read_ordered_begin( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_read_ordered_begin_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 91,92c95,96 < void mpi_file_read_ordered_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,int *ierr ); --- > void mpi_file_read_ordered_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Fint *ierr ); 94,95c98,99 < void mpi_file_read_ordered_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,int *ierr ) --- > void mpi_file_read_ordered_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Fint *ierr ) 107,108c111,112 < FORTRAN_API void FORT_CALL mpi_file_read_ordered_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_read_ordered_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Fint *ierr ); 110,111c114,115 < FORTRAN_API void FORT_CALL mpi_file_read_ordered_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,int *ierr ){ --- > FORTRAN_API void FORT_CALL mpi_file_read_ordered_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Fint *ierr ){ 115c119 < *ierr = MPI_File_read_ordered_begin(fh_c,buf,*count,*datatype); --- > *ierr = MPI_File_read_ordered_begin(fh_c,buf,*count,(MPI_Datatype)*datatype); Index: romio/mpi-io/fortran/read_ordef.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/read_ordef.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: read_ordef.c,v 1.12 2002/10/24 17:01:23 gropp Exp $ --- > * $Id: read_ordef.c,v 1.13 2003/07/08 22:25:47 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_READ_ORDERED_END( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_read_ordered_end__( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_read_ordered_end( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_read_ordered_end_( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 91c95 < int *ierr ); --- > MPI_Fint *ierr ); 93c97 < FORTRAN_API void FORT_CALL mpi_file_read_ordered_end_(MPI_Fint *fh,void *buf,MPI_Status *status, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_read_ordered_end_(MPI_Fint *fh,void *buf,MPI_Status *status, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/read_ordf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/read_ordf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: read_ordf.c,v 1.13 2002/10/24 17:01:24 gropp Exp $ --- > * $Id: read_ordf.c,v 1.14 2003/07/08 22:25:47 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_READ_ORDERED( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_read_ordered__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_read_ordered( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_read_ordered_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 91,92c95,96 < void mpi_file_read_ordered_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ); --- > void mpi_file_read_ordered_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 94,95c98,99 < void mpi_file_read_ordered_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ) --- > void mpi_file_read_ordered_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ) 107,108c111,112 < FORTRAN_API void FORT_CALL mpi_file_read_ordered_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_read_ordered_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 110,111c114,115 < FORTRAN_API void FORT_CALL mpi_file_read_ordered_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ){ --- > FORTRAN_API void FORT_CALL mpi_file_read_ordered_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ){ 115c119 < *ierr = MPI_File_read_ordered(fh_c,buf,*count,*datatype,status); --- > *ierr = MPI_File_read_ordered(fh_c,buf,*count,(MPI_Datatype)*datatype,status); Index: romio/mpi-io/fortran/read_shf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/read_shf.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: read_shf.c,v 1.12 2002/10/24 17:01:24 gropp Exp $ --- > * $Id: read_shf.c,v 1.13 2003/07/08 22:25:47 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_READ_SHARED( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_read_shared__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_read_shared( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_read_shared_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 91,94c95,98 < void mpi_file_read_shared_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ); < void mpi_file_read_shared_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ) --- > void mpi_file_read_shared_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); > void mpi_file_read_shared_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ) 106,109c110,113 < FORTRAN_API void FORT_CALL mpi_file_read_shared_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ); < FORTRAN_API void FORT_CALL mpi_file_read_shared_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_read_shared_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); > FORTRAN_API void FORT_CALL mpi_file_read_shared_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ) 114c118 < *ierr = MPI_File_read_shared(fh_c,buf,*count,*datatype,status); --- > *ierr = MPI_File_read_shared(fh_c,buf,*count,(MPI_Datatype)*datatype,status); Index: romio/mpi-io/fortran/readf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/readf.c,v retrieving revision 1.14 retrieving revision 1.15 diff -r1.14 -r1.15 3c3 < * $Id: readf.c,v 1.14 2002/10/24 17:01:24 gropp Exp $ --- > * $Id: readf.c,v 1.15 2003/07/08 22:25:47 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_READ( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_read__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_read( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_read_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 91,92c95,96 < void mpi_file_read_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ); --- > void mpi_file_read_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 94,95c98,99 < void mpi_file_read_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ) --- > void mpi_file_read_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ) 107,108c111,112 < FORTRAN_API void FORT_CALL mpi_file_read_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_read_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 110,111c114,115 < FORTRAN_API void FORT_CALL mpi_file_read_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_read_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ) 116c120 < *ierr = MPI_File_read(fh_c,buf,*count,*datatype,status); --- > *ierr = MPI_File_read(fh_c,buf,*count,(MPI_Datatype)*datatype,status); Index: romio/mpi-io/fortran/seek_shf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/seek_shf.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: seek_shf.c,v 1.12 2002/10/24 17:01:24 gropp Exp $ --- > * $Id: seek_shf.c,v 1.13 2003/07/08 22:25:47 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_SEEK_SHARED( MPI_Fint *, MPI_Offset *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_seek_shared__( MPI_Fint *, MPI_Offset *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_seek_shared( MPI_Fint *, MPI_Offset *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_seek_shared_( MPI_Fint *, MPI_Offset *, MPI_Fint *, MPI_Fint * ); 90,91c94,95 < FORTRAN_API void FORT_CALL mpi_file_seek_shared_(MPI_Fint *fh,MPI_Offset *offset,int *whence, < int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_seek_shared_(MPI_Fint *fh,MPI_Offset *offset,MPI_Fint *whence, > MPI_Fint *ierr ); 93c97 < FORTRAN_API void FORT_CALL mpi_file_seek_shared_(MPI_Fint *fh,MPI_Offset *offset,int *whence, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_seek_shared_(MPI_Fint *fh,MPI_Offset *offset,MPI_Fint *whence, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/seekf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/seekf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: seekf.c,v 1.13 2002/10/24 17:01:24 gropp Exp $ --- > * $Id: seekf.c,v 1.14 2003/07/08 22:25:47 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_SEEK( MPI_Fint *, MPI_Offset *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_seek__( MPI_Fint *, MPI_Offset *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_seek( MPI_Fint *, MPI_Offset *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_seek_( MPI_Fint *, MPI_Offset *, MPI_Fint *, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_seek_(MPI_Fint *fh,MPI_Offset *offset,int *whence, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_seek_(MPI_Fint *fh,MPI_Offset *offset,MPI_Fint *whence, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_seek_(MPI_Fint *fh,MPI_Offset *offset,int *whence, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_seek_(MPI_Fint *fh,MPI_Offset *offset,MPI_Fint *whence, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/set_atomf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/set_atomf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: set_atomf.c,v 1.13 2002/10/24 17:01:24 gropp Exp $ --- > * $Id: set_atomf.c,v 1.14 2003/07/08 22:25:48 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_SET_ATOMICITY( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_set_atomicity__( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_set_atomicity( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_set_atomicity_( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_set_atomicity_(MPI_Fint *fh,int *flag, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_set_atomicity_(MPI_Fint *fh,MPI_Fint *flag, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_set_atomicity_(MPI_Fint *fh,int *flag, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_set_atomicity_(MPI_Fint *fh,MPI_Fint *flag, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/set_errhf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/set_errhf.c,v retrieving revision 1.8 retrieving revision 1.9 diff -r1.8 -r1.9 3c3 < * $Id: set_errhf.c,v 1.8 2002/10/24 17:01:25 gropp Exp $ --- > * $Id: set_errhf.c,v 1.9 2003/07/08 22:25:48 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_SET_ERRHANDLER( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_set_errhandler__( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_set_errhandler( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_set_errhandler_( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_set_errhandler_(MPI_Fint *fh, MPI_Fint *err_handler, int *ierr); --- > FORTRAN_API void FORT_CALL mpi_file_set_errhandler_(MPI_Fint *fh, MPI_Fint *err_handler, MPI_Fint *ierr); 92c96 < FORTRAN_API void FORT_CALL mpi_file_set_errhandler_(MPI_Fint *fh, MPI_Fint *err_handler, int *ierr) --- > FORTRAN_API void FORT_CALL mpi_file_set_errhandler_(MPI_Fint *fh, MPI_Fint *err_handler, MPI_Fint *ierr) Index: romio/mpi-io/fortran/set_infof.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/set_infof.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: set_infof.c,v 1.13 2002/10/24 17:01:25 gropp Exp $ --- > * $Id: set_infof.c,v 1.14 2003/07/08 22:25:48 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_SET_INFO( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_set_info__( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_set_info( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_set_info_( MPI_Fint *, MPI_Fint *, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_set_info_(MPI_Fint *fh, MPI_Fint *info, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_set_info_(MPI_Fint *fh, MPI_Fint *info, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_set_info_(MPI_Fint *fh, MPI_Fint *info, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_set_info_(MPI_Fint *fh, MPI_Fint *info, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/set_sizef.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/set_sizef.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: set_sizef.c,v 1.13 2002/10/24 17:01:25 gropp Exp $ --- > * $Id: set_sizef.c,v 1.14 2003/07/08 22:25:48 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_SET_SIZE( MPI_Fint *, MPI_Offset *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_set_size__( MPI_Fint *, MPI_Offset *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_set_size( MPI_Fint *, MPI_Offset *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_set_size_( MPI_Fint *, MPI_Offset *, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_set_size_(MPI_Fint *fh,MPI_Offset *size, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_set_size_(MPI_Fint *fh,MPI_Offset *size, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_set_size_(MPI_Fint *fh,MPI_Offset *size, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_set_size_(MPI_Fint *fh,MPI_Offset *size, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/set_viewf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/set_viewf.c,v retrieving revision 1.15 retrieving revision 1.16 diff -r1.15 -r1.16 3c3 < * $Id: set_viewf.c,v 1.15 2002/10/24 17:01:25 gropp Exp $ --- > * $Id: set_viewf.c,v 1.16 2003/07/08 22:25:48 thakur Exp $ 20a21 > extern FORTRAN_API void FORT_CALL MPI_FILE_SET_VIEW( MPI_Fint *, MPI_Offset *, MPI_Fint *, MPI_Fint *, char * FORT_MIXED_LEN_DECL, MPI_Fint *, MPI_Fint * FORT_END_LEN_DECL ); 22a24 > extern FORTRAN_API void FORT_CALL mpi_file_set_view__( MPI_Fint *, MPI_Offset *, MPI_Fint *, MPI_Fint *, char * FORT_MIXED_LEN_DECL, MPI_Fint *, MPI_Fint * FORT_END_LEN_DECL ); 24a27 > extern FORTRAN_API void FORT_CALL mpi_file_set_view( MPI_Fint *, MPI_Offset *, MPI_Fint *, MPI_Fint *, char * FORT_MIXED_LEN_DECL, MPI_Fint *, MPI_Fint * FORT_END_LEN_DECL ); 26a30 > extern FORTRAN_API void FORT_CALL mpi_file_set_view_( MPI_Fint *, MPI_Offset *, MPI_Fint *, MPI_Fint *, char * FORT_MIXED_LEN_DECL, MPI_Fint *, MPI_Fint * FORT_END_LEN_DECL ); 145,147c149 < FORTRAN_API void FORT_CALL mpi_file_set_view_(MPI_Fint *fh,MPI_Offset *disp,MPI_Datatype *etype, < MPI_Datatype *filetype,char *datarep,MPI_Fint *info, int *ierr, < int str_len ); --- > FORTRAN_API void FORT_CALL mpi_file_set_view_( MPI_Fint *fh, MPI_Offset *disp, MPI_Fint *etype, MPI_Fint *filetype, char *datarep FORT_MIXED_LEN_DECL, MPI_Fint *info, MPI_Fint *ierr FORT_END_LEN_DECL ); 149,151c151 < FORTRAN_API void FORT_CALL mpi_file_set_view_(MPI_Fint *fh,MPI_Offset *disp,MPI_Datatype *etype, < MPI_Datatype *filetype,char *datarep,MPI_Fint *info, int *ierr, < int str_len ) --- > FORTRAN_API void FORT_CALL mpi_file_set_view_( MPI_Fint *fh, MPI_Offset *disp, MPI_Fint *etype, MPI_Fint *filetype, char *datarep FORT_MIXED_LEN(str_len), MPI_Fint *info, MPI_Fint *ierr FORT_END_LEN(str_len) ) Index: romio/mpi-io/fortran/wr_atallbf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/wr_atallbf.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: wr_atallbf.c,v 1.12 2002/10/24 17:01:25 gropp Exp $ --- > * $Id: wr_atallbf.c,v 1.13 2003/07/08 22:25:48 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_WRITE_AT_ALL_BEGIN( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_write_at_all_begin__( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_write_at_all_begin( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_write_at_all_begin_( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 93c97 < int *count,MPI_Fint *datatype, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype, MPI_Fint *ierr ); 96c100 < int *count,MPI_Fint *datatype, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype, MPI_Fint *ierr ) 109c113 < int *count,MPI_Datatype *datatype, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype, MPI_Fint *ierr ); 112c116 < int *count,MPI_Datatype *datatype, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype, MPI_Fint *ierr ) 117c121 < *ierr = MPI_File_write_at_all_begin(fh_c,*offset,buf,*count,*datatype); --- > *ierr = MPI_File_write_at_all_begin(fh_c,*offset,buf,*count,(MPI_Datatype)*datatype); Index: romio/mpi-io/fortran/wr_atallef.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/wr_atallef.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: wr_atallef.c,v 1.12 2002/10/24 17:01:25 gropp Exp $ --- > * $Id: wr_atallef.c,v 1.13 2003/07/08 22:25:49 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_WRITE_AT_ALL_END( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_write_at_all_end__( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_write_at_all_end( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_write_at_all_end_( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 91c95 < int *ierr ); --- > MPI_Fint *ierr ); 93c97 < FORTRAN_API void FORT_CALL mpi_file_write_at_all_end_(MPI_Fint *fh,void *buf,MPI_Status *status, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_write_at_all_end_(MPI_Fint *fh,void *buf,MPI_Status *status, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/write_allbf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/write_allbf.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: write_allbf.c,v 1.12 2002/10/24 17:01:26 gropp Exp $ --- > * $Id: write_allbf.c,v 1.13 2003/07/08 22:25:49 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_WRITE_ALL_BEGIN( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_write_all_begin__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_write_all_begin( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_write_all_begin_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 91,94c95,98 < void mpi_file_write_all_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype, int *ierr ); < void mpi_file_write_all_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype, int *ierr ){ --- > void mpi_file_write_all_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype, MPI_Fint *ierr ); > void mpi_file_write_all_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype, MPI_Fint *ierr ){ 105,108c109,112 < FORTRAN_API void FORT_CALL mpi_file_write_all_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype, int *ierr ); < FORTRAN_API void FORT_CALL mpi_file_write_all_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype, int *ierr ){ --- > FORTRAN_API void FORT_CALL mpi_file_write_all_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype, MPI_Fint *ierr ); > FORTRAN_API void FORT_CALL mpi_file_write_all_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype, MPI_Fint *ierr ){ 112c116 < *ierr = MPI_File_write_all_begin(fh_c,buf,*count,*datatype); --- > *ierr = MPI_File_write_all_begin(fh_c,buf,*count,(MPI_Datatype)*datatype); Index: romio/mpi-io/fortran/write_allef.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/write_allef.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: write_allef.c,v 1.12 2002/10/24 17:01:26 gropp Exp $ --- > * $Id: write_allef.c,v 1.13 2003/07/08 22:25:49 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_WRITE_ALL_END( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_write_all_end__( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_write_all_end( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_write_all_end_( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 90c94 < FORTRAN_API void FORT_CALL mpi_file_write_all_end_(MPI_Fint *fh,void *buf,MPI_Status *status, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_write_all_end_(MPI_Fint *fh,void *buf,MPI_Status *status, MPI_Fint *ierr ); 92c96 < FORTRAN_API void FORT_CALL mpi_file_write_all_end_(MPI_Fint *fh,void *buf,MPI_Status *status, int *ierr ){ --- > FORTRAN_API void FORT_CALL mpi_file_write_all_end_(MPI_Fint *fh,void *buf,MPI_Status *status, MPI_Fint *ierr ){ Index: romio/mpi-io/fortran/write_allf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/write_allf.c,v retrieving revision 1.14 retrieving revision 1.15 diff -r1.14 -r1.15 3c3 < * $Id: write_allf.c,v 1.14 2002/10/24 17:01:26 gropp Exp $ --- > * $Id: write_allf.c,v 1.15 2003/07/08 22:25:49 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_WRITE_ALL( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_write_all__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_write_all( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_write_all_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 91,92c95,96 < void mpi_file_write_all_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ); --- > void mpi_file_write_all_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 94,95c98,99 < void mpi_file_write_all_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ){ --- > void mpi_file_write_all_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ){ 106,107c110,111 < FORTRAN_API void FORT_CALL mpi_file_write_all_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_write_all_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 109,110c113,114 < FORTRAN_API void FORT_CALL mpi_file_write_all_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ){ --- > FORTRAN_API void FORT_CALL mpi_file_write_all_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ){ Index: romio/mpi-io/fortran/write_atallf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/write_atallf.c,v retrieving revision 1.14 retrieving revision 1.15 diff -r1.14 -r1.15 3c3 < * $Id: write_atallf.c,v 1.14 2002/10/24 17:01:26 gropp Exp $ --- > * $Id: write_atallf.c,v 1.15 2003/07/08 22:25:49 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_WRITE_AT_ALL( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_write_at_all__( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_write_at_all( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_write_at_all_( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 92,93c96,97 < int *count,MPI_Fint *datatype, < MPI_Status *status, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Status *status, MPI_Fint *ierr ); 96,97c100,101 < int *count,MPI_Fint *datatype, < MPI_Status *status, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Status *status, MPI_Fint *ierr ) 110,111c114,115 < int *count,MPI_Datatype *datatype, < MPI_Status *status, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Status *status, MPI_Fint *ierr ); 114,115c118,119 < int *count,MPI_Datatype *datatype, < MPI_Status *status, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Status *status, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/write_atf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/write_atf.c,v retrieving revision 1.14 retrieving revision 1.15 diff -r1.14 -r1.15 3c3 < * $Id: write_atf.c,v 1.14 2002/10/24 17:01:26 gropp Exp $ --- > * $Id: write_atf.c,v 1.15 2003/07/08 22:25:49 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_WRITE_AT( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_write_at__( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_write_at( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_write_at_( MPI_Fint *, MPI_Offset *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 92,93c96,97 < int *count,MPI_Fint *datatype, < MPI_Status *status, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Status *status, MPI_Fint *ierr ); 96,97c100,101 < int *count,MPI_Fint *datatype, < MPI_Status *status, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Status *status, MPI_Fint *ierr ) 110,111c114,115 < int *count,MPI_Datatype *datatype, < MPI_Status *status, int *ierr ); --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Status *status, MPI_Fint *ierr ); 114,115c118,119 < int *count,MPI_Datatype *datatype, < MPI_Status *status, int *ierr ) --- > MPI_Fint *count,MPI_Fint *datatype, > MPI_Status *status, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/write_ordbf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/write_ordbf.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: write_ordbf.c,v 1.12 2002/10/24 17:01:26 gropp Exp $ --- > * $Id: write_ordbf.c,v 1.13 2003/07/08 22:25:50 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_WRITE_ORDERED_BEGIN( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_write_ordered_begin__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_write_ordered_begin( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_write_ordered_begin_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Fint * ); 91,92c95,96 < void mpi_file_write_ordered_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype, int *ierr ); --- > void mpi_file_write_ordered_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype, MPI_Fint *ierr ); 95c99 < MPI_Fint *datatype, int *ierr ){ --- > MPI_Fint *datatype, MPI_Fint *ierr ){ 106,107c110,111 < FORTRAN_API void FORT_CALL mpi_file_write_ordered_begin_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_write_ordered_begin_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype, MPI_Fint *ierr ); 110c114 < MPI_Datatype *datatype, int *ierr ){ --- > MPI_Fint *datatype, MPI_Fint *ierr ){ Index: romio/mpi-io/fortran/write_ordef.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/write_ordef.c,v retrieving revision 1.12 retrieving revision 1.13 diff -r1.12 -r1.13 3c3 < * $Id: write_ordef.c,v 1.12 2002/10/24 17:01:26 gropp Exp $ --- > * $Id: write_ordef.c,v 1.13 2003/07/08 22:25:50 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_WRITE_ORDERED_END( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_write_ordered_end__( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_write_ordered_end( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_write_ordered_end_( MPI_Fint *, void*, MPI_Status*, MPI_Fint * ); 91c95 < int *ierr ); --- > MPI_Fint *ierr ); 93c97 < FORTRAN_API void FORT_CALL mpi_file_write_ordered_end_(MPI_Fint *fh,void *buf,MPI_Status *status, int *ierr ){ --- > FORTRAN_API void FORT_CALL mpi_file_write_ordered_end_(MPI_Fint *fh,void *buf,MPI_Status *status, MPI_Fint *ierr ){ Index: romio/mpi-io/fortran/write_ordf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/write_ordf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: write_ordf.c,v 1.13 2002/10/24 17:01:27 gropp Exp $ --- > * $Id: write_ordf.c,v 1.14 2003/07/08 22:25:50 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_WRITE_ORDERED( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_write_ordered__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_write_ordered( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_write_ordered_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 91,92c95,96 < void mpi_file_write_ordered_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ); --- > void mpi_file_write_ordered_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 94,95c98,99 < void mpi_file_write_ordered_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ){ --- > void mpi_file_write_ordered_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ){ 106,107c110,111 < FORTRAN_API void FORT_CALL mpi_file_write_ordered_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_write_ordered_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 109,110c113,114 < FORTRAN_API void FORT_CALL mpi_file_write_ordered_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ){ --- > FORTRAN_API void FORT_CALL mpi_file_write_ordered_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ){ Index: romio/mpi-io/fortran/write_shf.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/write_shf.c,v retrieving revision 1.13 retrieving revision 1.14 diff -r1.13 -r1.14 3c3 < * $Id: write_shf.c,v 1.13 2002/10/24 17:01:27 gropp Exp $ --- > * $Id: write_shf.c,v 1.14 2003/07/08 22:25:50 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_WRITE_SHARED( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_write_shared__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_write_shared( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_write_shared_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 91,92c95,96 < void mpi_file_write_shared_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ); --- > void mpi_file_write_shared_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 94,95c98,99 < void mpi_file_write_shared_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ) --- > void mpi_file_write_shared_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ) 107,108c111,112 < FORTRAN_API void FORT_CALL mpi_file_write_shared_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_write_shared_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 111c115 < MPI_Datatype *datatype,MPI_Status *status, int *ierr ) --- > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ) Index: romio/mpi-io/fortran/writef.c =================================================================== RCS file: /MPIhome/romio/mpi-io/fortran/writef.c,v retrieving revision 1.14 retrieving revision 1.15 diff -r1.14 -r1.15 3c3 < * $Id: writef.c,v 1.14 2002/10/24 17:01:27 gropp Exp $ --- > * $Id: writef.c,v 1.15 2003/07/08 22:25:50 thakur Exp $ 17a18 > extern FORTRAN_API void FORT_CALL MPI_FILE_WRITE( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 19a21 > extern FORTRAN_API void FORT_CALL mpi_file_write__( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 21a24 > extern FORTRAN_API void FORT_CALL mpi_file_write( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 23a27 > extern FORTRAN_API void FORT_CALL mpi_file_write_( MPI_Fint *, void*, MPI_Fint *, MPI_Fint *, MPI_Status*, MPI_Fint * ); 91,92c95,96 < void mpi_file_write_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ); --- > void mpi_file_write_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 94,95c98,99 < void mpi_file_write_(MPI_Fint *fh,void *buf,int *count, < MPI_Fint *datatype,MPI_Status *status, int *ierr ) --- > void mpi_file_write_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ) 107,108c111,112 < FORTRAN_API void FORT_CALL mpi_file_write_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ); --- > FORTRAN_API void FORT_CALL mpi_file_write_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ); 110,111c114,115 < FORTRAN_API void FORT_CALL mpi_file_write_(MPI_Fint *fh,void *buf,int *count, < MPI_Datatype *datatype,MPI_Status *status, int *ierr ) --- > FORTRAN_API void FORT_CALL mpi_file_write_(MPI_Fint *fh,void *buf,MPI_Fint *count, > MPI_Fint *datatype,MPI_Status *status, MPI_Fint *ierr ) Index: romio/test/noncontig_coll2.c =================================================================== RCS file: /MPIhome/romio/test/noncontig_coll2.c,v retrieving revision 1.5 retrieving revision 1.8 diff -r1.5 -r1.8 1a2,5 > /* > * (C) 2001 by Argonne National Laboratory. > * See COPYRIGHT in top-level directory. > */ 246c250 < MPI_Bcast(dest, len+1, MPI_CHAR, 0, MPI_COMM_WORLD); --- > MPI_Bcast(dest, len, MPI_CHAR, 0, MPI_COMM_WORLD); 260c264 < MPI_Bcast(dest, len+1, MPI_CHAR, 0, MPI_COMM_WORLD); --- > MPI_Bcast(dest, len, MPI_CHAR, 0, MPI_COMM_WORLD); 281c285 < MPI_Bcast(dest, len+1, MPI_CHAR, 0, MPI_COMM_WORLD); --- > MPI_Bcast(dest, len, MPI_CHAR, 0, MPI_COMM_WORLD); 300c304 < MPI_Bcast(dest, len+1, MPI_CHAR, 0, MPI_COMM_WORLD); --- > MPI_Bcast(dest, len, MPI_CHAR, 0, MPI_COMM_WORLD); 358a363 > ++cb_config_len; 389c394 < else printf("No errors.\n"); --- > else printf(" No Errors\n"); Index: src/coll/intra_fns_new.c =================================================================== RCS file: /MPIhome/mpich/src/coll/intra_fns_new.c,v retrieving revision 1.20 retrieving revision 1.27 diff -r1.20 -r1.27 2c2 < * $Id: intra_fns_new.c,v 1.20 2002/12/04 23:01:04 thakur Exp $ --- > * $Id: intra_fns_new.c,v 1.27 2003/04/07 23:34:28 thakur Exp $ 16a17 > #define MPIR_BCAST_LONG_MSG 524288 20a22,24 > #define MPIR_ALLGATHER_LONG_MSG 524288 > #define MPIR_REDUCE_SHORT_MSG 2048 > #define MPIR_ALLREDUCE_SHORT_MSG 2048 22c26,27 < #define MPIR_REDUCE_SCATTER_SHORT_MSG 512 --- > #define MPIR_REDSCAT_COMMUTATIVE_LONG_MSG 524288 > #define MPIR_REDSCAT_NONCOMMUTATIVE_SHORT_MSG 512 277c282 < For short messages, we use a minimum spanning tree (MST) algorithm. --- > For short messages, we use a binary tree algorithm. 282c287 < We first scatter the buffer using an MST algorithm. This costs --- > We first scatter the buffer using a binary tree algorithm. This costs 290,295c295,301 < For the allgather, we use a recursive doubling algorithm. This < takes lgp steps. In each step pairs of processes exchange all the < data they have (we take care of non-power-of-two situations). This < costs approximately lgp.alpha + n.((p-1)/p).beta. (Approximately < because it may be slightly more in the non-power-of-two case, but < it's still a logarithmic algorithm.) Therefore, for long messages --- > For the allgather, we use a recursive doubling algorithm for > medium-size messages. This takes lgp steps. In each step pairs > of processes exchange all the data they have (we take care of > non-power-of-two situations). This costs approximately lgp.alpha + > n.((p-1)/p).beta. (Approximately because it may be slightly more in > the non-power-of-two case, but it's still a logarithmic algorithm.) > Therefore, for long messages 299c305 < Note that this algorithm has twice the latency as the MST algorithm --- > Note that this algorithm has twice the latency as the tree algorithm 303a310,313 > For very long messages, we use a ring algorithm for the allgather, which > takes p-1 steps because it performs better than recursive doubling. > Total Cost = (lgp+p-1).alpha + 2.n.((p-1)/p).beta > 308,309c318 < End Algorithm: MPI_Bcast < */ --- > End Algorithm: MPI_Bcast */ 325a335 > int *recvcnts, *displs, left, right, jnext; 392c402 < if ((nbytes < MPIR_BCAST_SHORT_MSG) && (size <= MPIR_BCAST_MIN_PROCS)) { --- > if ((nbytes < MPIR_BCAST_SHORT_MSG) || (size <= MPIR_BCAST_MIN_PROCS)) { 489c499 < /* use long message algorithm: MST scatter followed by an allgather */ --- > /* use long message algorithm: binary tree scatter followed by an allgather */ 493,494c503,504 < root+1 gets the second piece, and so forth. Uses the same minimum < spanning tree (MST) algorithm as above. Ceiling division --- > root+1 gets the second piece, and so forth. Uses the same binary > tree algorithm as above. Ceiling division 575,611c585 < /* Scatter complete. Now do an allgather using recursive < doubling. The basic recursive doubling algorithm works for < power-of-two number of processes. We modify it for < non-powers-of-two. */ < < mask = 0x1; < i = 0; < while (mask < size) { < relative_dst = relative_rank ^ mask; < < dst = (relative_dst + root) % size; < < /* find offset into send and recv buffers. < zero out the least significant "i" bits of relative_rank and < relative_dst to find root of src and dst < subtrees. Use ranks of roots as index to send from < and recv into buffer */ < < dst_tree_root = relative_dst >> i; < dst_tree_root <<= i; < < my_tree_root = relative_rank >> i; < my_tree_root <<= i; < < send_offset = my_tree_root * scatter_size; < recv_offset = dst_tree_root * scatter_size; < < if (relative_dst < size) { < mpi_errno = MPI_Sendrecv((void *)((char *)tmp_buf + send_offset), < curr_size, MPI_BYTE, dst, MPIR_BCAST_TAG, < (void *)((char *)tmp_buf + recv_offset), < scatter_size*mask, MPI_BYTE, dst, < MPIR_BCAST_TAG, comm->self, &status); < if (mpi_errno) return mpi_errno; < MPI_Get_count(&status, MPI_BYTE, &recv_size); < curr_size += recv_size; < } --- > /* Scatter complete. Now do an allgather. */ 613,619c587,588 < /* if some processes in this process's subtree in this step < did not have any destination process to communicate with < because of non-power-of-two, we need to send them the < data that they would normally have received from those < processes. That is, the haves in this subtree must send to < the havenots. We use a logarithmic recursive-halfing algorithm < for this. */ --- > if (nbytes < MPIR_BCAST_LONG_MSG) { > /* short message allgather. use recurive doubling. */ 621,633c590,620 < if (dst_tree_root + mask > size) { < nprocs_completed = size - my_tree_root - mask; < /* nprocs_completed is the number of processes in this < subtree that have all the data. Send data to others < in a tree fashion. First find root of current tree < that is being divided into two. k is the number of < least-significant bits in this process's rank that < must be zeroed out to find the rank of the root */ < j = mask; < k = 0; < while (j) { < j >>= 1; < k++; --- > mask = 0x1; > i = 0; > while (mask < size) { > relative_dst = relative_rank ^ mask; > > dst = (relative_dst + root) % size; > > /* find offset into send and recv buffers. > zero out the least significant "i" bits of relative_rank and > relative_dst to find root of src and dst > subtrees. Use ranks of roots as index to send from > and recv into buffer */ > > dst_tree_root = relative_dst >> i; > dst_tree_root <<= i; > > my_tree_root = relative_rank >> i; > my_tree_root <<= i; > > send_offset = my_tree_root * scatter_size; > recv_offset = dst_tree_root * scatter_size; > > if (relative_dst < size) { > mpi_errno = MPI_Sendrecv((void *)((char *)tmp_buf + send_offset), > curr_size, MPI_BYTE, dst, MPIR_BCAST_TAG, > (void *)((char *)tmp_buf + recv_offset), > scatter_size*mask, MPI_BYTE, dst, > MPIR_BCAST_TAG, comm->self, &status); > if (mpi_errno) return mpi_errno; > MPI_Get_count(&status, MPI_BYTE, &recv_size); > curr_size += recv_size; 635,685c622,643 < k--; < < offset = scatter_size * (my_tree_root + mask); < tmp_mask = mask >> 1; < < while (tmp_mask) { < relative_dst = relative_rank ^ tmp_mask; < dst = (relative_dst + root) % size; < < tree_root = relative_rank >> k; < tree_root <<= k; < < /* send only if this proc has data and destination < doesn't have data. */ < < /* if (rank == 3) { < printf("rank %d, dst %d, root %d, nprocs_completed %d\n", relative_rank, relative_dst, tree_root, nprocs_completed); < fflush(stdout); < }*/ < < if ((relative_dst > relative_rank) && < (relative_rank < tree_root + nprocs_completed) < && (relative_dst >= tree_root + nprocs_completed)) { < < /* printf("Rank %d, send to %d, offset %d, size %d\n", rank, dst, offset, recv_size); < fflush(stdout); */ < mpi_errno = MPI_Send(((char *)tmp_buf + offset), < recv_size, MPI_BYTE, dst, < MPIR_BCAST_TAG, comm->self); < /* recv_size was set in the previous < receive. that's the amount of data to be < sent now. */ < if (mpi_errno) return mpi_errno; < } < /* recv only if this proc. doesn't have data and sender < has data */ < else if ((relative_dst < relative_rank) && < (relative_dst < tree_root + nprocs_completed) && < (relative_rank >= tree_root + nprocs_completed)) { < /* printf("Rank %d waiting to recv from rank %d\n", < relative_rank, dst); */ < mpi_errno = MPI_Recv(((char *)tmp_buf + offset), < scatter_size*nprocs_completed, MPI_BYTE, < dst, MPIR_BCAST_TAG, comm->self, &status); < /* nprocs_completed is also equal to the no. of processes < whose data we don't have */ < if (mpi_errno) return mpi_errno; < MPI_Get_count(&status, MPI_BYTE, &recv_size); < curr_size += recv_size; < /* printf("Rank %d, recv from %d, offset %d, size %d\n", rank, dst, offset, recv_size); < fflush(stdout);*/ --- > > /* if some processes in this process's subtree in this step > did not have any destination process to communicate with > because of non-power-of-two, we need to send them the > data that they would normally have received from those > processes. That is, the haves in this subtree must send to > the havenots. We use a logarithmic recursive-halfing algorithm > for this. */ > > if (dst_tree_root + mask > size) { > nprocs_completed = size - my_tree_root - mask; > /* nprocs_completed is the number of processes in this > subtree that have all the data. Send data to others > in a tree fashion. First find root of current tree > that is being divided into two. k is the number of > least-significant bits in this process's rank that > must be zeroed out to find the rank of the root */ > j = mask; > k = 0; > while (j) { > j >>= 1; > k++; 687d644 < tmp_mask >>= 1; 688a646,699 > > offset = scatter_size * (my_tree_root + mask); > tmp_mask = mask >> 1; > > while (tmp_mask) { > relative_dst = relative_rank ^ tmp_mask; > dst = (relative_dst + root) % size; > > tree_root = relative_rank >> k; > tree_root <<= k; > > /* send only if this proc has data and destination > doesn't have data. */ > > /* if (rank == 3) { > printf("rank %d, dst %d, root %d, nprocs_completed %d\n", relative_rank, relative_dst, tree_root, nprocs_completed); > fflush(stdout); > }*/ > > if ((relative_dst > relative_rank) && > (relative_rank < tree_root + nprocs_completed) > && (relative_dst >= tree_root + nprocs_completed)) { > > /* printf("Rank %d, send to %d, offset %d, size %d\n", rank, dst, offset, recv_size); > fflush(stdout); */ > mpi_errno = MPI_Send(((char *)tmp_buf + offset), > recv_size, MPI_BYTE, dst, > MPIR_BCAST_TAG, comm->self); > /* recv_size was set in the previous > receive. that's the amount of data to be > sent now. */ > if (mpi_errno) return mpi_errno; > } > /* recv only if this proc. doesn't have data and sender > has data */ > else if ((relative_dst < relative_rank) && > (relative_dst < tree_root + nprocs_completed) && > (relative_rank >= tree_root + nprocs_completed)) { > /* printf("Rank %d waiting to recv from rank %d\n", > relative_rank, dst); */ > mpi_errno = MPI_Recv(((char *)tmp_buf + offset), > scatter_size*nprocs_completed, MPI_BYTE, > dst, MPIR_BCAST_TAG, comm->self, &status); > /* nprocs_completed is also equal to the no. of processes > whose data we don't have */ > if (mpi_errno) return mpi_errno; > MPI_Get_count(&status, MPI_BYTE, &recv_size); > curr_size += recv_size; > /* printf("Rank %d, recv from %d, offset %d, size %d\n", rank, dst, offset, recv_size); > fflush(stdout);*/ > } > tmp_mask >>= 1; > k--; > } 689a701,703 > > mask <<= 1; > i++; 690a705 > } 692,693c707,744 < mask <<= 1; < i++; --- > else { > /* long-message allgather. use ring algorithm. */ > MPIR_ALLOC(recvcnts, (int *)MALLOC(size*sizeof(int)), comm, > MPI_ERR_EXHAUSTED, "MPI_BCAST"); > MPIR_ALLOC(displs, (int *)MALLOC(size*sizeof(int)), comm, > MPI_ERR_EXHAUSTED, "MPI_BCAST"); > > for (i=0; i recvcnts[i] = nbytes - i*scatter_size; > if (recvcnts[i] > scatter_size) > recvcnts[i] = scatter_size; > if (recvcnts[i] < 0) > recvcnts[i] = 0; > } > > displs[0] = 0; > for (i=1; i displs[i] = displs[i-1] + recvcnts[i-1]; > > left = (size + rank - 1) % size; > right = (rank + 1) % size; > > j = rank; > jnext = left; > for (i=1; i mpi_errno = > MPI_Sendrecv((char *)tmp_buf+displs[(j-root+size)%size], > recvcnts[(j-root+size)%size], MPI_BYTE, right, MPIR_BCAST_TAG, > (char *)tmp_buf + displs[(jnext-root+size)%size], > recvcnts[(jnext-root+size)%size], MPI_BYTE, left, > MPIR_BCAST_TAG, comm->self, &status ); > if (mpi_errno) break; > j = jnext; > jnext = (size + jnext - 1) % size; > } > > FREE(recvcnts); > FREE(displs); 695a747 > 717c769 < We use a minimum spanning tree (MST) algorithm for both short and --- > We use a binary tree algorithm for both short and 751a804,805 > if (sendcnt == 0) return MPI_SUCCESS; > 780c834 < /* Use MST algorithm. */ --- > /* Use binary tree algorithm. */ 1086c1140 < We use a minimum spanning tree (MST) algorithm for both short and --- > We use a binary tree algorithm for both short and 1122a1177,1178 > if (recvcnt == 0) return MPI_SUCCESS; > 1150c1206 < /* Use MST algorithm */ --- > /* Use binary tree algorithm */ 1488,1491c1544,1547 < mpi_errno = MPI_Send( (void *)((char *)sendbuf+displs[i]*extent), < sendcnts[i], sendtype->self, i, MPIR_SCATTERV_TAG, comm->self); < if (mpi_errno) return mpi_errno; < } --- > mpi_errno = MPI_Send( (void *)((char *)sendbuf+displs[i]*extent), > sendcnts[i], sendtype->self, i, MPIR_SCATTERV_TAG, comm->self); > if (mpi_errno) return mpi_errno; > } 1538c1594 < For both short and long messages, we use a recursive doubling --- > For short and medium-size messages, we use a recursive doubling 1550c1606,1620 < the same cost as the MST algorithm for MPI_Gather! --- > the same cost as the tree algorithm for MPI_Gather! > > For long messages, we use a ring algorithm. In the first step, each > process i sends its contribution to process i+1 and receives > the contribution from process i-1 (with wrap-around). From the > second step onwards, each process i forwards to process i+1 the > data it received from process i-1 in the previous step. This takes > a total of p-1 steps. > > Cost = (p-1).alpha + n.((p-1)/p).beta > > We use this algorithm instead of recursive doubling for long > messages because we find that this communication pattern (nearest > neighbor) performs twice as fast as recursive doubling for long > messages (on Myrinet and IBM SP). 1575,1577c1645,1647 < #ifdef OLD < int left, right, jnext; < #endif --- > int left, right, jnext, type_size; > > if (sendcount == 0) return MPI_SUCCESS; 1593c1663 < if (sendcount == 0) return MPI_SUCCESS; --- > MPI_Type_size(sendtype->self, &type_size); 1601,1645c1671,1672 < /* use recursive doubling algorithm */ < < if (is_homogeneous) { < /* homogeneous. no need to pack into tmp_buf on each node. copy < local data into recvbuf */ < mpi_errno = MPI_Sendrecv ( sendbuf, sendcount, sendtype->self, < rank, MPIR_ALLGATHER_TAG, < ((char *)recvbuf + < rank*recvcount*recv_extent), < recvcount, recvtype->self, < rank, MPIR_ALLGATHER_TAG, < comm->self, &status ); < if (mpi_errno) return mpi_errno; < curr_cnt = recvcount; < < mask = 0x1; < i = 0; < while (mask < size) { < dst = rank ^ mask; < < /* find offset into send and recv buffers. zero out < the least significant "i" bits of rank and dst to < find root of src and dst subtrees. Use ranks of < roots as index to send from and recv into buffer */ < < dst_tree_root = dst >> i; < dst_tree_root <<= i; < < my_tree_root = rank >> i; < my_tree_root <<= i; < < send_offset = my_tree_root * recvcount * recv_extent; < recv_offset = dst_tree_root * recvcount * recv_extent; < < if (dst < size) { < mpi_errno = MPI_Sendrecv(((char *)recvbuf + send_offset), < curr_cnt, recvtype->self, dst, MPIR_ALLGATHER_TAG, < ((char *)recvbuf + recv_offset), < recvcount*mask, recvtype->self, dst, < MPIR_ALLGATHER_TAG, comm->self, &status); < if (mpi_errno) return mpi_errno; < < MPI_Get_count(&status, recvtype->self, &last_recv_cnt); < curr_cnt += last_recv_cnt; < } --- > if (sendcount*type_size < MPIR_ALLGATHER_LONG_MSG) { > /* short message. use recursive doubling algorithm */ 1647,1669c1674,1685 < /* if some processes in this process's subtree in this step < did not have any destination process to communicate with < because of non-power-of-two, we need to send them the < data that they would normally have received from those < processes. That is, the haves in this subtree must send to < the havenots. We use a logarithmic recursive-halfing algorithm < for this. */ < < if (dst_tree_root + mask > size) { < nprocs_completed = size - my_tree_root - mask; < /* nprocs_completed is the number of processes in this < subtree that have all the data. Send data to others < in a tree fashion. First find root of current tree < that is being divided into two. k is the number of < least-significant bits in this process's rank that < must be zeroed out to find the rank of the root */ < j = mask; < k = 0; < while (j) { < j >>= 1; < k++; < } < k--; --- > if (is_homogeneous) { > /* homogeneous. no need to pack into tmp_buf on each node. copy > local data into recvbuf */ > mpi_errno = MPI_Sendrecv ( sendbuf, sendcount, sendtype->self, > rank, MPIR_ALLGATHER_TAG, > ((char *)recvbuf + > rank*recvcount*recv_extent), > recvcount, recvtype->self, > rank, MPIR_ALLGATHER_TAG, > comm->self, &status ); > if (mpi_errno) return mpi_errno; > curr_cnt = recvcount; 1671,1675c1687,1712 < offset = recvcount * (my_tree_root + mask) * recv_extent; < tmp_mask = mask >> 1; < < while (tmp_mask) { < dst = rank ^ tmp_mask; --- > mask = 0x1; > i = 0; > while (mask < size) { > dst = rank ^ mask; > > /* find offset into send and recv buffers. zero out > the least significant "i" bits of rank and dst to > find root of src and dst subtrees. Use ranks of > roots as index to send from and recv into buffer */ > > dst_tree_root = dst >> i; > dst_tree_root <<= i; > > my_tree_root = rank >> i; > my_tree_root <<= i; > > send_offset = my_tree_root * recvcount * recv_extent; > recv_offset = dst_tree_root * recvcount * recv_extent; > > if (dst < size) { > mpi_errno = MPI_Sendrecv(((char *)recvbuf + send_offset), > curr_cnt, recvtype->self, dst, MPIR_ALLGATHER_TAG, > ((char *)recvbuf + recv_offset), > recvcount*mask, recvtype->self, dst, > MPIR_ALLGATHER_TAG, comm->self, &status); > if (mpi_errno) return mpi_errno; 1677,1678c1714,1716 < tree_root = rank >> k; < tree_root <<= k; --- > MPI_Get_count(&status, recvtype->self, &last_recv_cnt); > curr_cnt += last_recv_cnt; > } 1680,1707c1718,1738 < /* send only if this proc has data and destination < doesn't have data. at any step, multiple processes < can send if they have the data */ < if ((dst > rank) && < (rank < tree_root + nprocs_completed) < && (dst >= tree_root + nprocs_completed)) { < mpi_errno = MPI_Send(((char *)recvbuf + offset), < last_recv_cnt, < recvtype->self, dst, < MPIR_ALLGATHER_TAG, comm->self); < /* last_recv_cnt was set in the previous < receive. that's the amount of data to be < sent now. */ < if (mpi_errno) return mpi_errno; < } < /* recv only if this proc. doesn't have data and sender < has data */ < else if ((dst < rank) && < (dst < tree_root + nprocs_completed) && < (rank >= tree_root + nprocs_completed)) { < mpi_errno = MPI_Recv(((char *)recvbuf + offset), < recvcount*nprocs_completed, recvtype->self, < dst, MPIR_ALLGATHER_TAG, comm->self, &status); < /* nprocs_completed is also equal to the no. of processes < whose data we don't have */ < if (mpi_errno) return mpi_errno; < MPI_Get_count(&status, recvtype->self, &last_recv_cnt); < curr_cnt += last_recv_cnt; --- > /* if some processes in this process's subtree in this step > did not have any destination process to communicate with > because of non-power-of-two, we need to send them the > data that they would normally have received from those > processes. That is, the haves in this subtree must send to > the havenots. We use a logarithmic recursive-halfing algorithm > for this. */ > > if (dst_tree_root + mask > size) { > nprocs_completed = size - my_tree_root - mask; > /* nprocs_completed is the number of processes in this > subtree that have all the data. Send data to others > in a tree fashion. First find root of current tree > that is being divided into two. k is the number of > least-significant bits in this process's rank that > must be zeroed out to find the rank of the root */ > j = mask; > k = 0; > while (j) { > j >>= 1; > k++; 1709d1739 < tmp_mask >>= 1; 1710a1741,1782 > > offset = recvcount * (my_tree_root + mask) * recv_extent; > tmp_mask = mask >> 1; > > while (tmp_mask) { > dst = rank ^ tmp_mask; > > tree_root = rank >> k; > tree_root <<= k; > > /* send only if this proc has data and destination > doesn't have data. at any step, multiple processes > can send if they have the data */ > if ((dst > rank) && > (rank < tree_root + nprocs_completed) > && (dst >= tree_root + nprocs_completed)) { > mpi_errno = MPI_Send(((char *)recvbuf + offset), > last_recv_cnt, > recvtype->self, dst, > MPIR_ALLGATHER_TAG, comm->self); > /* last_recv_cnt was set in the previous > receive. that's the amount of data to be > sent now. */ > if (mpi_errno) return mpi_errno; > } > /* recv only if this proc. doesn't have data and sender > has data */ > else if ((dst < rank) && > (dst < tree_root + nprocs_completed) && > (rank >= tree_root + nprocs_completed)) { > mpi_errno = MPI_Recv(((char *)recvbuf + offset), > recvcount*nprocs_completed, recvtype->self, > dst, MPIR_ALLGATHER_TAG, comm->self, &status); > /* nprocs_completed is also equal to the no. of processes > whose data we don't have */ > if (mpi_errno) return mpi_errno; > MPI_Get_count(&status, recvtype->self, &last_recv_cnt); > curr_cnt += last_recv_cnt; > } > tmp_mask >>= 1; > k--; > } 1711a1784,1786 > > mask <<= 1; > i++; 1713,1715d1787 < < mask <<= 1; < i++; 1717,1755d1788 < } < < else { < /* heterogeneous. need to use temp. buffer. */ < MPI_Pack_size(recvcount*size, recvtype->self, comm->self, &tmp_buf_size); < MPIR_ALLOC(tmp_buf, (void *)MALLOC(tmp_buf_size), comm, < MPI_ERR_EXHAUSTED, "MPI_ALLGATHER"); < < /* calculate the value of nbytes, the number of bytes in packed < representation that each process contributes. We can't simply divide < tmp_buf_size by comm_size because tmp_buf_size is an upper < bound on the amount of memory required. (For example, for < a single integer, MPICH returns pack_size=12.) Therefore, we < actually pack some data into tmp_buf and see by how much < 'position' is incremented. */ < < position = 0; < MPI_Pack(recvbuf, 1, recvtype->self, tmp_buf, tmp_buf_size, < &position, comm->self); < nbytes = position*recvcount; < < /* pack local data into right location in tmp_buf */ < position = rank * nbytes; < MPI_Pack(sendbuf, sendcount, sendtype->self, tmp_buf, tmp_buf_size, < &position, comm->self); < curr_cnt = nbytes; < < mask = 0x1; < i = 0; < while (mask < size) { < dst = rank ^ mask; < < /* find offset into send and recv buffers. zero out < the least significant "i" bits of rank and dst to < find root of src and dst subtrees. Use ranks of < roots as index to send from and recv into buffer. */ < < dst_tree_root = dst >> i; < dst_tree_root <<= i; 1757,1769c1790,1794 < my_tree_root = rank >> i; < my_tree_root <<= i; < < send_offset = my_tree_root * nbytes; < recv_offset = dst_tree_root * nbytes; < < if (dst < size) { < mpi_errno = MPI_Sendrecv(((char *)tmp_buf + send_offset), < curr_cnt, MPI_BYTE, dst, MPIR_ALLGATHER_TAG, < ((char *)tmp_buf + recv_offset), < nbytes*mask, MPI_BYTE, dst, < MPIR_ALLGATHER_TAG, comm->self, &status); < if (mpi_errno) return mpi_errno; --- > else { > /* heterogeneous. need to use temp. buffer. */ > MPI_Pack_size(recvcount*size, recvtype->self, comm->self, &tmp_buf_size); > MPIR_ALLOC(tmp_buf, (void *)MALLOC(tmp_buf_size), comm, > MPI_ERR_EXHAUSTED, "MPI_ALLGATHER"); 1771,1797c1796,1802 < MPI_Get_count(&status, MPI_BYTE, &last_recv_cnt); < curr_cnt += last_recv_cnt; < } < < /* if some processes in this process's subtree in this step < did not have any destination process to communicate with < because of non-power-of-two, we need to send them the < data that they would normally have received from those < processes. That is, the haves in this subtree must send to < the havenots. We use a logarithmic recursive-halfing algorithm < for this. */ < < if (dst_tree_root + mask > size) { < nprocs_completed = size - my_tree_root - mask; < /* nprocs_completed is the number of processes in this < subtree that have all the data. Send data to others < in a tree fashion. First find root of current tree < that is being divided into two. k is the number of < least-significant bits in this process's rank that < must be zeroed out to find the rank of the root */ < j = mask; < k = 0; < while (j) { < j >>= 1; < k++; < } < k--; --- > /* calculate the value of nbytes, the number of bytes in packed > representation that each process contributes. We can't simply divide > tmp_buf_size by comm_size because tmp_buf_size is an upper > bound on the amount of memory required. (For example, for > a single integer, MPICH returns pack_size=12.) Therefore, we > actually pack some data into tmp_buf and see by how much > 'position' is incremented. */ 1799,1806c1804,1818 < offset = nbytes * (my_tree_root + mask); < tmp_mask = mask >> 1; < < while (tmp_mask) { < dst = rank ^ tmp_mask; < < tree_root = rank >> k; < tree_root <<= k; --- > position = 0; > MPI_Pack(recvbuf, 1, recvtype->self, tmp_buf, tmp_buf_size, > &position, comm->self); > nbytes = position*recvcount; > > /* pack local data into right location in tmp_buf */ > position = rank * nbytes; > MPI_Pack(sendbuf, sendcount, sendtype->self, tmp_buf, tmp_buf_size, > &position, comm->self); > curr_cnt = nbytes; > > mask = 0x1; > i = 0; > while (mask < size) { > dst = rank ^ mask; 1808,1813c1820,1840 < /* send only if this proc has data and destination < doesn't have data. at any step, multiple processes < can send if they have the data */ < if ((dst > rank) && < (rank < tree_root + nprocs_completed) < && (dst >= tree_root + nprocs_completed)) { --- > /* find offset into send and recv buffers. zero out > the least significant "i" bits of rank and dst to > find root of src and dst subtrees. Use ranks of > roots as index to send from and recv into buffer. */ > > dst_tree_root = dst >> i; > dst_tree_root <<= i; > > my_tree_root = rank >> i; > my_tree_root <<= i; > > send_offset = my_tree_root * nbytes; > recv_offset = dst_tree_root * nbytes; > > if (dst < size) { > mpi_errno = MPI_Sendrecv(((char *)tmp_buf + send_offset), > curr_cnt, MPI_BYTE, dst, MPIR_ALLGATHER_TAG, > ((char *)tmp_buf + recv_offset), > nbytes*mask, MPI_BYTE, dst, > MPIR_ALLGATHER_TAG, comm->self, &status); > if (mpi_errno) return mpi_errno; 1815,1836c1842,1866 < mpi_errno = MPI_Send(((char *)tmp_buf + offset), < last_recv_cnt, MPI_BYTE, < dst, MPIR_ALLGATHER_TAG, < comm->self); < /* last_recv_cnt was set in the previous < receive. that's the amount of data to be < sent now. */ < if (mpi_errno) return mpi_errno; < } < /* recv only if this proc. doesn't have data and sender < has data */ < else if ((dst < rank) && < (dst < tree_root + nprocs_completed) && < (rank >= tree_root + nprocs_completed)) { < mpi_errno = MPI_Recv(((char *)tmp_buf + offset), < nbytes*nprocs_completed, MPI_BYTE, < dst, MPIR_ALLGATHER_TAG, comm->self, &status); < /* nprocs_completed is also equal to the no. of processes < whose data we don't have */ < if (mpi_errno) return mpi_errno; < MPI_Get_count(&status, MPI_BYTE, &last_recv_cnt); < curr_cnt += last_recv_cnt; --- > MPI_Get_count(&status, MPI_BYTE, &last_recv_cnt); > curr_cnt += last_recv_cnt; > } > > /* if some processes in this process's subtree in this step > did not have any destination process to communicate with > because of non-power-of-two, we need to send them the > data that they would normally have received from those > processes. That is, the haves in this subtree must send to > the havenots. We use a logarithmic recursive-halfing algorithm > for this. */ > > if (dst_tree_root + mask > size) { > nprocs_completed = size - my_tree_root - mask; > /* nprocs_completed is the number of processes in this > subtree that have all the data. Send data to others > in a tree fashion. First find root of current tree > that is being divided into two. k is the number of > least-significant bits in this process's rank that > must be zeroed out to find the rank of the root */ > j = mask; > k = 0; > while (j) { > j >>= 1; > k++; 1838d1867 < tmp_mask >>= 1; 1839a1869,1911 > > offset = nbytes * (my_tree_root + mask); > tmp_mask = mask >> 1; > > while (tmp_mask) { > dst = rank ^ tmp_mask; > > tree_root = rank >> k; > tree_root <<= k; > > /* send only if this proc has data and destination > doesn't have data. at any step, multiple processes > can send if they have the data */ > if ((dst > rank) && > (rank < tree_root + nprocs_completed) > && (dst >= tree_root + nprocs_completed)) { > > mpi_errno = MPI_Send(((char *)tmp_buf + offset), > last_recv_cnt, MPI_BYTE, > dst, MPIR_ALLGATHER_TAG, > comm->self); > /* last_recv_cnt was set in the previous > receive. that's the amount of data to be > sent now. */ > if (mpi_errno) return mpi_errno; > } > /* recv only if this proc. doesn't have data and sender > has data */ > else if ((dst < rank) && > (dst < tree_root + nprocs_completed) && > (rank >= tree_root + nprocs_completed)) { > mpi_errno = MPI_Recv(((char *)tmp_buf + offset), > nbytes*nprocs_completed, MPI_BYTE, > dst, MPIR_ALLGATHER_TAG, comm->self, &status); > /* nprocs_completed is also equal to the no. of processes > whose data we don't have */ > if (mpi_errno) return mpi_errno; > MPI_Get_count(&status, MPI_BYTE, &last_recv_cnt); > curr_cnt += last_recv_cnt; > } > tmp_mask >>= 1; > k--; > } 1840a1913,1914 > mask <<= 1; > i++; 1842,1843c1916,1921 < mask <<= 1; < i++; --- > > position = 0; > MPI_Unpack(tmp_buf, tmp_buf_size, &position, recvbuf, recvcount*size, > recvtype->self, comm->self); > > FREE(tmp_buf); 1845,1850d1922 < < position = 0; < MPI_Unpack(tmp_buf, tmp_buf_size, &position, recvbuf, recvcount*size, < recvtype->self, comm->self); < < FREE(tmp_buf); 1852a1925,1926 > else { > /* long message. use ring algorithm. */ 1854,1881c1928 < #ifdef OLD < < /* Do a gather for each process in the communicator < This is the "circular" algorithm for allgather - each process sends to < its right and receives from its left. This is faster than simply < doing size Gathers. < */ < < /* First, load the "local" version in the recvbuf. */ < mpi_errno = < MPI_Sendrecv( sendbuf, sendcount, sendtype->self, rank, < MPIR_ALLGATHER_TAG, < (void *)((char *)recvbuf + rank*recvcount*recv_extent), < recvcount, recvtype->self, rank, MPIR_ALLGATHER_TAG, < comm->self, < &status ); < if (mpi_errno) return mpi_errno; < < /* < Now, send left to right. This fills in the receive area in < reverse order. < */ < left = (size + rank - 1) % size; < right = (rank + 1) % size; < < j = rank; < jnext = left; < for (i=1; i /* First, load the "local" version in the recvbuf. */ 1883,1891c1930,1956 < MPI_Sendrecv( (void *)((char *)recvbuf+j*recvcount*recv_extent), < recvcount, recvtype->self, right, MPIR_ALLGATHER_TAG, < (void *)((char *)recvbuf + jnext*recvcount*recv_extent), < recvcount, recvtype->self, left, < MPIR_ALLGATHER_TAG, comm->self, < &status ); < if (mpi_errno) break; < j = jnext; < jnext = (size + jnext - 1) % size; --- > MPI_Sendrecv( sendbuf, sendcount, sendtype->self, rank, > MPIR_ALLGATHER_TAG, > (void *)((char *)recvbuf + rank*recvcount*recv_extent), > recvcount, recvtype->self, rank, MPIR_ALLGATHER_TAG, > comm->self, &status ); > if (mpi_errno) return mpi_errno; > > /* > Now, send left to right. This fills in the receive area in > reverse order. > */ > left = (size + rank - 1) % size; > right = (rank + 1) % size; > > j = rank; > jnext = left; > for (i=1; i mpi_errno = > MPI_Sendrecv( (void *)((char *)recvbuf+j*recvcount*recv_extent), > recvcount, recvtype->self, right, MPIR_ALLGATHER_TAG, > (void *)((char *)recvbuf + jnext*recvcount*recv_extent), > recvcount, recvtype->self, left, > MPIR_ALLGATHER_TAG, comm->self, > &status ); > if (mpi_errno) break; > j = jnext; > jnext = (size + jnext - 1) % size; 1893c1958 < #endif --- > } 1953c2018 < int left, right, jnext; --- > int left, right, jnext, type_size; 1959,1960d2023 < MPI_Type_extent ( recvtype->self, &recv_extent ); < 1966a2030,2032 > MPI_Type_extent ( recvtype->self, &recv_extent ); > MPI_Type_size(recvtype->self, &type_size); > 1973c2039 < if (total_count > MPIR_ALLGATHERV_MEDIUM_MSG) { --- > if (total_count*type_size > MPIR_ALLGATHERV_MEDIUM_MSG) { 2400a2467,2468 > if (sendcount == 0) return MPI_SUCCESS; > 2768a2837,3354 > > /* This is the default implementation of reduce. The algorithm is: > > Algorithm: MPI_Reduce > > For long messages and for builtin ops and if count >= pof2 (where > pof2 is the nearest power-of-two less than or equal to the number > of processes), we use Rabenseifner's algorithm (see > http://www.hlrs.de/organization/par/services/models/mpi/myreduce.html ). > This algorithm implements the reduce in two steps: first a > reduce-scatter, followed by a gather to the root. A > recursive-halving algorithm (beginning with processes that are > distance 1 apart) is used for the reduce-scatter, and a binary tree > algorithm is used for the gather. The non-power-of-two case is > handled by dropping to the nearest lower power-of-two: the first > few odd-numbered processes send their data to their left neighbors > (rank-1), and the reduce-scatter happens among the remaining > power-of-two processes. If the root is one of the excluded > processes, then after the reduce-scatter, rank 0 sends its result to > the root and exits; the root now acts as rank 0 in the binary tree > algorithm for gather. > > For the power-of-two case, the cost for the reduce-scatter is > lgp.alpha + n.((p-1)/p).beta + n.((p-1)/p).gamma. The cost for the > gather to root is lgp.alpha + n.((p-1)/p).beta. Therefore, the > total cost is: > Cost = 2.lgp.alpha + 2.n.((p-1)/p).beta + n.((p-1)/p).gamma > > For the non-power-of-two case, assuming the root is not one of the > odd-numbered processes that get excluded in the reduce-scatter, > Cost = (2.floor(lgp)+1).alpha + (2.((p-1)/p) + 1).n.beta + n.(1+(p-1)/p).gamma > > > For short messages, user-defined ops, and count < pof2, we use a > binary tree algorithm for both short and long messages. > > Cost = lgp.alpha + n.lgp.beta + n.lgp.gamma > > > We use the binary tree algorithm in the case of user-defined ops > because in this case derived datatypes are allowed, and the user > could pass basic datatypes on one process and derived on another as > long as the type maps are the same. Breaking up derived datatypes > to do the reduce-scatter is tricky. > > Possible improvements: > > End Algorithm: MPI_Reduce > */ > > static int intra_Reduce ( > void *sendbuf, > void *recvbuf, > int count, > struct MPIR_DATATYPE *datatype, > MPI_Op op, > int root, > struct MPIR_COMMUNICATOR *comm ) > { > MPI_Status status; > int size, rank, type_size, pof2, rem, newrank; > int mask, relrank, source, lroot, *cnts, *disps, i, j, send_idx=0; > int mpi_errno = MPI_SUCCESS, recv_idx, last_idx=0, newdst; > int dst, send_cnt, recv_cnt, newroot, newdst_tree_root, > newroot_tree_root; > MPI_User_function *uop; > MPI_Aint extent, lb; > void *tmp_buf; > struct MPIR_OP *op_ptr; > static char myname[] = "MPI_REDUCE"; > > if (count == 0) return MPI_SUCCESS; > > /* Is root within the communicator? */ > MPIR_Comm_size ( comm, &size ); > #ifndef MPIR_NO_ERROR_CHECKING > if ( root >= size ) > mpi_errno = MPIR_Err_setmsg(MPI_ERR_ROOT, MPIR_ERR_ROOT_TOOBIG, > myname,(char *)0,(char *)0,root,size); > if (root < 0) > mpi_errno = MPIR_Err_setmsg(MPI_ERR_ROOT,MPIR_ERR_DEFAULT,myname, > (char *)0,(char *)0,root); > if (mpi_errno) > return MPIR_ERROR(comm, mpi_errno, myname ); > #endif > > /* If the operation is predefined, we could check that the datatype's > type signature is compatible with the operation. > */ > #if defined(MPID_Reduce) && !defined(TOPOLOGY_INTRA_FNS_H) > /* Eventually, this could apply the MPID_Reduce routine in a loop for > counts > 1 */ > if (comm->ADIReduce && count == 1) { > /* Call a routine to sort through the datatypes and operations ... > This allows us to provide partial support (e.g., only SUM_DOUBLE) > */ > if (MPIR_ADIReduce( comm->ADIctx, comm, sendbuf, recvbuf, count, > datatype->self, op, root ) == MPI_SUCCESS) > return MPI_SUCCESS; > } > #endif > > /* Get my rank and switch communicators to the hidden collective */ > MPIR_Comm_rank ( comm, &rank ); > comm = comm->comm_coll; > op_ptr = MPIR_GET_OP_PTR(op); > MPIR_TEST_MPI_OP(op,op_ptr,comm,myname); > uop = op_ptr->op; > > MPI_Type_extent(datatype->self, &extent); > MPI_Type_lb( datatype->self, &lb ); > > /* Create a temporary buffer */ > > MPIR_ALLOC(tmp_buf, MALLOC(count*extent), comm, MPI_ERR_EXHAUSTED, myname); > /* adjust for potential negative lower bound in datatype */ > tmp_buf = (void *)((char*)tmp_buf - lb); > > /* If I'm not the root, then my recvbuf may not be valid, therefore > I have to allocate a temporary one */ > if (rank != root) { > MPIR_ALLOC(recvbuf, MALLOC(count*extent), comm, > MPI_ERR_EXHAUSTED, myname); > recvbuf = (void *)((char*)recvbuf - lb); > } > > mpi_errno = MPI_Sendrecv(sendbuf, count, datatype->self, rank, > MPIR_REDUCE_TAG, recvbuf, count, > datatype->self, rank, > MPIR_REDUCE_TAG, comm->self, &status); > if (mpi_errno) return mpi_errno; > > MPI_Type_size(datatype->self, &type_size); > > /* find nearest power-of-two less than or equal to comm_size */ > pof2 = 1; > while (pof2 <= size) pof2 <<= 1; > pof2 >>=1; > > /* Lock for collective operation */ > MPID_THREAD_LOCK(comm->ADIctx,comm); > > MPIR_Op_errno = MPI_SUCCESS; > > if ((count*type_size > MPIR_REDUCE_SHORT_MSG) && > (op_ptr->permanent) && (count >= pof2)) { > /* do a reduce-scatter followed by gather to root. */ > > rem = size - pof2; > > /* In the non-power-of-two case, all odd-numbered > processes of rank < 2*rem send their data to > (rank-1). These odd-numbered processes no longer > participate in the algorithm until the very end. The > remaining processes form a nice power-of-two. > > Note that in MPI_Allreduce we have the even-numbered processes > send data to odd-numbered processes. That is better for > non-commutative operations because it doesn't require a > buffer copy. However, for MPI_Reduce, the most common case > is commutative operations with root=0. Therefore we want > even-numbered processes to participate the computation for > the root=0 case, in order to avoid an extra send-to-root > communication after the reduce-scatter. In MPI_Allreduce it > doesn't matter because all processes must get the result. */ > > if (rank < 2*rem) { > if (rank % 2 != 0) { /* odd */ > mpi_errno = MPI_Send(recvbuf, count, > datatype->self, rank-1, > MPIR_REDUCE_TAG, comm->self); > if (mpi_errno) return mpi_errno; > > /* temporarily set the rank to -1 so that this > process does not pariticipate in recursive > doubling */ > newrank = -1; > } > else { /* even */ > mpi_errno = MPI_Recv(tmp_buf, count, > datatype->self, rank+1, > MPIR_REDUCE_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > > /* do the reduction on received data. */ > /* This algorithm is used only for predefined ops > and predefined ops are always commutative. */ > > (*uop)(tmp_buf, recvbuf, &count, &datatype->self); > > /* change the rank */ > newrank = rank / 2; > } > } > else /* rank >= 2*rem */ > newrank = rank - rem; > > /* for the reduce-scatter, calculate the count that > each process receives and the displacement within > the buffer */ > > /* We allocate these arrays on all processes, even if newrank=-1, > because if root is one of the excluded processes, we will > need them on the root later on below. */ > MPIR_ALLOC(cnts, (int *)MALLOC(pof2*sizeof(int)), comm, > MPI_ERR_EXHAUSTED, myname); > MPIR_ALLOC(disps, (int *)MALLOC(pof2*sizeof(int)), comm, > MPI_ERR_EXHAUSTED, myname); > > if (newrank != -1) { > for (i=0; i<(pof2-1); i++) > cnts[i] = count/pof2; > cnts[pof2-1] = count - (count/pof2)*(pof2-1); > > disps[0] = 0; > for (i=1; i disps[i] = disps[i-1] + cnts[i-1]; > > mask = 0x1; > send_idx = recv_idx = 0; > last_idx = pof2; > while (mask < pof2) { > newdst = newrank ^ mask; > /* find real rank of dest */ > dst = (newdst < rem) ? newdst*2 : newdst + rem; > > send_cnt = recv_cnt = 0; > if (newrank < newdst) { > send_idx = recv_idx + pof2/(mask*2); > for (i=send_idx; i send_cnt += cnts[i]; > for (i=recv_idx; i recv_cnt += cnts[i]; > } > else { > recv_idx = send_idx + pof2/(mask*2); > for (i=send_idx; i send_cnt += cnts[i]; > for (i=recv_idx; i recv_cnt += cnts[i]; > } > > /* printf("Rank %d, send_idx %d, recv_idx %d, send_cnt %d, recv_cnt %d, last_idx %d\n", newrank, send_idx, recv_idx, > send_cnt, recv_cnt, last_idx); > */ > /* Send data from recvbuf. Recv into tmp_buf */ > mpi_errno = MPI_Sendrecv((char *) recvbuf + > disps[send_idx]*extent, > send_cnt, datatype->self, > dst, MPIR_REDUCE_TAG, > (char *) tmp_buf + > disps[recv_idx]*extent, > recv_cnt, datatype->self, dst, > MPIR_REDUCE_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > > /* tmp_buf contains data received in this step. > recvbuf contains data accumulated so far */ > > /* This algorithm is used only for predefined ops > and predefined ops are always commutative. */ > (*uop)((char *) tmp_buf + disps[recv_idx]*extent, > (char *) recvbuf + disps[recv_idx]*extent, > &recv_cnt, &datatype->self); > > /* update send_idx for next iteration */ > send_idx = recv_idx; > mask <<= 1; > > /* update last_idx, but not in last iteration > because the value is needed in the gather > step below. */ > if (mask < pof2) > last_idx = recv_idx + pof2/mask; > } > } > > /* now do the gather to root */ > > /* Is root one of the processes that was excluded from the > computation above? If so, send data from newrank=0 to > the root and have root take on the role of newrank = 0 */ > > if (root < 2*rem) { > if (root % 2 != 0) { > if (rank == root) { /* recv */ > /* initialize the arrays that weren't initialized */ > for (i=0; i<(pof2-1); i++) > cnts[i] = count/pof2; > cnts[pof2-1] = count - (count/pof2)*(pof2-1); > > disps[0] = 0; > for (i=1; i disps[i] = disps[i-1] + cnts[i-1]; > > mpi_errno = MPI_Recv(recvbuf, cnts[0], datatype->self, > 0, MPIR_REDUCE_TAG, comm->self, > &status); > newrank = 0; > send_idx = 0; > last_idx = 2; > } > else if (newrank == 0) { /* send */ > mpi_errno = MPI_Send(recvbuf, cnts[0], datatype->self, > root, MPIR_REDUCE_TAG, comm->self); > newrank = -1; > } > newroot = 0; > } > else newroot = root / 2; > } > else > newroot = root - rem; > > if (newrank != -1) { > j = 0; > mask = 0x1; > while (mask < pof2) { > mask <<= 1; > j++; > } > mask >>= 1; > j--; > while (mask > 0) { > newdst = newrank ^ mask; > > /* find real rank of dest */ > dst = (newdst < rem) ? newdst*2 : newdst + rem; > /* if root is playing the role of newdst=0, adjust for > it */ > if ((newdst == 0) && (root < 2*rem) && (root % 2 != 0)) > dst = root; > > /* if the root of newdst's half of the tree is the > same as the root of newroot's half of the tree, send to > newdst and exit, else receive from newdst. */ > > newdst_tree_root = newdst >> j; > newdst_tree_root <<= j; > > newroot_tree_root = newroot >> j; > newroot_tree_root <<= j; > > send_cnt = recv_cnt = 0; > if (newrank < newdst) { > /* update last_idx except on first iteration */ > if (mask != pof2/2) > last_idx = last_idx + pof2/(mask*2); > > recv_idx = send_idx + pof2/(mask*2); > for (i=send_idx; i send_cnt += cnts[i]; > for (i=recv_idx; i recv_cnt += cnts[i]; > } > else { > recv_idx = send_idx - pof2/(mask*2); > for (i=send_idx; i send_cnt += cnts[i]; > for (i=recv_idx; i recv_cnt += cnts[i]; > } > > if (newdst_tree_root == newroot_tree_root) { > /* send and exit */ > /* printf("Rank %d, send_idx %d, send_cnt %d, last_idx %d\n", newrank, send_idx, send_cnt, last_idx); > fflush(stdout); */ > /* Send data from recvbuf. Recv into tmp_buf */ > mpi_errno = MPI_Send((char *) recvbuf + > disps[send_idx]*extent, > send_cnt, datatype->self, > dst, MPIR_REDUCE_TAG, > comm->self); > if (mpi_errno) return mpi_errno; > break; > } > else { > /* recv and continue */ > /* printf("Rank %d, recv_idx %d, recv_cnt %d, last_idx %d\n", newrank, recv_idx, recv_cnt, last_idx); > fflush(stdout); */ > mpi_errno = MPI_Recv((char *) recvbuf + > disps[recv_idx]*extent, > recv_cnt, datatype->self, dst, > MPIR_REDUCE_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > } > > if (newrank > newdst) send_idx = recv_idx; > > mask >>= 1; > j--; > } > } > > FREE(cnts); > FREE(disps); > } > > else { /* use a binary tree algorithm */ > > /* Here's the algorithm. Relative to the root, look at the bit pattern in > my rank. Starting from the right (lsb), if the bit is 1, send to > the node with that bit zero and exit; if the bit is 0, receive from the > node with that bit set and combine (as long as that node is within the > group) > > Note that by receiving with source selection, we guarentee that we get > the same bits with the same input. If we allowed the parent to receive > the children in any order, then timing differences could cause different > results (roundoff error, over/underflows in some cases, etc). > > Because of the way these are ordered, if root is 0, then this is correct > for both commutative and non-commutitive operations. If root is not > 0, then for non-commutitive, we use a root of zero and then send > the result to the root. To see this, note that the ordering is > mask = 1: (ab)(cd)(ef)(gh) (odds send to evens) > mask = 2: ((ab)(cd))((ef)(gh)) (3,6 send to 0,4) > mask = 4: (((ab)(cd))((ef)(gh))) (4 sends to 0) > > Comments on buffering. > If the datatype is not contiguous, we still need to pass contiguous > data to the user routine. > In this case, we should make a copy of the data in some format, > and send/operate on that. > > In general, we can't use MPI_PACK, because the alignment of that > is rather vague, and the data may not be re-usable. What we actually > need is a "squeeze" operation that removes the skips. > */ > mask = 0x1; > if (op_ptr->commute) lroot = root; > else lroot = 0; > relrank = (rank - lroot + size) % size; > > while (/*(mask & relrank) == 0 && */mask < size) { > /* Receive */ > if ((mask & relrank) == 0) { > source = (relrank | mask); > if (source < size) { > source = (source + lroot) % size; > mpi_errno = MPI_Recv (tmp_buf, count, datatype->self, source, > MPIR_REDUCE_TAG, comm->self, &status); > if (mpi_errno) return mpi_errno; > /* The sender is above us, so the received buffer must be > the second argument (in the noncommutitive case). */ > /* error pop/push allows errors found by predefined routines > to be visible. We need a better way to do this */ > /* MPIR_ERROR_POP(comm); */ > if (op_ptr->commute) > (*uop)(tmp_buf, recvbuf, &count, &datatype->self); > else { > (*uop)(recvbuf, tmp_buf, &count, &datatype->self); > mpi_errno = MPI_Sendrecv(tmp_buf, count, > datatype->self, rank, > MPIR_REDUCE_TAG, > recvbuf, count, > datatype->self, rank, > MPIR_REDUCE_TAG, > comm->self, &status); > if (mpi_errno) return mpi_errno; > } > /* MPIR_ERROR_PUSH(comm); */ > } > } > else { > /* I've received all that I'm going to. Send my result to > my parent */ > source = ((relrank & (~ mask)) + lroot) % size; > mpi_errno = MPI_Send( recvbuf, count, datatype->self, > source, > MPIR_REDUCE_TAG, > comm->self ); > if (mpi_errno) return mpi_errno; > break; > } > mask <<= 1; > } > > if (!op_ptr->commute && root != 0) { > if (rank == 0) { > mpi_errno = MPI_Send( recvbuf, count, datatype->self, root, > MPIR_REDUCE_TAG, comm->self ); > } > else if (rank == root) { > mpi_errno = MPI_Recv ( recvbuf, count, datatype->self, 0, /*size-1, */ > MPIR_REDUCE_TAG, comm->self, &status); > } > if (mpi_errno) return mpi_errno; > } > } > > FREE( (char *)tmp_buf + lb ); > > /* Free the temporarily allocated recvbuf */ > if (rank != root) > FREE( (char *)recvbuf + lb ); > > /* If the predefined operation detected an error, report it here */ > /* Note that only the root gets this result, so this can cause > programs to hang, particularly if this is used to implement > MPI_Allreduce. Use care with this. > */ > if (mpi_errno == MPI_SUCCESS && MPIR_Op_errno) { > /* PRINTF( "Error in performing MPI_Op in reduce\n" ); */ > mpi_errno = MPIR_Op_errno; > } > > /* Unlock for collective operation */ > MPID_THREAD_UNLOCK(comm->ADIctx,comm); > > return (mpi_errno); > } > > > #ifdef OLD 2773,2774c3359 < We use a minimum spanning tree (MST) algorithm for both short and < long messages. --- > We use a binary tree algorithm for both short and long messages. 2965a3551,3895 > #endif > > > > /* This is the default implementation of allreduce. The algorithm is: > > Algorithm: MPI_Allreduce > > For the heterogeneous case, we call MPI_Reduce followed by MPI_Bcast > in order to meet the requirement that all processes must have the > same result. For the homogeneous case, we use the following algorithms. > > > For long messages and for builtin ops and if count >= pof2 (where > pof2 is the nearest power-of-two less than or equal to the number > of processes), we use Rabenseifner's algorithm (see > http://www.hlrs.de/organization/par/services/models/mpi/myreduce.html ). > This algorithm implements the allreduce in two steps: first a > reduce-scatter, followed by an allgather. A recursive-halving > algorithm (beginning with processes that are distance 1 apart) is > used for the reduce-scatter, and a recursive doubling > algorithm is used for the gather. The non-power-of-two case is > handled by dropping to the nearest lower power-of-two: the first > few even-numbered processes send their data to their right neighbors > (rank+1), and the reduce-scatter and allgather happen among the remaining > power-of-two processes. At the end, the first few even-numbered > processes get the result from their right neighbors. > > For the power-of-two case, the cost for the reduce-scatter is > lgp.alpha + n.((p-1)/p).beta + n.((p-1)/p).gamma. The cost for the > allgather lgp.alpha + n.((p-1)/p).beta. Therefore, the > total cost is: > Cost = 2.lgp.alpha + 2.n.((p-1)/p).beta + n.((p-1)/p).gamma > > For the non-power-of-two case, > Cost = (2.floor(lgp)+2).alpha + (2.((p-1)/p) + 2).n.beta + n.(1+(p-1)/p).gamma > > > For long messages, for user-defined ops, and for count < pof2 > we use a recursive doubling algorithm (similar to the one in > MPI_Allgather). We use this algorithm in the case of user-defined ops > because in this case derived datatypes are allowed, and the user > could pass basic datatypes on one process and derived on another as > long as the type maps are the same. Breaking up derived datatypes > to do the reduce-scatter is tricky. > > Cost = lgp.alpha + n.lgp.beta + n.lgp.gamma > > Possible improvements: > > End Algorithm: MPI_Allreduce > */ > > > static int intra_Allreduce ( > void *sendbuf, > void *recvbuf, > int count, > struct MPIR_DATATYPE *datatype, > MPI_Op op, > struct MPIR_COMMUNICATOR *comm ) > { > int rc, is_homogeneous; > int size, rank, type_size; > int mpi_errno = MPI_SUCCESS; > int mask, dst, pof2, newrank, rem, newdst, i, > send_idx, recv_idx, last_idx, send_cnt, recv_cnt, *cnts, *disps; > MPI_Aint lb, extent; > MPI_Status status; > void *tmp_buf; > MPI_User_function *uop; > struct MPIR_OP *op_ptr; > static char myname[] = "MPI_ALLREDUCE"; > > if (count == 0) return MPI_SUCCESS; > > is_homogeneous = 1; > #ifdef MPID_HAS_HETERO > is_homogeneous = (comm->msgform == MPID_MSG_OK) ? 1 : 0; > #endif > #ifdef MPID_DOES_DATACONV > is_homogeneous = 0; /* Globus */ > #endif > > if (!is_homogeneous) { > /* heterogeneous. To get the same result on all processes, we > do a reduce to 0 and then broadcast. */ > mpi_errno = MPI_Reduce ( sendbuf, recvbuf, count, > datatype->self, op, 0, > comm->self ); > if (mpi_errno == MPIR_ERR_OP_NOT_DEFINED || mpi_errno == MPI_SUCCESS) { > rc = MPI_Bcast ( recvbuf, count, datatype->self, 0, comm->self ); > if (rc) mpi_errno = rc; > } > } > else { > /* homogeneous */ > > MPIR_Comm_size(comm, &size); > MPIR_Comm_rank(comm, &rank); > > /* Switch communicators to the hidden collective */ > comm = comm->comm_coll; > > op_ptr = MPIR_GET_OP_PTR(op); > MPIR_TEST_MPI_OP(op,op_ptr,comm,myname); > uop = op_ptr->op; > > /* need to allocate temporary buffer to store incoming data*/ > MPI_Type_extent(datatype->self, &extent); > MPIR_ALLOC(tmp_buf,(void *)MALLOC(count*extent), comm, > MPI_ERR_EXHAUSTED, myname); > /* adjust for potential negative lower bound in datatype */ > MPI_Type_lb( datatype->self, &lb ); > tmp_buf = (void *)((char*)tmp_buf - lb); > > /* Lock for collective operation */ > MPID_THREAD_LOCK(comm->ADIctx,comm); > MPIR_Op_errno = MPI_SUCCESS; > > /* copy local data into recvbuf */ > mpi_errno = MPI_Sendrecv ( sendbuf, count, datatype->self, > rank, MPIR_ALLREDUCE_TAG, > recvbuf, count, datatype->self, > rank, MPIR_ALLREDUCE_TAG, > comm->self, &status ); > if (mpi_errno) return mpi_errno; > > MPI_Type_size(datatype->self, &type_size); > > /* find nearest power-of-two less than or equal to comm_size */ > pof2 = 1; > while (pof2 <= size) pof2 <<= 1; > pof2 >>=1; > > rem = size - pof2; > > /* In the non-power-of-two case, all even-numbered > processes of rank < 2*rem send their data to > (rank+1). These even-numbered processes no longer > participate in the algorithm until the very end. The > remaining processes form a nice power-of-two. */ > > if (rank < 2*rem) { > if (rank % 2 == 0) { /* even */ > mpi_errno = MPI_Send(recvbuf, count, > datatype->self, rank+1, > MPIR_ALLREDUCE_TAG, comm->self); > if (mpi_errno) return mpi_errno; > > /* temporarily set the rank to -1 so that this > process does not pariticipate in recursive > doubling */ > newrank = -1; > } > else { /* odd */ > mpi_errno = MPI_Recv(tmp_buf, count, > datatype->self, rank-1, > MPIR_ALLREDUCE_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > > /* do the reduction on received data. since the > ordering is right, it doesn't matter whether > the operation is commutative or not. */ > (*uop)(tmp_buf, recvbuf, &count, &datatype->self); > > /* change the rank */ > newrank = rank / 2; > } > } > else /* rank >= 2*rem */ > newrank = rank - rem; > > /* If op is user-defined or count is less than pof2, use > recursive doubling algorithm. Otherwise do a reduce-scatter > followed by allgather. (If op is user-defined, > derived datatypes are allowed and the user could pass basic > datatypes on one process and derived on another as long as > the type maps are the same. Breaking up derived > datatypes to do the reduce-scatter is tricky, therefore > using recursive doubling in that case.) */ > > if (newrank != -1) { > if ((count*type_size <= MPIR_ALLREDUCE_SHORT_MSG) || > (op_ptr->permanent == 0) || > (count < pof2)) { /* use recursive doubling */ > mask = 0x1; > while (mask < pof2) { > newdst = newrank ^ mask; > /* find real rank of dest */ > dst = (newdst < rem) ? newdst*2 + 1 : newdst + rem; > > /* Send the most current data, which is in recvbuf. Recv > into tmp_buf */ > mpi_errno = MPI_Sendrecv(recvbuf, count, datatype->self, > dst, MPIR_ALLREDUCE_TAG, tmp_buf, > count, datatype->self, dst, > MPIR_ALLREDUCE_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > > /* tmp_buf contains data received in this step. > recvbuf contains data accumulated so far */ > > if (op_ptr->commute || (dst < rank)) { > /* op is commutative OR the order is already right */ > (*uop)(tmp_buf, recvbuf, &count, &datatype->self); > } > else { > /* op is noncommutative and the order is not right */ > (*uop)(recvbuf, tmp_buf, &count, &datatype->self); > > /* copy result back into recvbuf */ > mpi_errno = MPI_Sendrecv(tmp_buf, count, > datatype->self, rank, > MPIR_ALLREDUCE_TAG, > recvbuf, count, > datatype->self, rank, > MPIR_ALLREDUCE_TAG, > comm->self, &status); > if (mpi_errno) return mpi_errno; > } > mask <<= 1; > } > } > > else { > > /* do a reduce-scatter followed by allgather */ > > /* for the reduce-scatter, calculate the count that > each process receives and the displacement within > the buffer */ > > MPIR_ALLOC(cnts, (int *)MALLOC(pof2*sizeof(int)), comm, > MPI_ERR_EXHAUSTED, myname); > MPIR_ALLOC(disps, (int *)MALLOC(pof2*sizeof(int)), comm, > MPI_ERR_EXHAUSTED, myname); > > for (i=0; i<(pof2-1); i++) > cnts[i] = count/pof2; > cnts[pof2-1] = count - (count/pof2)*(pof2-1); > > disps[0] = 0; > for (i=1; i disps[i] = disps[i-1] + cnts[i-1]; > > mask = 0x1; > send_idx = recv_idx = 0; > last_idx = pof2; > while (mask < pof2) { > newdst = newrank ^ mask; > /* find real rank of dest */ > dst = (newdst < rem) ? newdst*2 + 1 : newdst + rem; > > send_cnt = recv_cnt = 0; > if (newrank < newdst) { > send_idx = recv_idx + pof2/(mask*2); > for (i=send_idx; i send_cnt += cnts[i]; > for (i=recv_idx; i recv_cnt += cnts[i]; > } > else { > recv_idx = send_idx + pof2/(mask*2); > for (i=send_idx; i send_cnt += cnts[i]; > for (i=recv_idx; i recv_cnt += cnts[i]; > } > > /* printf("Rank %d, send_idx %d, recv_idx %d, send_cnt %d, recv_cnt %d, last_idx %d\n", newrank, send_idx, recv_idx, > send_cnt, recv_cnt, last_idx); > */ > /* Send data from recvbuf. Recv into tmp_buf */ > mpi_errno = MPI_Sendrecv((char *) recvbuf + > disps[send_idx]*extent, > send_cnt, datatype->self, > dst, MPIR_ALLREDUCE_TAG, > (char *) tmp_buf + > disps[recv_idx]*extent, > recv_cnt, datatype->self, dst, > MPIR_ALLREDUCE_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > > /* tmp_buf contains data received in this step. > recvbuf contains data accumulated so far */ > > /* This algorithm is used only for predefined ops > and predefined ops are always commutative. */ > (*uop)((char *) tmp_buf + disps[recv_idx]*extent, > (char *) recvbuf + disps[recv_idx]*extent, > &recv_cnt, &datatype->self); > > /* update send_idx for next iteration */ > send_idx = recv_idx; > mask <<= 1; > > /* update last_idx, but not in last iteration > because the value is needed in the allgather > step below. */ > if (mask < pof2) > last_idx = recv_idx + pof2/mask; > } > > /* now do the allgather */ > > mask >>= 1; > while (mask > 0) { > newdst = newrank ^ mask; > /* find real rank of dest */ > dst = (newdst < rem) ? newdst*2 + 1 : newdst + rem; > > send_cnt = recv_cnt = 0; > if (newrank < newdst) { > /* update last_idx except on first iteration */ > if (mask != pof2/2) > last_idx = last_idx + pof2/(mask*2); > > recv_idx = send_idx + pof2/(mask*2); > for (i=send_idx; i send_cnt += cnts[i]; > for (i=recv_idx; i recv_cnt += cnts[i]; > } > else { > recv_idx = send_idx - pof2/(mask*2); > for (i=send_idx; i send_cnt += cnts[i]; > for (i=recv_idx; i recv_cnt += cnts[i]; > } > > mpi_errno = MPI_Sendrecv((char *) recvbuf + > disps[send_idx]*extent, > send_cnt, datatype->self, > dst, MPIR_ALLREDUCE_TAG, > (char *) recvbuf + > disps[recv_idx]*extent, > recv_cnt, datatype->self, dst, > MPIR_ALLREDUCE_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; 2966a3897,3936 > if (newrank > newdst) send_idx = recv_idx; > > mask >>= 1; > } > > FREE(cnts); > FREE(disps); > } > } > > /* In the non-power-of-two case, all odd-numbered > processes of rank < 2*rem send the result to > (rank-1), the ranks who didn't participate above. */ > if (rank < 2*rem) { > if (rank % 2) /* odd */ > mpi_errno = MPI_Send(recvbuf, count, > datatype->self, rank-1, > MPIR_ALLREDUCE_TAG, comm->self); > else /* even */ > mpi_errno = MPI_Recv(recvbuf, count, > datatype->self, rank+1, > MPIR_ALLREDUCE_TAG, comm->self, > &status); > > if (mpi_errno) return mpi_errno; > } > > /* Unlock for collective operation */ > MPID_THREAD_UNLOCK(comm->ADIctx,comm); > > FREE((char *)tmp_buf+lb); > > if (mpi_errno == MPI_SUCCESS && MPIR_Op_errno) { > /* PRINTF( "Error in performing MPI_Op in reduce\n" ); */ > mpi_errno = MPIR_Op_errno; > } > } > > return (mpi_errno); > } 2968a3939 > #ifdef OLD 3164a4136,4711 > #endif > > > /* This is the default implementation of reduce_scatter. The algorithm is: > > Algorithm: MPI_Reduce_scatter > > If the operation is commutative, for short and medium-size > messages, we use a recursive-halving algorithm in which the first > p/2 processes send the second n/2 data to their counterparts in the > other half and receive the first n/2 data from them. This procedure > continues recursively, halving the data communicated at each step, > for a total of lgp steps. If the number of processes is not a > power-of-two, we convert it to the nearest lower power-of-two by > having the first few even-numbered processes send their data to the > neighboring odd-numbered process at (rank+1). Those odd-numbered > processes compute the result for their left neighbor as well in the > recursive halving algorithm, and then at the end send the result > back to the processes that didn't participate. > Therefore, if p is a power-of-two, > Cost = lgp.alpha + n.((p-1)/p).beta + n.((p-1)/p).gamma > If p is not a power-of-two, > Cost = (floor(lgp)+2).alpha + n.(1+(p-1+n)/p).beta + n.(1+(p-1)/p).gamma > The above cost in the non power-of-two case is approximate because > there is some imbalance in the amount of work each process does > because some processes do the work of their neighbors as well. > > For commutative operations and very long messages we use > we use a pairwise exchange algorithm similar to > the one used in MPI_Alltoall. At step i, each process sends n/p > amount of data to (rank+i) and receives n/p amount of data from > (rank-i). > Cost = (p-1).alpha + n.((p-1)/p).beta + n.((p-1)/p).gamma > > > If the operation is not commutative, we do the following: > > For very short messages, we use a recursive doubling algorithm, which > takes lgp steps. At step 1, processes exchange (n-n/p) amount of > data; at step 2, (n-2n/p) amount of data; at step 3, (n-4n/p) > amount of data, and so forth. > > Cost = lgp.alpha + n.(lgp-(p-1)/p).beta + n.(lgp-(p-1)/p).gamma > > For medium and long messages, we use pairwise exchange as above. > > Possible improvements: > > End Algorithm: MPI_Reduce_scatter */ > > static int intra_Reduce_scatter ( > void *sendbuf, > void *recvbuf, > int *recvcnts, > struct MPIR_DATATYPE *datatype, > MPI_Op op, > struct MPIR_COMMUNICATOR *comm ) > { > int rank, size, i; > MPI_Aint extent, lb; > int *disps; > void *tmp_recvbuf, *tmp_results; > int mpi_errno = MPI_SUCCESS; > int type_size, dis[2], blklens[2], total_count, nbytes, src, dst; > int mask, dst_tree_root, my_tree_root, j, k; > int *newcnts, *newdisps, rem, newdst, send_idx, recv_idx, > last_idx, send_cnt, recv_cnt; > int pof2, old_i, newrank, received; > MPI_Datatype sendtype, recvtype; > int nprocs_completed, tmp_mask, tree_root; > MPI_User_function *uop; > struct MPIR_OP *op_ptr; > MPI_Status status; > static char myname[] = "MPI_REDUCE_SCATTER"; > > MPI_Type_extent(datatype->self, &extent); > MPI_Type_lb( datatype->self, &lb ); > > op_ptr = MPIR_GET_OP_PTR(op); > MPIR_TEST_MPI_OP(op,op_ptr,comm,myname); > uop = op_ptr->op; > > MPIR_Comm_size(comm, &size); > MPIR_Comm_rank(comm, &rank); > comm = comm->comm_coll; > > MPIR_ALLOC(disps,(int *)MALLOC(size*sizeof(int)),comm, MPI_ERR_EXHAUSTED, > myname); > > total_count = 0; > for (i=0; i disps[i] = total_count; > total_count += recvcnts[i]; > } > > if (total_count == 0) { > FREE(disps); > return MPI_SUCCESS; > } > > MPI_Type_size(datatype->self, &type_size); > nbytes = total_count * type_size; > > /* Lock for collective operation */ > MPID_THREAD_LOCK(comm->ADIctx,comm); > MPIR_Op_errno = MPI_SUCCESS; > > if ((op_ptr->commute) && (nbytes < MPIR_REDSCAT_COMMUTATIVE_LONG_MSG)) { > /* commutative and short. use recursive halving algorithm */ > > /* allocate temp. buffer to receive incoming data */ > MPIR_ALLOC(tmp_recvbuf,(int *)MALLOC(extent*total_count),comm, > MPI_ERR_EXHAUSTED, myname); > /* adjust for potential negative lower bound in datatype */ > tmp_recvbuf = (void *)((char*)tmp_recvbuf - lb); > > /* need to allocate another temporary buffer to accumulate > results because recvbuf may not be big enough */ > MPIR_ALLOC(tmp_results,(int *)MALLOC(extent*total_count),comm, > MPI_ERR_EXHAUSTED, myname); > /* adjust for potential negative lower bound in datatype */ > tmp_results = (void *)((char*)tmp_results - lb); > > mpi_errno = MPI_Sendrecv(sendbuf, total_count, datatype->self, rank, > MPIR_REDUCE_SCATTER_TAG, tmp_results, > total_count, datatype->self, rank, > MPIR_REDUCE_SCATTER_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > > pof2 = 1; > while (pof2 <= size) pof2 <<= 1; > pof2 >>=1; > > rem = size - pof2; > > /* In the non-power-of-two case, all even-numbered > processes of rank < 2*rem send their data to > (rank+1). These even-numbered processes no longer > participate in the algorithm until the very end. The > remaining processes form a nice power-of-two. */ > > if (rank < 2*rem) { > if (rank % 2 == 0) { /* even */ > mpi_errno = MPI_Send(tmp_results, total_count, > datatype->self, rank+1, > MPIR_REDUCE_SCATTER_TAG, comm->self); > if (mpi_errno) return mpi_errno; > > /* temporarily set the rank to -1 so that this > process does not pariticipate in recursive > doubling */ > newrank = -1; > } > else { /* odd */ > mpi_errno = MPI_Recv(tmp_recvbuf, total_count, > datatype->self, rank-1, > MPIR_REDUCE_SCATTER_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > > /* do the reduction on received data. since the > ordering is right, it doesn't matter whether > the operation is commutative or not. */ > (*uop)(tmp_recvbuf, tmp_results, &total_count, &datatype->self); > > /* change the rank */ > newrank = rank / 2; > } > } > else /* rank >= 2*rem */ > newrank = rank - rem; > > if (newrank != -1) { > /* recalculate the recvcnts and disps arrays because the > even-numbered processes who no longer participate will > have their result calculated by the process to their > right (rank+1). */ > > MPIR_ALLOC(newcnts, (int *)MALLOC(pof2*sizeof(int)), comm, > MPI_ERR_EXHAUSTED, myname); > MPIR_ALLOC(newdisps, (int *)MALLOC(pof2*sizeof(int)), comm, > MPI_ERR_EXHAUSTED, myname); > > for (i=0; i /* what does i map to in the old ranking? */ > old_i = (i < rem) ? i*2 + 1 : i + rem; > if (old_i < 2*rem) { > /* This process has to also do its left neighbor's > work */ > newcnts[i] = recvcnts[old_i] + recvcnts[old_i-1]; > } > else > newcnts[i] = recvcnts[old_i]; > } > > newdisps[0] = 0; > for (i=1; i newdisps[i] = newdisps[i-1] + newcnts[i-1]; > > mask = pof2 >> 1; > send_idx = recv_idx = 0; > last_idx = pof2; > while (mask > 0) { > newdst = newrank ^ mask; > /* find real rank of dest */ > dst = (newdst < rem) ? newdst*2 + 1 : newdst + rem; > > send_cnt = recv_cnt = 0; > if (newrank < newdst) { > send_idx = recv_idx + mask; > for (i=send_idx; i send_cnt += newcnts[i]; > for (i=recv_idx; i recv_cnt += newcnts[i]; > } > else { > recv_idx = send_idx + mask; > for (i=send_idx; i send_cnt += newcnts[i]; > for (i=recv_idx; i recv_cnt += newcnts[i]; > } > > /* printf("Rank %d, send_idx %d, recv_idx %d, send_cnt %d, recv_cnt %d, last_idx %d\n", newrank, send_idx, recv_idx, > send_cnt, recv_cnt, last_idx); > */ > /* Send data from tmp_results. Recv into tmp_recvbuf */ > > if ((send_cnt != 0) && (recv_cnt != 0)) > mpi_errno = MPI_Sendrecv((char *) tmp_results + > newdisps[send_idx]*extent, > send_cnt, datatype->self, > dst, MPIR_REDUCE_SCATTER_TAG, > (char *) tmp_recvbuf + > newdisps[recv_idx]*extent, > recv_cnt, datatype->self, dst, > MPIR_REDUCE_SCATTER_TAG, comm->self, > &status); > else if ((send_cnt == 0) && (recv_cnt != 0)) > mpi_errno = MPI_Recv((char *) tmp_recvbuf + > newdisps[recv_idx]*extent, > recv_cnt, datatype->self, dst, > MPIR_REDUCE_SCATTER_TAG, comm->self, > &status); > else if ((recv_cnt == 0) && (send_cnt != 0)) > mpi_errno = MPI_Send((char *) tmp_results + > newdisps[send_idx]*extent, > send_cnt, datatype->self, > dst, MPIR_REDUCE_SCATTER_TAG, > comm->self); > > if (mpi_errno) return mpi_errno; > > /* tmp_recvbuf contains data received in this step. > tmp_results contains data accumulated so far */ > > if (recv_cnt != 0) > (*uop)((char *) tmp_recvbuf + newdisps[recv_idx]*extent, > (char *) tmp_results + newdisps[recv_idx]*extent, > &recv_cnt, &datatype->self); > > /* update send_idx for next iteration */ > send_idx = recv_idx; > last_idx = recv_idx + mask; > mask >>= 1; > } > > /* copy this process's result from tmp_results to recvbuf */ > if (recvcnts[rank]) { > mpi_errno = MPI_Sendrecv((char *)tmp_results + > disps[rank]*extent, > recvcnts[rank], datatype->self, rank, > MPIR_REDUCE_SCATTER_TAG, recvbuf, > recvcnts[rank], datatype->self, rank, > MPIR_REDUCE_SCATTER_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > } > > FREE(newcnts); > FREE(newdisps); > } > > /* In the non-power-of-two case, all odd-numbered > processes of rank < 2*rem send to (rank-1) the result they > calculated for that process */ > if (rank < 2*rem) { > if (rank % 2) { /* odd */ > if (recvcnts[rank-1]) > mpi_errno = MPI_Send((char *) tmp_results + > disps[rank-1]*extent, recvcnts[rank-1], > datatype->self, rank-1, > MPIR_REDUCE_SCATTER_TAG, comm->self); > } > else { /* even */ > if (recvcnts[rank]) > mpi_errno = MPI_Recv(recvbuf, recvcnts[rank], > datatype->self, rank+1, > MPIR_REDUCE_SCATTER_TAG, comm->self, > &status); > } > if (mpi_errno) return mpi_errno; > } > > FREE(tmp_results); > FREE(tmp_recvbuf); > } > > if (((op_ptr->commute) && (nbytes >= > MPIR_REDSCAT_COMMUTATIVE_LONG_MSG)) || > (!(op_ptr->commute) && (nbytes >= > MPIR_REDSCAT_NONCOMMUTATIVE_SHORT_MSG))) { > > /* commutative and long message, or noncommutative and long message. > use (p-1) pairwise exchanges */ > > /* copy local data into recvbuf */ > mpi_errno = MPI_Sendrecv (((char *)sendbuf+disps[rank]*extent), > recvcnts[rank], datatype->self, rank, > MPIR_REDUCE_SCATTER_TAG, recvbuf, > recvcnts[rank], datatype->self, rank, > MPIR_REDUCE_SCATTER_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > > /* allocate temporary buffer to store incoming data */ > MPIR_ALLOC(tmp_recvbuf,(int *)MALLOC(extent*recvcnts[rank]+1),comm, > MPI_ERR_EXHAUSTED, myname); > /* adjust for potential negative lower bound in datatype */ > tmp_recvbuf = (void *)((char*)tmp_recvbuf - lb); > > for (i=1; i src = (rank - i + size) % size; > dst = (rank + i) % size; > > /* send the data that dst needs. recv data that this process > needs from src into tmp_recvbuf */ > mpi_errno = MPI_Sendrecv(((char *)sendbuf+disps[dst]*extent), > recvcnts[dst], datatype->self, dst, > MPIR_REDUCE_SCATTER_TAG, tmp_recvbuf, > recvcnts[rank], datatype->self, src, > MPIR_REDUCE_SCATTER_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > > if ((op_ptr->commute) || (src < rank)) > (*uop)(tmp_recvbuf, recvbuf, &recvcnts[rank], &datatype->self); > else { > (*uop)(recvbuf, tmp_recvbuf, &recvcnts[rank], &datatype->self); > /* copy result back into recvbuf */ > mpi_errno = MPI_Sendrecv (tmp_recvbuf, > recvcnts[rank], datatype->self, rank, > MPIR_REDUCE_SCATTER_TAG, recvbuf, > recvcnts[rank], datatype->self, rank, > MPIR_REDUCE_SCATTER_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > } > } > > FREE((char *)tmp_recvbuf+lb); > } > > if (!(op_ptr->commute) && (nbytes < > MPIR_REDSCAT_NONCOMMUTATIVE_SHORT_MSG)) { > > /* noncommutative and short messages, use recursive doubling. */ > > /* need to allocate temporary buffer to receive incoming data*/ > MPIR_ALLOC(tmp_recvbuf,(void *)MALLOC(extent*total_count), comm, > MPI_ERR_EXHAUSTED, myname); > /* adjust for potential negative lower bound in datatype */ > tmp_recvbuf = (void *)((char*)tmp_recvbuf - lb); > > /* need to allocate another temporary buffer to accumulate > results */ > MPIR_ALLOC(tmp_results,(void *)MALLOC(extent*total_count), comm, > MPI_ERR_EXHAUSTED, myname); > /* adjust for potential negative lower bound in datatype */ > tmp_results = (void *)((char*)tmp_results - lb); > > /* copy sendbuf into tmp_results */ > mpi_errno = MPI_Sendrecv (sendbuf, total_count, datatype->self, rank, > MPIR_REDUCE_SCATTER_TAG, tmp_results, > total_count, datatype->self, rank, > MPIR_REDUCE_SCATTER_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > > mask = 0x1; > i = 0; > while (mask < size) { > dst = rank ^ mask; > > dst_tree_root = dst >> i; > dst_tree_root <<= i; > > my_tree_root = rank >> i; > my_tree_root <<= i; > > /* At step 1, processes exchange (n-n/p) amount of > data; at step 2, (n-2n/p) amount of data; at step 3, (n-4n/p) > amount of data, and so forth. We use derived datatypes for this. > > At each step, a process does not need to send data > indexed from my_tree_root to > my_tree_root+mask-1. Similarly, a process won't receive > data indexed from dst_tree_root to dst_tree_root+mask-1. */ > > /* calculate sendtype */ > blklens[0] = blklens[1] = 0; > for (j=0; j blklens[0] += recvcnts[j]; > for (j=my_tree_root+mask; j blklens[1] += recvcnts[j]; > > dis[0] = 0; > dis[1] = blklens[0]; > for (j=my_tree_root; (j dis[1] += recvcnts[j]; > > MPI_Type_indexed(2, blklens, dis, datatype->self, &sendtype); > MPI_Type_commit(&sendtype); > > /* calculate recvtype */ > blklens[0] = blklens[1] = 0; > for (j=0; j blklens[0] += recvcnts[j]; > for (j=dst_tree_root+mask; j blklens[1] += recvcnts[j]; > > dis[0] = 0; > dis[1] = blklens[0]; > for (j=dst_tree_root; (j dis[1] += recvcnts[j]; > > MPI_Type_indexed(2, blklens, dis, datatype->self, &recvtype); > MPI_Type_commit(&recvtype); > > received = 0; > if (dst < size) { > /* tmp_results contains data to be sent in each step. Data is > received in tmp_recvbuf and then accumulated into > tmp_results. the accumulation is done later below. */ > > mpi_errno = MPI_Sendrecv(tmp_results, 1, sendtype, dst, > MPIR_REDUCE_SCATTER_TAG, tmp_recvbuf, > 1, recvtype, dst, > MPIR_REDUCE_SCATTER_TAG, comm->self, > &status); > received = 1; > if (mpi_errno) return mpi_errno; > } > > /* if some processes in this process's subtree in this step > did not have any destination process to communicate with > because of non-power-of-two, we need to send them the > result. We use a logarithmic recursive-halfing algorithm > for this. */ > > if (dst_tree_root + mask > size) { > nprocs_completed = size - my_tree_root - mask; > /* nprocs_completed is the number of processes in this > subtree that have all the data. Send data to others > in a tree fashion. First find root of current tree > that is being divided into two. k is the number of > least-significant bits in this process's rank that > must be zeroed out to find the rank of the root */ > j = mask; > k = 0; > while (j) { > j >>= 1; > k++; > } > k--; > > tmp_mask = mask >> 1; > while (tmp_mask) { > dst = rank ^ tmp_mask; > > tree_root = rank >> k; > tree_root <<= k; > > /* send only if this proc has data and destination > doesn't have data. at any step, multiple processes > can send if they have the data */ > if ((dst > rank) && > (rank < tree_root + nprocs_completed) > && (dst >= tree_root + nprocs_completed)) { > /* send the current result */ > mpi_errno = MPI_Send(tmp_recvbuf, 1, recvtype, > dst, MPIR_REDUCE_SCATTER_TAG, > comm->self); > if (mpi_errno) return mpi_errno; > } > /* recv only if this proc. doesn't have data and sender > has data */ > else if ((dst < rank) && > (dst < tree_root + nprocs_completed) && > (rank >= tree_root + nprocs_completed)) { > mpi_errno = MPI_Recv(tmp_recvbuf, 1, recvtype, dst, > MPIR_REDUCE_SCATTER_TAG, > comm->self, &status); > received = 1; > if (mpi_errno) return mpi_errno; > } > tmp_mask >>= 1; > k--; > } > } > > /* The following reduction is done here instead of after > the MPI_Sendrecv or MPI_Recv above. This is > because to do it above, in the noncommutative > case, we would need an extra temp buffer so as not to > overwrite temp_recvbuf, because temp_recvbuf may have > to be communicated to other processes in the > non-power-of-two case. To avoid that extra allocation, > we do the reduce here. */ > if (received) { > if ((op_ptr->commute) || (dst_tree_root < my_tree_root)) { > (*uop)(tmp_recvbuf, tmp_results, &blklens[0], > &datatype->self); > (*uop)(((char *)tmp_recvbuf + dis[1]*extent), > ((char *)tmp_results + dis[1]*extent), > &blklens[1], &datatype->self); > } > else { > (*uop)(tmp_results, tmp_recvbuf, &blklens[0], > &datatype->self); > (*uop)(((char *)tmp_results + dis[1]*extent), > ((char *)tmp_recvbuf + dis[1]*extent), > &blklens[1], &datatype->self); > /* copy result back into tmp_results */ > mpi_errno = MPI_Sendrecv(tmp_recvbuf, 1, recvtype, rank, > MPIR_REDUCE_SCATTER_TAG, > tmp_results, 1, recvtype, rank, > MPIR_REDUCE_SCATTER_TAG, > comm->self, &status); > if (mpi_errno) return mpi_errno; > } > } > > MPI_Type_free(&sendtype); > MPI_Type_free(&recvtype); > > mask <<= 1; > i++; > } > > /* now copy final results from tmp_results to recvbuf */ > mpi_errno = MPI_Sendrecv (((char *)tmp_results+disps[rank]*extent), > recvcnts[rank], datatype->self, rank, > MPIR_REDUCE_SCATTER_TAG, recvbuf, > recvcnts[rank], datatype->self, rank, > MPIR_REDUCE_SCATTER_TAG, comm->self, > &status); > if (mpi_errno) return mpi_errno; > > FREE((char *)tmp_recvbuf+lb); > FREE((char *)tmp_results+lb); > } > > FREE(disps); > > /* Unlock for collective operation */ > MPID_THREAD_UNLOCK(comm->ADIctx,comm); > > if (mpi_errno == MPI_SUCCESS && MPIR_Op_errno) { > /* PRINTF( "Error in performing MPI_Op in reduce_scatter\n" ); */ > mpi_errno = MPIR_Op_errno; > } > > return (mpi_errno); > } 3166a4714,4715 > > #ifdef OLD 3255c4804 < MPIR_ALLOC(tmp_recvbuf,(int *)MALLOC(extent*recvcnts[rank]),comm, --- > MPIR_ALLOC(tmp_recvbuf,(void *)MALLOC(extent*recvcnts[rank]),comm, 3516,3565d5064 < < #ifdef OLD < < /* Determine the "count" of items to reduce and set the displacements*/ < MPIR_Type_get_limits( datatype, &lb, &ub ); < m_extent = ub - lb; < /* MPI_Type_extent (datatype, &extent); */ < MPIR_Comm_size (comm, &size); < MPIR_Comm_rank (comm, &rank); < < /* Allocate the displacements and initialize them */ < MPIR_ALLOC(displs,(int *)MALLOC(size*sizeof(int)),comm, MPI_ERR_EXHAUSTED, < myname); < < total_count = 0; < for (i=0;iself, op, 0, < comm->self); < if (mpi_errno == MPI_SUCCESS || mpi_errno == MPIR_ERR_OP_NOT_DEFINED) { < rc = MPI_Scatterv ( buffer, recvcnts, displs, datatype->self, < recvbuf, recvcnts[rank], datatype->self, 0, < comm->self ); < if (rc) mpi_errno = rc; < } < /* Free the temporary buffers */ < FREE((char *)buffer+lb); FREE(displs); < #endif < 3568c5067 < --- > #endif Index: src/fortran/src/wtimef.c =================================================================== RCS file: /MPIhome/mpich/src/fortran/src/wtimef.c,v retrieving revision 1.4 retrieving revision 1.5 diff -r1.4 -r1.5 20c20 < double mpi_time_ ( void ); --- > double mpi_wtime_ ( void ); Index: src/pt2pt/testall.c =================================================================== RCS file: /MPIhome/mpich/src/pt2pt/testall.c,v retrieving revision 1.25 retrieving revision 1.27 diff -r1.25 -r1.27 2c2 < * $Id: testall.c,v 1.25 2002/03/15 18:51:55 gropp Exp $ --- > * $Id: testall.c,v 1.27 2003/02/19 16:38:32 gropp Exp $ 41c41 < 'MPI_STATUSES_NULL'. --- > 'MPI_STATUSES_IGNORE'. 160,162c160,167 < if ((array_of_statuses && < array_of_statuses[i].MPI_TAG != MPIR_MSG_CANCELLED) || < !MPID_SendRequestCancelled(request)) { --- > /* There was a test on > array_of_statuses[i].MPI_TAG != MPIR_MSG_CANCELLED > here to avoid the MPID_SendRequestCancelled call, > but that depends on setting the MPI_TAG field > in the array of statuses. It would be better to > make the MPID_SendRequestCancelled routine a > macro */ > if (!MPID_SendRequestCancelled(request)) { 165c170 < array_of_requests[i] = 0; --- > array_of_requests[i] = MPI_REQUEST_NULL; 188c193 < array_of_requests[i] = 0; --- > array_of_requests[i] = MPI_REQUEST_NULL;