Kaydet (Commit) 6a4504bb authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Disable -fsanitize=float-divide-by-zero in rtl_math_atanh

...which relies on division by zero producing inf, for atanh(1) = inf.  (As
tested by CppunitTest_sal_rtl.)

Change-Id: I0e5de8850ab4cbd05f83027c1eb548e2e0c9a9b2
Reviewed-on: https://gerrit.libreoffice.org/50613Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarStephan Bergmann <sbergman@redhat.com>
üst 9bb9589d
......@@ -1277,6 +1277,9 @@ double SAL_CALL rtl_math_log1p(double fValue) SAL_THROW_EXTERN_C()
}
double SAL_CALL rtl_math_atanh(double fValue) SAL_THROW_EXTERN_C()
#if defined __clang__
__attribute__((no_sanitize("float-divide-by-zero"))) // atahn(1) -> inf
#endif
{
return 0.5 * rtl_math_log1p(2.0 * fValue / (1.0-fValue));
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment