diff options
author | Robb Matzke <matzke@llnl.gov> | 1998-09-30 18:50:49 (GMT) |
---|---|---|
committer | Robb Matzke <matzke@llnl.gov> | 1998-09-30 18:50:49 (GMT) |
commit | beab7f66e5dd260732fad34b9c26ccb0d8d580a5 (patch) | |
tree | d4513e30c4d6b722d466b295e6d009272e937d54 /src/H5Farray.c | |
parent | 8460a082a4e1fc9ea9be15cfb6bbdd866ebf9f4b (diff) | |
download | hdf5-beab7f66e5dd260732fad34b9c26ccb0d8d580a5.zip hdf5-beab7f66e5dd260732fad34b9c26ccb0d8d580a5.tar.gz hdf5-beab7f66e5dd260732fad34b9c26ccb0d8d580a5.tar.bz2 |
[svn-r730] Changes since 19980928
----------------------
./MANIFEST
Changed freebsd2.2.1 to freebsd2.2.7 to match change in file name.
Added a few missing files. Are all of these supposed to be
distributed?
./tools/testfiles/h5dumptst.c
+ ./tools/testfiles/tall-1.ddl
+ ./tools/testfiles/tall-2.ddl
+ ./tools/testfiles/tall-3.ddl
./tools/testfiles/tall.ddl
./tools/testfiles/tall.h5
+ ./tools/testfiles/tattr-1.ddl
+ ./tools/testfiles/tattr-2.ddl
+ ./tools/testfiles/tattr-3.ddl
+ ./tools/testfiles/tattr-4.ddl
./tools/testfiles/tattr.ddl
./tools/testfiles/tattr.h5
+ ./tools/testfiles/tdset-1.ddl
+ ./tools/testfiles/tdset-2.ddl
+ ./tools/testfiles/tdset-3.ddl
+ ./tools/testfiles/tdset-4.ddl
./tools/testfiles/tdset.ddl
./tools/testfiles/tdset.h5
+ ./tools/testfiles/tgroup-1.ddl
+ ./tools/testfiles/tgroup-2.ddl
+ ./tools/testfiles/tgroup-3.ddl
./tools/testfiles/tgroup.ddl
./tools/testfiles/tgroup.h5
+ ./tools/testfiles/tslink-1.ddl
+ ./tools/testfiles/tslink-2.ddl
./tools/testfiles/tslink.ddl
./tools/testfiles/tslink.h5
./src/H5B.c
./src/H5Bprivate.h
./src/H5D.c
./src/H5Dprivate.h
./src/H5Farray.c
./src/H5Fistore.c
./src/H5Fprivate.h
./src/H5Gstab.c
./src/H5P.c
./src/H5Ppublic.h
./src/H5Sall.c
./src/H5Shyper.c
./src/H5Spoint.c
./src/H5Sprivate.h
./test/istore.c
Implemented split ratios as documented in previous
e-mails. Frank, the new API functions are H5Pget_btree_ratios()
and H5Pset_btree_ratios().
./src/H5Sall.c
./src/H5Shyper.c
./src/H5Spoint.c
./src/H5Sprivate.h
Added more type checking for the data transfer property list
passed to these functions.
./src/H5D.c
Added a dataset transfer property list as an argument to
H5D_allocate() for the parallel version in order to pass split
ratios down to H5F_istore_lock(). Eventually we won't need
the split ratios for H5D_allocate() because we'll build a
completely full B-tree from the leaves up, but it might be
useful to have other transfer properties at that level
anyway. I always caled H5D_allocate() with &H5D_dflt_xfer.
./MANIFEST
./test/Makefile.in
./test/overhead.c [NEW]
Added an `overhead' test run by `make timings'.
Diffstat (limited to 'src/H5Farray.c')
-rw-r--r-- | src/H5Farray.c | 88 |
1 files changed, 53 insertions, 35 deletions
diff --git a/src/H5Farray.c b/src/H5Farray.c index 27ec922..b3ebcff 100644 --- a/src/H5Farray.c +++ b/src/H5Farray.c @@ -110,14 +110,19 @@ H5F_arr_create (H5F_t *f, struct H5O_layout_t *layout/*in,out*/) * June 2, 1998 Albert Cheng * Added xfer_mode argument * + * Sep 28, 1998 Robb Matzke + * Added the `xfer' argument and removed the `xfer_mode' + * argument since it's a field of `xfer'. + * *------------------------------------------------------------------------- */ herr_t -H5F_arr_read (H5F_t *f, const struct H5O_layout_t *layout, +H5F_arr_read (H5F_t *f, const H5D_xfer_t *xfer, + const struct H5O_layout_t *layout, const struct H5O_pline_t *pline, const struct H5O_efl_t *efl, const hsize_t _hslab_size[], const hsize_t mem_size[], const hssize_t mem_offset[], const hssize_t file_offset[], - const H5D_transfer_t xfer_mode, void *_buf/*out*/) + void *_buf/*out*/) { uint8 *buf = (uint8 *)_buf; /*cast for arithmetic */ hssize_t file_stride[H5O_LAYOUT_NDIMS]; /*strides through file */ @@ -148,7 +153,7 @@ H5F_arr_read (H5F_t *f, const struct H5O_layout_t *layout, H5V_vector_cpy (layout->ndims, hslab_size, _hslab_size); #ifdef HAVE_PARALLEL - if (xfer_mode==H5D_XFER_COLLECTIVE){ + if (xfer->xfer_mode==H5D_XFER_COLLECTIVE){ if (layout->type != H5D_CONTIGUOUS) HRETURN_ERROR (H5E_DATASET, H5E_READERROR, FAIL, "collective access on non-contiguous datasets not " @@ -222,7 +227,7 @@ H5F_arr_read (H5F_t *f, const struct H5O_layout_t *layout, * memory. */ #ifdef HAVE_PARALLEL - if (xfer_mode==H5D_XFER_COLLECTIVE){ + if (xfer->xfer_mode==H5D_XFER_COLLECTIVE){ /* Currently supports same number of collective access. * Need to be changed LATER to combine all reads into one * collective MPIO call. @@ -253,7 +258,8 @@ H5F_arr_read (H5F_t *f, const struct H5O_layout_t *layout, HRETURN_ERROR (H5E_IO, H5E_READERROR, FAIL, "external data read failed"); } - } else if (H5F_block_read (f, &addr, elmt_size, xfer_mode, buf)<0) { + } else if (H5F_block_read (f, &addr, elmt_size, xfer->xfer_mode, + buf)<0) { HRETURN_ERROR (H5E_IO, H5E_READERROR, FAIL, "block read failed"); } @@ -286,7 +292,7 @@ H5F_arr_read (H5F_t *f, const struct H5O_layout_t *layout, "unable to copy into a proper hyperslab"); } } - if (H5F_istore_read (f, layout, pline, file_offset, hslab_size, + if (H5F_istore_read (f, xfer, layout, pline, file_offset, hslab_size, buf)<0) { HRETURN_ERROR (H5E_IO, H5E_READERROR, FAIL, "chunked read failed"); } @@ -328,15 +334,19 @@ H5F_arr_read (H5F_t *f, const struct H5O_layout_t *layout, * June 2, 1998 Albert Cheng * Added xfer_mode argument * + * Sep 28, 1998 Robb Matzke + * Added `xfer' argument, removed `xfer_mode' argument since it + * is a member of H5D_xfer_t. + * *------------------------------------------------------------------------- */ herr_t -H5F_arr_write (H5F_t *f, const struct H5O_layout_t *layout, +H5F_arr_write (H5F_t *f, const H5D_xfer_t *xfer, + const struct H5O_layout_t *layout, const struct H5O_pline_t *pline, const struct H5O_efl_t *efl, const hsize_t _hslab_size[], const hsize_t mem_size[], const hssize_t mem_offset[], - const hssize_t file_offset[], const H5D_transfer_t xfer_mode, - const void *_buf) + const hssize_t file_offset[], const void *_buf) { const uint8 *buf = (const uint8 *)_buf; /*cast for arithmetic */ hssize_t file_stride[H5O_LAYOUT_NDIMS]; /*strides through file */ @@ -355,35 +365,40 @@ H5F_arr_write (H5F_t *f, const struct H5O_layout_t *layout, FUNC_ENTER (H5F_arr_write, FAIL); /* Check args */ - assert (f); - assert (layout); - assert (_hslab_size); - assert (file_offset); - assert (mem_offset); - assert (mem_size); - assert (buf); + assert(f); + assert(layout); + assert(_hslab_size); + assert(file_offset); + assert(mem_offset); + assert(mem_size); + assert(buf); /* Make a local copy of _size so we can modify it */ H5V_vector_cpy (layout->ndims, hslab_size, _hslab_size); #ifdef HAVE_PARALLEL - if (xfer_mode==H5D_XFER_COLLECTIVE){ - if (layout->type != H5D_CONTIGUOUS) + if (xfer->xfer_mode==H5D_XFER_COLLECTIVE) { + if (layout->type != H5D_CONTIGUOUS) { HRETURN_ERROR (H5E_DATASET, H5E_WRITEERROR, FAIL, - "collective access on non-contiguous datasets not supported yet"); + "collective access on non-contiguous datasets not " + "supported yet"); + } } #endif #ifdef QAK -{ - extern int qak_debug; - - printf("%s: layout->ndims=%d\n",FUNC,(int)layout->ndims); - for(i=0; i<layout->ndims; i++) - printf("%s: %d: hslab_size=%d, mem_size=%d, mem_offset=%d, file_offset=%d\n",FUNC,i,(int)_hslab_size[i],(int)mem_size[i],(int)mem_offset[i],(int)file_offset[i]); - if(qak_debug) { - printf("%s: *buf=%d, *(buf+1)=%d\n", FUNC,(int)*(const uint16 *)buf,(int)*((const uint16 *)buf+1)); + { + extern int qak_debug; + + printf("%s: layout->ndims=%d\n",FUNC,(int)layout->ndims); + for(i=0; i<layout->ndims; i++) + printf("%s: %d: hslab_size=%d, mem_size=%d, mem_offset=%d, " + "file_offset=%d\n", FUNC, i, (int)_hslab_size[i], + (int)mem_size[i],(int)mem_offset[i],(int)file_offset[i]); + if(qak_debug) { + printf("%s: *buf=%d, *(buf+1)=%d\n", FUNC, + (int)*(const uint16 *)buf, (int)*((const uint16 *)buf+1)); + } } -} #endif /* QAK */ switch (layout->type) { @@ -440,7 +455,7 @@ H5F_arr_write (H5F_t *f, const struct H5O_layout_t *layout, * disk. */ #ifdef HAVE_PARALLEL - if (xfer_mode==H5D_XFER_COLLECTIVE){ + if (xfer->xfer_mode==H5D_XFER_COLLECTIVE){ /* Currently supports same number of collective access. * Need to be changed LATER to combine all writes into one * collective MPIO call. @@ -454,11 +469,13 @@ H5F_arr_write (H5F_t *f, const struct H5O_layout_t *layout, MPI_Allreduce(&temp, &min, 1, MPI_UNSIGNED_LONG, MPI_MIN, f->shared->access_parms->u.mpio.comm); #ifdef AKC -printf("nelmts=%lu, min=%lu, max=%lu\n", temp, min, max); + printf("nelmts=%lu, min=%lu, max=%lu\n", temp, min, max); #endif - if (max != min) + if (max != min) { HRETURN_ERROR(H5E_DATASET, H5E_WRITEERROR, FAIL, - "collective access with unequal number of blocks not supported yet"); + "collective access with unequal number of " + "blocks not supported yet"); + } } #endif @@ -470,7 +487,8 @@ printf("nelmts=%lu, min=%lu, max=%lu\n", temp, min, max); HRETURN_ERROR (H5E_IO, H5E_READERROR, FAIL, "external data write failed"); } - } else if (H5F_block_write (f, &addr, elmt_size, xfer_mode, buf)<0) { + } else if (H5F_block_write(f, &addr, elmt_size, xfer->xfer_mode, + buf)<0) { HRETURN_ERROR (H5E_IO, H5E_WRITEERROR, FAIL, "block write failed"); } @@ -490,7 +508,7 @@ printf("nelmts=%lu, min=%lu, max=%lu\n", temp, min, max); case H5D_CHUNKED: /* - * This method is unable to access external raw daa files or to copy + * This method is unable to access external raw data files or to copy * from a proper hyperslab. */ if (efl && efl->nused>0) { @@ -504,7 +522,7 @@ printf("nelmts=%lu, min=%lu, max=%lu\n", temp, min, max); "unable to copy from a proper hyperslab"); } } - if (H5F_istore_write (f, layout, pline, file_offset, hslab_size, + if (H5F_istore_write (f, xfer, layout, pline, file_offset, hslab_size, buf)<0) { HRETURN_ERROR (H5E_IO, H5E_WRITEERROR, FAIL, "chunked write failed"); |