Failing tests with -ffast-math -funsafe-math-optimizations
@ggael
Submitted by Gael GuennebaudAssigned to Nobody
Link to original bugzilla bug (#1686)
Version: 3.4 (development)
Description
For the record, I tried gcc7 with -ffast-math -funsafe-math-optimizations and here is what I got (number in parenthesis are line numbers):
33 - packetmath_1 (464) (numext::isnan)(data2[0])
34 - packetmath_2 (678) internal::predux_any(internal::pload<Packet>(data1)) && "internal::predux_any(0101)"
217 - array_cwise_4 (452) (Eigen::isinf)(m4/zero).all()
337 - stable_norm_3 (219) (numext::isnan)(numext::hypot(nan,a))
338 - stable_norm_4 "
339 - stable_norm_5 (216) verifyIsApprox(numext::hypot(big,big), sqrt2*numext::abs(big))
340 - stable_norm_6 "
341 - stable_norm_1 (94) !(numext::isfinite)(sqrt(-abs(big)))
342 - stable_norm_2 "
380 - inverse_7 (80) verifyIsApprox(m1, m2.inverse())
424 - schur_real_1 (97) test_is_equal(rsNaN.info(), NoConvergence, true)
427 - schur_real_4 "
436 - eigensolver_selfadjoint_13 (174) test_is_equal(eiSymmNaN.info(), NoConvergence, true)
437 - eigensolver_selfadjoint_2 "
438 - eigensolver_selfadjoint_3 "
439 - eigensolver_selfadjoint_4 "
440 - eigensolver_selfadjoint_5 "
441 - eigensolver_selfadjoint_9 "
450 - eigensolver_complex_1 (140) (ei3.eigenvectors().transpose()*ei3.eigenvectors().transpose()).eval().isIdentity()
451 - eigensolver_complex_2 "
453 - eigensolver_complex_4 "
471 - jacobisvd_7 (308) sub(some_inf, some_inf) != sub(some_inf, some_inf)
477 - jacobisvd_10 "
484 - bdcsvd_7 -> variable
485 - bdcsvd_8 -> variable
490 - bdcsvd_10 -> (308) sub(some_inf, some_inf) != sub(some_inf, some_inf)
510 - geo_quaternion_3 (infinite loop in JacobiSVD)
629 - umeyama_6 (Not Run)
649 - prec_inverse_4x4_2 (24) error == 0.0
650 - prec_inverse_4x4_3 "
672 - half_float (159) !(half(1.0) < half(0.0 / 0.0))
708 - boostmultiprec_10 svd_common.h (308) sub(some_inf, some_inf) != sub(some_inf, some_inf)
This is mostly for curiosity I don't plan to invest time on them, but if someone care you know where to start.
Also note that with gcc ours built-in isnan/isfinite/isinf are OK with fast-math (unlike the std:: versions)
Edited by Eigen Bugzilla