summaryrefslogtreecommitdiffstats
path: root/src/H5AC.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/H5AC.c')
-rw-r--r--src/H5AC.c50
1 files changed, 24 insertions, 26 deletions
diff --git a/src/H5AC.c b/src/H5AC.c
index e6bcbb6..c5466be 100644
--- a/src/H5AC.c
+++ b/src/H5AC.c
@@ -1002,7 +1002,7 @@ H5AC_mark_entry_dirty(void *thing)
* is really necessary in the trace file. Write the result to catch
* occult errors.
*/
- if((H5C_get_trace_file_ptr_from_entry(thing, &trace_file_ptr) >= 0) &&
+ if((H5C_get_trace_file_ptr_from_entry((const H5C_cache_entry_t *) thing, &trace_file_ptr) >= 0) &&
(NULL != trace_file_ptr))
sprintf(trace, "%s 0x%lx", FUNC,
(unsigned long)(((H5C_cache_entry_t *)thing)->addr));
@@ -1150,7 +1150,7 @@ H5AC_pin_protected_entry(void *thing)
/* For the pin protected entry call, only the addr is really necessary
* in the trace file. Also write the result to catch occult errors.
*/
- if((H5C_get_trace_file_ptr_from_entry(thing, &trace_file_ptr) >= 0) &&
+ if((H5C_get_trace_file_ptr_from_entry((const H5C_cache_entry_t *)thing, &trace_file_ptr) >= 0) &&
(NULL != trace_file_ptr))
sprintf(trace, "%s 0x%lx", FUNC,
(unsigned long)(((H5C_cache_entry_t *)thing)->addr));
@@ -1198,7 +1198,7 @@ H5AC_create_flush_dependency(void * parent_thing, void * child_thing)
HDassert(child_thing);
#if H5AC__TRACE_FILE_ENABLED
- if((H5C_get_trace_file_ptr_from_entry(parent_thing, &trace_file_ptr) >= 0) &&
+ if((H5C_get_trace_file_ptr_from_entry((H5C_cache_entry_t *)parent_thing, &trace_file_ptr) >= 0) &&
(NULL != trace_file_ptr))
sprintf(trace, "%s %lx %lx",
FUNC,
@@ -1309,10 +1309,8 @@ H5AC_protect(H5F_t *f,
}
#endif /* H5AC__TRACE_FILE_ENABLED */
- if ( rw == H5AC_READ ) {
-
+ if ( rw == H5AC_READ )
protect_flags |= H5C__READ_ONLY_FLAG;
- }
thing = H5C_protect(f,
dxpl_id,
@@ -1385,7 +1383,7 @@ H5AC_resize_entry(void *thing, size_t new_size)
* really necessary in the trace file. Write the result to catch
* occult errors.
*/
- if((H5C_get_trace_file_ptr_from_entry(thing, &trace_file_ptr) >= 0) &&
+ if((H5C_get_trace_file_ptr_from_entry((H5C_cache_entry_t *)thing, &trace_file_ptr) >= 0) &&
(NULL != trace_file_ptr))
sprintf(trace, "%s 0x%lx %d", FUNC,
(unsigned long)(((H5C_cache_entry_t *)thing)->addr),
@@ -1451,7 +1449,7 @@ H5AC_unpin_entry(void *thing)
/* For the unpin entry call, only the addr is really necessary
* in the trace file. Also write the result to catch occult errors.
*/
- if((H5C_get_trace_file_ptr_from_entry(thing, &trace_file_ptr) >= 0) &&
+ if((H5C_get_trace_file_ptr_from_entry((H5C_cache_entry_t *)thing, &trace_file_ptr) >= 0) &&
(NULL != trace_file_ptr))
sprintf(trace, "%s 0x%lx", FUNC,
(unsigned long)(((H5C_cache_entry_t *)thing)->addr));
@@ -1498,8 +1496,8 @@ H5AC_destroy_flush_dependency(void * parent_thing, void * child_thing)
HDassert(child_thing);
#if H5AC__TRACE_FILE_ENABLED
- if((H5C_get_trace_file_ptr_from_entry(parent_thing, &trace_file_ptr) >= 0) &&
- (NULL != trace_file_ptr))
+ if((H5C_get_trace_file_ptr_from_entry((H5C_cache_entry_t *)parent_thing, &trace_file_ptr) >= 0) &&
+ (NULL != trace_file_ptr))
sprintf(trace, "%s %llx %llx",
FUNC,
(unsigned long long)(((H5C_cache_entry_t *)parent_thing)->addr),
@@ -1648,7 +1646,7 @@ H5AC_unprotect(H5F_t *f, hid_t dxpl_id, const H5AC_class_t *type, haddr_t addr,
done:
#if H5AC__TRACE_FILE_ENABLED
if(trace_file_ptr != NULL)
- HDfprintf(trace_file_ptr, "%s %x %d\n",
+ HDfprintf(trace_file_ptr, "%s 0x%x %d\n",
trace, (unsigned)flags, (int)ret_value);
#endif /* H5AC__TRACE_FILE_ENABLED */
@@ -2154,7 +2152,7 @@ done:
( trace_file_ptr != NULL ) ) {
HDfprintf(trace_file_ptr,
- "%s %d %d %d %d \"%s\" %d %d %d %f %d %d %ld %d %f %f %d %f %f %d %d %d %f %f %d %d %d %d %f %d %d %d\n",
+ "%s %d %d %d %d \"%s\" %d %d %d %f %d %d %ld %d %f %f %d %f %f %d %d %d %f %f %d %d %d %d %f %zu %d %d\n",
"H5AC_set_cache_auto_resize_config",
trace_config.version,
(int)(trace_config.rpt_fcn_enabled),
@@ -2450,7 +2448,7 @@ H5AC_open_trace_file(H5AC_t * cache_ptr,
HGOTO_ERROR(H5E_FILE, H5E_CANTOPENFILE, FAIL, "trace file open failed.")
}
- HDfprintf(file_ptr, "### HDF5 metadata cache trace file ###\n");
+ HDfprintf(file_ptr, "### HDF5 metadata cache trace file version 1 ###\n");
if ( H5C_set_trace_file_ptr(cache_ptr, file_ptr) < 0 ) {
@@ -2988,12 +2986,12 @@ done:
#ifdef H5_HAVE_PARALLEL
static herr_t
H5AC_check_if_write_permitted(const H5F_t *f,
- hid_t UNUSED dxpl_id,
+ hid_t H5_ATTR_UNUSED dxpl_id,
hbool_t * write_permitted_ptr)
#else /* H5_HAVE_PARALLEL */
static herr_t
-H5AC_check_if_write_permitted(const H5F_t UNUSED * f,
- hid_t UNUSED dxpl_id,
+H5AC_check_if_write_permitted(const H5F_t H5_ATTR_UNUSED * f,
+ hid_t H5_ATTR_UNUSED dxpl_id,
hbool_t * write_permitted_ptr)
#endif /* H5_HAVE_PARALLEL */
{
@@ -3561,7 +3559,7 @@ H5AC_log_flushed_entry(H5C_t * cache_ptr,
haddr_t addr,
hbool_t was_dirty,
unsigned flags,
- int UNUSED type_id)
+ int H5_ATTR_UNUSED type_id)
{
herr_t ret_value = SUCCEED; /* Return value */
hbool_t cleared;
@@ -5002,15 +5000,15 @@ H5AC_run_sync_point(H5F_t *f,
#if H5AC_DEBUG_DIRTY_BYTES_CREATION
HDfprintf(stdout,
- "%d:H5AC_propagate...:%d: (u/uu/i/iu/r/ru) = %d/%d/%d/%d/%d/%d\n",
- (int)(aux_ptr->mpi_rank),
- (int)(aux_ptr->dirty_bytes_propagations),
- (int)(aux_ptr->unprotect_dirty_bytes),
- (int)(aux_ptr->unprotect_dirty_bytes_updates),
- (int)(aux_ptr->insert_dirty_bytes),
- (int)(aux_ptr->insert_dirty_bytes_updates),
- (int)(aux_ptr->rename_dirty_bytes),
- (int)(aux_ptr->rename_dirty_bytes_updates));
+ "%d:H5AC_propagate...:%u: (u/uu/i/iu/r/ru) = %zu/%u/%zu/%u/%zu/%u\n",
+ aux_ptr->mpi_rank,
+ aux_ptr->dirty_bytes_propagations,
+ aux_ptr->unprotect_dirty_bytes,
+ aux_ptr->unprotect_dirty_bytes_updates,
+ aux_ptr->insert_dirty_bytes,
+ aux_ptr->insert_dirty_bytes_updates,
+ aux_ptr->rename_dirty_bytes,
+ aux_ptr->rename_dirty_bytes_updates);
#endif /* H5AC_DEBUG_DIRTY_BYTES_CREATION */
switch(aux_ptr->metadata_write_strategy) {