summaryrefslogtreecommitdiffstats
path: root/tools/test/perform
diff options
context:
space:
mode:
authorSean McBride <sean@rogue-research.com>2021-08-23 21:14:53 (GMT)
committerGitHub <noreply@github.com>2021-08-23 21:14:53 (GMT)
commitf6c49fe8911a39810b236f7babf09a70fcc76c7b (patch)
tree4ee702ab548adf8e619525e14716dde7d26bb331 /tools/test/perform
parentb5f5c59f297be19096051282068cdcc14275eb34 (diff)
downloadhdf5-f6c49fe8911a39810b236f7babf09a70fcc76c7b.zip
hdf5-f6c49fe8911a39810b236f7babf09a70fcc76c7b.tar.gz
hdf5-f6c49fe8911a39810b236f7babf09a70fcc76c7b.tar.bz2
More clang tidy (#908)
* Pacify clang-analyzer-unix.cstring.NullArg * Apply some bugprone-suspicious-string-compare * Apply some readability-simplify-boolean-expr * Apply some readability-make-member-function-const * Apple some bugprone-macro-parentheses * Changed an f suffix to L for `long double` * Applied some readability-uppercase-literal-suffix automatically * Committing clang-format changes Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Diffstat (limited to 'tools/test/perform')
-rw-r--r--tools/test/perform/chunk_cache.c6
-rw-r--r--tools/test/perform/zip_perf.c2
2 files changed, 4 insertions, 4 deletions
diff --git a/tools/test/perform/chunk_cache.c b/tools/test/perform/chunk_cache.c
index 25fa34c..b515961 100644
--- a/tools/test/perform/chunk_cache.c
+++ b/tools/test/perform/chunk_cache.c
@@ -26,9 +26,9 @@
#define RANK 2
#define DSET1_NAME "partial_chunks"
-#define DSET1_DIM1 9 * 1000
+#define DSET1_DIM1 (9 * 1000)
#define DSET1_DIM2 9
-#define CHUNK1_DIM1 2 * 1000
+#define CHUNK1_DIM1 (2 * 1000)
#define CHUNK1_DIM2 2
#define DSET2_NAME "hash_value"
@@ -38,7 +38,7 @@
#define CHUNK2_DIM2 100
#define RDCC_NSLOTS 5
-#define RDCC_NBYTES 1024 * 1024 * 10
+#define RDCC_NBYTES (1024 * 1024 * 10)
#define RDCC_W0 0.75F
#define FILTER_COUNTER 306
diff --git a/tools/test/perform/zip_perf.c b/tools/test/perform/zip_perf.c
index 05ad083..d8cd3a1 100644
--- a/tools/test/perform/zip_perf.c
+++ b/tools/test/perform/zip_perf.c
@@ -35,7 +35,7 @@
#define MICROSECOND 1000000.0
/* report 0.0 in case t is zero too */
-#define MB_PER_SEC(bytes, t) ((fabs(t) < 0.0000000001) ? 0.0 : ((((double)bytes) / (double)ONE_MB) / (t)))
+#define MB_PER_SEC(bytes, t) ((fabs(t) < 0.0000000001) ? 0.0 : ((((double)(bytes)) / (double)ONE_MB) / (t)))
#ifndef TRUE
#define TRUE 1