summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2015-11-20 14:11:31 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2015-11-20 14:11:31 (GMT)
commit55b1eb056e4b8f766f72271bfc691b8e2ca569c2 (patch)
tree0adabbb3e6d1d02b810533b5867b1c6c9b4ae653
parent294f742823fef379a13532da9d920aff2d4725d8 (diff)
downloadhdf5-55b1eb056e4b8f766f72271bfc691b8e2ca569c2.zip
hdf5-55b1eb056e4b8f766f72271bfc691b8e2ca569c2.tar.gz
hdf5-55b1eb056e4b8f766f72271bfc691b8e2ca569c2.tar.bz2
[svn-r28414] Description:
More cleanups and normalizations for merge to trunk. Tested on: MacOSX/64 10.11.1 (amazon) w/serial & parallel (h5committest not required on this branch)
-rw-r--r--src/H5SM.c2
-rw-r--r--src/H5SMbtree2.c58
-rw-r--r--src/H5SMcache.c4
-rw-r--r--src/H5SMmessage.c26
-rw-r--r--src/H5SMpkg.h6
5 files changed, 48 insertions, 48 deletions
diff --git a/src/H5SM.c b/src/H5SM.c
index 4c83479..16eee76 100644
--- a/src/H5SM.c
+++ b/src/H5SM.c
@@ -1639,7 +1639,7 @@ H5SM_find_in_list(const H5SM_list_t *list, const H5SM_mesg_key_t *key, size_t *e
*/
for(x = 0; x < list->header->list_max; x++) {
if((list->messages[x].location != H5SM_NO_LOC) &&
- (0 == H5SM_message_compare(key, &(list->messages[x]))))
+ (0 == H5SM__message_compare(key, &(list->messages[x]))))
HGOTO_DONE(x)
else if(empty_pos && list->messages[x].location == H5SM_NO_LOC) {
/* Note position */
diff --git a/src/H5SMbtree2.c b/src/H5SMbtree2.c
index aafcb91..48a87eb 100644
--- a/src/H5SMbtree2.c
+++ b/src/H5SMbtree2.c
@@ -46,11 +46,11 @@
/* v2 B-tree callbacks */
static void *H5SM__bt2_crt_context(void *udata);
-static herr_t H5SM_bt2_dst_context(void *ctx);
-static herr_t H5SM_bt2_store(void *native, const void *udata);
-static herr_t H5SM_bt2_debug(FILE *stream, const H5F_t *f, hid_t dxpl_id,
+static herr_t H5SM__bt2_dst_context(void *ctx);
+static herr_t H5SM__bt2_store(void *native, const void *udata);
+static herr_t H5SM__bt2_debug(FILE *stream, const H5F_t *f, hid_t dxpl_id,
int indent, int fwidth, const void *record, const void *_udata);
-static void *H5SM_bt2_crt_dbg_context(H5F_t *f, hid_t dxpl_id, haddr_t addr);
+static void *H5SM__bt2_crt_dbg_context(H5F_t *f, hid_t dxpl_id, haddr_t addr);
/*****************************/
@@ -62,14 +62,14 @@ const H5B2_class_t H5SM_INDEX[1]={{ /* B-tree class information */
"H5B2_SOHM_INDEX_ID", /* Name of B-tree class */
sizeof(H5SM_sohm_t), /* Size of native record */
H5SM__bt2_crt_context, /* Create client callback context */
- H5SM_bt2_dst_context, /* Destroy client callback context */
- H5SM_bt2_store, /* Record storage callback */
- H5SM_message_compare, /* Record comparison callback */
- H5SM_message_encode, /* Record encoding callback */
- H5SM_message_decode, /* Record decoding callback */
- H5SM_bt2_debug, /* Record debugging callback */
- H5SM_bt2_crt_dbg_context, /* Create debugging context */
- H5SM_bt2_dst_context /* Destroy debugging context */
+ H5SM__bt2_dst_context, /* Destroy client callback context */
+ H5SM__bt2_store, /* Record storage callback */
+ H5SM__message_compare, /* Record comparison callback */
+ H5SM__message_encode, /* Record encoding callback */
+ H5SM__message_decode, /* Record decoding callback */
+ H5SM__bt2_debug, /* Record debugging callback */
+ H5SM__bt2_crt_dbg_context, /* Create debugging context */
+ H5SM__bt2_dst_context /* Destroy debugging context */
}};
@@ -123,7 +123,7 @@ done:
/*-------------------------------------------------------------------------
- * Function: H5SM_bt2_dst_context
+ * Function: H5SM__bt2_dst_context
*
* Purpose: Destroy client callback context
*
@@ -136,11 +136,11 @@ done:
*-------------------------------------------------------------------------
*/
static herr_t
-H5SM_bt2_dst_context(void *_ctx)
+H5SM__bt2_dst_context(void *_ctx)
{
H5SM_bt2_ctx_t *ctx = (H5SM_bt2_ctx_t *)_ctx; /* Callback context structure */
- FUNC_ENTER_NOAPI_NOINIT_NOERR
+ FUNC_ENTER_STATIC_NOERR
/* Sanity check */
HDassert(ctx);
@@ -149,11 +149,11 @@ H5SM_bt2_dst_context(void *_ctx)
ctx = H5FL_FREE(H5SM_bt2_ctx_t, ctx);
FUNC_LEAVE_NOAPI(SUCCEED)
-} /* H5SM_bt2_dst_context() */
+} /* H5SM__bt2_dst_context() */
/*-------------------------------------------------------------------------
- * Function: H5SM_bt2_store
+ * Function: H5SM__bt2_store
*
* Purpose: Store a H5SM_sohm_t SOHM message in the B-tree. The message
* comes in UDATA as a H5SM_mesg_key_t* and is copied to
@@ -168,21 +168,21 @@ H5SM_bt2_dst_context(void *_ctx)
*-------------------------------------------------------------------------
*/
static herr_t
-H5SM_bt2_store(void *native, const void *udata)
+H5SM__bt2_store(void *native, const void *udata)
{
const H5SM_mesg_key_t *key = (const H5SM_mesg_key_t *)udata;
- FUNC_ENTER_NOAPI_NOINIT_NOERR
+ FUNC_ENTER_STATIC_NOERR
/* Copy the source message to the B-tree */
*(H5SM_sohm_t *)native = key->message;
FUNC_LEAVE_NOAPI(SUCCEED)
-} /* end H5SM_bt2_store */
+} /* end H5SM__bt2_store */
/*-------------------------------------------------------------------------
- * Function: H5SM_bt2_debug
+ * Function: H5SM__bt2_debug
*
* Purpose: Print debugging information for a H5SM_sohm_t.
*
@@ -195,12 +195,12 @@ H5SM_bt2_store(void *native, const void *udata)
*-------------------------------------------------------------------------
*/
static herr_t
-H5SM_bt2_debug(FILE *stream, const H5F_t H5_ATTR_UNUSED *f, hid_t H5_ATTR_UNUSED dxpl_id,
+H5SM__bt2_debug(FILE *stream, const H5F_t H5_ATTR_UNUSED *f, hid_t H5_ATTR_UNUSED dxpl_id,
int indent, int fwidth, const void *record, const void H5_ATTR_UNUSED *_udata)
{
const H5SM_sohm_t *sohm = (const H5SM_sohm_t *)record;
- FUNC_ENTER_NOAPI_NOINIT_NOERR
+ FUNC_ENTER_STATIC_NOERR
if(sohm->location == H5SM_IN_HEAP)
HDfprintf(stream, "%*s%-*s {%a, %lo, %Hx}\n", indent, "", fwidth,
@@ -214,11 +214,11 @@ H5SM_bt2_debug(FILE *stream, const H5F_t H5_ATTR_UNUSED *f, hid_t H5_ATTR_UNUSED
} /* end else */
FUNC_LEAVE_NOAPI(SUCCEED)
-} /* end H5SM_bt2_debug */
+} /* end H5SM__bt2_debug */
/*-------------------------------------------------------------------------
- * Function: H5SM_bt2_crt_dbg_context
+ * Function: H5SM__bt2_crt_dbg_context
*
* Purpose: Create context for debugging callback
*
@@ -231,12 +231,12 @@ H5SM_bt2_debug(FILE *stream, const H5F_t H5_ATTR_UNUSED *f, hid_t H5_ATTR_UNUSED
*-------------------------------------------------------------------------
*/
static void *
-H5SM_bt2_crt_dbg_context(H5F_t *f, hid_t H5_ATTR_UNUSED dxpl_id, haddr_t H5_ATTR_UNUSED addr)
+H5SM__bt2_crt_dbg_context(H5F_t *f, hid_t H5_ATTR_UNUSED dxpl_id, haddr_t H5_ATTR_UNUSED addr)
{
H5SM_bt2_ctx_t *ctx; /* Callback context structure */
- void *ret_value; /* Return value */
+ void *ret_value = NULL; /* Return value */
- FUNC_ENTER_NOAPI_NOINIT
+ FUNC_ENTER_STATIC
/* Sanity check */
HDassert(f);
@@ -253,7 +253,7 @@ H5SM_bt2_crt_dbg_context(H5F_t *f, hid_t H5_ATTR_UNUSED dxpl_id, haddr_t H5_ATTR
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* H5SM_bt2_crt_dbg_context() */
+} /* H5SM__bt2_crt_dbg_context() */
/*-------------------------------------------------------------------------
diff --git a/src/H5SMcache.c b/src/H5SMcache.c
index f2f37df..7b94743 100644
--- a/src/H5SMcache.c
+++ b/src/H5SMcache.c
@@ -636,7 +636,7 @@ H5SM__cache_list_deserialize(const void *_image, size_t len, void *_udata,
/* Read messages into the list array */
ctx.sizeof_addr = H5F_SIZEOF_ADDR(udata->f);
for(u = 0; u < udata->header->num_messages; u++) {
- if(H5SM_message_decode(image, &(list->messages[u]), &ctx) < 0)
+ if(H5SM__message_decode(image, &(list->messages[u]), &ctx) < 0)
HGOTO_ERROR(H5E_SOHM, H5E_CANTLOAD, NULL, "can't decode shared message")
image += H5SM_SOHM_ENTRY_SIZE(udata->f);
@@ -752,7 +752,7 @@ H5SM__cache_list_serialize(const H5F_t *f, void *_image, size_t len,
ctx.sizeof_addr = H5F_SIZEOF_ADDR(f);
for(u = 0; ((u < list->header->list_max) && (mesgs_serialized < list->header->num_messages)); u++) {
if(list->messages[u].location != H5SM_NO_LOC) {
- if(H5SM_message_encode(image, &(list->messages[u]), &ctx) < 0)
+ if(H5SM__message_encode(image, &(list->messages[u]), &ctx) < 0)
HGOTO_ERROR(H5E_SOHM, H5E_CANTFLUSH, FAIL, "unable to serialize shared message")
image += H5SM_SOHM_ENTRY_SIZE(f);
diff --git a/src/H5SMmessage.c b/src/H5SMmessage.c
index 5dbe5cf..426ea20 100644
--- a/src/H5SMmessage.c
+++ b/src/H5SMmessage.c
@@ -74,7 +74,7 @@ static herr_t H5SM_compare_iter_op(H5O_t *oh, H5O_mesg_t *mesg, unsigned sequenc
/*-------------------------------------------------------------------------
* Function: H5SM_compare_cb
*
- * Purpose: Callback for H5HF_op, used in H5SM_message_compare below.
+ * Purpose: Callback for H5HF_op, used in H5SM__message_compare below.
* Determines whether the search key passed in in _UDATA is
* equal to OBJ or not.
*
@@ -170,7 +170,7 @@ done:
/*-------------------------------------------------------------------------
- * Function: H5SM_message_compare
+ * Function: H5SM__message_compare
*
* Purpose: Determine whether the search key rec1 represents a shared
* message that is equal to rec2 or not, and if not, whether
@@ -186,13 +186,13 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5SM_message_compare(const void *rec1, const void *rec2)
+H5SM__message_compare(const void *rec1, const void *rec2)
{
const H5SM_mesg_key_t *key = (const H5SM_mesg_key_t *) rec1;
const H5SM_sohm_t *mesg = (const H5SM_sohm_t *) rec2;
herr_t ret_value = 0;
- FUNC_ENTER_NOAPI_NOINIT_NOERR
+ FUNC_ENTER_PACKAGE_NOERR
/* If the key has an fheap ID, we're looking for a message that's
* already in the index; if the fheap ID matches, we've found the message
@@ -269,11 +269,11 @@ H5SM_message_compare(const void *rec1, const void *rec2)
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5SM_message_compare */
+} /* end H5SM__message_compare */
/*-------------------------------------------------------------------------
- * Function: H5SM_message_encode
+ * Function: H5SM__message_encode
*
* Purpose: Serialize a H5SM_sohm_t struct into a buffer RAW.
*
@@ -286,12 +286,12 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5SM_message_encode(uint8_t *raw, const void *_nrecord, void *_ctx)
+H5SM__message_encode(uint8_t *raw, const void *_nrecord, void *_ctx)
{
H5SM_bt2_ctx_t *ctx = (H5SM_bt2_ctx_t *)_ctx; /* Callback context structure */
const H5SM_sohm_t *message = (const H5SM_sohm_t *)_nrecord;
- FUNC_ENTER_NOAPI_NOINIT_NOERR
+ FUNC_ENTER_PACKAGE_NOERR
/* Sanity check */
HDassert(ctx);
@@ -313,11 +313,11 @@ H5SM_message_encode(uint8_t *raw, const void *_nrecord, void *_ctx)
} /* end else */
FUNC_LEAVE_NOAPI(SUCCEED)
-} /* end H5SM_message_encode */
+} /* end H5SM__message_encode */
/*-------------------------------------------------------------------------
- * Function: H5SM_message_decode
+ * Function: H5SM__message_decode
*
* Purpose: Read an encoded SOHM message from RAW into an H5SM_sohm_t struct.
*
@@ -330,12 +330,12 @@ H5SM_message_encode(uint8_t *raw, const void *_nrecord, void *_ctx)
*-------------------------------------------------------------------------
*/
herr_t
-H5SM_message_decode(const uint8_t *raw, void *_nrecord, void *_ctx)
+H5SM__message_decode(const uint8_t *raw, void *_nrecord, void *_ctx)
{
H5SM_bt2_ctx_t *ctx = (H5SM_bt2_ctx_t *)_ctx; /* Callback context structure */
H5SM_sohm_t *message = (H5SM_sohm_t *)_nrecord;
- FUNC_ENTER_NOAPI_NOINIT_NOERR
+ FUNC_ENTER_PACKAGE_NOERR
message->location = (H5SM_storage_loc_t)*raw++;
UINT32DECODE(raw, message->hash);
@@ -354,5 +354,5 @@ H5SM_message_decode(const uint8_t *raw, void *_nrecord, void *_ctx)
} /* end else */
FUNC_LEAVE_NOAPI(SUCCEED)
-} /* end H5SM_message_decode */
+} /* end H5SM__message_decode */
diff --git a/src/H5SMpkg.h b/src/H5SMpkg.h
index ac2ba1b..f072741 100644
--- a/src/H5SMpkg.h
+++ b/src/H5SMpkg.h
@@ -268,9 +268,9 @@ H5_DLLVAR const H5B2_class_t H5SM_INDEX[1];
H5_DLL ssize_t H5SM_get_index(const H5SM_master_table_t *table, unsigned type_id);
/* Encode and decode routines, used for B-tree and cache encoding/decoding */
-H5_DLL herr_t H5SM_message_compare(const void *rec1, const void *rec2);
-H5_DLL herr_t H5SM_message_encode(uint8_t *raw, const void *native, void *ctx);
-H5_DLL herr_t H5SM_message_decode(const uint8_t *raw, void *native, void *ctx);
+H5_DLL herr_t H5SM__message_compare(const void *rec1, const void *rec2);
+H5_DLL herr_t H5SM__message_encode(uint8_t *raw, const void *native, void *ctx);
+H5_DLL herr_t H5SM__message_decode(const uint8_t *raw, void *native, void *ctx);
/* H5B2_remove_t callback to add messages to a list index */
H5_DLL herr_t H5SM_bt2_convert_to_list_op(const void * record, void *op_data);