diff options
author | Neil Fortner <nfortne2@hdfgroup.org> | 2012-05-30 22:01:00 (GMT) |
---|---|---|
committer | Neil Fortner <nfortne2@hdfgroup.org> | 2012-05-30 22:01:00 (GMT) |
commit | 9786c0e5cb563c362c9b6f5b9bd0730b9ddcadf6 (patch) | |
tree | 006f9f714a95e349ae313fd76afdae9a45910c19 /src/H5Oainfo.c | |
parent | 1f6cb6f84a0fdeec79938624ef874d4147d52d87 (diff) | |
download | hdf5-9786c0e5cb563c362c9b6f5b9bd0730b9ddcadf6.zip hdf5-9786c0e5cb563c362c9b6f5b9bd0730b9ddcadf6.tar.gz hdf5-9786c0e5cb563c362c9b6f5b9bd0730b9ddcadf6.tar.bz2 |
[svn-r22422] Purpose: Add support for SWMR with v2 b-trees
Description:
Adds SWMR support to the v2 b-trees when used as a chunk index. Because each
node keeps track of the total number of records reachable through each of its
children, nodes must be shadowed every time a descendent record is inserted or
removed. This implementation prevents this from happening, however, if the node
has already been shadowed since the last time the v2 b-tree header was flushed.
Also modified SWMR test to include v2 b-trees.
Tested: jam, koala, ostrich (h5committest), durandal
Note: There is a preexisting failure in the ph5diff (-v) test
Diffstat (limited to 'src/H5Oainfo.c')
-rw-r--r-- | src/H5Oainfo.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/src/H5Oainfo.c b/src/H5Oainfo.c index b207ea2..b6aa4fc 100644 --- a/src/H5Oainfo.c +++ b/src/H5Oainfo.c @@ -333,7 +333,7 @@ H5O_ainfo_free(void *mesg) *------------------------------------------------------------------------- */ static herr_t -H5O_ainfo_delete(H5F_t *f, hid_t dxpl_id, H5O_t UNUSED *open_oh, void *_mesg) +H5O_ainfo_delete(H5F_t *f, hid_t dxpl_id, H5O_t *open_oh, void *_mesg) { H5O_ainfo_t *ainfo = (H5O_ainfo_t *)_mesg; herr_t ret_value = SUCCEED; /* Return value */ @@ -346,7 +346,8 @@ H5O_ainfo_delete(H5F_t *f, hid_t dxpl_id, H5O_t UNUSED *open_oh, void *_mesg) /* If the object is using "dense" attribute storage, delete it */ if(H5F_addr_defined(ainfo->fheap_addr)) - if(H5A_dense_delete(f, dxpl_id, ainfo) < 0) + /*!FIXME use ohdr proxy -NAF */ + if(H5A_dense_delete(f, dxpl_id, ainfo, open_oh) < 0) HGOTO_ERROR(H5E_OHDR, H5E_CANTFREE, FAIL, "unable to free dense attribute storage") done: @@ -427,12 +428,14 @@ H5O_ainfo_copy_file(H5F_t *file_src, void *mesg_src, H5F_t *file_dst, *ainfo_dst = *ainfo_src; if(H5F_addr_defined(ainfo_src->fheap_addr)) { - /* copy dense attribute */ - + /* Prepare to copy dense attributes - actual copy in post_copy */ + /* Set copied metadata tag */ H5_BEGIN_TAG(dxpl_id, H5AC__COPIED_TAG, NULL); - if(H5A_dense_create(file_dst, dxpl_id, ainfo_dst) < 0) + /*!FIXME Must pass something for the parent, once we have a way to + * depend on an object being copied (ohdr proxy?) -NAF */ + if(H5A_dense_create(file_dst, dxpl_id, ainfo_dst, NULL) < 0) HGOTO_ERROR(H5E_OHDR, H5E_CANTINIT, NULL, "unable to create dense storage for attributes") /* Reset metadata tag */ |