diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2004-04-22 20:21:51 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2004-04-22 20:21:51 (GMT) |
commit | 253ee36580536cb1ebcc51876ee841538d0a83eb (patch) | |
tree | 808502fbc18eecba4c0db8eafcd95ddddd04e345 /src/H5Spkg.h | |
parent | 6010b691f953b8aeb167d694ff09b5b1f88b14b1 (diff) | |
download | hdf5-253ee36580536cb1ebcc51876ee841538d0a83eb.zip hdf5-253ee36580536cb1ebcc51876ee841538d0a83eb.tar.gz hdf5-253ee36580536cb1ebcc51876ee841538d0a83eb.tar.bz2 |
[svn-r8409] Purpose:
Code optimization
Description:
Instead of dynamicly allocating various arrays for various pieces of
information about a selection or selection iterator, just use fixed size
array of size H5S_MAX_RANK (as the rest of the library does).
Platforms tested:
Solaris 2.7 (arabica)
FreeBSD 4.9 (sleipnir)
h5committest
Diffstat (limited to 'src/H5Spkg.h')
-rw-r--r-- | src/H5Spkg.h | 19 |
1 files changed, 4 insertions, 15 deletions
diff --git a/src/H5Spkg.h b/src/H5Spkg.h index 5d73fa2..5ce7535 100644 --- a/src/H5Spkg.h +++ b/src/H5Spkg.h @@ -98,23 +98,12 @@ struct H5S_hyper_span_info_t { struct H5S_hyper_span_t *head; /* Pointer to list of spans in next dimension down */ }; -/* Information about one dimension in a hyperslab selection */ -struct H5S_hyper_dim_t { - hssize_t start; - hsize_t stride; - hsize_t count; - hsize_t block; -}; - /* Information about new-style hyperslab selection */ typedef struct { - H5S_hyper_dim_t *diminfo; /* ->[rank] of per-dim selection info */ - /* diminfo only points to one array, which holds the information - * for one hyperslab selection. Perhaps this might need to be - * expanded into a list of arrays when the H5Sselect_hyperslab's - * restriction to H5S_SELECT_SET is removed. */ - H5S_hyper_dim_t *app_diminfo;/* ->[rank] of per-dim selection info */ - /* 'diminfo' points to a [potentially] optimized version of the user's + hbool_t diminfo_valid; /* Whether the dataset has valid diminfo */ + H5S_hyper_dim_t opt_diminfo[H5S_MAX_RANK]; /* per-dim selection info */ + H5S_hyper_dim_t app_diminfo[H5S_MAX_RANK]; /* per-dim selection info */ + /* 'opt_diminfo' points to a [potentially] optimized version of the user's * hyperslab information. 'app_diminfo' points to the actual parameters * that the application used for setting the hyperslab selection. These * are only used for re-gurgitating the original values used to set the |