diff options
author | Bruno Haible <bruno@clisp.org> | 2011-11-06 02:28:32 +0100 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2011-11-06 02:36:24 +0100 |
commit | b8d5f042e8a565bab1d73a5d7f56db342ae51451 (patch) | |
tree | dbf6b74316f8038a88332feda421b78ce978fa38 /tests/test-fma1.c | |
parent | cebba9faecfecedf8378a06f46823166e3b4374a (diff) | |
download | gnulib-b8d5f042e8a565bab1d73a5d7f56db342ae51451.tar.gz |
Tests for module 'fma'.
* modules/fma-tests: New file.
* tests/test-fma1.c: New file.
* tests/test-fma1.h: New file.
* tests/test-fma2.c: New file.
* tests/test-fma2.h: New file.
Diffstat (limited to 'tests/test-fma1.c')
-rw-r--r-- | tests/test-fma1.c | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/tests/test-fma1.c b/tests/test-fma1.c new file mode 100644 index 0000000000..f3ef31e174 --- /dev/null +++ b/tests/test-fma1.c @@ -0,0 +1,47 @@ +/* Test of fma(). + Copyright (C) 2011 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <http://www.gnu.org/licenses/>. */ + +/* Written by Bruno Haible <bruno@clisp.org>, 2011. */ + +#include <config.h> + +#include <math.h> + +#include "signature.h" +SIGNATURE_CHECK (fma, double, (double, double, double)); + +#include "isnand-nolibm.h" +#include "infinity.h" +#include "nan.h" +#include "macros.h" + +#undef INFINITY +#undef NAN + +#define DOUBLE double +#define ISNAN isnand +#define INFINITY Infinityd () +#define NAN NaNd () +#define L_(literal) literal +#include "test-fma1.h" + +int +main () +{ + test_function (fma); + + return 0; +} |