summaryrefslogtreecommitdiffstats
path: root/src/H5Sprivate.h
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2004-05-01 18:16:22 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2004-05-01 18:16:22 (GMT)
commit050ff9dc1a84b609709822a75f5337485396a9a0 (patch)
tree16c5b549a91323d224b59bd598deb4e41d76e53f /src/H5Sprivate.h
parent9850d9929774126b08ee7b4ecc50c9d25d20c122 (diff)
downloadhdf5-050ff9dc1a84b609709822a75f5337485396a9a0.zip
hdf5-050ff9dc1a84b609709822a75f5337485396a9a0.tar.gz
hdf5-050ff9dc1a84b609709822a75f5337485396a9a0.tar.bz2
[svn-r8459] Purpose:
Code optimization Description: Move the element size for the selection into the selection iterator instead of always passing it as a parameter. Also, eleminate another 64-bit multiply for "all" selections. Platforms tested: Solaris 2.7 (arabica) FreeBSD 4.9 (sleipnir) too minor to require h5committest
Diffstat (limited to 'src/H5Sprivate.h')
-rw-r--r--src/H5Sprivate.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/H5Sprivate.h b/src/H5Sprivate.h
index d350738..c3dc4e2 100644
--- a/src/H5Sprivate.h
+++ b/src/H5Sprivate.h
@@ -80,7 +80,8 @@ typedef struct {
/* "All" selection iteration container */
typedef struct {
- hsize_t offset; /* Next element to output */
+ hsize_t elmt_offset; /* Next element to output */
+ hsize_t byte_offset; /* Next byte to output */
} H5S_all_iter_t;
typedef struct H5S_sel_iter_t H5S_sel_iter_t;
@@ -106,6 +107,7 @@ struct H5S_sel_iter_t {
unsigned rank; /* Rank of dataspace the selection iterator is operating on */
hsize_t *dims; /* Dimensions of dataspace the selection is operating on */
hsize_t elmt_left; /* Number of elements left to iterate over */
+ size_t elmt_size; /* Size of elements to iterate over */
/* Information specific to each type of iterator */
union {
@@ -201,17 +203,17 @@ H5_DLL herr_t H5S_select_iterate(void *buf, hid_t type_id, const H5S_t *space,
H5_DLL herr_t H5S_select_fill(void *fill, size_t fill_size,
const H5S_t *space, void *buf);
H5_DLL herr_t H5S_select_fscat (H5F_t *f, struct H5O_layout_t *layout,
- const H5D_dcpl_cache_t *dcpl_cache, const union H5D_storage_t *store, size_t elmt_size,
+ const H5D_dcpl_cache_t *dcpl_cache, const union H5D_storage_t *store,
const H5S_t *file_space, H5S_sel_iter_t *file_iter, hsize_t nelmts,
const H5D_dxpl_cache_t *dxpl_cache, hid_t dxpl_id, const void *_buf);
H5_DLL hsize_t H5S_select_fgath (H5F_t *f, const struct H5O_layout_t *layout,
- const H5D_dcpl_cache_t *dcpl_cache, const union H5D_storage_t *store, size_t elmt_size,
+ const H5D_dcpl_cache_t *dcpl_cache, const union H5D_storage_t *store,
const H5S_t *file_space, H5S_sel_iter_t *file_iter, hsize_t nelmts,
const H5D_dxpl_cache_t *dxpl_cache, hid_t dxpl_id, void *buf);
-H5_DLL herr_t H5S_select_mscat (const void *_tscat_buf, size_t elmt_size,
+H5_DLL herr_t H5S_select_mscat (const void *_tscat_buf,
const H5S_t *space, H5S_sel_iter_t *iter, hsize_t nelmts,
const H5D_dxpl_cache_t *dxpl_cache, void *_buf/*out*/);
-H5_DLL hsize_t H5S_select_mgath (const void *_buf, size_t elmt_size,
+H5_DLL hsize_t H5S_select_mgath (const void *_buf,
const H5S_t *space, H5S_sel_iter_t *iter, hsize_t nelmts,
const H5D_dxpl_cache_t *dxpl_cache, void *_tgath_buf/*out*/);
H5_DLL herr_t H5S_select_read(H5F_t *f, const struct H5O_layout_t *layout,