diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2007-12-10 21:38:03 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2007-12-10 21:38:03 (GMT) |
commit | 66addd2d2c56c31137b2e50f66134e66c0bb746d (patch) | |
tree | af0a17a8fc8a632bb13358463544e21ef503c2b5 /src/H5Dint.c | |
parent | e7d0100948c274dc8d77b6aaabb8f157340db61d (diff) | |
download | hdf5-66addd2d2c56c31137b2e50f66134e66c0bb746d.zip hdf5-66addd2d2c56c31137b2e50f66134e66c0bb746d.tar.gz hdf5-66addd2d2c56c31137b2e50f66134e66c0bb746d.tar.bz2 |
[svn-r14334] Description:
- Avoid trying to update 1-D dataset's chunk indices (they can't change)
- Cache a copy of a dataspace describing a chunk, when doing single
element I/O
- Keep a 'chunk info' struct around, for single element I/O
- Avoid creating a skip list for chunk infos when performing I/O on single
element
Also, minor formatting cleanups to testing code
Tested on:
FreeBSD/32 6.2 (duty) in debug mode
FreeBSD/64 6.2 (liberty) w/C++ & FORTRAN, in debug mode
Linux/32 2.6 (kagiso) w/PGI compilers, w/C++ & FORTRAN, w/threadsafe,
in debug mode
Linux/64-amd64 2.6 (smirom) w/default API=1.6.x, w/C++ & FORTRAN,
in production mode
Linux/64-ia64 2.6 (cobalt) w/Intel compilers, w/C++ & FORTRAN,
in production mode
Solaris/32 2.10 (linew) w/deprecated symbols disabled, w/C++ & FORTRAN,
w/szip filter, in production mode
Mac OS X/32 10.4.10 (amazon) in debug mode
Linux/64-ia64 2.4 (tg-login3) w/parallel, w/FORTRAN, in production mode
Diffstat (limited to 'src/H5Dint.c')
-rw-r--r-- | src/H5Dint.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/H5Dint.c b/src/H5Dint.c index d344d41..4ee6c19 100644 --- a/src/H5Dint.c +++ b/src/H5Dint.c @@ -98,6 +98,9 @@ H5FL_DEFINE_STATIC(H5D_shared_t); /* Declare the external PQ free list for the sieve buffer information */ H5FL_BLK_EXTERN(sieve_buf); +/* Declare the external free list to manage the H5D_chunk_info_t struct */ +H5FL_EXTERN(H5D_chunk_info_t); + /* Define a static "default" dataset structure to use to initialize new datasets */ static H5D_shared_t H5D_def_dset; @@ -1517,6 +1520,18 @@ H5D_close(H5D_t *dataset) dataset->shared->cache.chunk.sel_chunks = NULL; } /* end if */ + /* Check for cached single chunk dataspace */ + if(dataset->shared->cache.chunk.single_space) { + (void)H5S_close(dataset->shared->cache.chunk.single_space); + dataset->shared->cache.chunk.single_space = NULL; + } /* end if */ + + /* Check for cached single element chunk info */ + if(dataset->shared->cache.chunk.single_chunk_info) { + (void)H5FL_FREE(H5D_chunk_info_t, dataset->shared->cache.chunk.single_chunk_info); + dataset->shared->cache.chunk.single_chunk_info = NULL; + } /* end if */ + /* Flush and destroy chunks in the cache */ if(H5D_istore_dest(dataset, H5AC_dxpl_id) < 0) HGOTO_ERROR(H5E_DATASET, H5E_CANTRELEASE, FAIL, "unable to destroy chunk cache") |