summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/H5FDvfd_swmr_private.h3
-rw-r--r--src/H5Fint.c2
-rw-r--r--src/H5Fpkg.h11
-rw-r--r--src/H5Fvfd_swmr.c12
4 files changed, 13 insertions, 15 deletions
diff --git a/src/H5FDvfd_swmr_private.h b/src/H5FDvfd_swmr_private.h
index f040af3..bc5c177 100644
--- a/src/H5FDvfd_swmr_private.h
+++ b/src/H5FDvfd_swmr_private.h
@@ -95,8 +95,7 @@ H5_DLL herr_t H5F_dump_eot_queue(void);
#define TIME_PASSED_MSEC(X, Y, Z) (unsigned int)(X - Y * 60000 - Z * 1000)
/* Add more tags */
-static const char *H5Fvfd_swmr_log_tags[] = {"FILE_OPEN",
- "FILE_CLOSE", "EOT_TRIGGER_TIME",
+static const char *H5Fvfd_swmr_log_tags[] = {"FILE_OPEN", "FILE_CLOSE", "EOT_TRIGGER_TIME",
"EOT_PROCESSING_TIME", "EOT_META_FILE_INDEX"};
#endif /* H5FDvfd_swmr_private_H */
diff --git a/src/H5Fint.c b/src/H5Fint.c
index b681c23..04e913e 100644
--- a/src/H5Fint.c
+++ b/src/H5Fint.c
@@ -2225,7 +2225,7 @@ H5F_open(const char *name, unsigned flags, hid_t fcpl_id, hid_t fapl_id)
ret_value = file;
#if 1 /*KENT*/
- //H5F_post_vfd_swmr_log_entry(file, 0, "File open ends");
+ // H5F_post_vfd_swmr_log_entry(file, 0, "File open ends");
H5F_POST_VFD_SWMR_LOG_ENTRY(file, 0, "File open ends")
#endif
done:
diff --git a/src/H5Fpkg.h b/src/H5Fpkg.h
index 7b93c72..cf68c8c 100644
--- a/src/H5Fpkg.h
+++ b/src/H5Fpkg.h
@@ -612,12 +612,11 @@ H5_DLL htri_t H5F__same_file_test(hid_t file_id1, hid_t file_id2);
H5_DLL herr_t H5F__reparse_file_lock_variable_test(void);
#endif /* H5F_TESTING */
-#define H5F_POST_VFD_SWMR_LOG_ENTRY(fp,entry_type_code,body) \
-if (fp !=NULL) \
- if (fp->shared != NULL) \
- if (fp->shared->vfd_swmr_log_on == TRUE) \
- H5F_post_vfd_swmr_log_entry(fp,entry_type_code,body);
-
+#define H5F_POST_VFD_SWMR_LOG_ENTRY(fp, entry_type_code, body) \
+ if (fp != NULL) \
+ if (fp->shared != NULL) \
+ if (fp->shared->vfd_swmr_log_on == TRUE) \
+ H5F_post_vfd_swmr_log_entry(fp, entry_type_code, body);
H5_DLL herr_t H5F_post_vfd_swmr_log_entry(H5F_t *f, int entry_type_code, char *body);
#endif /* H5Fpkg_H */
diff --git a/src/H5Fvfd_swmr.c b/src/H5Fvfd_swmr.c
index 9031176..1bfe65b 100644
--- a/src/H5Fvfd_swmr.c
+++ b/src/H5Fvfd_swmr.c
@@ -318,7 +318,7 @@ H5F_vfd_swmr_close_or_flush(H5F_t *f, hbool_t closing)
if (H5F__vfd_swmr_update_end_of_tick_and_tick_num(shared, TRUE) < 0)
HDONE_ERROR(H5E_FILE, H5E_CANTSET, FAIL, "unable to update end of tick");
}
- //if(H5F_post_vfd_swmr_log_entry(f, 1, "File close ends")<0)
+ // if(H5F_post_vfd_swmr_log_entry(f, 1, "File close ends")<0)
// HDONE_ERROR(H5E_FILE, H5E_LOGGING, FAIL, "Fail to report VFD SMWR logging info.");
H5F_POST_VFD_SWMR_LOG_ENTRY(f, 1, "File close ends")
done:
@@ -904,7 +904,7 @@ done:
if (HDclock_gettime(CLOCK_MONOTONIC, &end_time) < 0)
HGOTO_ERROR(H5E_FILE, H5E_CANTGET, FAIL, "can't get time via clock_gettime");
log_msg = HDmalloc(48);
- temp_time = (unsigned int)(TOTAL_TIME_PASSED(start_time, end_time)*1000);
+ temp_time = (unsigned int)(TOTAL_TIME_PASSED(start_time, end_time) * 1000);
HDsprintf(log_msg, "Writer time is %u milliseconds", temp_time);
H5F_post_vfd_swmr_log_entry(f, 3, log_msg);
HDfree(log_msg);
@@ -1934,7 +1934,7 @@ H5F_post_vfd_swmr_log_entry(H5F_t *f, int entry_type_code, char *body)
if (f->shared->vfd_swmr_log_on == false)
HGOTO_DONE(SUCCEED)
#endif
- if (HDclock_gettime(CLOCK_MONOTONIC, &current_time) < 0)
+ if (HDclock_gettime(CLOCK_MONOTONIC, &current_time) < 0)
HGOTO_ERROR(H5E_FILE, H5E_CANTGET, FAIL, "can't get time via clock_gettime");
temp_time = TOTAL_TIME_PASSED(f->shared->vfd_swmr_log_start_time, current_time);
elap_min = TIME_PASSED_MIN(temp_time);
@@ -1947,10 +1947,10 @@ H5F_post_vfd_swmr_log_entry(H5F_t *f, int entry_type_code, char *body)
H5Fvfd_swmr_log_tags[entry_type_code], elap_min, elap_sec, elap_msec, body);
#endif
- HDfprintf(f->shared->vfd_swmr_log_file_ptr, "%-25s: %.3lf s: %s\n",
- H5Fvfd_swmr_log_tags[entry_type_code], temp_time, body);
+ HDfprintf(f->shared->vfd_swmr_log_file_ptr, "%-25s: %.3lf s: %s\n", H5Fvfd_swmr_log_tags[entry_type_code],
+ temp_time, body);
done:
- //return ret_value;
+ // return ret_value;
FUNC_LEAVE_NOAPI(ret_value)
}