summaryrefslogtreecommitdiffstats
path: root/tools/test/perform/perf_meta.c
diff options
context:
space:
mode:
authorSean McBride <sean@rogue-research.com>2023-06-19 05:13:38 (GMT)
committerGitHub <noreply@github.com>2023-06-19 05:13:38 (GMT)
commit65d8c9347010771473b53c91adcec2f281772213 (patch)
tree487567dae0dc005de896f616b90e67744239a5e2 /tools/test/perform/perf_meta.c
parent1f20354ee6cdfa9fd157ac9cdfff9acdf320a32d (diff)
downloadhdf5-65d8c9347010771473b53c91adcec2f281772213.zip
hdf5-65d8c9347010771473b53c91adcec2f281772213.tar.gz
hdf5-65d8c9347010771473b53c91adcec2f281772213.tar.bz2
Many fixes to various compiler warnings (#3124)
* Fixed various -Wmissing-variable-declarations by adding static keyword * In a few cases, renamed the variable suffix from _g to _s. * Fixed some -Wmissing-variable-declarations by using different declaration macros * Fixed various -Wconditional-uninitialized warnings by just initializing variable to zero * Fixed various -Wcomma warnings * Fixed clang -Wstrict-prototypes warnings * Fixed various -Wunused-variable warnings * Updated some casts to fix the only 3 -Wcast-qual warnings * Fixed the only -Wsometimes-uninitialized warning
Diffstat (limited to 'tools/test/perform/perf_meta.c')
-rw-r--r--tools/test/perform/perf_meta.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/tools/test/perform/perf_meta.c b/tools/test/perform/perf_meta.c
index 6e62f6a..5fe3631 100644
--- a/tools/test/perform/perf_meta.c
+++ b/tools/test/perform/perf_meta.c
@@ -28,25 +28,25 @@
#define FACC_MPIO 0x1 /* MPIO */
/* Which test to run */
-int RUN_TEST = 0x0; /* all tests as default */
-int TEST_1 = 0x1; /* Test 1 */
-int TEST_2 = 0x2; /* Test 2 */
-int TEST_3 = 0x4; /* Test 3 */
+static int RUN_TEST = 0x0; /* all tests as default */
+static int TEST_1 = 0x1; /* Test 1 */
+static int TEST_2 = 0x2; /* Test 2 */
+static int TEST_3 = 0x4; /* Test 3 */
-const char *FILENAME[] = {"meta_perf_1", "meta_perf_2", "meta_perf_3", NULL};
+static const char *FILENAME[] = {"meta_perf_1", "meta_perf_2", "meta_perf_3", NULL};
/* Default values for performance. Can be changed through command line options */
-int NUM_DSETS = 16;
-int NUM_ATTRS = 8;
-int BATCH_ATTRS = 2;
-hbool_t flush_dset = FALSE;
-hbool_t flush_attr = FALSE;
-int nerrors = 0; /* errors count */
-hid_t fapl;
+static int NUM_DSETS = 16;
+static int NUM_ATTRS = 8;
+static int BATCH_ATTRS = 2;
+static hbool_t flush_dset = FALSE;
+static hbool_t flush_attr = FALSE;
+static int nerrors = 0; /* errors count */
+static hid_t fapl;
/* Data space IDs */
-hid_t space;
-hid_t small_space;
+static hid_t space;
+static hid_t small_space;
/* Performance data */
typedef struct p_time {
@@ -59,7 +59,7 @@ typedef struct p_time {
} p_time;
/*Test file access type for parallel. MPIO as default */
-int facc_type = FACC_DEFAULT;
+static int facc_type = FACC_DEFAULT;
double retrieve_time(void);
void perf(p_time *perf_t, double start_t, double end_t);