summaryrefslogtreecommitdiffstats
path: root/src/H5Sprivate.h
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2001-11-02 20:31:35 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2001-11-02 20:31:35 (GMT)
commit1cd9eb7e0d282aaf5161af220aae00cc7f7e31f9 (patch)
tree90c364175d9336948f7f98ec7c632494af48edb3 /src/H5Sprivate.h
parente9d955be61f79ceddd6be3d279f723d8e9153b9b (diff)
downloadhdf5-1cd9eb7e0d282aaf5161af220aae00cc7f7e31f9.zip
hdf5-1cd9eb7e0d282aaf5161af220aae00cc7f7e31f9.tar.gz
hdf5-1cd9eb7e0d282aaf5161af220aae00cc7f7e31f9.tar.bz2
[svn-r4586] Purpose:
Code speedups, etc. Description: Bring in new algorithms and data structures for dealing with hyperslabs. This speeds up the hyperslab I/O for non-regular hyperslabs by a huge amount. Currently, the new API functions are ifdef'ed out, pending discussion and consensus approval. Platforms tested: FreeBSD 4.4 (hawkwind)
Diffstat (limited to 'src/H5Sprivate.h')
-rw-r--r--src/H5Sprivate.h30
1 files changed, 15 insertions, 15 deletions
diff --git a/src/H5Sprivate.h b/src/H5Sprivate.h
index 11eb054..594e8bf 100644
--- a/src/H5Sprivate.h
+++ b/src/H5Sprivate.h
@@ -33,15 +33,17 @@
/* Forward references of common typedefs */
typedef struct H5S_t H5S_t;
typedef struct H5S_pnt_node_t H5S_pnt_node_t;
+typedef struct H5S_hyper_span_t H5S_hyper_span_t;
+typedef struct H5S_hyper_span_info_t H5S_hyper_span_info_t;
/* Enumerated type for the type of selection */
typedef enum {
- H5S_SEL_ERROR = -1, /* Error */
- H5S_SEL_NONE = 0, /* Nothing selected */
- H5S_SEL_POINTS = 1, /* Sequence of points selected */
- H5S_SEL_HYPERSLABS = 2, /* Hyperslab selection defined */
- H5S_SEL_ALL = 3, /* Entire extent selected */
- H5S_SEL_N = 4 /*THIS MUST BE LAST */
+ H5S_SEL_ERROR = -1, /* Error */
+ H5S_SEL_NONE = 0, /* Nothing selected */
+ H5S_SEL_POINTS = 1, /* Sequence of points selected */
+ H5S_SEL_HYPERSLABS = 2, /* "New-style" hyperslab selection defined */
+ H5S_SEL_ALL = 3, /* Entire extent selected */
+ H5S_SEL_N = 4 /*THIS MUST BE LAST */
}H5S_sel_type;
/* Point selection iteration container */
@@ -50,9 +52,12 @@ typedef struct {
H5S_pnt_node_t *curr; /* Pointer to next node to output */
} H5S_point_iter_t;
-/* Hyperslab selection iteration container */
+/* New Hyperslab selection iteration container */
typedef struct {
hsize_t elmt_left; /* Number of elements left to iterate over */
+ H5S_hyper_span_info_t *spans; /* Pointer to copy of the span tree */
+ H5S_hyper_span_t **span; /* Array of pointers to span nodes */
+ hssize_t *off; /* Offset in span node */
hssize_t *pos; /* Position to start iterating at */
} H5S_hyper_iter_t;
@@ -65,7 +70,7 @@ typedef struct {
/* Selection iteration container */
typedef union {
H5S_point_iter_t pnt; /* Point selection iteration information */
- H5S_hyper_iter_t hyp; /* Hyperslab selection iteration information */
+ H5S_hyper_iter_t hyp; /* New Hyperslab selection iteration information */
H5S_all_iter_t all; /* "All" selection iteration information */
} H5S_sel_iter_t;
@@ -81,7 +86,7 @@ typedef struct H5S_fconv_t {
H5S_sel_type type;
/* Initialize file element numbering information */
- herr_t (*init)(const H5S_t *space, H5S_sel_iter_t *iter);
+ herr_t (*init)(const H5S_t *space, size_t elmt_size, H5S_sel_iter_t *iter);
/* Determine optimal number of elements to transfer */
hsize_t (*avail)(const H5S_t *file_space, const H5S_sel_iter_t *file_iter,
@@ -110,7 +115,7 @@ typedef struct H5S_mconv_t {
H5S_sel_type type;
/* Initialize memory element numbering information */
- herr_t (*init)(const H5S_t *space, H5S_sel_iter_t *iter);
+ herr_t (*init)(const H5S_t *space, size_t elmt_size, H5S_sel_iter_t *iter);
/* Gather elements from app buffer to type conversion buffer */
hsize_t (*gath)(const void *buf, size_t elmt_size,
@@ -207,11 +212,6 @@ __DLL__ H5S_t *H5S_read(struct H5G_entry_t *ent);
__DLL__ int H5S_cmp(const H5S_t *ds1, const H5S_t *ds2);
__DLL__ htri_t H5S_is_simple(const H5S_t *sdim);
__DLL__ unsigned H5S_nelem(const H5S_t *space);
-__DLL__ herr_t H5S_select_hyperslab(H5S_t *space, H5S_seloper_t op,
- const hssize_t start[],
- const hsize_t _stride[],
- const hsize_t count[],
- const hsize_t _block[]);
__DLL__ int H5S_get_hyperslab(const H5S_t *ds, hssize_t offset[]/*out*/,
hsize_t size[]/*out*/, hsize_t stride[]/*out*/);
__DLL__ herr_t H5S_select_copy(H5S_t *dst, const H5S_t *src);