summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorAllen Byrne <50328838+byrnHDF@users.noreply.github.com>2021-10-17 13:09:14 (GMT)
committerGitHub <noreply@github.com>2021-10-17 13:09:14 (GMT)
commit81af7d7f3a1ae148bf0816fb275e1a2365ab9deb (patch)
tree7cdb157c688cf313c3008c7e7b82861f7aade51c /tools
parentd1dd4a424685200b382185736e3435a6ae8e5505 (diff)
downloadhdf5-81af7d7f3a1ae148bf0816fb275e1a2365ab9deb.zip
hdf5-81af7d7f3a1ae148bf0816fb275e1a2365ab9deb.tar.gz
hdf5-81af7d7f3a1ae148bf0816fb275e1a2365ab9deb.tar.bz2
1 12 Merge Remove clang warnings from develop (#1097)
* Merge Remove clang warnings from develop * Correct test data typo
Diffstat (limited to 'tools')
-rw-r--r--tools/lib/h5diff_array.c4
-rw-r--r--tools/src/h5perf/sio_perf.c18
-rw-r--r--tools/test/h5diff/h5diffgentest.c112
-rw-r--r--tools/test/h5dump/h5dumpgentest.c40
-rw-r--r--tools/test/perform/chunk_cache.c2
-rw-r--r--tools/test/perform/overhead.c2
-rw-r--r--tools/test/perform/zip_perf.c2
7 files changed, 90 insertions, 90 deletions
diff --git a/tools/lib/h5diff_array.c b/tools/lib/h5diff_array.c
index 2d6c66c..e16a045 100644
--- a/tools/lib/h5diff_array.c
+++ b/tools/lib/h5diff_array.c
@@ -2070,7 +2070,7 @@ diff_ldouble_element(unsigned char *mem1, unsigned char *mem2, hsize_t elem_idx,
/* both not NaN, do the comparison */
if (!isnan1 && !isnan2) {
- if (ABS(temp1_double - temp2_double) > opts->delta) {
+ if ((double)ABS(temp1_double - temp2_double) > opts->delta) {
opts->print_percentage = 0;
print_pos(opts, elem_idx, 0);
if (print_data(opts)) {
@@ -2163,7 +2163,7 @@ diff_ldouble_element(unsigned char *mem1, unsigned char *mem2, hsize_t elem_idx,
}
nfound++;
}
- else if (per > opts->percent && ABS(temp1_double - temp2_double) > opts->delta) {
+ else if (per > opts->percent && (double)ABS(temp1_double - temp2_double) > opts->delta) {
opts->print_percentage = 1;
print_pos(opts, elem_idx, 0);
if (print_data(opts)) {
diff --git a/tools/src/h5perf/sio_perf.c b/tools/src/h5perf/sio_perf.c
index 1b200b0..9c7675f 100644
--- a/tools/src/h5perf/sio_perf.c
+++ b/tools/src/h5perf/sio_perf.c
@@ -310,14 +310,14 @@ run_test(iotype iot, parameters parms, struct options *opts)
minmax * read_mm_table = NULL;
minmax * read_gross_mm_table = NULL;
minmax * read_raw_mm_table = NULL;
- minmax write_sys_mm = {0.0F, 0.0F, 0.0F, 0};
- minmax write_mm = {0.0F, 0.0F, 0.0F, 0};
- minmax write_gross_mm = {0.0F, 0.0F, 0.0F, 0};
- minmax write_raw_mm = {0.0F, 0.0F, 0.0F, 0};
- minmax read_sys_mm = {0.0F, 0.0F, 0.0F, 0};
- minmax read_mm = {0.0F, 0.0F, 0.0F, 0};
- minmax read_gross_mm = {0.0F, 0.0F, 0.0F, 0};
- minmax read_raw_mm = {0.0F, 0.0F, 0.0F, 0};
+ minmax write_sys_mm = {0.0, 0.0, 0.0, 0};
+ minmax write_mm = {0.0, 0.0, 0.0, 0};
+ minmax write_gross_mm = {0.0, 0.0, 0.0, 0};
+ minmax write_raw_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_sys_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_gross_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_raw_mm = {0.0, 0.0, 0.0, 0};
raw_size = (off_t)parms.num_bytes;
parms.io_type = iot;
@@ -574,7 +574,7 @@ accumulate_minmax_stuff(const minmax *mm, int count, minmax *total_mm)
{
int i;
- total_mm->sum = 0.0F;
+ total_mm->sum = 0.0;
total_mm->max = -DBL_MAX;
total_mm->min = DBL_MAX;
total_mm->num = count;
diff --git a/tools/test/h5diff/h5diffgentest.c b/tools/test/h5diff/h5diffgentest.c
index f03254e..017b8a3 100644
--- a/tools/test/h5diff/h5diffgentest.c
+++ b/tools/test/h5diff/h5diffgentest.c
@@ -358,10 +358,10 @@ test_basic(const char *fname1, const char *fname2, const char *fname3)
*/
{
- double data1[3][2] = {{1.0F, 1.0F}, {1.00F, 1.000F}, {0.0F, 0.0F}};
- double data2[3][2] = {{0.0F, 1.1F}, {1.01F, 1.001F}, {0.0F, 1.0F}};
- double data3[3][2] = {{100.0F, 100.0F}, {100.00F, 100.000F}, {100.0F, 100.0F}};
- double data4[3][2] = {{105.0F, 120.0F}, {160.00F, 95.000F}, {80.0F, 40.0F}};
+ double data1[3][2] = {{1.0, 1.0}, {1.00, 1.000}, {0.0, 0.0}};
+ double data2[3][2] = {{0.0, 1.1}, {1.01, 1.001}, {0.0, 1.0}};
+ double data3[3][2] = {{100.0, 100.0}, {100.00, 100.000}, {100.0, 100.0}};
+ double data4[3][2] = {{105.0, 120.0}, {160.00, 95.000}, {80.0, 40.0}};
write_dset(gid1, 2, dims2, "dset1", H5T_NATIVE_DOUBLE, data1);
write_dset(gid2, 2, dims2, "dset2", H5T_NATIVE_DOUBLE, data2);
@@ -409,8 +409,8 @@ test_basic(const char *fname1, const char *fname2, const char *fname3)
*-------------------------------------------------------------------------
*/
{
- double data9[3][2] = {{100.0F, 100.0F}, {100.0F, 0.0F}, {0.0F, 100.0F}};
- double data10[3][2] = {{120.0F, 80.0F}, {0.0F, 100.0F}, {0.0F, 50.0F}};
+ double data9[3][2] = {{100.0, 100.0}, {100.0, 0.0}, {0.0, 100.0}};
+ double data10[3][2] = {{120.0, 80.0}, {0.0, 100.0}, {0.0, 50.0}};
write_dset(gid1, 2, dims2, "dset9", H5T_NATIVE_DOUBLE, data9);
write_dset(gid1, 2, dims2, "dset10", H5T_NATIVE_DOUBLE, data10);
@@ -466,18 +466,18 @@ test_basic(const char *fname1, const char *fname2, const char *fname3)
float data16[6];
data15[0] = (float)HDsqrt(-1.0);
- data15[1] = 1.0F;
+ data15[1] = 1.0;
data15[2] = (float)HDsqrt(-1.0);
- data15[3] = 1.0F;
- data15[4] = 1.0F;
- data15[5] = 1.0F;
+ data15[3] = 1.0;
+ data15[4] = 1.0;
+ data15[5] = 1.0;
data16[0] = (float)HDsqrt(-1.0);
data16[1] = (float)HDsqrt(-1.0);
- data16[2] = 1.0F;
- data16[3] = 1.0F;
- data16[4] = 1.0F;
- data16[5] = 1.0F;
+ data16[2] = 1.0;
+ data16[3] = 1.0;
+ data16[4] = 1.0;
+ data16[5] = 1.0;
write_dset(gid1, 1, dims1, "fp15", H5T_NATIVE_FLOAT, data15);
write_dset(gid1, 1, dims1, "fp16", H5T_NATIVE_FLOAT, data16);
@@ -554,8 +554,8 @@ test_basic(const char *fname1, const char *fname2, const char *fname3)
buf1[1].d = HDsqrt(-1.0);
buf1[1].f = (float)HDsqrt(-1.0);
- buf2[1].d = 0.0F;
- buf2[1].f = 0.0F;
+ buf2[1].d = 0.0;
+ buf2[1].f = 0.0;
type_size = sizeof(cmp1_t);
tid = H5Tcreate(H5T_COMPOUND, type_size);
@@ -583,13 +583,13 @@ test_basic(const char *fname1, const char *fname2, const char *fname3)
int i;
} cmp3_t;
- double data2[6] = {0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F};
+ double data2[6] = {0.0, 0.0, 0.0, 0.0, 0.0, 0.0};
int data3[6] = {0, 0, 0, 0, 0, 0};
int data4[3][2] = {{0, 0}, {0, 0}, {0, 0}};
int data5[2][2] = {{0, 0}, {0, 0}};
unsigned int data6[3][2] = {{0, 0}, {0, 0}, {0, 0}};
- cmp1_t data7[1] = {{1.0f, 2}};
- cmp2_t data8[1] = {{1, 2.0f}};
+ cmp1_t data7[1] = {{1.0, 2}};
+ cmp2_t data8[1] = {{1, 2.0}};
hsize_t dims3[2] = {2, 2};
hsize_t dims4[1] = {1};
size_t type_size;
@@ -789,10 +789,10 @@ test_datatypes(const char *fname)
int buf3b[3][2] = {{1, 1}, {3, 4}, {5, 6}};
long buf4a[3][2] = {{1, 1}, {1, 1}, {1, 1}};
long buf4b[3][2] = {{1, 1}, {3, 4}, {5, 6}};
- float buf5a[3][2] = {{1.0F, 1.0F}, {1.0F, 1.0F}, {1.0F, 1.0F}};
- float buf5b[3][2] = {{1.0F, 1.0F}, {3.0F, 4.0F}, {5.0F, 6.0F}};
- double buf6a[3][2] = {{1.0F, 1.0F}, {1.0F, 1.0F}, {1.0F, 1.0F}};
- double buf6b[3][2] = {{1.0F, 1.0F}, {3.0F, 4.0F}, {5.0F, 6.0F}};
+ float buf5a[3][2] = {{1.0, 1.0}, {1.0, 1.0}, {1.0, 1.0}};
+ float buf5b[3][2] = {{1.0, 1.0}, {3.0, 4.0}, {5.0, 6.0}};
+ double buf6a[3][2] = {{1.0, 1.0}, {1.0, 1.0}, {1.0, 1.0}};
+ double buf6b[3][2] = {{1.0, 1.0}, {3.0, 4.0}, {5.0, 6.0}};
/*unsigned/signed test
signed char -128 to 127
@@ -5212,27 +5212,27 @@ write_attr_strings(hid_t loc_id, const char *dset_name, hid_t fid,
char buf1[2][STR_SIZE] = {"ab", "de"}; /* string */
char * buf1a[2]; /* VL string */
char buf2[2] = {1, 2}; /* bitfield, opaque */
- s_t buf3[2] = {{1, 2.0F}, {3, 4.0F}}; /* compound */
+ s_t buf3[2] = {{1, 2.0}, {3, 4.0}}; /* compound */
hobj_ref_t buf4[2]; /* reference */
e_t buf45[2] = {RED, RED}; /* enum */
hvl_t buf5[2]; /* vlen */
hsize_t dimarray[1] = {3}; /* array dimension */
int buf6[2][3] = {{1, 2, 3}, {4, 5, 6}}; /* array */
int buf7[2] = {1, 2}; /* integer */
- float buf8[2] = {1.0F, 2.0F}; /* float */
+ float buf8[2] = {1.0, 2.0}; /* float */
/* create 2D attributes with dimension [3][2], 6 elements */
- hsize_t dims2[2] = {3, 2};
- char buf12[3][2][STR_SIZE] = {{"ab", "cd"}, {"ef", "gh"}, {"ij", "kl"}}; /* string */
- char * buf12a[3][2]; /* VL string */
- char buf22[3][2] = {{1, 2}, {3, 4}, {5, 6}}; /* bitfield, opaque */
- s_t buf32[6] = {{1, 2.0F}, {3, 4.0F}, {5, 6.0F}, {7, 8.0F}, {9, 10.0F}, {11, 12.0F}}; /* compound */
+ hsize_t dims2[2] = {3, 2};
+ char buf12[3][2][STR_SIZE] = {{"ab", "cd"}, {"ef", "gh"}, {"ij", "kl"}}; /* string */
+ char * buf12a[3][2]; /* VL string */
+ char buf22[3][2] = {{1, 2}, {3, 4}, {5, 6}}; /* bitfield, opaque */
+ s_t buf32[6] = {{1, 2.0}, {3, 4.0}, {5, 6.0}, {7, 8.0}, {9, 10.0}, {11, 12.0}}; /* compound */
hobj_ref_t buf42[3][2]; /* reference */
e_t buf452[3][2]; /* enum */
hvl_t buf52[3][2]; /* vlen */
int buf62[6][3] = {{1, 2, 3}, {4, 5, 6}, {7, 8, 9}, {10, 11, 12}, {13, 14, 15}, {16, 17, 18}}; /* array */
- int buf72[3][2] = {{1, 2}, {3, 4}, {5, 6}}; /* integer */
- float buf82[3][2] = {{1.0F, 2.0F}, {3.0F, 4.0F}, {5.0F, 6.0F}}; /* float */
+ int buf72[3][2] = {{1, 2}, {3, 4}, {5, 6}}; /* integer */
+ float buf82[3][2] = {{1.0, 2.0}, {3.0, 4.0}, {5.0, 6.0}}; /* float */
/* create 3D attributes with dimension [4][3][2], 24 elements */
hsize_t dims3[3] = {4, 3, 2};
@@ -5933,7 +5933,7 @@ write_attr_strings(hid_t loc_id, const char *dset_name, hid_t fid,
for (k = 0; k < 2; k++)
if (make_diffs) {
buf33[i][j][k].a = 0;
- buf33[i][j][k].b = 0.0F;
+ buf33[i][j][k].b = 0.0;
}
else {
buf33[i][j][k].a = (char)n++;
@@ -6143,7 +6143,7 @@ write_attr_strings(hid_t loc_id, const char *dset_name, hid_t fid,
for (k = 0; k < 2; k++) {
if (make_diffs) {
buf73[i][j][k] = 0;
- buf83[i][j][k] = 0.0F;
+ buf83[i][j][k] = 0.0;
}
else {
buf73[i][j][k] = n++;
@@ -6201,27 +6201,27 @@ write_attr_in(hid_t loc_id, const char *dset_name, hid_t fid,
char buf1[2][STR_SIZE] = {"ab", "de"}; /* string */
char * buf1a[2]; /* VL string */
char buf2[2] = {1, 2}; /* bitfield, opaque */
- s_t buf3[2] = {{1, 2.0F}, {3, 4.0F}}; /* compound */
+ s_t buf3[2] = {{1, 2.0}, {3, 4.0}}; /* compound */
hobj_ref_t buf4[2]; /* reference */
e_t buf45[2] = {RED, RED}; /* enum */
hvl_t buf5[2]; /* vlen */
hsize_t dimarray[1] = {3}; /* array dimension */
int buf6[2][3] = {{1, 2, 3}, {4, 5, 6}}; /* array */
int buf7[2] = {1, 2}; /* integer */
- float buf8[2] = {1.0F, 2.0F}; /* float */
+ float buf8[2] = {1.0, 2.0}; /* float */
/* create 2D attributes with dimension [3][2], 6 elements */
- hsize_t dims2[2] = {3, 2};
- char buf12[3][2][STR_SIZE] = {{"ab", "cd"}, {"ef", "gh"}, {"ij", "kl"}}; /* string */
- char * buf12a[3][2]; /* VL string */
- char buf22[3][2] = {{1, 2}, {3, 4}, {5, 6}}; /* bitfield, opaque */
- s_t buf32[6] = {{1, 2.0F}, {3, 4.0F}, {5, 6.0F}, {7, 8.0F}, {9, 10.0F}, {11, 12.0F}}; /* compound */
+ hsize_t dims2[2] = {3, 2};
+ char buf12[3][2][STR_SIZE] = {{"ab", "cd"}, {"ef", "gh"}, {"ij", "kl"}}; /* string */
+ char * buf12a[3][2]; /* VL string */
+ char buf22[3][2] = {{1, 2}, {3, 4}, {5, 6}}; /* bitfield, opaque */
+ s_t buf32[6] = {{1, 2.0}, {3, 4.0}, {5, 6.0}, {7, 8.0}, {9, 10.0}, {11, 12.0}}; /* compound */
hobj_ref_t buf42[3][2]; /* reference */
e_t buf452[3][2]; /* enum */
hvl_t buf52[3][2]; /* vlen */
int buf62[6][3] = {{1, 2, 3}, {4, 5, 6}, {7, 8, 9}, {10, 11, 12}, {13, 14, 15}, {16, 17, 18}}; /* array */
- int buf72[3][2] = {{1, 2}, {3, 4}, {5, 6}}; /* integer */
- float buf82[3][2] = {{1.0F, 2.0F}, {3.0F, 4.0F}, {5.0F, 6.0F}}; /* float */
+ int buf72[3][2] = {{1, 2}, {3, 4}, {5, 6}}; /* integer */
+ float buf82[3][2] = {{1.0, 2.0}, {3.0, 4.0}, {5.0, 6.0}}; /* float */
/* create 3D attributes with dimension [4][3][2], 24 elements */
hsize_t dims3[3] = {4, 3, 2};
@@ -6922,7 +6922,7 @@ write_attr_in(hid_t loc_id, const char *dset_name, hid_t fid,
for (k = 0; k < 2; k++) {
if (make_diffs) {
buf33[i][j][k].a = 0;
- buf33[i][j][k].b = 0.0F;
+ buf33[i][j][k].b = 0.0;
}
else {
buf33[i][j][k].a = (char)n++;
@@ -7132,7 +7132,7 @@ write_attr_in(hid_t loc_id, const char *dset_name, hid_t fid,
for (k = 0; k < 2; k++) {
if (make_diffs) {
buf73[i][j][k] = 0;
- buf83[i][j][k] = 0.0F;
+ buf83[i][j][k] = 0.0;
}
else {
buf73[i][j][k] = n++;
@@ -7193,26 +7193,26 @@ write_dset_in(hid_t loc_id, const char *dset_name, hid_t fid,
char buf1[2][STR_SIZE] = {"ab", "de"}; /* string */
char * buf1a[2]; /* VL string */
char buf2[2] = {1, 2}; /* bitfield, opaque */
- s_t buf3[2] = {{1, 2.0F}, {3, 4.0F}}; /* compound */
+ s_t buf3[2] = {{1, 2.0}, {3, 4.0}}; /* compound */
hobj_ref_t buf4[2]; /* reference */
e_t buf45[2] = {RED, GREEN}; /* enum */
hvl_t buf5[2]; /* vlen */
hsize_t dimarray[1] = {3}; /* array dimension */
int buf6[2][3] = {{1, 2, 3}, {4, 5, 6}}; /* array */
int buf7[2] = {1, 2}; /* integer */
- float buf8[2] = {1.0F, 2.0F}; /* float */
+ float buf8[2] = {1.0, 2.0}; /* float */
/* create 2D attributes with dimension [3][2], 6 elements */
- hsize_t dims2[2] = {3, 2};
- char buf12[3][2][STR_SIZE] = {{"ab", "cd"}, {"ef", "gh"}, {"ij", "kl"}}; /* string */
- char * buf12a[3][2]; /* VL string */
- char buf22[3][2] = {{1, 2}, {3, 4}, {5, 6}}; /* bitfield, opaque */
- s_t buf32[6] = {{1, 2.0F}, {3, 4.0F}, {5, 6.0F}, {7, 8.0F}, {9, 10.0F}, {11, 12.0F}}; /* compound */
+ hsize_t dims2[2] = {3, 2};
+ char buf12[3][2][STR_SIZE] = {{"ab", "cd"}, {"ef", "gh"}, {"ij", "kl"}}; /* string */
+ char * buf12a[3][2]; /* VL string */
+ char buf22[3][2] = {{1, 2}, {3, 4}, {5, 6}}; /* bitfield, opaque */
+ s_t buf32[6] = {{1, 2.0}, {3, 4.0}, {5, 6.0}, {7, 8.0}, {9, 10.0}, {11, 12.0}}; /* compound */
hobj_ref_t buf42[3][2]; /* reference */
hvl_t buf52[3][2]; /* vlen */
int buf62[6][3] = {{1, 2, 3}, {4, 5, 6}, {7, 8, 9}, {10, 11, 12}, {13, 14, 15}, {16, 17, 18}}; /* array */
- int buf72[3][2] = {{1, 2}, {3, 4}, {5, 6}}; /* integer */
- float buf82[3][2] = {{1.0F, 2.0F}, {3.0F, 4.0F}, {5.0F, 6.0F}}; /* float */
+ int buf72[3][2] = {{1, 2}, {3, 4}, {5, 6}}; /* integer */
+ float buf82[3][2] = {{1.0, 2.0}, {3.0, 4.0}, {5.0, 6.0}}; /* float */
/* create 3D attributes with dimension [4][3][2], 24 elements */
hsize_t dims3[3] = {4, 3, 2};
@@ -7680,7 +7680,7 @@ write_dset_in(hid_t loc_id, const char *dset_name, hid_t fid,
for (k = 0; k < 2; k++) {
if (make_diffs) {
buf33[i][j][k].a = 0;
- buf33[i][j][k].b = 0.0F;
+ buf33[i][j][k].b = 0.0;
}
else {
buf33[i][j][k].a = (char)n++;
@@ -7778,7 +7778,7 @@ write_dset_in(hid_t loc_id, const char *dset_name, hid_t fid,
for (k = 0; k < 2; k++) {
if (make_diffs) {
buf73[i][j][k] = 0;
- buf83[i][j][k] = 0.0F;
+ buf83[i][j][k] = 0.0;
}
else {
buf73[i][j][k] = n++;
diff --git a/tools/test/h5dump/h5dumpgentest.c b/tools/test/h5dump/h5dumpgentest.c
index a6bf311..261fb09 100644
--- a/tools/test/h5dump/h5dumpgentest.c
+++ b/tools/test/h5dump/h5dumpgentest.c
@@ -498,7 +498,7 @@ gent_dataset(void)
for (i = 0; i < 30; i++)
for (j = 0; j < 20; j++)
- dset2[i][j] = 0.0001F * (float)j + (float)i;
+ dset2[i][j] = 0.0001 * (double)j + (double)i;
H5Dwrite(dataset, H5T_NATIVE_DOUBLE, H5S_ALL, H5S_ALL, H5P_DEFAULT, dset2_data);
@@ -605,7 +605,7 @@ gent_attribute(void)
attr = H5Acreate2(root, "attr3", H5T_IEEE_F64BE, space, H5P_DEFAULT, H5P_DEFAULT);
for (i = 0; i < 10; i++)
- d[i] = 0.1F * (float)i;
+ d[i] = 0.1 * (double)i;
H5Awrite(attr, H5T_NATIVE_DOUBLE, d);
H5Sclose(space);
@@ -1019,7 +1019,7 @@ gent_compound_dt(void)
for (i = 0; i < (int)sdim; i++) {
dset1[i].a = i;
dset1[i].b = (float)(i * i);
- dset1[i].c = (float)(1.0F / (float)(i + 1));
+ dset1[i].c = (double)(1.0 / (double)(i + 1));
dset2[i].a = i;
dset2[i].b = (float)((float)i + (float)i * 0.1F);
@@ -1206,7 +1206,7 @@ gent_compound_dt2(void)
for (i = 0; i < (int)sdim; i++) {
dset1[i].a = i;
dset1[i].b = (float)(i * i);
- dset1[i].c = (float)(1.0F / (float)(i + 1));
+ dset1[i].c = (double)(1.0 / (double)(i + 1));
dset2[i].a = i;
dset2[i].b = (float)((float)i + (float)i * 0.1F);
@@ -1646,7 +1646,7 @@ gent_many(void)
space2 = H5Screate_simple(1, dims, NULL);
attr = H5Acreate2(dataset, "attr3", H5T_IEEE_F64BE, space2, H5P_DEFAULT, H5P_DEFAULT);
for (i = 0; i < 10; i++)
- d[i] = 0.1F * (float)i;
+ d[i] = 0.1 * (double)i;
H5Awrite(attr, H5T_NATIVE_DOUBLE, d);
H5Sclose(space2);
H5Aclose(attr);
@@ -2503,7 +2503,7 @@ gent_nestcomp(void)
for (i = 0; i < 10; i++) {
s1[i].a = i;
s1[i].b = (float)(i * i);
- s1[i].c = 1.0F / (float)(i + 1);
+ s1[i].c = 1.0 / (double)(i + 1);
s1[i].d.a = (char)(65 + i);
s1[i].d.b[0] = -100.0F;
s1[i].d.b[1] = 100.0F;
@@ -5077,7 +5077,7 @@ gent_compound_complex(void)
Array1[m].e = (float)((float)m * 0.96F);
for (n = 0; n < F41_ARRAY_DIMf; n++)
- Array1[m].f[n] = ((float)m * 1024.9637F);
+ Array1[m].f[n] = ((double)m * 1024.9637);
Array1[m].g = 'm';
}
@@ -6361,7 +6361,7 @@ gent_ldouble_scalar(void)
hid_t tid;
hid_t sid;
hsize_t dims[1] = {6};
- long double buf[6] = {0.0, 1.0, 2.0, 3.0, 4.0, 5.0};
+ long double buf[6] = {0.0L, 1.0L, 2.0L, 3.0L, 4.0L, 5.0L};
if ((fid = H5Fcreate(FILE88, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
goto error;
@@ -7022,7 +7022,7 @@ gent_fpformat(void)
{
hid_t fid, sid, did;
hsize_t dims[1] = {6};
- double dbuf[6] = {-0.1234567f, 0.1234567f, 0, 0, 0, 0};
+ double dbuf[6] = {-0.1234567, 0.1234567, 0, 0, 0, 0};
float fbuf[6] = {-0.1234567f, 0.1234567f, 0, 0, 0, 0};
fid = H5Fcreate(FILE60, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT);
@@ -7450,7 +7450,7 @@ gent_packedbits(void)
for (i = 0; i < dims[0]; i++)
for (j = 0; j < dims[1]; j++)
- dsetdbl[i][j] = 0.0001F * (float)j + (float)i;
+ dsetdbl[i][j] = 0.0001 * (double)j + (double)i;
H5Dwrite(dataset, H5T_NATIVE_DOUBLE, H5S_ALL, H5S_ALL, H5P_DEFAULT, dsetdbl[0]);
@@ -7684,7 +7684,7 @@ gent_attr_intsize(void)
for (i = 0; i < dims[0]; i++)
for (j = 0; j < dims[1]; j++)
- dsetdbl[i][j] = 0.0001F * (float)j + (float)i;
+ dsetdbl[i][j] = 0.0001 * (double)j + (double)i;
H5Awrite(attr, H5T_NATIVE_DOUBLE, dsetdbl[0]);
@@ -7994,7 +7994,7 @@ gent_compound_intsizes(void)
for (n = 0; n < (int)dims[0]; n++)
for (o = 0; o < (int)dims[1]; o++)
- Array1[m].dsetdbl[n][o] = 0.0001F * (float)o + (float)n;
+ Array1[m].dsetdbl[n][o] = 0.0001 * (double)o + (double)n;
}
/* Create the array data type for the 8 bits signed int array */
@@ -8284,7 +8284,7 @@ gent_compound_attr_intsizes(void)
for (n = 0; n < (int)dims[0]; n++)
for (o = 0; o < (int)dims[1]; o++)
- Array1[m].dsetdbl[n][o] = 0.0001F * (float)o + (float)n;
+ Array1[m].dsetdbl[n][o] = 0.0001 * (double)o + (double)n;
}
/* Create the array data type for the 8 bits signed int array */
@@ -8789,7 +8789,7 @@ gent_intscalars(void)
for (i = 0; i < dims[0]; i++)
for (j = 0; j < dims[1]; j++)
- dsetdbl[i][j] = 0.0001F * (float)j + (float)i;
+ dsetdbl[i][j] = 0.0001 * (double)j + (double)i;
H5Dwrite(dataset, tid, H5S_ALL, H5S_ALL, H5P_DEFAULT, dsetdbl[0]);
@@ -9033,7 +9033,7 @@ gent_attr_intscalars(void)
for (i = 0; i < dims[0]; i++)
for (j = 0; j < dims[1]; j++)
- dsetdbl[i][j] = 0.0001F * (float)j + (float)i;
+ dsetdbl[i][j] = 0.0001 * (double)j + (double)i;
H5Awrite(attr, tid, dsetdbl[0]);
@@ -9236,7 +9236,7 @@ gent_compound_int_array(void)
dims[0] = F76_DIM8;
for (n = 0; n < (int)dims[0]; n++)
- Cmpd1[m].dsetdbl[n] = 0.0001F + (float)n;
+ Cmpd1[m].dsetdbl[n] = 0.0001 + (double)n;
}
/* Create the array data type for the 8 bits signed int array */
@@ -9477,8 +9477,8 @@ gent_compound_ints(void)
val64bits <<= 1;
/* Double Dummy set for failure tests */
- Cmpd1[m].dsetdbl = 0.0001F + (float)m;
- Cmpd2[m].dsetdbl = 0.0001F + (float)m;
+ Cmpd1[m].dsetdbl = 0.0001 + (double)m;
+ Cmpd2[m].dsetdbl = 0.0001 + (double)m;
}
/* Create the dataspace */
@@ -9853,7 +9853,7 @@ gent_intattrscalars(void)
for (i = 0; i < dims[0]; i++)
for (j = 0; j < dims[1]; j++)
- dsetdbl[i][j] = 0.0001F * (float)j + (float)i;
+ dsetdbl[i][j] = 0.0001 * (double)j + (double)i;
H5Dwrite(dataset, tid, H5S_ALL, H5S_ALL, H5P_DEFAULT, dsetdbl);
/* Attribute of double */
@@ -10182,7 +10182,7 @@ gent_intsattrs(void)
for (i = 0; i < dims[0]; i++)
for (j = 0; j < dims[1]; j++) {
- dsetdbl[i][j] = 0.0001F * (float)j + (float)i;
+ dsetdbl[i][j] = 0.0001 * (double)j + (double)i;
asetdbl[i * dims[1] + j] = dsetdbl[i][j];
}
diff --git a/tools/test/perform/chunk_cache.c b/tools/test/perform/chunk_cache.c
index b515961..ad9bf09 100644
--- a/tools/test/perform/chunk_cache.c
+++ b/tools/test/perform/chunk_cache.c
@@ -39,7 +39,7 @@
#define RDCC_NSLOTS 5
#define RDCC_NBYTES (1024 * 1024 * 10)
-#define RDCC_W0 0.75F
+#define RDCC_W0 0.75
#define FILTER_COUNTER 306
static size_t nbytes_global;
diff --git a/tools/test/perform/overhead.c b/tools/test/perform/overhead.c
index dba8220..2687ce9 100644
--- a/tools/test/perform/overhead.c
+++ b/tools/test/perform/overhead.c
@@ -193,7 +193,7 @@ test(fill_t fill_style, const double splits[], hbool_t verbose, hbool_t use_rdcc
if (!use_rdcc) {
if (H5Pget_cache(fapl, &mdc_nelmts, NULL, NULL, NULL) < 0)
goto error;
- if (H5Pset_cache(fapl, mdc_nelmts, 0, 0, 0.0F) < 0)
+ if (H5Pset_cache(fapl, mdc_nelmts, 0, 0, 0.0) < 0)
goto error;
}
if ((file = H5Fcreate(FILE_NAME_1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0)
diff --git a/tools/test/perform/zip_perf.c b/tools/test/perform/zip_perf.c
index d8cd3a1..123fb98 100644
--- a/tools/test/perform/zip_perf.c
+++ b/tools/test/perform/zip_perf.c
@@ -396,7 +396,7 @@ do_write_test(unsigned long file_size, unsigned long min_buf_size, unsigned long
error("out of memory");
}
- compression_time = 0.0F;
+ compression_time = 0.0;
if (random_test)
fill_with_random_data(src, src_len);