From: David Wells Date: Mon, 13 May 2019 21:03:37 +0000 (-0400) Subject: Disable floating point exceptions in two HDF5 tests. X-Git-Tag: v9.1.0-rc1~15^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f63a0cd6333858187ba8fc3ea81dd10e26b1e8d7;p=dealii.git Disable floating point exceptions in two HDF5 tests. --- diff --git a/tests/base/hdf5_03.cc b/tests/base/hdf5_03.cc index ef496fc72b..604f4d4083 100644 --- a/tests/base/hdf5_03.cc +++ b/tests/base/hdf5_03.cc @@ -754,6 +754,16 @@ read_test(HDF5::Group root_group, int main(int argc, char **argv) { + // tests.h enables floating point exceptions in debug mode, but this test + // generates an (irrelevant) exception when run with more than one MPI + // process so disable them again: +#if defined(DEBUG) && defined(DEAL_II_HAVE_FP_EXCEPTIONS) + { + const int current_fe_except = fegetexcept(); + fedisableexcept(current_fe_except); + } +#endif + initlog(); try diff --git a/tests/base/hdf5_05.cc b/tests/base/hdf5_05.cc index e42b1dde56..86635f11a1 100644 --- a/tests/base/hdf5_05.cc +++ b/tests/base/hdf5_05.cc @@ -1394,6 +1394,16 @@ read_test(HDF5::Group root_group, int main(int argc, char **argv) { + // tests.h enables floating point exceptions in debug mode, but this test + // generates an (irrelevant) exception when run with more than one MPI + // process so disable them again: +#if defined(DEBUG) && defined(DEAL_II_HAVE_FP_EXCEPTIONS) + { + const int current_fe_except = fegetexcept(); + fedisableexcept(current_fe_except); + } +#endif + initlog(); try