On 2007-12-29 20:09:58 -0000, Dave Korn wrote: > On 29 December 2007 20:07, Dennis Clarke wrote: > > Do you have a testsuite ? Some battary of tests that can be thrown at the > > code to determine correct responses to various calculations, error > > conditions, underflows and rounding errors etc etc ? > > There's a "make check" target in the tarball. I don't know how thorough it > is.
The testsuite has been improved, but many things remain to do. Here are the generic improvements since the release of MPFR 2.3.0 (though not everything is in the 2.3 branch, the tests from the trunk can now be run against the 2.3 branch): * In the generic tests (based on random inputs), much fewer cases that yield an exception are generated, i.e. more interesting cases are tested in average. * Generic bad cases for the correct rounding are now tested for functions that have an inverse function implemented (r4817). For the other functions, this should also be possible with a Newton iteration, but this isn't implemented yet. * Some functions were failing when some global flag was set before the call, and unfortunately most tests were done with all flags cleared. Now, in the generic tests, all the global flags are set before a test with a probability 1/2 (part of r5115). * The exponent range is now checked at the end of each test file (r5136). So, if a function doesn't restore the exponent range in some cases, this will probably be detected. We also test worst cases in double precision for some elementary functions. Then there are very useful tests provided by users (in particular Kevin Rauch, who found many bugs in special cases). The concept of bad cases should be extended to the underflow and overflow thresholds, but this isn't done yet. -- Vincent Lefèvre <[EMAIL PROTECTED]> - Web: <http://www.vinc17.org/> 100% accessible validated (X)HTML - Blog: <http://www.vinc17.org/blog/> Work: CR INRIA - computer arithmetic / Arenaire project (LIP, ENS-Lyon)