summaryrefslogtreecommitdiffstats
path: root/src/H5Smpio.c
diff options
context:
space:
mode:
authorAlbert Cheng <acheng@hdfgroup.org>2000-11-27 18:25:18 (GMT)
committerAlbert Cheng <acheng@hdfgroup.org>2000-11-27 18:25:18 (GMT)
commitfb7987e708eb08d7cf7675a2aff50668a4941a55 (patch)
tree0b5bf71029aad3ac3ea2e8111171376e46f722aa /src/H5Smpio.c
parentf0b45019bb22d6a5240b12dfdb77871c83377454 (diff)
downloadhdf5-fb7987e708eb08d7cf7675a2aff50668a4941a55.zip
hdf5-fb7987e708eb08d7cf7675a2aff50668a4941a55.tar.gz
hdf5-fb7987e708eb08d7cf7675a2aff50668a4941a55.tar.bz2
[svn-r3003] Purpose:
Bug fix Description: The optimized MPI-IO calls, H5S_mpio_spaces_write/H5S_mpio_spaces_read, are changed for collective data transfer only since they call H5FD_mpio_setup to do setup to eveually call MPI_File_set_view in H5FD_mpio_read or H5FD_mpio_write. MPI_File_set_view is a collective call. Letting independent data transfer use this route would result in hanging. Solution: For now, the checking is being done in H5D_write and H5D_read before H5S_mpio_spaces_write/H5S_mpio_spaces_read is called because the checking code in H5S_mpio_spaces_xfer, though with the right idea, is not correct yet. Platforms tested: IRIX64-64 parallel.
Diffstat (limited to 'src/H5Smpio.c')
-rw-r--r--src/H5Smpio.c30
1 files changed, 29 insertions, 1 deletions
diff --git a/src/H5Smpio.c b/src/H5Smpio.c
index db6f762..fb92862 100644
--- a/src/H5Smpio.c
+++ b/src/H5Smpio.c
@@ -541,6 +541,7 @@ H5S_mpio_space_type( const H5S_t *space, const size_t elmt_size,
* rky 980918
* Added must_convert parameter to let caller know we can't optimize
* the xfer.
+ *
* Albert Cheng, 001123
* Include the MPI_type freeing as part of cleanup code.
*
@@ -587,7 +588,34 @@ H5S_mpio_spaces_xfer(H5F_t *f, const struct H5O_layout_t *layout,
*must_convert = 1; /* can't do optimized xfer; do the old way */
HGOTO_DONE(SUCCEED);
}
-
+
+ /*
+ * For collective data transfer only since this would eventually
+ * call H5FD_mpio_setup to do setup to eveually call MPI_File_set_view
+ * in H5FD_mpio_read or H5FD_mpio_write. MPI_File_set_view is a
+ * collective call. Letting independent data transfer use this
+ * route would result in hanging.
+ */
+#if 0
+ /* For now, the checking is being done in
+ * H5D_write and H5D_read before it is called because
+ * the following block of code, though with the right idea, is not
+ * correct yet.
+ */
+ { /* Get the transfer mode */
+ H5D_xfer_t *dxpl;
+ H5FD_mpio_dxpl_t *dx;
+
+ if (H5P_DEFAULT!=dxpl_id && (dxpl=H5I_object(dxpl_id)) &&
+ H5FD_MPIO==dxpl->driver_id && (dx=dxpl->driver_info) &&
+ H5FD_MPIO_COLLECTIVE==dx->xfer_mode) {
+ /* let it fall through */
+ }else{
+ *must_convert = 1; /* can't do optimized xfer; do the old way */
+ HGOTO_DONE(SUCCEED);
+ }
+ }
+#endif
/* create the MPI buffer type */
err = H5S_mpio_space_type( mem_space, elmt_size,