diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2004-05-08 19:09:50 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2004-05-08 19:09:50 (GMT) |
commit | 0f805b3aa507d557fbab6cc8ccec81b50daf6dd8 (patch) | |
tree | 10f5d92e41a140dd11711f7af0d845079601e87d /src/H5Sselect.c | |
parent | 583bdf994cb40b4568a09657a0961392660ebdff (diff) | |
download | hdf5-0f805b3aa507d557fbab6cc8ccec81b50daf6dd8.zip hdf5-0f805b3aa507d557fbab6cc8ccec81b50daf6dd8.tar.gz hdf5-0f805b3aa507d557fbab6cc8ccec81b50daf6dd8.tar.bz2 |
[svn-r8496] Purpose:
Code optimization
Description:
Further reduce the number of copies we make of a hyperslab selection for
chunked I/O, especially when we are only going to throw the old selection away
for a new one.
Platforms tested:
Solaris 2.7 (arabica)
FreeBSD 4.9 (sleipnir) w/parallel
Diffstat (limited to 'src/H5Sselect.c')
-rw-r--r-- | src/H5Sselect.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/H5Sselect.c b/src/H5Sselect.c index d232cdf..1e79410 100644 --- a/src/H5Sselect.c +++ b/src/H5Sselect.c @@ -113,13 +113,18 @@ done: DESCRIPTION Copies all the selection information (include offset) from the source dataspace to the destination dataspace. + + If the SHARE_SELECTION flag is set, then the selection can be shared + between the source and destination dataspaces. (This should only occur in + situations where the destination dataspace will immediately change to a new + selection) GLOBAL VARIABLES COMMENTS, BUGS, ASSUMPTIONS EXAMPLES REVISION LOG --------------------------------------------------------------------------*/ herr_t -H5S_select_copy (H5S_t *dst, const H5S_t *src) +H5S_select_copy (H5S_t *dst, const H5S_t *src, hbool_t share_selection) { herr_t ret_value=SUCCEED; /* return value */ @@ -132,7 +137,7 @@ H5S_select_copy (H5S_t *dst, const H5S_t *src) /* Copy regular fields */ HDmemcpy(&dst->select,&src->select,sizeof(H5S_select_t)); -/* Need to copy order information still */ +/* Need to copy permutation order information still */ /* Copy offset information */ if(src->extent.u.simple.rank>0) { @@ -166,7 +171,7 @@ H5S_select_copy (H5S_t *dst, const H5S_t *src) break; case H5S_SEL_HYPERSLABS: - ret_value=H5S_hyper_copy(dst,src); + ret_value=H5S_hyper_copy(dst,src,share_selection); break; default: |