summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rw-r--r--tools/lib/h5diff_array.c180
-rw-r--r--tools/src/h5import/h5import.c2
-rw-r--r--tools/src/h5repack/h5repack_main.c12
-rw-r--r--tools/test/perform/pio_engine.c14
-rw-r--r--tools/test/perform/sio_engine.c5
5 files changed, 112 insertions, 101 deletions
diff --git a/tools/lib/h5diff_array.c b/tools/lib/h5diff_array.c
index 6667b01..52bae51 100644
--- a/tools/lib/h5diff_array.c
+++ b/tools/lib/h5diff_array.c
@@ -155,7 +155,7 @@ static void print_char_pos(int *ph, int pp, hsize_t curr_pos, size_t u,
hsize_t *acc, hsize_t *pos, int rank, hsize_t *dims, const char *obj1,
const char *obj2);
static void h5diff_print_char(char ch);
-static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
+static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t idx,
int rank, hsize_t *dims, hsize_t *acc, hsize_t *pos,
diff_opt_t *opts, const char *obj1, const char *obj2,
hid_t container1_id, hid_t container2_id, /*where the reference came from*/
@@ -408,9 +408,11 @@ hsize_t diff_array(void *_mem1, void *_mem2, hsize_t nelmts, hsize_t hyper_start
* Dereference the object and compare the type (basic object type).
*-------------------------------------------------------------------------
*/
-static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index, int rank,
- hsize_t *dims, hsize_t *acc, hsize_t *pos, diff_opt_t *opts, const char *obj1, const char *obj2,
- hid_t container1_id, hid_t container2_id,
+static hsize_t
+diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t idx, int rank,
+ hsize_t *dims, hsize_t *acc, hsize_t *pos, diff_opt_t *opts,
+ const char *obj1, const char *obj2,
+ hid_t container1_id, hid_t container2_id,
int *ph, /*print header */
mcomp_t *members) /*compound members */
{
@@ -470,7 +472,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
offset = members->offsets[j];
memb_type = members->ids[j];
- nfound += diff_datum(mem1 + offset, mem2 + offset, memb_type, index,
+ nfound += diff_datum(mem1 + offset, mem2 + offset, memb_type, idx,
rank, dims, acc, pos, opts, obj1, obj2, container1_id, container2_id, ph, members->m[j]);
}
}
@@ -574,11 +576,11 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (size1 != size2)
if (print_data(opts))
for (u = size; u < sizex; u++)
- character_compare(s + u, sx + u, index, u, rank, dims, acc, pos, opts, obj1, obj2, ph);
+ character_compare(s + u, sx + u, idx, u, rank, dims, acc, pos, opts, obj1, obj2, ph);
}
else
for (u = 0; u < size; u++)
- nfound += character_compare(s + u, sx + u, index, u, rank, dims, acc, pos, opts, obj1, obj2, ph);
+ nfound += character_compare(s + u, sx + u, idx, u, rank, dims, acc, pos, opts, obj1, obj2, ph);
} /* end check for NULL pointer for string */
}
break;
@@ -591,7 +593,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
H5TOOLS_DEBUG("diff_datum H5T_BITFIELD");
/* byte-by-byte comparison */
for (u = 0; u < type_size; u++)
- nfound += character_compare_opt(mem1 + u, mem2 + u, index, rank, dims, acc, pos, opts, obj1, obj2, ph);
+ nfound += character_compare_opt(mem1 + u, mem2 + u, idx, rank, dims, acc, pos, opts, obj1, obj2, ph);
break;
/*-------------------------------------------------------------------------
@@ -602,7 +604,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
H5TOOLS_DEBUG("diff_datum H5T_OPAQUE");
/* byte-by-byte comparison */
for (u = 0; u < type_size; u++)
- nfound += character_compare_opt(mem1 + u, mem2 + u, index, rank, dims, acc, pos, opts, obj1, obj2, ph);
+ nfound += character_compare_opt(mem1 + u, mem2 + u, idx, rank, dims, acc, pos, opts, obj1, obj2, ph);
break;
/*-------------------------------------------------------------------------
@@ -643,7 +645,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
*/
nfound += 1;
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(S_FORMAT, enum_name1, enum_name2);
}
@@ -653,14 +655,14 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (HDstrcmp(enum_name1, enum_name2) != 0) {
nfound = 1;
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(S_FORMAT, enum_name1, enum_name2);
}
}
else {
for (u = 0; u < type_size; u++)
- nfound += character_compare_opt(mem1 + u, mem2 + u, index, rank, dims, acc, pos, opts, obj1, obj2, ph);
+ nfound += character_compare_opt(mem1 + u, mem2 + u, idx, rank, dims, acc, pos, opts, obj1, obj2, ph);
}
}
/* enable error reporting */
@@ -690,7 +692,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
for (u = 0, nelmts = 1; u < (unsigned) ndims; u++)
nelmts *= adims[u];
for (u = 0; u < nelmts; u++) {
- nfound += diff_datum(mem1 + u * size, mem2 + u * size, memb_type, index,
+ nfound += diff_datum(mem1 + u * size, mem2 + u * size, memb_type, idx,
rank, dims, acc, pos, opts, obj1, obj2, container1_id, container2_id, ph, members);
}
H5Tclose(memb_type);
@@ -1100,7 +1102,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
nelmts = ((hvl_t *)((void *)mem1))->len;
for (j = 0; j < nelmts; j++)
- nfound += diff_datum(((char *) (((hvl_t *)((void *)mem1))->p)) + j * size, ((char *) (((hvl_t *)((void *)mem2))->p)) + j * size, memb_type, index, /* Extra (void *) cast to quiet "cast to create alignment" warning - 2019/07/05, QAK */
+ nfound += diff_datum(((char *) (((hvl_t *)((void *)mem1))->p)) + j * size, ((char *) (((hvl_t *)((void *)mem2))->p)) + j * size, memb_type, idx, /* Extra (void *) cast to quiet "cast to create alignment" warning - 2019/07/05, QAK */
rank, dims, acc, pos, opts, obj1, obj2, container1_id, container2_id, ph, members);
H5Tclose(memb_type);
@@ -1130,7 +1132,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (opts->d && !opts->p) {
if (ABS(temp1_char-temp2_char) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT, temp1_char, temp2_char, ABS(temp1_char - temp2_char));
}
@@ -1143,7 +1145,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P_NOTCOMP, temp1_char, temp2_char, ABS(temp1_char - temp2_char));
}
@@ -1151,7 +1153,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P, temp1_char, temp2_char, ABS(temp1_char - temp2_char), per);
}
@@ -1164,7 +1166,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P_NOTCOMP, temp1_char, temp2_char, ABS(temp1_char - temp2_char));
}
@@ -1172,7 +1174,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent && ABS(temp1_char - temp2_char) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P, temp1_char, temp2_char, ABS(temp1_char - temp2_char), per);
}
@@ -1181,7 +1183,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (temp1_char != temp2_char) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT, temp1_char, temp2_char, ABS(temp1_char - temp2_char));
}
@@ -1206,7 +1208,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (opts->d && !opts->p) {
if (PDIFF(temp1_uchar, temp2_uchar) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT, temp1_uchar, temp2_uchar, PDIFF(temp1_uchar, temp2_uchar));
}
@@ -1219,7 +1221,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P_NOTCOMP, temp1_uchar, temp2_uchar, PDIFF(temp1_uchar, temp2_uchar));
}
@@ -1227,7 +1229,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P, temp1_uchar, temp2_uchar, PDIFF(temp1_uchar, temp2_uchar), per);
}
@@ -1240,7 +1242,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P_NOTCOMP, temp1_uchar, temp2_uchar, PDIFF(temp1_uchar, temp2_uchar));
}
@@ -1248,7 +1250,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent && PDIFF(temp1_uchar, temp2_uchar) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P, temp1_uchar, temp2_uchar, PDIFF(temp1_uchar, temp2_uchar), per);
}
@@ -1257,7 +1259,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (temp1_uchar != temp2_uchar) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT, temp1_uchar, temp2_uchar, PDIFF(temp1_uchar, temp2_uchar));
}
@@ -1282,7 +1284,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (opts->d && !opts->p) {
if (ABS(temp1_short - temp2_short) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT, temp1_short, temp2_short, ABS(temp1_short - temp2_short));
}
@@ -1295,7 +1297,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P_NOTCOMP, temp1_short, temp2_short, ABS(temp1_short - temp2_short));
}
@@ -1303,7 +1305,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P, temp1_short, temp2_short, ABS(temp1_short - temp2_short), per);
}
@@ -1316,7 +1318,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P_NOTCOMP, temp1_short, temp2_short, ABS(temp1_short - temp2_short));
}
@@ -1324,7 +1326,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent && ABS(temp1_short - temp2_short) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P, temp1_short, temp2_short, ABS(temp1_short - temp2_short), per);
}
@@ -1333,7 +1335,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (temp1_short != temp2_short) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT, temp1_short, temp2_short, ABS(temp1_short - temp2_short));
}
@@ -1358,7 +1360,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (opts->d && !opts->p) {
if (PDIFF(temp1_ushort, temp2_ushort) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT, temp1_ushort, temp2_ushort, PDIFF(temp1_ushort, temp2_ushort));
}
@@ -1371,7 +1373,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P_NOTCOMP, temp1_ushort, temp2_ushort, PDIFF(temp1_ushort, temp2_ushort));
}
@@ -1379,7 +1381,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P, temp1_ushort, temp2_ushort, PDIFF(temp1_ushort, temp2_ushort), per);
}
@@ -1392,7 +1394,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P_NOTCOMP, temp1_ushort, temp2_ushort, PDIFF(temp1_ushort, temp2_ushort));
}
@@ -1400,7 +1402,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent && PDIFF(temp1_ushort, temp2_ushort) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P, temp1_ushort, temp2_ushort, PDIFF(temp1_ushort, temp2_ushort), per);
}
@@ -1409,7 +1411,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (temp1_ushort != temp2_ushort) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT, temp1_ushort, temp2_ushort, PDIFF(temp1_ushort, temp2_ushort));
}
@@ -1434,7 +1436,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (opts->d && !opts->p) {
if (ABS(temp1_int-temp2_int) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT, temp1_int, temp2_int, ABS(temp1_int - temp2_int));
}
@@ -1447,7 +1449,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P_NOTCOMP, temp1_int, temp2_int, ABS(temp1_int - temp2_int));
}
@@ -1455,7 +1457,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P, temp1_int, temp2_int, ABS(temp1_int - temp2_int), per);
}
@@ -1468,7 +1470,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P_NOTCOMP, temp1_int, temp2_int, ABS(temp1_int - temp2_int));
}
@@ -1476,7 +1478,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent && ABS(temp1_int - temp2_int) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P, temp1_int, temp2_int, ABS(temp1_int - temp2_int), per);
}
@@ -1485,7 +1487,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (temp1_int != temp2_int) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT, temp1_int, temp2_int, ABS(temp1_int - temp2_int));
}
@@ -1510,7 +1512,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (opts->d && !opts->p) {
if (PDIFF(temp1_uint, temp2_uint) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(UI_FORMAT, temp1_uint, temp2_uint, PDIFF(temp1_uint, temp2_uint));
}
@@ -1523,7 +1525,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(UI_FORMAT_P_NOTCOMP, temp1_uint, temp2_uint, PDIFF(temp1_uint, temp2_uint));
}
@@ -1531,7 +1533,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(UI_FORMAT_P, temp1_uint, temp2_uint, PDIFF(temp1_uint, temp2_uint), per);
}
@@ -1544,7 +1546,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(UI_FORMAT_P_NOTCOMP, temp1_uint, temp2_uint, PDIFF(temp1_uint, temp2_uint));
}
@@ -1552,7 +1554,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent && PDIFF(temp1_uint,temp2_uint) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(UI_FORMAT_P, temp1_uint, temp2_uint, PDIFF(temp1_uint, temp2_uint), per);
}
@@ -1561,7 +1563,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (temp1_uint != temp2_uint) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(UI_FORMAT, temp1_uint, temp2_uint, PDIFF(temp1_uint, temp2_uint));
}
@@ -1586,7 +1588,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (opts->d && !opts->p) {
if (ABS(temp1_long-temp2_long) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(LI_FORMAT, temp1_long, temp2_long, ABS(temp1_long - temp2_long));
}
@@ -1599,7 +1601,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(LI_FORMAT_P_NOTCOMP, temp1_long, temp2_long, ABS(temp1_long - temp2_long));
}
@@ -1607,7 +1609,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(LI_FORMAT_P, temp1_long, temp2_long, ABS(temp1_long - temp2_long), per);
}
@@ -1620,7 +1622,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(LI_FORMAT_P_NOTCOMP, temp1_long, temp2_long, ABS(temp1_long - temp2_long));
}
@@ -1628,7 +1630,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent && ABS(temp1_long-temp2_long) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(LI_FORMAT_P, temp1_long, temp2_long, ABS(temp1_long - temp2_long), per);
}
@@ -1637,7 +1639,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (temp1_long != temp2_long) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(LI_FORMAT, temp1_long, temp2_long, ABS(temp1_long - temp2_long));
}
@@ -1662,7 +1664,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (opts->d && !opts->p) {
if (PDIFF(temp1_ulong, temp2_ulong) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(ULI_FORMAT, temp1_ulong, temp2_ulong, PDIFF(temp1_ulong, temp2_ulong));
}
@@ -1675,7 +1677,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(ULI_FORMAT_P_NOTCOMP, temp1_ulong, temp2_ulong, PDIFF(temp1_ulong, temp2_ulong));
}
@@ -1683,7 +1685,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(ULI_FORMAT_P, temp1_ulong, temp2_ulong, PDIFF(temp1_ulong, temp2_ulong), per);
}
@@ -1696,7 +1698,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(ULI_FORMAT_P_NOTCOMP, temp1_ulong, temp2_ulong, PDIFF(temp1_ulong, temp2_ulong));
}
@@ -1704,7 +1706,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent && PDIFF(temp1_ulong,temp2_ulong) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(ULI_FORMAT_P, temp1_ulong, temp2_ulong, PDIFF(temp1_ulong, temp2_ulong), per);
}
@@ -1713,7 +1715,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (temp1_ulong != temp2_ulong) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(ULI_FORMAT, temp1_ulong, temp2_ulong, PDIFF(temp1_ulong, temp2_ulong));
}
@@ -1764,7 +1766,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (!isnan1 && !isnan2) {
if (ABS(temp1_float-temp2_float) > (float) opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT, (double) temp1_float, (double) temp2_float, (double) ABS(temp1_float - temp2_float));
}
@@ -1774,7 +1776,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
/* only one is NaN, assume difference */
else if ((isnan1 && !isnan2) || (!isnan1 && isnan2)) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT, (double) temp1_float, (double) temp2_float, (double) ABS(temp1_float - temp2_float));
}
@@ -1801,7 +1803,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT_P_NOTCOMP, (double) temp1_float, (double) temp2_float, (double) ABS(temp1_float - temp2_float));
}
@@ -1809,7 +1811,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent && (double) ABS(temp1_float - temp2_float) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT_P, (double) temp1_float, (double) temp2_float,
(double) ABS(temp1_float - temp2_float), (double) ABS(1 - temp2_float / temp1_float));
@@ -1820,7 +1822,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
/* only one is NaN, assume difference */
else if ((isnan1 && !isnan2) || (!isnan1 && isnan2)) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT, (double) temp1_float, (double) temp2_float, (double) ABS(temp1_float - temp2_float));
}
@@ -1847,7 +1849,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT_P_NOTCOMP, (double) temp1_float, (double) temp2_float, (double) ABS(temp1_float - temp2_float));
}
@@ -1855,7 +1857,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT_P, (double) temp1_float, (double) temp2_float,
(double) ABS(temp1_float - temp2_float), (double) ABS(1 - temp2_float / temp1_float));
@@ -1866,7 +1868,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
/* only one is NaN, assume difference */
else if ((isnan1 && !isnan2) || (!isnan1 && isnan2)) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT, (double) temp1_float, (double) temp2_float, (double) ABS(temp1_float - temp2_float));
}
@@ -1879,7 +1881,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
*/
else if (equal_float(temp1_float, temp2_float, opts) == FALSE) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT, (double) temp1_float, (double) temp2_float, (double) ABS(temp1_float - temp2_float));
}
@@ -1922,7 +1924,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (!isnan1 && !isnan2) {
if (ABS(temp1_double-temp2_double) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
@@ -1932,7 +1934,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
/* only one is NaN, assume difference */
else if ((isnan1 && !isnan2) || (!isnan1 && isnan2)) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
@@ -1959,7 +1961,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT_P_NOTCOMP, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
@@ -1967,7 +1969,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT_P, temp1_double, temp2_double, ABS(temp1_double - temp2_double), ABS(1 - temp2_double / temp1_double));
}
@@ -1977,7 +1979,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
/* only one is NaN, assume difference */
else if ((isnan1 && !isnan2) || (!isnan1 && isnan2)) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
@@ -2004,7 +2006,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT_P_NOTCOMP, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
@@ -2013,7 +2015,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
else if (per > opts->percent &&
ABS(temp1_double-temp2_double) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT_P, temp1_double, temp2_double, ABS(temp1_double - temp2_double), ABS(1 - temp2_double / temp1_double));
}
@@ -2023,7 +2025,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
/* only one is NaN, assume difference */
else if ((isnan1 && !isnan2) || (!isnan1 && isnan2)) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
@@ -2036,7 +2038,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
*/
else if (equal_double(temp1_double, temp2_double, opts) == FALSE) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
@@ -2083,7 +2085,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (!isnan1 && !isnan2) {
if (ABS(temp1_double-temp2_double) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(LD_FORMAT, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
@@ -2093,7 +2095,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
/* only one is NaN, assume difference */
else if ((isnan1 && !isnan2) || (!isnan1 && isnan2)) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
@@ -2120,7 +2122,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(LD_FORMAT_P_NOTCOMP, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
@@ -2128,7 +2130,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(LD_FORMAT_P, temp1_double, temp2_double, ABS(temp1_double - temp2_double), ABS(1 - temp2_double / temp1_double));
}
@@ -2138,7 +2140,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
/* only one is NaN, assume difference */
else if ((isnan1 && !isnan2) || (!isnan1 && isnan2)) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
@@ -2165,7 +2167,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
if (not_comparable && !both_zero) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(LD_FORMAT_P_NOTCOMP, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
@@ -2173,7 +2175,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
}
else if (per > opts->percent && ABS(temp1_double-temp2_double) > opts->delta) {
if (print_data(opts)) {
- print_pos(ph, 1, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 1, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(LD_FORMAT_P, temp1_double, temp2_double, ABS(temp1_double - temp2_double), ABS(1 - temp2_double / temp1_double));
}
@@ -2183,7 +2185,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
/* only one is NaN, assume difference */
else if ((isnan1 && !isnan2) || (!isnan1 && isnan2)) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(F_FORMAT, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
@@ -2196,7 +2198,7 @@ static hsize_t diff_datum(void *_mem1, void *_mem2, hid_t m_type, hsize_t index,
*/
else if (equal_ldouble(temp1_double, temp2_double, opts) == FALSE) {
if (print_data(opts)) {
- print_pos(ph, 0, index, acc, pos, rank, dims, obj1, obj2);
+ print_pos(ph, 0, idx, acc, pos, rank, dims, obj1, obj2);
parallel_print(SPACES);
parallel_print(LD_FORMAT, temp1_double, temp2_double, ABS(temp1_double - temp2_double));
}
diff --git a/tools/src/h5import/h5import.c b/tools/src/h5import/h5import.c
index 00fe7cf..f87f371 100644
--- a/tools/src/h5import/h5import.c
+++ b/tools/src/h5import/h5import.c
@@ -1428,7 +1428,7 @@ static int processConfigurationFile(char *infile, struct Input *in)
/* Initialize machine endian */
volatile uint32_t ibyte=0x01234567;
/* 0 for big endian, 1 for little endian. */
- if ((*((uint8_t*)(&ibyte))) == 0x67) {
+ if ((*((volatile uint8_t*)(&ibyte))) == 0x67) {
if ((kindex = OutputByteOrderStrToInt("LE")) == -1) {
(void) HDfprintf(stderr, "%s", err11e);
return (-1);
diff --git a/tools/src/h5repack/h5repack_main.c b/tools/src/h5repack/h5repack_main.c
index ea6b0e1..72ed7d7 100644
--- a/tools/src/h5repack/h5repack_main.c
+++ b/tools/src/h5repack/h5repack_main.c
@@ -411,7 +411,7 @@ set_sort_order(const char *form)
static
int parse_command_line(int argc, const char **argv, pack_opt_t* options)
{
- int opt;
+ int bound, opt;
int ret_value = 0;
/* parse command line options */
@@ -491,19 +491,21 @@ int parse_command_line(int argc, const char **argv, pack_opt_t* options)
break;
case 'j':
- options->low_bound = (H5F_libver_t)HDatoi(opt_arg);
- if (options->low_bound < H5F_LIBVER_EARLIEST || options->low_bound > H5F_LIBVER_LATEST) {
+ bound = HDatoi(opt_arg);
+ if (bound < H5F_LIBVER_EARLIEST || bound > H5F_LIBVER_LATEST) {
error_msg("in parsing low bound\n");
goto done;
}
+ options->low_bound = bound;
break;
case 'k':
- options->high_bound = (H5F_libver_t)HDatoi(opt_arg);
- if (options->high_bound < H5F_LIBVER_EARLIEST || options->high_bound > H5F_LIBVER_LATEST) {
+ bound = HDatoi(opt_arg);
+ if (bound < H5F_LIBVER_EARLIEST || bound > H5F_LIBVER_LATEST) {
error_msg("in parsing high bound\n");
goto done;
}
+ options->high_bound = bound;
break;
case 'c':
diff --git a/tools/test/perform/pio_engine.c b/tools/test/perform/pio_engine.c
index 3863550..cdd698e 100644
--- a/tools/test/perform/pio_engine.c
+++ b/tools/test/perform/pio_engine.c
@@ -129,6 +129,7 @@ static herr_t do_fopen(parameters *param, char *fname, file_descr *fd /*out*/,
int flags);
static herr_t do_fclose(iotype iot, file_descr *fd);
static void do_cleanupfile(iotype iot, char *fname);
+static off_t sqrto(off_t);
/*
* Function: do_pio
@@ -199,7 +200,7 @@ do_pio(parameters param)
bsize = buf_size; /* Actual buffer size */
}
else {
- snbytes = (off_t)sqrt((double)nbytes); /* General dataset size */
+ snbytes = sqrto(nbytes); /* General dataset size */
bsize = buf_size * blk_size; /* Actual buffer size */
}
@@ -596,7 +597,7 @@ do_write(results *res, file_descr *fd, parameters *parms, long ndsets,
/* nbytes is always the number of bytes per dataset (1D or 2D). If the
dataspace is 2D, snbytes is the size of a side of the dataset square.
*/
- snbytes = (off_t)sqrt((double)nbytes);
+ snbytes = sqrto(nbytes);
/* Contiguous Pattern: */
if (!parms->interleaved) {
@@ -1489,6 +1490,13 @@ done:
return ret_code;
}
+static off_t
+sqrto(off_t x)
+{
+ double root_x = sqrt((double)x);
+ return (off_t)root_x;
+}
+
/*
* Function: do_read
* Purpose: read the required amount of data from the file.
@@ -1581,7 +1589,7 @@ do_read(results *res, file_descr *fd, parameters *parms, long ndsets,
/* nbytes is always the number of bytes per dataset (1D or 2D). If the
dataspace is 2D, snbytes is the size of a side of the 'dataset square'.
*/
- snbytes = (off_t)sqrt((double)nbytes);
+ snbytes = sqrto(nbytes);
bsize = buf_size * blk_size;
diff --git a/tools/test/perform/sio_engine.c b/tools/test/perform/sio_engine.c
index 69409bb..9ea94cb 100644
--- a/tools/test/perform/sio_engine.c
+++ b/tools/test/perform/sio_engine.c
@@ -1268,8 +1268,7 @@ done:
* 'temp' in the code below, but early (4.4.7, at least) gcc only
* allows diagnostic pragmas to be toggled outside of functions.
*/
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wformat-nonliteral"
+H5_GCC_DIAG_OFF(format-nonliteral)
static void
do_cleanupfile(iotype iot, char *filename)
{
@@ -1331,5 +1330,5 @@ do_cleanupfile(iotype iot, char *filename)
}
}
}
-#pragma GCC diagnostic pop
+H5_GCC_DIAG_ON(format-nonliteral)