summaryrefslogtreecommitdiffstats
path: root/src/H5Distore.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2004-10-04 20:29:41 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2004-10-04 20:29:41 (GMT)
commit6d3c07598c93db261fabf9523cfd8ad16585be1c (patch)
tree5478eb7a1d14f68a41e9c185d181ca36bec6c32f /src/H5Distore.c
parentc719c2d3b876a3ac6f0aec7d776d5aaebf5e1fef (diff)
downloadhdf5-6d3c07598c93db261fabf9523cfd8ad16585be1c.zip
hdf5-6d3c07598c93db261fabf9523cfd8ad16585be1c.tar.gz
hdf5-6d3c07598c93db261fabf9523cfd8ad16585be1c.tar.bz2
[svn-r9359] Purpose:
Bug fix Description: Relax restrictions on parallel I/O to allow compressed, chunked datasets to be read in parallel (collective access will be degraded to independent access, but will retrieve the information still). Platforms tested: FreeBSD 4.10 (sleipnir) w/parallel Solaris 2.7 (arabica) IRIX64 6.5 (modi4) h5committest
Diffstat (limited to 'src/H5Distore.c')
-rw-r--r--src/H5Distore.c28
1 files changed, 13 insertions, 15 deletions
diff --git a/src/H5Distore.c b/src/H5Distore.c
index 9d991d3..3673cad 100644
--- a/src/H5Distore.c
+++ b/src/H5Distore.c
@@ -1922,17 +1922,11 @@ HDfprintf(stderr,"%s: buf=%p\n",FUNC,buf);
* writing to other elements in the same chunk. Do a direct
* read-through of only the elements requested.
*/
- if ((dset->shared->layout.u.chunk.size>dset->shared->cache.chunk.nbytes && dset->shared->dcpl_cache.pline.nused==0 && chunk_addr!=HADDR_UNDEF)
- || (IS_H5FD_MPI(dset->ent.file) && (H5F_ACC_RDWR & H5F_get_intent(dset->ent.file)))) {
+ if (dset->shared->dcpl_cache.pline.nused==0 && ((dset->shared->layout.u.chunk.size>dset->shared->cache.chunk.nbytes && chunk_addr!=HADDR_UNDEF)
+ || (IS_H5FD_MPI(dset->ent.file) && (H5F_ACC_RDWR & H5F_get_intent(dset->ent.file))))) {
H5D_io_info_t chk_io_info; /* Temporary I/O info object */
H5D_storage_t chk_store; /* Chunk storage information */
-#ifdef H5_HAVE_PARALLEL
- /* Additional sanity check when operating in parallel */
- if (chunk_addr==HADDR_UNDEF || dset->shared->dcpl_cache.pline.nused>0)
- HGOTO_ERROR (H5E_IO, H5E_WRITEERROR, FAIL, "unable to locate raw data chunk");
-#endif /* H5_HAVE_PARALLEL */
-
/* Set up the storage information for the chunk */
chk_store.contig.dset_addr=chunk_addr;
chk_store.contig.dset_size=(hsize_t)dset->shared->layout.u.chunk.size;
@@ -2125,17 +2119,21 @@ HDfprintf(stderr,"%s: mem_offset_arr[%Zu]=%Hu\n",FUNC,*mem_curr_seq,mem_offset_a
* writing to other elements in the same chunk. Do a direct
* write-through of only the elements requested.
*/
- if ((dset->shared->layout.u.chunk.size>dset->shared->cache.chunk.nbytes && dset->shared->dcpl_cache.pline.nused==0 && chunk_addr!=HADDR_UNDEF)
- || (IS_H5FD_MPI(dset->ent.file) && (H5F_ACC_RDWR & H5F_get_intent(dset->ent.file)))) {
- H5D_io_info_t chk_io_info; /* Temporary I/O info object */
- H5D_storage_t chk_store; /* Chunk storage information */
-
#ifdef H5_HAVE_PARALLEL
- /* Additional sanity check when operating in parallel */
- if (chunk_addr==HADDR_UNDEF || dset->shared->dcpl_cache.pline.nused>0)
+ /* Additional sanity checks when operating in parallel */
+ if(IS_H5FD_MPI(dset->ent.file)) {
+ if (chunk_addr==HADDR_UNDEF)
HGOTO_ERROR (H5E_IO, H5E_WRITEERROR, FAIL, "unable to locate raw data chunk");
+ if (dset->shared->dcpl_cache.pline.nused>0)
+ HGOTO_ERROR (H5E_IO, H5E_WRITEERROR, FAIL, "cannot write to chunked storage with filters in parallel");
+ } /* end if */
#endif /* H5_HAVE_PARALLEL */
+ if (dset->shared->dcpl_cache.pline.nused==0 && ((dset->shared->layout.u.chunk.size>dset->shared->cache.chunk.nbytes && chunk_addr!=HADDR_UNDEF)
+ || (IS_H5FD_MPI(dset->ent.file) && (H5F_ACC_RDWR & H5F_get_intent(dset->ent.file))))) {
+ H5D_io_info_t chk_io_info; /* Temporary I/O info object */
+ H5D_storage_t chk_store; /* Chunk storage information */
+
/* Set up the storage information for the chunk */
chk_store.contig.dset_addr=chunk_addr;
chk_store.contig.dset_size=(hsize_t)dset->shared->layout.u.chunk.size;