From: Matthias Maier Date: Sat, 24 Jun 2023 23:56:34 +0000 (-0500) Subject: Test: lac/linear_operator_10: disable floating point exceptions X-Git-Tag: v9.5.0-rc1~28^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2a86ae95e487560e5c035031b767ac779fb77540;p=dealii.git Test: lac/linear_operator_10: disable floating point exceptions --- diff --git a/tests/lac/linear_operator_10.cc b/tests/lac/linear_operator_10.cc index a489fd7f14..79263104b7 100644 --- a/tests/lac/linear_operator_10.cc +++ b/tests/lac/linear_operator_10.cc @@ -50,6 +50,16 @@ test_preconditioner(const MATRIX & A, const VECTOR & b, const ADDITIONAL_DATA &data = ADDITIONAL_DATA()) { + // This test might trigger spurious floating point exceptions in Trilinos + // despite functioning properly. Simply disable floating point exceptions + // again (after they had been enabled int tests.h). +#if defined(DEBUG) && defined(DEAL_II_HAVE_FP_EXCEPTIONS) + { + const int current_fe_except = fegetexcept(); + fedisableexcept(current_fe_except); + } +#endif + const auto lo_A = linear_operator(A); // Note: The above should be equivalent to the following: //