freebsd-dev/lib/msun/tests
Dimitry Andric df3b437c1e Fix failures in libm's lround_test after clang 12 import
It turned out that the (type)DTYPE_MAX conversions at the top of
s_lround.c are now emitted as cvtsi2sd instructions, at least on SSE
capable CPUs. This caused the FE_INEXACT flag to always be set, at least
for the double and float variants. Under clang 11, the whole INRANGE()
comparisons were still optimized away, but this has "improved" in clang
12, due to stricter adherence to the -ffp-exception-behavior=maytrap
compiler flag.

To avoid run-time integer to float conversions, use static constants
instead, so they are computed at compile time, and the INRANGE()
statements are optimized away again, if applicable.

While here, use an integer instead of a floating type to store the test
results in lround_test.c, as this is more appropriate, and we can also
drop the volatile hack.

Reported by:	arichardson
MFC after:	3 days
2021-06-22 18:38:45 +02:00
..
cexp_test.c Improve test messages for msun tests 2021-03-22 11:55:06 +00:00
conj_test.c Improve test messages for msun tests 2021-03-22 11:55:06 +00:00
csqrt_test.c Fix lib/msun/tests/csqrt_test on platforms with 128-bit long double 2021-03-22 16:57:43 +00:00
ctrig_test.c Improve test messages for msun tests 2021-03-22 11:55:06 +00:00
exponential_test.c Improve test messages for msun tests 2021-03-22 11:55:06 +00:00
fenv_test.c lib/msun/tests: Add more debug output to fenv_test.c 2021-03-22 11:55:07 +00:00
fma_test.c Remove amd64 XFAIL from tests/lib/msun/fma_test:infinities 2021-04-15 16:28:08 +01:00
fmaxmin_test.c Improve test messages for msun tests 2021-03-22 11:55:06 +00:00
ilogb_test.c Convert the msun tests to ATF 2021-03-22 11:55:06 +00:00
invctrig_test.c Improve test messages for msun tests 2021-03-22 11:55:06 +00:00
invtrig_test.c Fix unused functions in invtrig_test.c 2021-03-22 13:06:02 +00:00
logarithm_test.c Allow lib/msun/logarithm_test to pass on ld128 platforms 2021-04-20 01:46:43 +01:00
lrint_test.c Improve test messages for msun tests 2021-03-22 11:55:06 +00:00
lround_test.c Fix failures in libm's lround_test after clang 12 import 2021-06-22 18:38:45 +02:00
Makefile lib/msun: Exclude ignored-pragmas from -Werror 2021-04-15 16:27:52 +01:00
Makefile.depend DIRDEPS_BUILD: Update dependencies. 2017-10-31 00:07:04 +00:00
nan_test.c Convert the msun tests to ATF 2021-03-22 11:55:06 +00:00
nearbyint_test.c Improve test messages for msun tests 2021-03-22 11:55:06 +00:00
next_test.c Improve test messages for msun tests 2021-03-22 11:55:06 +00:00
rem_test.c Convert the msun tests to ATF 2021-03-22 11:55:06 +00:00
test-utils.h Improve test messages for msun tests 2021-03-22 11:55:06 +00:00
trig_test.c Improve test messages for msun tests 2021-03-22 11:55:06 +00:00