Replace MPI_Type_extent with MPI_Type_get_extent in ROMIO.
Signed-off-by: Ben Menadue <ben.menadue@nci.org.au> (back-ported from commit open-mpi/ompi@34ec0bd8ab) Signed-off-by: Gilles Gouaillardet <gilles@rist.or.jp>
Этот коммит содержится в:
родитель
11428e400a
Коммит
9d7f0e1c95
@ -526,7 +526,7 @@ static void ADIOI_Read_and_exch(ADIO_File fd, void *buf, MPI_Datatype
|
|||||||
int req_len, flag, rank;
|
int req_len, flag, rank;
|
||||||
MPI_Status status;
|
MPI_Status status;
|
||||||
ADIOI_Flatlist_node *flat_buf=NULL;
|
ADIOI_Flatlist_node *flat_buf=NULL;
|
||||||
MPI_Aint buftype_extent;
|
MPI_Aint buftype_extent, buftype_lb;
|
||||||
int coll_bufsize;
|
int coll_bufsize;
|
||||||
#ifdef RDCOLL_DEBUG
|
#ifdef RDCOLL_DEBUG
|
||||||
int iii;
|
int iii;
|
||||||
@ -607,7 +607,7 @@ static void ADIOI_Read_and_exch(ADIO_File fd, void *buf, MPI_Datatype
|
|||||||
if (!buftype_is_contig) {
|
if (!buftype_is_contig) {
|
||||||
flat_buf = ADIOI_Flatten_and_find(datatype);
|
flat_buf = ADIOI_Flatten_and_find(datatype);
|
||||||
}
|
}
|
||||||
MPI_Type_extent(datatype, &buftype_extent);
|
MPI_Type_get_extent(datatype, &buftype_lb, &buftype_extent);
|
||||||
|
|
||||||
done = 0;
|
done = 0;
|
||||||
off = st_loc;
|
off = st_loc;
|
||||||
|
@ -637,7 +637,7 @@ static void ADIOI_Exch_and_write(ADIO_File fd, const void *buf, MPI_Datatype
|
|||||||
int *send_buf_idx, *curr_to_proc, *done_to_proc;
|
int *send_buf_idx, *curr_to_proc, *done_to_proc;
|
||||||
MPI_Status status;
|
MPI_Status status;
|
||||||
ADIOI_Flatlist_node *flat_buf=NULL;
|
ADIOI_Flatlist_node *flat_buf=NULL;
|
||||||
MPI_Aint buftype_extent;
|
MPI_Aint buftype_extent, buftype_lb;
|
||||||
int info_flag, coll_bufsize;
|
int info_flag, coll_bufsize;
|
||||||
char *value;
|
char *value;
|
||||||
static char myname[] = "ADIOI_EXCH_AND_WRITE";
|
static char myname[] = "ADIOI_EXCH_AND_WRITE";
|
||||||
@ -752,7 +752,7 @@ static void ADIOI_Exch_and_write(ADIO_File fd, const void *buf, MPI_Datatype
|
|||||||
if (!buftype_is_contig) {
|
if (!buftype_is_contig) {
|
||||||
flat_buf = ADIOI_Flatten_and_find(datatype);
|
flat_buf = ADIOI_Flatten_and_find(datatype);
|
||||||
}
|
}
|
||||||
MPI_Type_extent(datatype, &buftype_extent);
|
MPI_Type_get_extent(datatype, &buftype_lb, &buftype_extent);
|
||||||
|
|
||||||
|
|
||||||
/* I need to check if there are any outstanding nonblocking writes to
|
/* I need to check if there are any outstanding nonblocking writes to
|
||||||
|
@ -195,9 +195,9 @@ void ADIOI_GRIDFTP_ReadDiscontig(ADIO_File fd, void *buf, int count,
|
|||||||
char myname[]="ADIOI_GRIDFTP_ReadDiscontig";
|
char myname[]="ADIOI_GRIDFTP_ReadDiscontig";
|
||||||
int myrank,nprocs;
|
int myrank,nprocs;
|
||||||
/* size and extent of buffer in memory */
|
/* size and extent of buffer in memory */
|
||||||
MPI_Aint btype_size,btype_extent;
|
MPI_Aint btype_size,btype_extent,btype_lb;
|
||||||
/* size and extent of file record layout */
|
/* size and extent of file record layout */
|
||||||
MPI_Aint ftype_size,ftype_extent;
|
MPI_Aint ftype_size,ftype_extent,ftype_lb;
|
||||||
/* size of file elemental type; seeks are done in units of this */
|
/* size of file elemental type; seeks are done in units of this */
|
||||||
MPI_Aint etype_size;
|
MPI_Aint etype_size;
|
||||||
MPI_Aint extent;
|
MPI_Aint extent;
|
||||||
@ -221,11 +221,11 @@ void ADIOI_GRIDFTP_ReadDiscontig(ADIO_File fd, void *buf, int count,
|
|||||||
|
|
||||||
etype_size=fd->etype_size;
|
etype_size=fd->etype_size;
|
||||||
MPI_Type_size_x(fd->filetype,&ftype_size);
|
MPI_Type_size_x(fd->filetype,&ftype_size);
|
||||||
MPI_Type_extent(fd->filetype,&ftype_extent);
|
MPI_Type_get_extent(fd->filetype,&ftype_lb,&ftype_extent);
|
||||||
/* This is arguably unnecessary, as this routine assumes that the
|
/* This is arguably unnecessary, as this routine assumes that the
|
||||||
buffer in memory is contiguous */
|
buffer in memory is contiguous */
|
||||||
MPI_Type_size_x(datatype,&btype_size);
|
MPI_Type_size_x(datatype,&btype_size);
|
||||||
MPI_Type_extent(datatype,&btype_extent);
|
MPI_Type_get_extent(datatype,&btype_lb,&btype_extent);
|
||||||
ADIOI_Datatype_iscontig(datatype,&buf_contig);
|
ADIOI_Datatype_iscontig(datatype,&buf_contig);
|
||||||
|
|
||||||
if ( ( btype_extent!=btype_size ) || ( ! buf_contig ) )
|
if ( ( btype_extent!=btype_size ) || ( ! buf_contig ) )
|
||||||
|
@ -207,8 +207,8 @@ void ADIOI_GRIDFTP_WriteDiscontig(ADIO_File fd, void *buf, int count,
|
|||||||
{
|
{
|
||||||
char myname[]="ADIOI_GRIDFTP_WriteDiscontig";
|
char myname[]="ADIOI_GRIDFTP_WriteDiscontig";
|
||||||
int myrank,nprocs;
|
int myrank,nprocs;
|
||||||
MPI_Aint btype_size,btype_extent;
|
MPI_Aint btype_size,btype_extent,btype_lb;
|
||||||
MPI_Aint ftype_size,ftype_extent;
|
MPI_Aint ftype_size,ftype_extent,ftype_lb;
|
||||||
MPI_Aint etype_size;
|
MPI_Aint etype_size;
|
||||||
MPI_Aint extent;
|
MPI_Aint extent;
|
||||||
ADIOI_Flatlist_node *flat_file;
|
ADIOI_Flatlist_node *flat_file;
|
||||||
@ -221,11 +221,11 @@ void ADIOI_GRIDFTP_WriteDiscontig(ADIO_File fd, void *buf, int count,
|
|||||||
MPI_Comm_size(fd->comm,&nprocs);
|
MPI_Comm_size(fd->comm,&nprocs);
|
||||||
etype_size=fd->etype_size;
|
etype_size=fd->etype_size;
|
||||||
MPI_Type_size_x(fd->filetype,&ftype_size);
|
MPI_Type_size_x(fd->filetype,&ftype_size);
|
||||||
MPI_Type_extent(fd->filetype,&ftype_extent);
|
MPI_Type_get_extent(fd->filetype,&ftype_lb,&ftype_extent);
|
||||||
/* This is arguably unnecessary, as this routine assumes that the
|
/* This is arguably unnecessary, as this routine assumes that the
|
||||||
buffer in memory is contiguous */
|
buffer in memory is contiguous */
|
||||||
MPI_Type_size_x(datatype,&btype_size);
|
MPI_Type_size_x(datatype,&btype_size);
|
||||||
MPI_Type_extent(datatype,&btype_extent);
|
MPI_Type_get_extent(datatype,&btype_lb,&btype_extent);
|
||||||
ADIOI_Datatype_iscontig(datatype,&buf_contig);
|
ADIOI_Datatype_iscontig(datatype,&buf_contig);
|
||||||
|
|
||||||
if ( ( btype_extent!=btype_size ) || ( ! buf_contig ) )
|
if ( ( btype_extent!=btype_size ) || ( ! buf_contig ) )
|
||||||
|
@ -316,7 +316,7 @@ static void ADIOI_LUSTRE_Exch_and_write(ADIO_File fd, const void *buf,
|
|||||||
char *write_buf = NULL;
|
char *write_buf = NULL;
|
||||||
MPI_Status status;
|
MPI_Status status;
|
||||||
ADIOI_Flatlist_node *flat_buf = NULL;
|
ADIOI_Flatlist_node *flat_buf = NULL;
|
||||||
MPI_Aint buftype_extent;
|
MPI_Aint buftype_extent, buftype_lb;
|
||||||
int stripe_size = striping_info[0], avail_cb_nodes = striping_info[2];
|
int stripe_size = striping_info[0], avail_cb_nodes = striping_info[2];
|
||||||
int data_sieving = 0;
|
int data_sieving = 0;
|
||||||
ADIO_Offset *srt_off = NULL;
|
ADIO_Offset *srt_off = NULL;
|
||||||
@ -417,7 +417,7 @@ static void ADIOI_LUSTRE_Exch_and_write(ADIO_File fd, const void *buf,
|
|||||||
if (!buftype_is_contig) {
|
if (!buftype_is_contig) {
|
||||||
flat_buf = ADIOI_Flatten_and_find(datatype);
|
flat_buf = ADIOI_Flatten_and_find(datatype);
|
||||||
}
|
}
|
||||||
MPI_Type_extent(datatype, &buftype_extent);
|
MPI_Type_get_extent(datatype, &buftype_lb, &buftype_extent);
|
||||||
/* I need to check if there are any outstanding nonblocking writes to
|
/* I need to check if there are any outstanding nonblocking writes to
|
||||||
* the file, which could potentially interfere with the writes taking
|
* the file, which could potentially interfere with the writes taking
|
||||||
* place in this collective write call. Since this is not likely to be
|
* place in this collective write call. Since this is not likely to be
|
||||||
|
@ -157,7 +157,7 @@ void ADIOI_LUSTRE_WriteStrided(ADIO_File fd, const void *buf, int count,
|
|||||||
ADIO_Offset num, size, n_filetypes, etype_in_filetype, st_n_filetypes;
|
ADIO_Offset num, size, n_filetypes, etype_in_filetype, st_n_filetypes;
|
||||||
ADIO_Offset abs_off_in_filetype=0;
|
ADIO_Offset abs_off_in_filetype=0;
|
||||||
MPI_Count filetype_size, etype_size, buftype_size;
|
MPI_Count filetype_size, etype_size, buftype_size;
|
||||||
MPI_Aint filetype_extent, buftype_extent;
|
MPI_Aint filetype_extent, buftype_extent, filetype_lb, buftype_lb;
|
||||||
int buf_count, buftype_is_contig, filetype_is_contig;
|
int buf_count, buftype_is_contig, filetype_is_contig;
|
||||||
ADIO_Offset userbuf_off;
|
ADIO_Offset userbuf_off;
|
||||||
ADIO_Offset off, req_off, disp, end_offset=0, writebuf_off, start_off;
|
ADIO_Offset off, req_off, disp, end_offset=0, writebuf_off, start_off;
|
||||||
@ -195,9 +195,9 @@ void ADIOI_LUSTRE_WriteStrided(ADIO_File fd, const void *buf, int count,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
MPI_Type_extent(fd->filetype, &filetype_extent);
|
MPI_Type_get_extent(fd->filetype, &filetype_lb, &filetype_extent);
|
||||||
MPI_Type_size_x(datatype, &buftype_size);
|
MPI_Type_size_x(datatype, &buftype_size);
|
||||||
MPI_Type_extent(datatype, &buftype_extent);
|
MPI_Type_get_extent(datatype, &buftype_lb, &buftype_extent);
|
||||||
etype_size = fd->etype_size;
|
etype_size = fd->etype_size;
|
||||||
|
|
||||||
ADIOI_Assert((buftype_size * count) == ((ADIO_Offset)(unsigned)buftype_size * (ADIO_Offset)count));
|
ADIOI_Assert((buftype_size * count) == ((ADIO_Offset)(unsigned)buftype_size * (ADIO_Offset)count));
|
||||||
|
@ -76,7 +76,7 @@ void ADIOI_PIOFS_WriteStrided(ADIO_File fd, void *buf, int count,
|
|||||||
int n_filetypes, etype_in_filetype;
|
int n_filetypes, etype_in_filetype;
|
||||||
ADIO_Offset abs_off_in_filetype=0;
|
ADIO_Offset abs_off_in_filetype=0;
|
||||||
MPI_Count filetype_size, etype_size, buftype_size;
|
MPI_Count filetype_size, etype_size, buftype_size;
|
||||||
MPI_Aint filetype_extent, buftype_extent, indx;
|
MPI_Aint filetype_extent, buftype_extent, indx, filetype_lb, buftype_lb;
|
||||||
int buf_count, buftype_is_contig, filetype_is_contig;
|
int buf_count, buftype_is_contig, filetype_is_contig;
|
||||||
ADIO_Offset off, disp;
|
ADIO_Offset off, disp;
|
||||||
int flag, new_bwr_size, new_fwr_size, err_flag=0;
|
int flag, new_bwr_size, new_fwr_size, err_flag=0;
|
||||||
@ -101,9 +101,9 @@ void ADIOI_PIOFS_WriteStrided(ADIO_File fd, void *buf, int count,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
MPI_Type_extent(fd->filetype, &filetype_extent);
|
MPI_Type_get_extent(fd->filetype, &filetype_lb, &filetype_extent);
|
||||||
MPI_Type_size_x(datatype, &buftype_size);
|
MPI_Type_size_x(datatype, &buftype_size);
|
||||||
MPI_Type_extent(datatype, &buftype_extent);
|
MPI_Type_get_extent(datatype, &buftype_lb, &buftype_extent);
|
||||||
etype_size = fd->etype_size;
|
etype_size = fd->etype_size;
|
||||||
|
|
||||||
bufsize = buftype_size * count;
|
bufsize = buftype_size * count;
|
||||||
|
@ -158,9 +158,9 @@ void ADIOI_PVFS_ReadStridedListIO(ADIO_File fd, void *buf, int count,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
MPI_Type_extent(fd->filetype, &filetype_extent);
|
MPI_Type_get_extent(fd->filetype, &filetype_lb, &filetype_extent);
|
||||||
MPI_Type_size_x(datatype, &buftype_size);
|
MPI_Type_size_x(datatype, &buftype_size);
|
||||||
MPI_Type_extent(datatype, &buftype_extent);
|
MPI_Type_get_extent(datatype, &buftype_lb, &buftype_extent);
|
||||||
etype_size = fd->etype_size;
|
etype_size = fd->etype_size;
|
||||||
|
|
||||||
bufsize = buftype_size * count;
|
bufsize = buftype_size * count;
|
||||||
|
@ -101,7 +101,7 @@ void ADIOI_PVFS_WriteStrided(ADIO_File fd, void *buf, int count,
|
|||||||
int n_filetypes, etype_in_filetype;
|
int n_filetypes, etype_in_filetype;
|
||||||
ADIO_Offset abs_off_in_filetype=0;
|
ADIO_Offset abs_off_in_filetype=0;
|
||||||
MPI_Count filetype_size, etype_size, buftype_size;
|
MPI_Count filetype_size, etype_size, buftype_size;
|
||||||
MPI_Aint filetype_extent, buftype_extent, indx;
|
MPI_Aint filetype_extent, buftype_extent, indx, filetype_lb, buftype_lb;
|
||||||
int buf_count, buftype_is_contig, filetype_is_contig;
|
int buf_count, buftype_is_contig, filetype_is_contig;
|
||||||
ADIO_Offset off, disp;
|
ADIO_Offset off, disp;
|
||||||
int flag, new_bwr_size, new_fwr_size, err_flag=0;
|
int flag, new_bwr_size, new_fwr_size, err_flag=0;
|
||||||
@ -138,9 +138,9 @@ void ADIOI_PVFS_WriteStrided(ADIO_File fd, void *buf, int count,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
MPI_Type_extent(fd->filetype, &filetype_extent);
|
MPI_Type_get_extent(fd->filetype, &filetype_lb, &filetype_extent);
|
||||||
MPI_Type_size_x(datatype, &buftype_size);
|
MPI_Type_size_x(datatype, &buftype_size);
|
||||||
MPI_Type_extent(datatype, &buftype_extent);
|
MPI_Type_get_extent(datatype, &buftype_lb, &buftype_extent);
|
||||||
etype_size = fd->etype_size;
|
etype_size = fd->etype_size;
|
||||||
|
|
||||||
bufsize = buftype_size * count;
|
bufsize = buftype_size * count;
|
||||||
@ -471,7 +471,7 @@ void ADIOI_PVFS_WriteStridedListIO(ADIO_File fd, void *buf, int count,
|
|||||||
int n_filetypes, etype_in_filetype;
|
int n_filetypes, etype_in_filetype;
|
||||||
ADIO_Offset abs_off_in_filetype=0;
|
ADIO_Offset abs_off_in_filetype=0;
|
||||||
MPI_Count filetype_size, etype_size, buftype_size;
|
MPI_Count filetype_size, etype_size, buftype_size;
|
||||||
MPI_Aint filetype_extent, buftype_extent;
|
MPI_Aint filetype_extent, buftype_extent, filetype_lb, buftype_lb;
|
||||||
int buf_count, buftype_is_contig, filetype_is_contig;
|
int buf_count, buftype_is_contig, filetype_is_contig;
|
||||||
ADIO_Offset userbuf_off;
|
ADIO_Offset userbuf_off;
|
||||||
ADIO_Offset off, disp, start_off;
|
ADIO_Offset off, disp, start_off;
|
||||||
@ -522,9 +522,9 @@ void ADIOI_PVFS_WriteStridedListIO(ADIO_File fd, void *buf, int count,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
MPI_Type_extent(fd->filetype, &filetype_extent);
|
MPI_Type_get_extent(fd->filetype, &filetype_lb, &filetype_extent);
|
||||||
MPI_Type_size_x(datatype, &buftype_size);
|
MPI_Type_size_x(datatype, &buftype_size);
|
||||||
MPI_Type_extent(datatype, &buftype_extent);
|
MPI_Type_get_extent(datatype, &buftype_lb, &buftype_extent);
|
||||||
etype_size = fd->etype_size;
|
etype_size = fd->etype_size;
|
||||||
|
|
||||||
bufsize = buftype_size * count;
|
bufsize = buftype_size * count;
|
||||||
|
@ -24,7 +24,7 @@ int ADIOI_PVFS2_StridedDtypeIO(ADIO_File fd, void *buf, int count,
|
|||||||
PVFS_Request tmp_mem_req, mem_req, tmp_file_req, file_req;
|
PVFS_Request tmp_mem_req, mem_req, tmp_file_req, file_req;
|
||||||
PVFS_sysresp_io resp_io;
|
PVFS_sysresp_io resp_io;
|
||||||
ADIO_Offset off = -1, bytes_into_filetype = 0;
|
ADIO_Offset off = -1, bytes_into_filetype = 0;
|
||||||
MPI_Aint filetype_extent = -1;
|
MPI_Aint filetype_extent = -1, filetype_lb = -1;
|
||||||
int i = -1;
|
int i = -1;
|
||||||
MPI_Count etype_size;
|
MPI_Count etype_size;
|
||||||
PVFS_size pvfs_disp = -1;
|
PVFS_size pvfs_disp = -1;
|
||||||
@ -54,7 +54,7 @@ int ADIOI_PVFS2_StridedDtypeIO(ADIO_File fd, void *buf, int count,
|
|||||||
*error_code = MPI_SUCCESS;
|
*error_code = MPI_SUCCESS;
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
MPI_Type_extent(fd->filetype, &filetype_extent);
|
MPI_Type_get_extent(fd->filetype, &filetype_lb, &filetype_extent);
|
||||||
MPI_Type_size_x(fd->etype, &etype_size);
|
MPI_Type_size_x(fd->etype, &etype_size);
|
||||||
if (filetype_size == 0) {
|
if (filetype_size == 0) {
|
||||||
*error_code = MPI_SUCCESS;
|
*error_code = MPI_SUCCESS;
|
||||||
|
@ -44,6 +44,7 @@ int ADIOI_PVFS2_StridedListIO(ADIO_File fd, void *buf, int count,
|
|||||||
ADIOI_Flatlist_node *flat_buf_p, *flat_file_p;
|
ADIOI_Flatlist_node *flat_buf_p, *flat_file_p;
|
||||||
MPI_Count buftype_size = -1, filetype_size = -1;
|
MPI_Count buftype_size = -1, filetype_size = -1;
|
||||||
MPI_Aint filetype_extent = -1, buftype_extent = -1;;
|
MPI_Aint filetype_extent = -1, buftype_extent = -1;;
|
||||||
|
MPI_Aint filetype_lb = -1, buftype_lb = -1;;
|
||||||
int buftype_is_contig = -1, filetype_is_contig = -1;
|
int buftype_is_contig = -1, filetype_is_contig = -1;
|
||||||
|
|
||||||
/* PVFS2 specific parameters */
|
/* PVFS2 specific parameters */
|
||||||
@ -67,9 +68,9 @@ int ADIOI_PVFS2_StridedListIO(ADIO_File fd, void *buf, int count,
|
|||||||
*error_code = MPI_SUCCESS;
|
*error_code = MPI_SUCCESS;
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
MPI_Type_extent(fd->filetype, &filetype_extent);
|
MPI_Type_get_extent(fd->filetype, &filetype_lb, &filetype_extent);
|
||||||
MPI_Type_size_x(datatype, &buftype_size);
|
MPI_Type_size_x(datatype, &buftype_size);
|
||||||
MPI_Type_extent(datatype, &buftype_extent);
|
MPI_Type_get_extent(datatype, &buftype_lb, &buftype_extent);
|
||||||
io_size = buftype_size*count;
|
io_size = buftype_size*count;
|
||||||
|
|
||||||
pvfs_fs = (ADIOI_PVFS2_fs*)fd->fs_ptr;
|
pvfs_fs = (ADIOI_PVFS2_fs*)fd->fs_ptr;
|
||||||
|
@ -24,7 +24,7 @@ void ADIOI_PVFS2_OldReadStrided(ADIO_File fd, void *buf, int count,
|
|||||||
int n_filetypes, etype_in_filetype;
|
int n_filetypes, etype_in_filetype;
|
||||||
ADIO_Offset abs_off_in_filetype=0;
|
ADIO_Offset abs_off_in_filetype=0;
|
||||||
MPI_Count filetype_size, etype_size, buftype_size;
|
MPI_Count filetype_size, etype_size, buftype_size;
|
||||||
MPI_Aint filetype_extent, buftype_extent;
|
MPI_Aint filetype_extent, buftype_extent, filetype_lb, buftype_lb;
|
||||||
int buf_count, buftype_is_contig, filetype_is_contig;
|
int buf_count, buftype_is_contig, filetype_is_contig;
|
||||||
ADIO_Offset off, disp, start_off, initial_off;
|
ADIO_Offset off, disp, start_off, initial_off;
|
||||||
int flag, st_frd_size, st_n_filetypes;
|
int flag, st_frd_size, st_n_filetypes;
|
||||||
@ -78,9 +78,9 @@ void ADIOI_PVFS2_OldReadStrided(ADIO_File fd, void *buf, int count,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
MPI_Type_extent(fd->filetype, &filetype_extent);
|
MPI_Type_get_extent(fd->filetype, &filetype_lb, &filetype_extent);
|
||||||
MPI_Type_size_x(datatype, &buftype_size);
|
MPI_Type_size_x(datatype, &buftype_size);
|
||||||
MPI_Type_extent(datatype, &buftype_extent);
|
MPI_Type_get_extent(datatype, &buftype_lb, &buftype_extent);
|
||||||
etype_size = fd->etype_size;
|
etype_size = fd->etype_size;
|
||||||
|
|
||||||
bufsize = buftype_size * count;
|
bufsize = buftype_size * count;
|
||||||
|
@ -29,7 +29,7 @@ void ADIOI_PVFS2_OldWriteStrided(ADIO_File fd, const void *buf, int count,
|
|||||||
int n_filetypes, etype_in_filetype;
|
int n_filetypes, etype_in_filetype;
|
||||||
ADIO_Offset abs_off_in_filetype=0;
|
ADIO_Offset abs_off_in_filetype=0;
|
||||||
MPI_Count filetype_size, etype_size, buftype_size;
|
MPI_Count filetype_size, etype_size, buftype_size;
|
||||||
MPI_Aint filetype_extent, buftype_extent;
|
MPI_Aint filetype_extent, buftype_extent, filetype_lb, buftype_lb;
|
||||||
int buf_count, buftype_is_contig, filetype_is_contig;
|
int buf_count, buftype_is_contig, filetype_is_contig;
|
||||||
ADIO_Offset off, disp, start_off, initial_off;
|
ADIO_Offset off, disp, start_off, initial_off;
|
||||||
int flag, st_fwr_size, st_n_filetypes;
|
int flag, st_fwr_size, st_n_filetypes;
|
||||||
@ -94,9 +94,9 @@ void ADIOI_PVFS2_OldWriteStrided(ADIO_File fd, const void *buf, int count,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
MPI_Type_extent(fd->filetype, &filetype_extent);
|
MPI_Type_get_extent(fd->filetype, &filetype_lb, &filetype_extent);
|
||||||
MPI_Type_size_x(datatype, &buftype_size);
|
MPI_Type_size_x(datatype, &buftype_size);
|
||||||
MPI_Type_extent(datatype, &buftype_extent);
|
MPI_Type_get_extent(datatype, &buftype_lb, &buftype_extent);
|
||||||
etype_size = fd->etype_size;
|
etype_size = fd->etype_size;
|
||||||
|
|
||||||
bufsize = buftype_size * count;
|
bufsize = buftype_size * count;
|
||||||
|
@ -26,7 +26,7 @@ void ADIOI_ZOIDFS_ReadStrided(ADIO_File fd, void *buf, int count,
|
|||||||
int n_filetypes, etype_in_filetype;
|
int n_filetypes, etype_in_filetype;
|
||||||
ADIO_Offset abs_off_in_filetype=0;
|
ADIO_Offset abs_off_in_filetype=0;
|
||||||
MPI_Count filetype_size, etype_size, buftype_size;
|
MPI_Count filetype_size, etype_size, buftype_size;
|
||||||
MPI_Aint filetype_extent, buftype_extent;
|
MPI_Aint filetype_extent, buftype_extent, filetype_lb, buftype_lb;
|
||||||
int buf_count, buftype_is_contig, filetype_is_contig;
|
int buf_count, buftype_is_contig, filetype_is_contig;
|
||||||
ADIO_Offset off, disp, start_off, initial_off;
|
ADIO_Offset off, disp, start_off, initial_off;
|
||||||
int flag, st_frd_size, st_n_filetypes;
|
int flag, st_frd_size, st_n_filetypes;
|
||||||
@ -80,9 +80,9 @@ void ADIOI_ZOIDFS_ReadStrided(ADIO_File fd, void *buf, int count,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
MPI_Type_extent(fd->filetype, &filetype_extent);
|
MPI_Type_get_extent(fd->filetype, &filetype_lb, &filetype_extent);
|
||||||
MPI_Type_size_x(datatype, &buftype_size);
|
MPI_Type_size_x(datatype, &buftype_size);
|
||||||
MPI_Type_extent(datatype, &buftype_extent);
|
MPI_Type_get_extent(datatype, &buftype_lb, &buftype_extent);
|
||||||
etype_size = fd->etype_size;
|
etype_size = fd->etype_size;
|
||||||
|
|
||||||
bufsize = buftype_size * count;
|
bufsize = buftype_size * count;
|
||||||
|
@ -31,7 +31,7 @@ void ADIOI_ZOIDFS_WriteStrided(ADIO_File fd, void *buf, int count,
|
|||||||
int n_filetypes, etype_in_filetype;
|
int n_filetypes, etype_in_filetype;
|
||||||
ADIO_Offset abs_off_in_filetype=0;
|
ADIO_Offset abs_off_in_filetype=0;
|
||||||
MPI_Count filetype_size, etype_size, buftype_size;
|
MPI_Count filetype_size, etype_size, buftype_size;
|
||||||
MPI_Aint filetype_extent, buftype_extent;
|
MPI_Aint filetype_extent, buftype_extent, filetype_lb, buftype_lb;
|
||||||
int buf_count, buftype_is_contig, filetype_is_contig;
|
int buf_count, buftype_is_contig, filetype_is_contig;
|
||||||
ADIO_Offset off, disp, start_off, initial_off;
|
ADIO_Offset off, disp, start_off, initial_off;
|
||||||
int flag, st_fwr_size, st_n_filetypes;
|
int flag, st_fwr_size, st_n_filetypes;
|
||||||
@ -94,9 +94,9 @@ void ADIOI_ZOIDFS_WriteStrided(ADIO_File fd, void *buf, int count,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
MPI_Type_extent(fd->filetype, &filetype_extent);
|
MPI_Type_get_extent(fd->filetype, &filetype_lb, &filetype_extent);
|
||||||
MPI_Type_size_x(datatype, &buftype_size);
|
MPI_Type_size_x(datatype, &buftype_size);
|
||||||
MPI_Type_extent(datatype, &buftype_extent);
|
MPI_Type_get_extent(datatype, &buftype_lb, &buftype_extent);
|
||||||
etype_size = fd->etype_size;
|
etype_size = fd->etype_size;
|
||||||
|
|
||||||
bufsize = buftype_size * count;
|
bufsize = buftype_size * count;
|
||||||
|
@ -122,7 +122,7 @@ void ADIOI_GEN_WriteStrided(ADIO_File fd, const void *buf, int count,
|
|||||||
ADIO_Offset num, size, n_filetypes, etype_in_filetype, st_n_filetypes;
|
ADIO_Offset num, size, n_filetypes, etype_in_filetype, st_n_filetypes;
|
||||||
ADIO_Offset n_etypes_in_filetype, abs_off_in_filetype=0;
|
ADIO_Offset n_etypes_in_filetype, abs_off_in_filetype=0;
|
||||||
MPI_Count filetype_size, etype_size, buftype_size;
|
MPI_Count filetype_size, etype_size, buftype_size;
|
||||||
MPI_Aint filetype_extent, buftype_extent;
|
MPI_Aint filetype_extent, buftype_extent, lb;
|
||||||
int buf_count, buftype_is_contig, filetype_is_contig;
|
int buf_count, buftype_is_contig, filetype_is_contig;
|
||||||
ADIO_Offset userbuf_off;
|
ADIO_Offset userbuf_off;
|
||||||
ADIO_Offset off, req_off, disp, end_offset=0, writebuf_off, start_off;
|
ADIO_Offset off, req_off, disp, end_offset=0, writebuf_off, start_off;
|
||||||
|
@ -24,7 +24,7 @@ void ADIOI_GEN_WriteStrided_naive(ADIO_File fd, const void *buf, int count,
|
|||||||
ADIO_Offset size, n_filetypes, etype_in_filetype;
|
ADIO_Offset size, n_filetypes, etype_in_filetype;
|
||||||
ADIO_Offset abs_off_in_filetype=0, req_len;
|
ADIO_Offset abs_off_in_filetype=0, req_len;
|
||||||
MPI_Count filetype_size, etype_size, buftype_size;
|
MPI_Count filetype_size, etype_size, buftype_size;
|
||||||
MPI_Aint filetype_extent, buftype_extent;
|
MPI_Aint filetype_extent, buftype_extent, lb;
|
||||||
int buf_count, buftype_is_contig, filetype_is_contig;
|
int buf_count, buftype_is_contig, filetype_is_contig;
|
||||||
ADIO_Offset userbuf_off;
|
ADIO_Offset userbuf_off;
|
||||||
ADIO_Offset off, req_off, disp, end_offset=0, start_off;
|
ADIO_Offset off, req_off, disp, end_offset=0, start_off;
|
||||||
|
@ -250,14 +250,14 @@ printf("ADIOI_OneSidedWriteAggregation started on rank %d\n",myrank);
|
|||||||
*/
|
*/
|
||||||
int bufTypeIsContig;
|
int bufTypeIsContig;
|
||||||
|
|
||||||
MPI_Aint bufTypeExtent;
|
MPI_Aint bufTypeExtent, lb;
|
||||||
ADIOI_Flatlist_node *flatBuf=NULL;
|
ADIOI_Flatlist_node *flatBuf=NULL;
|
||||||
ADIOI_Datatype_iscontig(datatype, &bufTypeIsContig);
|
ADIOI_Datatype_iscontig(datatype, &bufTypeIsContig);
|
||||||
|
|
||||||
if (!bufTypeIsContig) {
|
if (!bufTypeIsContig) {
|
||||||
/* Flatten the non-contiguous source datatype and set the extent. */
|
/* Flatten the non-contiguous source datatype and set the extent. */
|
||||||
flatBuf = ADIOI_Flatten_and_find(datatype);
|
flatBuf = ADIOI_Flatten_and_find(datatype);
|
||||||
MPI_Type_extent(datatype, &bufTypeExtent);
|
MPI_Type_get_extent(datatype, &lb, &bufTypeExtent);
|
||||||
#ifdef onesidedtrace
|
#ifdef onesidedtrace
|
||||||
printf("flatBuf->count is %d bufTypeExtent is %d\n", flatBuf->count,bufTypeExtent);
|
printf("flatBuf->count is %d bufTypeExtent is %d\n", flatBuf->count,bufTypeExtent);
|
||||||
for (i=0;i<flatBuf->count;i++)
|
for (i=0;i<flatBuf->count;i++)
|
||||||
@ -1281,7 +1281,7 @@ printf("ADIOI_OneSidedReadAggregation started on rank %d\n",myrank);
|
|||||||
*/
|
*/
|
||||||
int bufTypeIsContig;
|
int bufTypeIsContig;
|
||||||
|
|
||||||
MPI_Aint bufTypeExtent;
|
MPI_Aint bufTypeExtent, lb;
|
||||||
ADIOI_Flatlist_node *flatBuf=NULL;
|
ADIOI_Flatlist_node *flatBuf=NULL;
|
||||||
ADIOI_Datatype_iscontig(datatype, &bufTypeIsContig);
|
ADIOI_Datatype_iscontig(datatype, &bufTypeIsContig);
|
||||||
|
|
||||||
@ -1289,7 +1289,7 @@ printf("ADIOI_OneSidedReadAggregation started on rank %d\n",myrank);
|
|||||||
/* Flatten the non-contiguous source datatype.
|
/* Flatten the non-contiguous source datatype.
|
||||||
*/
|
*/
|
||||||
flatBuf = ADIOI_Flatten_and_find(datatype);
|
flatBuf = ADIOI_Flatten_and_find(datatype);
|
||||||
MPI_Type_extent(datatype, &bufTypeExtent);
|
MPI_Type_get_extent(datatype, &lb, &bufTypeExtent);
|
||||||
#ifdef onesidedtrace
|
#ifdef onesidedtrace
|
||||||
printf("flatBuf->count is %d bufTypeExtent is %d\n", flatBuf->count,bufTypeExtent);
|
printf("flatBuf->count is %d bufTypeExtent is %d\n", flatBuf->count,bufTypeExtent);
|
||||||
for (i=0;i<flatBuf->count;i++)
|
for (i=0;i<flatBuf->count;i++)
|
||||||
|
@ -50,7 +50,7 @@ int MPI_Type_create_darray(int size, int rank, int ndims,
|
|||||||
{
|
{
|
||||||
int err, error_code;
|
int err, error_code;
|
||||||
int i;
|
int i;
|
||||||
MPI_Aint orig_extent, size_with_aint;
|
MPI_Aint orig_extent, orig_lb, size_with_aint;
|
||||||
MPI_Offset size_with_offset;
|
MPI_Offset size_with_offset;
|
||||||
static char myname[] = "MPI_TYPE_CREATE_DARRAY";
|
static char myname[] = "MPI_TYPE_CREATE_DARRAY";
|
||||||
|
|
||||||
@ -159,7 +159,7 @@ int MPI_Type_create_darray(int size, int rank, int ndims,
|
|||||||
return MPIO_Err_return_comm(MPI_COMM_SELF, error_code);
|
return MPIO_Err_return_comm(MPI_COMM_SELF, error_code);
|
||||||
}
|
}
|
||||||
|
|
||||||
MPI_Type_extent(oldtype, &orig_extent);
|
MPI_Type_get_extent(oldtype, &orig_lb, &orig_extent);
|
||||||
|
|
||||||
/* check if MPI_Aint is large enough for size of global array.
|
/* check if MPI_Aint is large enough for size of global array.
|
||||||
if not, complain. */
|
if not, complain. */
|
||||||
|
@ -43,7 +43,7 @@ int MPI_Type_create_subarray(int ndims, int *array_of_sizes,
|
|||||||
int order, MPI_Datatype oldtype,
|
int order, MPI_Datatype oldtype,
|
||||||
MPI_Datatype *newtype)
|
MPI_Datatype *newtype)
|
||||||
{
|
{
|
||||||
MPI_Aint extent, size_with_aint;
|
MPI_Aint extent, lb, size_with_aint;
|
||||||
int i, err, error_code;
|
int i, err, error_code;
|
||||||
MPI_Offset size_with_offset;
|
MPI_Offset size_with_offset;
|
||||||
|
|
||||||
@ -128,7 +128,7 @@ int MPI_Type_create_subarray(int ndims, int *array_of_sizes,
|
|||||||
return MPIO_Err_return_comm(MPI_COMM_SELF, error_code);
|
return MPIO_Err_return_comm(MPI_COMM_SELF, error_code);
|
||||||
}
|
}
|
||||||
|
|
||||||
MPI_Type_extent(oldtype, &extent);
|
MPI_Type_get_extent(oldtype, &lb, &extent);
|
||||||
|
|
||||||
/* check if MPI_Aint is large enough for size of global array.
|
/* check if MPI_Aint is large enough for size of global array.
|
||||||
if not, complain. */
|
if not, complain. */
|
||||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user