diff options
author | Kimmy Mu <kmu@hdfgroup.org> | 2020-01-23 02:59:49 (GMT) |
---|---|---|
committer | kmu <kmu@hdfgroup.org> | 2020-01-28 02:43:34 (GMT) |
commit | a4f163c7c6b562509f403f602a8fb09f7b1124ec (patch) | |
tree | 3145033970717b9bc630ecd32b960047e3e00190 /tools/test | |
parent | 2cd1e08d7007b6669418c0c85278876d81946660 (diff) | |
download | hdf5-a4f163c7c6b562509f403f602a8fb09f7b1124ec.zip hdf5-a4f163c7c6b562509f403f602a8fb09f7b1124ec.tar.gz hdf5-a4f163c7c6b562509f403f602a8fb09f7b1124ec.tar.bz2 |
Merge pull request #2295 in HDFFV/hdf5 from ~KMU/hdf5:bugfix/float to develop
* commit '9afaf94bef740f89958a1a8aae369d5f607845f4':
not use hdf5 private header
fix float type cmp warning
fix float type cmp warning
Diffstat (limited to 'tools/test')
-rw-r--r-- | tools/test/perform/pio_perf.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tools/test/perform/pio_perf.c b/tools/test/perform/pio_perf.c index 5977731..1a40f44 100644 --- a/tools/test/perform/pio_perf.c +++ b/tools/test/perform/pio_perf.c @@ -80,8 +80,12 @@ #define PIO_MPI 0x2 #define PIO_HDF5 0x4 +#define DBL_EPSILON 2.2204460492503131e-16 +#define H5_DBL_ABS_EQUAL(X,Y) (fabsf((X)-(Y)) < DBL_EPSILON) + /* report 0.0 in case t is zero too */ #define MB_PER_SEC(bytes,t) (((t)==0.0) ? 0.0 : ((((double)bytes) / ONE_MB) / (t))) +#define MB_PER_SEC(bytes,t) (H5_DBL_ABS_EQUAL((t), 0.0) ? 0.0 : ((((double)bytes) / ONE_MB) / (t))) #ifndef TRUE #define TRUE 1 |