diff options
author | MuQun Yang <ymuqun@hdfgroup.org> | 2005-09-27 03:33:20 (GMT) |
---|---|---|
committer | MuQun Yang <ymuqun@hdfgroup.org> | 2005-09-27 03:33:20 (GMT) |
commit | 08b0e9da810f65fa11e0aaebc31a04373fdd521b (patch) | |
tree | 81dfec0199304e0511598b44dab2e4e933038033 | |
parent | f343e0fbc2c55706fe70381257573817a06efc39 (diff) | |
download | hdf5-08b0e9da810f65fa11e0aaebc31a04373fdd521b.zip hdf5-08b0e9da810f65fa11e0aaebc31a04373fdd521b.tar.gz hdf5-08b0e9da810f65fa11e0aaebc31a04373fdd521b.tar.bz2 |
[svn-r11469] Purpose:
Fix the collective chunk IO bug when MPI complicated derived datatype is not working.
Description:
Suspected it was an MPI-IO bug at mcr with mpich 1.2.4.
The current implementation had no optimization for collective IO after discussing with Albert. So I decided to switch collective IO to independent IO when we found MPI complicated derived datatype not working.
Solution:
Platforms tested:
heping mpich 1.2.6
tera-grid mpich 1.2.5
(shouldn't affect platforms which the complicated derived datatype is working, so no
need to test three platforms.)
Misc. update:
-rw-r--r-- | src/H5Dio.c | 40 |
1 files changed, 0 insertions, 40 deletions
diff --git a/src/H5Dio.c b/src/H5Dio.c index b030f95..baf0131 100644 --- a/src/H5Dio.c +++ b/src/H5Dio.c @@ -1606,29 +1606,9 @@ H5D_chunk_read(H5D_io_info_t *io_info, hsize_t nelmts, } #ifndef H5_MPI_COMPLEX_DERIVED_DATATYPE_WORKS else { - int is_regular; /* If this chunk's selections are regular */ - int mpi_code; /* MPI error code */ - int all_regular = 0; /* If this chunk's selections are regular on all processes */ - - /* Determine if this process has regular selections */ - if(H5S_SELECT_IS_REGULAR(chunk_info->fspace) == TRUE && - H5S_SELECT_IS_REGULAR(chunk_info->mspace) == TRUE) - is_regular = 1; - else - is_regular = 0; - - /* Determine if all processes have regular selections */ - if (MPI_SUCCESS != (mpi_code = MPI_Allreduce(&is_regular, &all_regular, 1, MPI_INT, MPI_LAND, io_info->comm))) - HMPI_GOTO_ERROR(FAIL, "MPI_Allreduce failed", mpi_code) - - /* For regular selection, - if MPI_COMPLEX_DERIVED_DATATYPE is not defined, - unless spaces for all processors are regular, independent read operation should be performed.*/ - if(!all_regular) { /* Switch to independent I/O (temporarily) */ make_ind = TRUE; make_coll = TRUE; - } /* end if */ } /* end else */ #endif /* H5_MPI_COMPLEX_DERIVED_DATATYPE_WORKS */ } /* end if */ @@ -1986,29 +1966,9 @@ H5D_chunk_write(H5D_io_info_t *io_info, hsize_t nelmts, } #ifndef H5_MPI_COMPLEX_DERIVED_DATATYPE_WORKS else { - int is_regular; /* If this chunk's selections are regular */ - int mpi_code; /* MPI error code */ - int all_regular = 0; /* If this chunk's selections are regular on all processes */ - - /* Determine if this process has regular selections */ - if(H5S_SELECT_IS_REGULAR(chunk_info->fspace) == TRUE && - H5S_SELECT_IS_REGULAR(chunk_info->mspace) == TRUE) - is_regular = 1; - else - is_regular = 0; - - /* Determine if all processes have regular selections */ - if (MPI_SUCCESS != (mpi_code = MPI_Allreduce(&is_regular, &all_regular, 1, MPI_INT, MPI_LAND, io_info->comm))) - HMPI_GOTO_ERROR(FAIL, "MPI_Allreduce failed", mpi_code) - - /* For regular selection, - if MPI_COMPLEX_DERIVED_DATATYPE is not defined, - unless spaces for all processors are regular, independent read operation should be performed.*/ - if(!all_regular) { /* Switch to independent I/O (temporarily) */ make_ind = TRUE; make_coll = TRUE; - } /* end if */ } /* end else */ #endif /* H5_MPI_COMPLEX_DERIVED_DATATYPE_WORKS */ } /* end if */ |