summaryrefslogtreecommitdiff
path: root/math
AgeCommit message (Collapse)AuthorFilesLines
2013-05-14Convert TEST_f_f1 tests from code to data.Joseph Myers1-34/+67
2013-05-13Convert TEST_fl_f tests from code to data.Joseph Myers1-38/+53
2013-05-13Convert TEST_fi_f tests from code to data.Joseph Myers1-36/+56
2013-05-13Convert TEST_c_f tests from code to data.Joseph Myers1-92/+129
2013-05-13Convert TEST_if_f tests from code to data.Joseph Myers1-124/+144
2013-05-13Consistently use TEST_fl_f in tests of scalbln.Joseph Myers1-25/+25
2013-05-13Define decimal constant M_1_DIV_El in libm-test.incAdhemerval Zanella1-1/+2
This patch replaces the 1.0 / M_El by the decimal constant M_1_DIV_El.
2013-05-12Convert TEST_fff_f tests from code to data.Joseph Myers1-888/+900
2013-05-12Convert TEST_c_c tests from code to data.Joseph Myers2-4599/+4680
2013-05-12Convert TEST_ff_f tests from code to data.Joseph Myers1-937/+1011
2013-05-11Make fma and nextafter tests use max_value instead of fltmax.Joseph Myers1-10/+6
2013-05-11Convert TEST_f_f tests from code to data.Joseph Myers1-2501/+2576
2013-05-10Start converting libm tests from code to data.Joseph Myers2-72/+171
2013-05-10Fix tgamma errno setting on domain error (bug 6809).Joseph Myers4-6/+9
2013-05-09Use M_SQRT1_2l instead of local M_SQRT_2_2 in libm-test.inc.Joseph Myers1-2/+1
2013-05-09Use M_PI_34l consistently in libm-test.inc.Joseph Myers1-2/+2
2013-05-09Use decimal constants in defining M_* in libm-test.inc.Joseph Myers1-5/+5
2013-05-08Factor out initializers for libm-test.inc constants.Joseph Myers1-19/+28
2013-05-08Use correct TEST_* macros for jn, ldexp and yn tests.Joseph Myers1-100/+101
2013-05-08Move some libm-test logic for running tests from gen-libm-test.pl to ↵Joseph Myers2-75/+213
libm-test.inc.
2013-05-08Improve tgamma accuracy (bugs 2546, 2560, 5159, 15426).Joseph Myers2-1/+502
2013-05-06Initialize x in frexp, modf, remqou tests.Joseph Myers1-0/+3
2013-05-06Consistently use TEST_f_f1 in gamma tests.Joseph Myers1-5/+5
2013-05-06PowerPC: fix hypot/hypof FP exceptionsAdhemerval Zanella1-0/+2
This patch fixes hypot/hypotf spurious floating-point exceptions generate by internal operations.
2013-05-04Remove unused libm-test expected-failure mechanism.Joseph Myers3-125/+44
2013-05-04Use static initializers for constant variables in libm-test.inc.Joseph Myers1-30/+19
2013-05-03Consistently use TEST_f_f1 in lgamma tests.Joseph Myers1-10/+8
2013-05-03Don't use IGNORE_ZERO_INF_SIGN in hypot tests.Joseph Myers1-2/+2
2013-05-01Fix catan, catanh spurious underflows (bug 15423).Joseph Myers7-97/+528
2013-04-30Fix catan, catanh inaccuracy from atan2 denominators near 0 (bug 15416).Joseph Myers7-12/+370
2013-04-29Integrate errno testing better in libm-test.inc.Joseph Myers2-199/+127
2013-04-29Add missing semicolons to libm-test.inc tests.Joseph Myers1-363/+363
2013-04-27Fix catan, catanh spurious overflows (bug 15409).Joseph Myers7-90/+338
2013-04-26Fix catan, catanh missing underflows (bug 15406).Joseph Myers7-6/+128
2013-04-26Fix csin, csinh, ccos, ccosh missing underflows (bug 15405).Joseph Myers10-0/+129
2013-04-24math: Use accurate answers for cos and sincos.Carlos O'Donell1-10/+10
Use the most accurate hex literals possible for the answers to the cos and sincos tests that vary according to the error in the rounding of PI/2. --- 2013-04-24 Carlos O'Donell <carlos@redhat.com> * math/libm-test.inc (cos_test): Use accurate hex constants. (sincost_test): Likewise.
2013-04-24Add catan, catanh tests at +/- 1 and +/- i.Joseph Myers1-0/+18
2013-04-24Use suffixed floating-point constants in float and long double catan/catanh.Joseph Myers4-28/+28
2013-04-24Fix catan, catanh inaccuracy through use of log (bug 15394).Joseph Myers7-9/+109
2013-04-11libm-test.inc: Fix tests where cos(PI/2) != 0.Carlos O'Donell1-2/+50
The value of PI is never exactly PI in any floating point representation, and the value of PI/2 is never PI/2. It is wrong to expect cos(M_PI_2l) to return 0, instead it will return an answer that is non-zero because M_PI_2l doesn't round to exactly PI/2 in the type used. That is to say that the correct answer is to do the following: * Take PI or PI/2. * Round to the floating point representation. * Take the rounded value and compute an infinite precision cos or sin. * Use the rounded result of the infinite precision cos or sin as the answer to the test. I used printf to do the type rounding, and Wolfram's Alpha to do the infinite precision cos calculations. The following changes bring x86-64 and x86 to 1/2 ulp for two tests. It shows that the x86 cos implementation is quite good, and that our test are flawed. Unfortunately given that the rounding errors are type dependent we need to fix this for each type. No regressions on x86-64 or x86. --- 2013-04-11 Carlos O'Donell <carlos@redhat.com> * math/libm-test.inc (cos_test): Fix PI/2 test. (sincos_test): Likewise. * sysdeps/x86_64/fpu/libm-test-ulps: Regenerate. * sysdeps/i386/fpu/libm-test-ulps: Regenerate.
2013-04-11Don't use run-via-rtld-prefix for anything other than testsSiddhesh Poyarekar1-1/+1
run-via-rtld-prefix checks whether the program to be run is a static test and skips if it is. This is fine, except that it assumes that the program to be run is the second $^, which is true only for tests. This change creates an rtld-prefix, which is simply the dynamic linker prefix with the necessary arguments and uses that in the non-test targets.
2013-04-06README.libm-test: Use testrun.sh to run libm test.Carlos O'Donell1-2/+1
Document the use of the convenience testrun.sh script for running the libm test. --- 2013-04-06 Carlos O'Donell <carlos@redhat.com> * math/README.libm-test (How can I generate "libm-test-ulps"?): Use testrun.sh to run libm tests.
2013-04-06New Makefile target `regen-ulps'.Carlos O'Donell3-19/+78
The wiki "Regeneration" page has this to say about update ULPs. "The libm-test-ulps files are semiautomatically updated. To update an ulps baseline, run each of the failing tests (test-float, test-double, etc.) with -u; this will generate a file called ULPs; concatenate each of those files with the existing libm-test-ulps file, after removing any entries for particularly huge numbers of ulps that you do not want to mark as expected. Then run gen-libm-test.pl -n -u FILE where FILE is the concatenated file produced in the previous step. This generates a file called NewUlps which is the new sorted version of libm-test-ulps." The same information is listed in math/README.libm-test, and is a lot of manual work that you often want to run over-and-over again while working on a particular test. The `regen-ulps' convenience target does this automatically for developers. We strictly assume the source tree is readonly and add a new --output-dir option to libm-test.inc to allow for writing out ULPs to $(objpfx). When run the new target does the following: * Starts with the baseline ULPs file. * Runs each of the libm math tests with -u. * Adds new changes seen with -u to the baseline. * Sorts and prepares the test output with gen-libm-test.pl. * Leaves math/NewUlps in your build tree to copy to your source tree, cleanup, and checkin. The math test documentation in math/README.libm-test is updated document the new Makefile target. --- 2013-04-06 Carlos O'Donell <carlos@redhat.com> * Makefile.in (regen-ulps): New target. * math/Makefile [ifneq (no,$(PERL)]: Declare regen-ulps with .PHONY. [ifneq (no,$(PERL)] (run-regen-ulps): New variable. [ifneq (no,$(PERL)] (regen-ulps): New target. [ifeq (no,$(PERL)] (regen-ulps): New target. * math/libm-test.inc (ulps_file_name): Define. (output_dir): New variable. (options): Add "output-dir" option. (parse_opt): Handle 'o' case. (main): If output_dir is non-NULL use it as a prefix otherwise use "". * math/README.libm-test: Update `How can I generate "libm-test-ulps"?'
2013-04-05[BZ #14686, #15336] Fix standard compliance. Don't use hard-coded qNaN values.Thomas Schwinge1-0/+25
2013-04-03Fix missing underflow from cexp (bug 14478).Joseph Myers4-0/+39
2013-04-02Fix cacosh inaccuracy and spurious exceptions (bug 15327).Joseph Myers4-59/+639
2013-04-02New <math.h> macro named issignaling to check for a signaling NaN (sNaN).Thomas Schwinge8-15/+177
It is based on draft TS 18661 and currently enabled as a GNU extension.
2013-03-30Fix casinh inaccuracy for imaginary part < 1.0, real part small (bug 10357).Joseph Myers4-0/+1133
2013-03-27Fix casinh inaccuracy near i, imaginary part > 1 (bug 15307).Joseph Myers4-0/+491
2013-03-22BZ#13889: expl (709.75) wrongly overflows for ldbl-128ibmAdhemerval Zanella1-0/+3
The patch increase the high value to check if expl overflows. Current high mark value is not really correct, the algorithm accepts high values. It also adds a correct wrapper function to check for overflow and underflow.