11 Jun 2011 12:36
fpgetround/fpsetround do not work
Nicolas Joly <njoly <at> pasteur.fr>
2011-06-11 10:36:18 GMT
2011-06-11 10:36:18 GMT
Hi, I just had soe more time to look into the failures or regression test for -current NetBSD/alpha i run from time to time on a PWS500au machine (available at http://www.netbsd.org/~njoly/alpha-atf/). Checking the lib/libc/ieeefp/t_round/fpround test show that fpgetround/fpsetround do not work as expected, but FLT_ROUNDS do. njoly <at> thanos [~]> /usr/tests/lib/libc/ieeefp/t_round fpround *** Check failed: /local/src/NetBSD/src/tests/lib/libc/ieeefp/t_round.c:41: fpgetround() != FP_RN *** Check failed: /local/src/NetBSD/src/tests/lib/libc/ieeefp/t_round.c:64: fpsetround(FP_RN) != FP_RN *** Check failed: /local/src/NetBSD/src/tests/lib/libc/ieeefp/t_round.c:67: fpgetround() != FP_RN Lokking into the respective code show that both functions (lib/libc/arch/alpha/gen/{flt_rounds,fpgetround}.c) use the same code except for trapb operands which where removed in 2001. Adding back the trapb ops to fpgetround()/fpsetround() make it work as expected. njoly <at> thanos [~]> /usr/tests/lib/libc/ieeefp/t_round fpround passed Any reason to not commit the attached patch ? Thanks.(Continue reading)
RSS Feed