summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDana Robinson <derobins@hdfgroup.org>2015-12-14 18:31:53 (GMT)
committerDana Robinson <derobins@hdfgroup.org>2015-12-14 18:31:53 (GMT)
commitddd91a7b1932d7efebcaba60d13beb5f237fc95d (patch)
tree2b95202682e74585ce29c646415643b5b91c1ada /src
parent322816c9666cf1010361bcf827f0d61183c3d904 (diff)
downloadhdf5-ddd91a7b1932d7efebcaba60d13beb5f237fc95d.zip
hdf5-ddd91a7b1932d7efebcaba60d13beb5f237fc95d.tar.gz
hdf5-ddd91a7b1932d7efebcaba60d13beb5f237fc95d.tar.bz2
[svn-r28643] Add H5D_t pointer to chunk callback.
Normalization for future single chunk indexing. Tested on: Ubuntu 15.10 (Linux 4.2.0 x86_64) gcc 5.2.1 serial only (these changes have been in revise_chunks for a long time)
Diffstat (limited to 'src')
-rw-r--r--src/H5Dbtree.c5
-rw-r--r--src/H5Dchunk.c10
-rw-r--r--src/H5Dpkg.h2
3 files changed, 9 insertions, 8 deletions
diff --git a/src/H5Dbtree.c b/src/H5Dbtree.c
index 30c3a28..e50a7ee 100644
--- a/src/H5Dbtree.c
+++ b/src/H5Dbtree.c
@@ -127,7 +127,7 @@ static herr_t H5D__btree_idx_init(const H5D_chk_idx_info_t *idx_info,
static herr_t H5D__btree_idx_create(const H5D_chk_idx_info_t *idx_info);
static hbool_t H5D__btree_idx_is_space_alloc(const H5O_storage_chunk_t *storage);
static herr_t H5D__btree_idx_insert(const H5D_chk_idx_info_t *idx_info,
- H5D_chunk_ud_t *udata);
+ H5D_chunk_ud_t *udata, const H5D_t *dset);
static herr_t H5D__btree_idx_get_addr(const H5D_chk_idx_info_t *idx_info,
H5D_chunk_ud_t *udata);
static int H5D__btree_idx_iterate(const H5D_chk_idx_info_t *idx_info,
@@ -991,7 +991,8 @@ H5D__btree_idx_is_space_alloc(const H5O_storage_chunk_t *storage)
*-------------------------------------------------------------------------
*/
static herr_t
-H5D__btree_idx_insert(const H5D_chk_idx_info_t *idx_info, H5D_chunk_ud_t *udata)
+H5D__btree_idx_insert(const H5D_chk_idx_info_t *idx_info, H5D_chunk_ud_t *udata,
+ const H5D_t H5_ATTR_UNUSED *dset)
{
herr_t ret_value = SUCCEED; /* Return value */
diff --git a/src/H5Dchunk.c b/src/H5Dchunk.c
index 4b33ebd..4ad6156 100644
--- a/src/H5Dchunk.c
+++ b/src/H5Dchunk.c
@@ -408,7 +408,7 @@ H5D__chunk_direct_write(const H5D_t *dset, hid_t dxpl_id, uint32_t filters,
/* Set the chunk's filter mask to the new settings */
udata.filter_mask = filters;
- if((layout->storage.u.chunk.ops->insert)(&idx_info, &udata) < 0)
+ if((layout->storage.u.chunk.ops->insert)(&idx_info, &udata, NULL) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTINSERT, FAIL, "unable to insert chunk addr into index")
} /* end if */
@@ -2090,7 +2090,7 @@ H5D__chunk_write(H5D_io_info_t *io_info, const H5D_type_info_t *type_info,
} /* end if */
else {
if(need_insert && io_info->dset->shared->layout.storage.u.chunk.ops->insert)
- if((io_info->dset->shared->layout.storage.u.chunk.ops->insert)(&idx_info, &udata) < 0)
+ if((io_info->dset->shared->layout.storage.u.chunk.ops->insert)(&idx_info, &udata, NULL) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTINSERT, FAIL, "unable to insert chunk addr into index")
} /* end else */
@@ -2714,7 +2714,7 @@ H5D__chunk_flush_entry(const H5D_t *dset, hid_t dxpl_id, const H5D_dxpl_cache_t
/* Insert the chunk record into the index */
if(need_insert && dset->shared->layout.storage.u.chunk.ops->insert)
- if((dset->shared->layout.storage.u.chunk.ops->insert)(&idx_info, &udata) < 0)
+ if((dset->shared->layout.storage.u.chunk.ops->insert)(&idx_info, &udata, dset) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTINSERT, FAIL, "unable to insert chunk addr into index")
/* Cache the chunk's info, in case it's accessed again shortly */
@@ -3690,7 +3690,7 @@ H5D__chunk_allocate(const H5D_t *dset, hid_t dxpl_id, hbool_t full_overwrite,
* serial operation. -QAK
*/
if(need_insert && ops->insert)
- if((ops->insert)(&idx_info, &udata) < 0)
+ if((ops->insert)(&idx_info, &udata, dset) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTINSERT, FAIL, "unable to insert chunk addr into index")
/* Increment indices and adjust the edge chunk state */
@@ -4822,7 +4822,7 @@ H5D__chunk_copy_cb(const H5D_chunk_rec_t *chunk_rec, void *_udata)
/* Insert chunk record into index */
if(need_insert && udata->idx_info_dst->storage->ops->insert)
- if((udata->idx_info_dst->storage->ops->insert)(udata->idx_info_dst, &udata_dst) < 0)
+ if((udata->idx_info_dst->storage->ops->insert)(udata->idx_info_dst, &udata_dst, NULL) < 0)
HGOTO_ERROR_TAG(H5E_DATASET, H5E_CANTINSERT, H5_ITER_ERROR, "unable to insert chunk addr into index")
/* Reset metadata tag in dxpl_id */
diff --git a/src/H5Dpkg.h b/src/H5Dpkg.h
index f391e8c..e9e87af 100644
--- a/src/H5Dpkg.h
+++ b/src/H5Dpkg.h
@@ -276,7 +276,7 @@ typedef herr_t (*H5D_chunk_init_func_t)(const H5D_chk_idx_info_t *idx_info,
typedef herr_t (*H5D_chunk_create_func_t)(const H5D_chk_idx_info_t *idx_info);
typedef hbool_t (*H5D_chunk_is_space_alloc_func_t)(const H5O_storage_chunk_t *storage);
typedef herr_t (*H5D_chunk_insert_func_t)(const H5D_chk_idx_info_t *idx_info,
- H5D_chunk_ud_t *udata);
+ H5D_chunk_ud_t *udata, const H5D_t *dset);
typedef herr_t (*H5D_chunk_get_addr_func_t)(const H5D_chk_idx_info_t *idx_info,
H5D_chunk_ud_t *udata);
typedef herr_t (*H5D_chunk_resize_func_t)(H5O_layout_chunk_t *layout);