summaryrefslogtreecommitdiffstats
path: root/tools/src/h5perf/pio_perf.c
diff options
context:
space:
mode:
authorDana Robinson <43805+derobins@users.noreply.github.com>2022-07-11 15:29:46 (GMT)
committerGitHub <noreply@github.com>2022-07-11 15:29:46 (GMT)
commit460ee73a642db71872efa8e5c51dcf5aee554790 (patch)
tree196f786f98c1877e19cbcc6929a56250232f8805 /tools/src/h5perf/pio_perf.c
parentbe5de999a92ec1ba7853827ff0b5966f3569e792 (diff)
downloadhdf5-460ee73a642db71872efa8e5c51dcf5aee554790.zip
hdf5-460ee73a642db71872efa8e5c51dcf5aee554790.tar.gz
hdf5-460ee73a642db71872efa8e5c51dcf5aee554790.tar.bz2
Adds format attribute to additional functions (#1868)
* Adds format attribute to (s|p)io_perf code * Added gcc format attribute to additional test code * Committing clang-format changes Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Diffstat (limited to 'tools/src/h5perf/pio_perf.c')
-rw-r--r--tools/src/h5perf/pio_perf.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/tools/src/h5perf/pio_perf.c b/tools/src/h5perf/pio_perf.c
index 7ebbefa..2e82dd4 100644
--- a/tools/src/h5perf/pio_perf.c
+++ b/tools/src/h5perf/pio_perf.c
@@ -199,7 +199,7 @@ static int destroy_comm_world(void);
static void output_results(const struct options *options, const char *name, minmax *table, int table_size,
off_t data_size);
static void output_times(const struct options *options, const char *name, minmax *table, int table_size);
-static void output_report(const char *fmt, ...);
+static void output_report(const char *fmt, ...) H5_ATTR_FORMAT(printf, 1, 2);
static void print_indent(int indent);
static void usage(const char *prog);
static void report_parameters(struct options *opts);
@@ -346,7 +346,7 @@ run_test_loop(struct options *opts)
/* only processes doing PIO will run the tests */
if (doing_pio) {
- output_report("Number of processors = %ld\n", parms.num_procs);
+ output_report("Number of processors = %d\n", parms.num_procs);
/* multiply the xfer buffer size by 2 for each loop iteration */
for (buf_size = opts->min_xfer_size; buf_size <= opts->max_xfer_size; buf_size <<= 1) {
@@ -1059,14 +1059,14 @@ output_times(const struct options *opts, const char *name, minmax *table, int ta
/* Note: The maximum throughput uses the minimum amount of time & vice versa */
print_indent(4);
- output_report("Minimum Accumulated Time using %d file(s): %7.5f s\n", opts->num_files, (total_mm.min));
+ output_report("Minimum Accumulated Time using %ld file(s): %7.5f s\n", opts->num_files, (total_mm.min));
print_indent(4);
- output_report("Average Accumulated Time using %d file(s): %7.5f s\n", opts->num_files,
+ output_report("Average Accumulated Time using %ld file(s): %7.5f s\n", opts->num_files,
(total_mm.sum / total_mm.num));
print_indent(4);
- output_report("Maximum Accumulated Time using %d file(s): %7.5f s\n", opts->num_files, (total_mm.max));
+ output_report("Maximum Accumulated Time using %ld file(s): %7.5f s\n", opts->num_files, (total_mm.max));
}
/*