summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDana Robinson <derobins@hdfgroup.org>2016-11-30 04:53:52 (GMT)
committerDana Robinson <derobins@hdfgroup.org>2016-11-30 04:53:52 (GMT)
commita046ac31d263465130c8824c80af6db06587552e (patch)
treed539770b4bb812c820344554674b8fff5957a6ae /src
parent63bcd73f1f53a8b4bb31083cbc30f9a90663438f (diff)
downloadhdf5-a046ac31d263465130c8824c80af6db06587552e.zip
hdf5-a046ac31d263465130c8824c80af6db06587552e.tar.gz
hdf5-a046ac31d263465130c8824c80af6db06587552e.tar.bz2
First cut at fixing the tagging issue with the free space managers.
* Converted the tag macros to regular ones so the parent's tag is used via the dxpl. * Updated the tag sanity check logic so for free space managers. * Turned new-style group checks back on in test/evict_on_close.c
Diffstat (limited to 'src')
-rw-r--r--src/H5Ctag.c11
-rw-r--r--src/H5FS.c29
-rw-r--r--src/H5FScache.c4
-rw-r--r--src/H5FSsection.c4
4 files changed, 21 insertions, 27 deletions
diff --git a/src/H5Ctag.c b/src/H5Ctag.c
index 6d5b454..e284cdc 100644
--- a/src/H5Ctag.c
+++ b/src/H5Ctag.c
@@ -645,20 +645,13 @@ H5C_verify_tag(int id, haddr_t tag)
} /* end else */
/* Free Space Manager */
- if((id == H5AC_FSPACE_HDR_ID) || (id == H5AC_FSPACE_SINFO_ID)) {
- if(tag != H5AC__FREESPACE_TAG)
- HGOTO_ERROR(H5E_CACHE, H5E_CANTTAG, FAIL, "freespace entry not tagged with H5AC__FREESPACE_TAG")
- } /* end if */
- else {
- if(tag == H5AC__FREESPACE_TAG)
+ if(tag == H5AC__FREESPACE_TAG && ((id != H5AC_FSPACE_HDR_ID) && (id != H5AC_FSPACE_SINFO_ID)))
HGOTO_ERROR(H5E_CACHE, H5E_CANTTAG, FAIL, "H5AC__FREESPACE_TAG applied to non-freespace entry")
- } /* end else */
/* SOHM */
- if((id == H5AC_SOHM_TABLE_ID) || (id == H5AC_SOHM_LIST_ID)) {
+ if((id == H5AC_SOHM_TABLE_ID) || (id == H5AC_SOHM_LIST_ID))
if(tag != H5AC__SOHM_TAG)
HGOTO_ERROR(H5E_CACHE, H5E_CANTTAG, FAIL, "sohm entry not tagged with H5AC__SOHM_TAG")
- } /* end if */
/* Global Heap */
if(id == H5AC_GHEAP_ID) {
diff --git a/src/H5FS.c b/src/H5FS.c
index c3b45d2..9c42531 100644
--- a/src/H5FS.c
+++ b/src/H5FS.c
@@ -109,7 +109,7 @@ H5FS_create(H5F_t *f, hid_t dxpl_id, haddr_t *fs_addr, const H5FS_create_t *fs_c
H5FS_t *fspace = NULL; /* New free space structure */
H5FS_t *ret_value = NULL; /* Return value */
- FUNC_ENTER_NOAPI_TAG(dxpl_id, H5AC__FREESPACE_TAG, NULL)
+ FUNC_ENTER_NOAPI(NULL)
#ifdef H5FS_DEBUG
HDfprintf(stderr, "%s: Creating free space manager, nclasses = %Zu\n", FUNC, nclasses);
#endif /* H5FS_DEBUG */
@@ -167,7 +167,7 @@ done:
#ifdef H5FS_DEBUG
HDfprintf(stderr, "%s: Leaving, ret_value = %d\n", FUNC, ret_value);
#endif /* H5FS_DEBUG */
- FUNC_LEAVE_NOAPI_TAG(ret_value, NULL)
+ FUNC_LEAVE_NOAPI(ret_value)
} /* H5FS_create() */
@@ -192,7 +192,7 @@ H5FS_open(H5F_t *f, hid_t dxpl_id, haddr_t fs_addr, uint16_t nclasses,
H5FS_hdr_cache_ud_t cache_udata; /* User-data for metadata cache callback */
H5FS_t *ret_value = NULL; /* Return value */
- FUNC_ENTER_NOAPI_TAG(dxpl_id, H5AC__FREESPACE_TAG, NULL)
+ FUNC_ENTER_NOAPI(NULL)
#ifdef H5FS_DEBUG
HDfprintf(stderr, "%s: Opening free space manager, fs_addr = %a, nclasses = %Zu\n", FUNC, fs_addr, nclasses);
#endif /* H5FS_DEBUG */
@@ -236,7 +236,7 @@ HDfprintf(stderr, "%s: fspace->rc = %u\n", FUNC, fspace->rc);
ret_value = fspace;
done:
- FUNC_LEAVE_NOAPI_TAG(ret_value, NULL)
+ FUNC_LEAVE_NOAPI(ret_value)
} /* H5FS_open() */
@@ -259,7 +259,7 @@ H5FS_delete(H5F_t *f, hid_t dxpl_id, haddr_t fs_addr)
H5FS_hdr_cache_ud_t cache_udata; /* User-data for metadata cache callback */
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_TAG(dxpl_id, H5AC__FREESPACE_TAG, FAIL)
+ FUNC_ENTER_NOAPI(FAIL)
#ifdef H5FS_DEBUG
HDfprintf(stderr, "%s: Deleting free space manager, fs_addr = %a\n", FUNC, fs_addr);
#endif /* H5FS_DEBUG */
@@ -386,7 +386,7 @@ done:
if(fspace && H5AC_unprotect(f, dxpl_id, H5AC_FSPACE_HDR, fs_addr, fspace, H5AC__DELETED_FLAG | H5AC__FREE_FILE_SPACE_FLAG) < 0)
HDONE_ERROR(H5E_FSPACE, H5E_CANTUNPROTECT, FAIL, "unable to release free space header")
- FUNC_LEAVE_NOAPI_TAG(ret_value, FAIL)
+ FUNC_LEAVE_NOAPI(ret_value)
} /* H5FS_delete() */
@@ -408,7 +408,7 @@ H5FS_close(H5F_t *f, hid_t dxpl_id, H5FS_t *fspace)
{
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_TAG(dxpl_id, H5AC__FREESPACE_TAG, FAIL)
+ FUNC_ENTER_NOAPI(FAIL)
/* Check arguments. */
HDassert(f);
@@ -569,7 +569,7 @@ done:
#ifdef H5FS_DEBUG
HDfprintf(stderr, "%s: Leaving, ret_value = %d, fspace->rc = %u\n", FUNC, ret_value, fspace->rc);
#endif /* H5FS_DEBUG */
- FUNC_LEAVE_NOAPI_TAG(ret_value, FAIL)
+ FUNC_LEAVE_NOAPI(ret_value)
} /* H5FS_close() */
@@ -824,7 +824,7 @@ H5FS_alloc_hdr(H5F_t *f, H5FS_t *fspace, haddr_t *fs_addr, hid_t dxpl_id)
{
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_TAG(dxpl_id, H5AC__FREESPACE_TAG, FAIL)
+ FUNC_ENTER_NOAPI(FAIL)
/* Check arguments. */
HDassert(f);
@@ -844,7 +844,7 @@ H5FS_alloc_hdr(H5F_t *f, H5FS_t *fspace, haddr_t *fs_addr, hid_t dxpl_id)
*fs_addr = fspace->addr;
done:
- FUNC_LEAVE_NOAPI_TAG(ret_value, FAIL)
+ FUNC_LEAVE_NOAPI(ret_value)
} /* H5FS_alloc_hdr() */
@@ -865,7 +865,7 @@ H5FS_alloc_sect(H5F_t *f, H5FS_t *fspace, hid_t dxpl_id)
{
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_TAG(dxpl_id, H5AC__FREESPACE_TAG, FAIL)
+ FUNC_ENTER_NOAPI(FAIL)
/* Check arguments. */
HDassert(f);
@@ -891,7 +891,7 @@ H5FS_alloc_sect(H5F_t *f, H5FS_t *fspace, hid_t dxpl_id)
} /* end if */
done:
- FUNC_LEAVE_NOAPI_TAG(ret_value, FAIL)
+ FUNC_LEAVE_NOAPI(ret_value)
} /* H5FS_alloc_sect() */
@@ -914,7 +914,7 @@ H5FS_free(H5F_t *f, H5FS_t *fspace, hid_t dxpl_id)
unsigned cache_flags; /* Flags for unprotecting cache entries */
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_TAG(dxpl_id, H5AC__FREESPACE_TAG, FAIL)
+ FUNC_ENTER_NOAPI(FAIL)
/* Check arguments. */
HDassert(f);
@@ -1000,7 +1000,7 @@ H5FS_free(H5F_t *f, H5FS_t *fspace, hid_t dxpl_id)
} /* end if */
done:
- FUNC_LEAVE_NOAPI_TAG(ret_value, FAIL)
+ FUNC_LEAVE_NOAPI(ret_value)
} /* H5FS_free() */
@@ -1212,3 +1212,4 @@ HDfprintf(stderr, "%s: fspace->tot_sect_count = %Hu\n", "H5FS_assert", fspace->t
FUNC_LEAVE_NOAPI(SUCCEED)
} /* end H5FS_assert() */
#endif /* H5FS_DEBUG_ASSERT */
+
diff --git a/src/H5FScache.c b/src/H5FScache.c
index c1a9e0a..9917a44 100644
--- a/src/H5FScache.c
+++ b/src/H5FScache.c
@@ -412,7 +412,7 @@ H5FS__cache_hdr_pre_serialize(const H5F_t *f, hid_t dxpl_id, void *_thing,
H5AC_ring_t orig_ring = H5AC_RING_INV; /* Original ring value */
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_STATIC_TAG(dxpl_id, H5AC__FREESPACE_TAG, FAIL)
+ FUNC_ENTER_STATIC
/* Sanity check */
HDassert(f);
@@ -644,7 +644,7 @@ done:
if(H5AC_reset_ring(dxpl, orig_ring) < 0)
HDONE_ERROR(H5E_FSPACE, H5E_CANTSET, FAIL, "unable to set property value")
- FUNC_LEAVE_NOAPI_TAG(ret_value, FAIL)
+ FUNC_LEAVE_NOAPI(ret_value)
} /* end H5FS__cache_hdr_pre_serialize() */
diff --git a/src/H5FSsection.c b/src/H5FSsection.c
index 4697bd50..766a823 100644
--- a/src/H5FSsection.c
+++ b/src/H5FSsection.c
@@ -208,7 +208,7 @@ H5FS_sinfo_lock(H5F_t *f, hid_t dxpl_id, H5FS_t *fspace, unsigned accmode)
H5FS_sinfo_cache_ud_t cache_udata; /* User-data for cache callback */
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_NOINIT_TAG(dxpl_id, H5AC__FREESPACE_TAG, FAIL)
+ FUNC_ENTER_NOAPI_NOINIT
#ifdef H5FS_SINFO_DEBUG
HDfprintf(stderr, "%s: Called, fspace->addr = %a, fspace->sinfo = %p, fspace->sect_addr = %a\n", FUNC, fspace->addr, fspace->sinfo, fspace->sect_addr);
@@ -298,7 +298,7 @@ done:
HDfprintf(stderr, "%s: Leaving, fspace->addr = %a, fspace->sinfo = %p, fspace->sect_addr = %a\n", FUNC, fspace->addr, fspace->sinfo, fspace->sect_addr);
HDfprintf(stderr, "%s: fspace->alloc_sect_size = %Hu, fspace->sect_size = %Hu\n", FUNC, fspace->alloc_sect_size, fspace->sect_size);
#endif /* H5FS_SINFO_DEBUG */
- FUNC_LEAVE_NOAPI_TAG(ret_value, FAIL)
+ FUNC_LEAVE_NOAPI(ret_value)
} /* H5FS_sinfo_lock() */