summaryrefslogtreecommitdiffstats
path: root/src/H5Shyper.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2002-04-03 17:07:14 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2002-04-03 17:07:14 (GMT)
commit7ae00db7a4a4e8330245b15aa1e2fa1659cb9b1b (patch)
treea01c9d03f52334938852b8f509bbe6bc8bcdac36 /src/H5Shyper.c
parentad641fa7b617c8ca2ec11602cde0f72fa12696cd (diff)
downloadhdf5-7ae00db7a4a4e8330245b15aa1e2fa1659cb9b1b.zip
hdf5-7ae00db7a4a4e8330245b15aa1e2fa1659cb9b1b.tar.gz
hdf5-7ae00db7a4a4e8330245b15aa1e2fa1659cb9b1b.tar.bz2
[svn-r5138] Purpose:
Bug Fix & Code Cleanup Description: The MPI-IO optimized transfer routines (H5S_mpio_spaces_read/H5S_mpio_space_write) are not being invoked in all the cases where they could be used. Additionally, the code for determining if an optimized transfer is wrapped into the actual I/O transfer routine in a very confusing way. Solution: Re-enabled MPI-IO optimized transfer routines in all the cases where they should work. Extracted all the pre-conditions for optimized transfers into separate routines from the transfer routines. Platforms tested: FreeBSD 4.5 (sleipnir) & IRIX64 6.5 (modi4)
Diffstat (limited to 'src/H5Shyper.c')
-rw-r--r--src/H5Shyper.c43
1 files changed, 42 insertions, 1 deletions
diff --git a/src/H5Shyper.c b/src/H5Shyper.c
index 487de1b..4c1f3f5 100644
--- a/src/H5Shyper.c
+++ b/src/H5Shyper.c
@@ -5963,7 +5963,7 @@ H5S_hyper_select_single(const H5S_t *space)
assert(space);
- /* Check for a "regular" hyperslab selection */
+ /* Check for a "single" hyperslab selection */
if(space->select.sel_info.hslab.diminfo != NULL) {
/*
* For a regular hyperslab to be single, it must have only one
@@ -6013,6 +6013,47 @@ H5S_hyper_select_single(const H5S_t *space)
/*--------------------------------------------------------------------------
NAME
+ H5S_hyper_select_regular
+ PURPOSE
+ Check if a hyperslab selection is "regular"
+ USAGE
+ htri_t H5S_hyper_select_regular(space)
+ const H5S_t *space; IN: Dataspace pointer to check
+ RETURNS
+ TRUE/FALSE/FAIL
+ DESCRIPTION
+ Checks to see if the current selection in a dataspace is the a regular
+ pattern.
+ This is primarily used for reading the entire selection in one swoop.
+ GLOBAL VARIABLES
+ COMMENTS, BUGS, ASSUMPTIONS
+ Doesn't check for "regular" hyperslab selections composed of spans
+ EXAMPLES
+ REVISION LOG
+--------------------------------------------------------------------------*/
+htri_t
+H5S_hyper_select_regular(const H5S_t *space)
+{
+ htri_t ret_value=FAIL; /* return value */
+
+ FUNC_ENTER (H5S_hyper_select_regular, FAIL);
+
+ /* Check args */
+ assert(space);
+
+ /* Only simple check for regular hyperslabs for now... */
+ if(space->select.sel_info.hslab.diminfo != NULL)
+ ret_value=TRUE;
+ else
+ ret_value=FALSE;
+
+done:
+ FUNC_LEAVE (ret_value);
+} /* H5S_hyper_select_regular() */
+
+
+/*--------------------------------------------------------------------------
+ NAME
H5S_hyper_select_iterate_helper
PURPOSE
Internal routine to iterate over the elements of a span tree hyperslab selection