import mpc 1.2.0

This commit is contained in:
Adrien Destugues 2022-07-15 15:15:39 +02:00
parent b8f3cf881a
commit 5e75222e07
71 changed files with 20589 additions and 3101 deletions

View File

@ -1,101 +1,368 @@
Copyright (C) INRIA 2003, 2005, 2007, 2008, 2009, 2010, 2011, 2012
Installation Instructions
*************************
Copyright (C) 1994-1996, 1999-2002, 2004-2016 Free Software
Foundation, Inc.
Copying and distribution of this file, with or without modification,
are permitted in any medium without royalty provided the copyright
notice and this notice are preserved. This file is offered as-is,
without any warranty.
without warranty of any kind.
Installing GNU MPC
Basic Installation
==================
This is for the impatient, for deeper explanations see the chapter
"Installing GNU MPC" in the Texinfo documentation (type 'info mpc.info').
Briefly, the shell command './configure && make && make install'
should configure, build, and install this package. The following
more-detailed instructions are generic; see the 'README' file for
instructions specific to this package. Some packages provide this
'INSTALL' file but do not implement all of the features documented
below. The lack of an optional feature in a given package is not
necessarily a bug. More recommendations for GNU packages can be found
in *note Makefile Conventions: (standards)Makefile Conventions.
0. You first need to install GMP, the GNU Multiprecision Arithmetic Library,
see <http://gmplib.org/>, and GNU MPFR, see <http://www.mpfr.org>.
GNU MPC requires GMP version 5.0.0 or later
and GNU MPFR version 3.0.0 or later.
The 'configure' shell script attempts to guess correct values for
various system-dependent variables used during compilation. It uses
those values to create a 'Makefile' in each directory of the package.
It may also create one or more '.h' files containing system-dependent
definitions. Finally, it creates a shell script 'config.status' that
you can run in the future to recreate the current configuration, and a
file 'config.log' containing compiler output (useful mainly for
debugging 'configure').
1. In the directory of the GNU MPC archive, type
It can also use an optional file (typically called 'config.cache' and
enabled with '--cache-file=config.cache' or simply '-C') that saves the
results of its tests to speed up reconfiguring. Caching is disabled by
default to prevent problems with accidental use of stale cache files.
tar xzf mpc-1.1.0.tar.gz
cd mpc-1.1.0
./configure
make
If you need to do unusual things to compile the package, please try
to figure out how 'configure' could check whether to do them, and mail
diffs or instructions to the address given in the 'README' so they can
be considered for the next release. If you are using the cache, and at
some point 'config.cache' contains results you don't want to keep, you
may remove or edit it.
This assumes that GMP and GNU MPFR are installed in a directory searched
by default by the compiler. Otherwise, use --with-gmp=DIR or
--with-mpfr=DIR with ./configure (see the Texinfo documentation).
The file 'configure.ac' (or 'configure.in') is used to create
'configure' by a program called 'autoconf'. You need 'configure.ac' if
you want to change it or regenerate 'configure' using a newer version of
'autoconf'.
2. You should run the test suite, type
The simplest way to compile this package is:
make check
1. 'cd' to the directory containing the package's source code and type
'./configure' to configure the package for your system.
If any error occurs, please report it on the mailing list
<mpc-discuss@lists.gforge.inria.fr>, or file a bug at the bug tracker
<https://gforge.inria.fr/tracker/?atid=607&group_id=131&func=browse> .
Running 'configure' might take a while. While running, it prints
some messages telling which features it is checking for.
3. To install the GNU MPC library, type
2. Type 'make' to compile the package.
make install
3. Optionally, type 'make check' to run any self-tests that come with
the package, generally using the just-built uninstalled binaries.
By default, the files are copied into subdirectories of /usr/local.
You need write permissions on these directories, or pass an alternative
installation directory using the --prefix option to ./configure.
4. Type 'make install' to install the programs and any data files and
documentation. When installing into a prefix owned by root, it is
recommended that the package be configured and built as a regular
user, and only the 'make install' phase executed with root
privileges.
4. You can optionally create documentation, type
5. Optionally, type 'make installcheck' to repeat any self-tests, but
this time using the binaries in their final installed location.
This target does not install anything. Running this target as a
regular user, particularly if the prior 'make install' required
root privileges, verifies that the installation completed
correctly.
make dvi
6. You can remove the program binaries and object files from the
source code directory by typing 'make clean'. To also remove the
files that 'configure' created (so you can compile the package for
a different kind of computer), type 'make distclean'. There is
also a 'make maintainer-clean' target, but that is intended mainly
for the package's developers. If you use it, you may have to get
all sorts of other programs in order to regenerate files that came
with the distribution.
or
7. Often, you can also type 'make uninstall' to remove the installed
files again. In practice, not all packages have tested that
uninstallation works correctly, even though it is required by the
GNU Coding Standards.
make ps
8. Some packages, particularly those that use Automake, provide 'make
distcheck', which can by used by developers to test that all other
targets like 'make install' and 'make uninstall' work correctly.
This target is generally not run by end users.
This requires the Texinfo package (version 4.2 at least).
Compilers and Options
=====================
In case of difficulties, please send a description of the problem to
<mpc-discuss@lists.gforge.inria.fr>.
Some systems require unusual options for compilation or linking that
the 'configure' script does not know about. Run './configure --help'
for details on some of the pertinent environment variables.
##############################################################################
You can give 'configure' initial values for configuration parameters
by setting variables in the command line or in the environment. Here is
an example:
Note for AIX users:
===================
./configure CC=c99 CFLAGS=-g LIBS=-lposix
If GMP was built with the 64-bit ABI, before building and testing GNU MPC,
it might be necessary to set the OBJECT_MODE environment variable to 64
by, e.g.,
export OBJECT_MODE=64
This has been tested with the C compiler IBM XL C/C++ Enterprise Edition
V8.0 for AIX, version: 08.00.0000.0021, GMP 4.2.4 and GNU MPFR 2.4.1.
*Note Defining Variables::, for more details.
##############################################################################
Compiling For Multiple Architectures
====================================
Note for Windows users:
=======================
You can compile the package for more than one kind of computer at the
same time, by placing the object files for each architecture in their
own directory. To do this, you can use GNU 'make'. 'cd' to the
directory where you want the object files and executables to go and run
the 'configure' script. 'configure' automatically checks for the source
code in the directory that 'configure' is in and in '..'. This is known
as a "VPATH" build.
There is a special file Makefile.vc for Windows, contributed by Mickaël
Gastineau. This file works both for the Windows Server 2003 R2 Platform SDK,
and for the Windows SDK of Vista. To use it, simply replace "make" by
"nmake /f makefile.vc" in the above instructions:
With a non-GNU 'make', it is safer to compile the package for one
architecture at a time in the source code directory. After you have
installed the package for one architecture, use 'make distclean' before
reconfiguring for another architecture.
compilation :
nmake /f makefile.vc GMP=<gmp_install_dir> MPFR=<mpfr_install_dir>
On MacOS X 10.5 and later systems, you can create libraries and
executables that work on multiple system types--known as "fat" or
"universal" binaries--by specifying multiple '-arch' options to the
compiler but only a single '-arch' option to the preprocessor. Like
this:
clean :
nmake /f makefile.vc GMP=<gmp_install_dir> MPFR=<mpfr_install_dir> clean
./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
CPP="gcc -E" CXXCPP="g++ -E"
check :
nmake /f makefile.vc GMP=<gmp_install_dir> MPFR=<mpfr_install_dir> check
This is not guaranteed to produce working output in all cases, you
may have to build one architecture at a time and combine the results
using the 'lipo' tool if you have problems.
If you want to compile mpc with mingw in the msys shell, you might need to
add the following to the configure command (or in your environment):
Installation Names
==================
LDFLAGS=-L/usr/local/lib CPPFLAGS=-I/usr/local/include
By default, 'make install' installs the package's commands under
'/usr/local/bin', include files under '/usr/local/include', etc. You
can specify an installation prefix other than '/usr/local' by giving
'configure' the option '--prefix=PREFIX', where PREFIX must be an
absolute file name.
In addition, you might need to give the following additional argument to
configure (reported for mpc-0.9):
You can specify separate installation prefixes for
architecture-specific files and architecture-independent files. If you
pass the option '--exec-prefix=PREFIX' to 'configure', the package uses
PREFIX as the prefix for installing programs and libraries.
Documentation and other data files still use the regular prefix.
CPP="x86_64-w64-mingw32-gcc -E"
In addition, if you use an unusual directory layout you can give
options like '--bindir=DIR' to specify different values for particular
kinds of files. Run 'configure --help' for a list of the directories
you can set and what kinds of files go in them. In general, the default
for these options is expressed in terms of '${prefix}', so that
specifying just '--prefix' will affect all of the other directory
specifications that were not explicitly provided.
(reported by Sisyphus)
The most portable way to affect installation locations is to pass the
correct locations to 'configure'; however, many packages provide one or
both of the following shortcuts of passing variable assignments to the
'make install' command line to change installation locations without
having to reconfigure or recompile.
The first method involves providing an override variable for each
affected directory. For example, 'make install
prefix=/alternate/directory' will choose an alternate location for all
directory configuration variables that were expressed in terms of
'${prefix}'. Any directories that were specified during 'configure',
but not in terms of '${prefix}', must each be overridden at install time
for the entire installation to be relocated. The approach of makefile
variable overrides for each directory variable is required by the GNU
Coding Standards, and ideally causes no recompilation. However, some
platforms have known limitations with the semantics of shared libraries
that end up requiring recompilation when using this method, particularly
noticeable in packages that use GNU Libtool.
The second method involves providing the 'DESTDIR' variable. For
example, 'make install DESTDIR=/alternate/directory' will prepend
'/alternate/directory' before all installation names. The approach of
'DESTDIR' overrides is not required by the GNU Coding Standards, and
does not work on platforms that have drive letters. On the other hand,
it does better at avoiding recompilation issues, and works well even
when some directory options were not specified in terms of '${prefix}'
at 'configure' time.
Optional Features
=================
If the package supports it, you can cause programs to be installed
with an extra prefix or suffix on their names by giving 'configure' the
option '--program-prefix=PREFIX' or '--program-suffix=SUFFIX'.
Some packages pay attention to '--enable-FEATURE' options to
'configure', where FEATURE indicates an optional part of the package.
They may also pay attention to '--with-PACKAGE' options, where PACKAGE
is something like 'gnu-as' or 'x' (for the X Window System). The
'README' should mention any '--enable-' and '--with-' options that the
package recognizes.
For packages that use the X Window System, 'configure' can usually
find the X include and library files automatically, but if it doesn't,
you can use the 'configure' options '--x-includes=DIR' and
'--x-libraries=DIR' to specify their locations.
Some packages offer the ability to configure how verbose the
execution of 'make' will be. For these packages, running './configure
--enable-silent-rules' sets the default to minimal output, which can be
overridden with 'make V=1'; while running './configure
--disable-silent-rules' sets the default to verbose, which can be
overridden with 'make V=0'.
Particular systems
==================
On HP-UX, the default C compiler is not ANSI C compatible. If GNU CC
is not installed, it is recommended to use the following options in
order to use an ANSI C compiler:
./configure CC="cc -Ae -D_XOPEN_SOURCE=500"
and if that doesn't work, install pre-built binaries of GCC for HP-UX.
HP-UX 'make' updates targets which have the same time stamps as their
prerequisites, which makes it generally unusable when shipped generated
files such as 'configure' are involved. Use GNU 'make' instead.
On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
parse its '<wchar.h>' header file. The option '-nodtk' can be used as a
workaround. If GNU CC is not installed, it is therefore recommended to
try
./configure CC="cc"
and if that doesn't work, try
./configure CC="cc -nodtk"
On Solaris, don't put '/usr/ucb' early in your 'PATH'. This
directory contains several dysfunctional programs; working variants of
these programs are available in '/usr/bin'. So, if you need '/usr/ucb'
in your 'PATH', put it _after_ '/usr/bin'.
On Haiku, software installed for all users goes in '/boot/common',
not '/usr/local'. It is recommended to use the following options:
./configure --prefix=/boot/common
Specifying the System Type
==========================
There may be some features 'configure' cannot figure out
automatically, but needs to determine by the type of machine the package
will run on. Usually, assuming the package is built to be run on the
_same_ architectures, 'configure' can figure that out, but if it prints
a message saying it cannot guess the machine type, give it the
'--build=TYPE' option. TYPE can either be a short name for the system
type, such as 'sun4', or a canonical name which has the form:
CPU-COMPANY-SYSTEM
where SYSTEM can have one of these forms:
OS
KERNEL-OS
See the file 'config.sub' for the possible values of each field. If
'config.sub' isn't included in this package, then this package doesn't
need to know the machine type.
If you are _building_ compiler tools for cross-compiling, you should
use the option '--target=TYPE' to select the type of system they will
produce code for.
If you want to _use_ a cross compiler, that generates code for a
platform different from the build platform, you should specify the
"host" platform (i.e., that on which the generated programs will
eventually be run) with '--host=TYPE'.
Sharing Defaults
================
If you want to set default values for 'configure' scripts to share,
you can create a site shell script called 'config.site' that gives
default values for variables like 'CC', 'cache_file', and 'prefix'.
'configure' looks for 'PREFIX/share/config.site' if it exists, then
'PREFIX/etc/config.site' if it exists. Or, you can set the
'CONFIG_SITE' environment variable to the location of the site script.
A warning: not all 'configure' scripts look for a site script.
Defining Variables
==================
Variables not defined in a site shell script can be set in the
environment passed to 'configure'. However, some packages may run
configure again during the build, and the customized values of these
variables may be lost. In order to avoid this problem, you should set
them in the 'configure' command line, using 'VAR=value'. For example:
./configure CC=/usr/local2/bin/gcc
causes the specified 'gcc' to be used as the C compiler (unless it is
overridden in the site shell script).
Unfortunately, this technique does not work for 'CONFIG_SHELL' due to an
Autoconf limitation. Until the limitation is lifted, you can use this
workaround:
CONFIG_SHELL=/bin/bash ./configure CONFIG_SHELL=/bin/bash
'configure' Invocation
======================
'configure' recognizes the following options to control how it
operates.
'--help'
'-h'
Print a summary of all of the options to 'configure', and exit.
'--help=short'
'--help=recursive'
Print a summary of the options unique to this package's
'configure', and exit. The 'short' variant lists options used only
in the top level, while the 'recursive' variant lists options also
present in any nested packages.
'--version'
'-V'
Print the version of Autoconf used to generate the 'configure'
script, and exit.
'--cache-file=FILE'
Enable the cache: use and save the results of the tests in FILE,
traditionally 'config.cache'. FILE defaults to '/dev/null' to
disable caching.
'--config-cache'
'-C'
Alias for '--cache-file=config.cache'.
'--quiet'
'--silent'
'-q'
Do not print messages saying which checks are being made. To
suppress all normal output, redirect it to '/dev/null' (any error
messages will still be shown).
'--srcdir=DIR'
Look for the package's source code in directory DIR. Usually
'configure' can determine that directory automatically.
'--prefix=DIR'
Use DIR as the installation prefix. *note Installation Names:: for
more details, including other options available for fine-tuning the
installation locations.
'--no-create'
'-n'
Run the configure checks, but stop before creating any output
files.
'configure' also accepts some other, not widely useful, options. Run
'configure --help' for more details.

View File

@ -1,6 +1,6 @@
## Makefile.am -- Process this file with automake to produce Makefile.in
##
## Copyright (C) 2008, 2010, 2011, 2012, 2013, 2014 INRIA
## Copyright (C) 2008, 2010, 2011, 2012, 2013, 2014, 2020 INRIA
##
## This file is part of GNU MPC.
##
@ -32,3 +32,6 @@ EXTRA_DIST = doc/fdl-1.3.texi src/mpc-log.h Makefile.vc
bench :
cd tools/bench && $(MAKE) $(AM_MAKEFLAGS) bench
mpcheck :
cd tools/mpcheck && $(MAKE) $(AM_MAKEFLAGS) mpcheck

View File

@ -1,7 +1,7 @@
# Makefile.in generated by automake 1.15.1 from Makefile.am.
# Makefile.in generated by automake 1.16.2 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2017 Free Software Foundation, Inc.
# Copyright (C) 1994-2020 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -170,9 +170,9 @@ am__recursive_targets = \
$(RECURSIVE_CLEAN_TARGETS) \
$(am__extra_recursive_targets)
AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
cscope distdir dist dist-all distcheck
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \
$(LISP)config.h.in
cscope distdir distdir-am dist dist-all distcheck
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) \
config.h.in
# Read a list of newline-separated strings from the standard input,
# and print each of them once, without duplicates. Input order is
# *not* preserved.
@ -193,10 +193,17 @@ ETAGS = etags
CTAGS = ctags
CSCOPE = cscope
DIST_SUBDIRS = $(SUBDIRS)
am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config.h.in AUTHORS \
COPYING.LESSER ChangeLog INSTALL NEWS README TODO ar-lib \
compile config.guess config.sub depcomp install-sh ltmain.sh \
missing
am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config.h.in \
$(top_srcdir)/build-aux/ar-lib $(top_srcdir)/build-aux/compile \
$(top_srcdir)/build-aux/config.guess \
$(top_srcdir)/build-aux/config.sub \
$(top_srcdir)/build-aux/install-sh \
$(top_srcdir)/build-aux/ltmain.sh \
$(top_srcdir)/build-aux/missing AUTHORS COPYING.LESSER \
ChangeLog INSTALL NEWS README TODO build-aux/ar-lib \
build-aux/compile build-aux/config.guess build-aux/config.sub \
build-aux/install-sh build-aux/ltmain.sh build-aux/mdate-sh \
build-aux/missing build-aux/texinfo.tex
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
distdir = $(PACKAGE)-$(VERSION)
top_distdir = $(distdir)
@ -396,8 +403,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
echo ' $(SHELL) ./config.status'; \
$(SHELL) ./config.status;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
@ -560,7 +567,10 @@ distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
-rm -f cscope.out cscope.in.out cscope.po.out cscope.files
distdir: $(DISTFILES)
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
$(am__remove_distdir)
test -d "$(distdir)" || mkdir "$(distdir)"
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@ -640,6 +650,10 @@ dist-xz: distdir
tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz
$(am__post_remove_distdir)
dist-zstd: distdir
tardir=$(distdir) && $(am__tar) | zstd -c $${ZSTD_CLEVEL-$${ZSTD_OPT--19}} >$(distdir).tar.zst
$(am__post_remove_distdir)
dist-tarZ: distdir
@echo WARNING: "Support for distribution archives compressed with" \
"legacy program 'compress' is deprecated." >&2
@ -682,6 +696,8 @@ distcheck: dist
eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).shar.gz | unshar ;;\
*.zip*) \
unzip $(distdir).zip ;;\
*.tar.zst*) \
zstd -dc $(distdir).tar.zst | $(am__untar) ;;\
esac
chmod -R a-w $(distdir)
chmod u+w $(distdir)
@ -862,18 +878,19 @@ uninstall-am: uninstall-includeHEADERS
am--refresh check check-am clean clean-cscope clean-generic \
clean-libtool cscope cscopelist-am ctags ctags-am dist \
dist-all dist-bzip2 dist-gzip dist-lzip dist-shar dist-tarZ \
dist-xz dist-zip distcheck distclean distclean-generic \
distclean-hdr distclean-libtool distclean-tags distcleancheck \
distdir distuninstallcheck dvi dvi-am html html-am info \
info-am install install-am install-data install-data-am \
install-dvi install-dvi-am install-exec install-exec-am \
install-html install-html-am install-includeHEADERS \
install-info install-info-am install-man install-pdf \
install-pdf-am install-ps install-ps-am install-strip \
installcheck installcheck-am installdirs installdirs-am \
maintainer-clean maintainer-clean-generic mostlyclean \
mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
tags tags-am uninstall uninstall-am uninstall-includeHEADERS
dist-xz dist-zip dist-zstd distcheck distclean \
distclean-generic distclean-hdr distclean-libtool \
distclean-tags distcleancheck distdir distuninstallcheck dvi \
dvi-am html html-am info info-am install install-am \
install-data install-data-am install-dvi install-dvi-am \
install-exec install-exec-am install-html install-html-am \
install-includeHEADERS install-info install-info-am \
install-man install-pdf install-pdf-am install-ps \
install-ps-am install-strip installcheck installcheck-am \
installdirs installdirs-am maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-generic \
mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \
uninstall-am uninstall-includeHEADERS
.PRECIOUS: Makefile
@ -881,6 +898,9 @@ uninstall-am: uninstall-includeHEADERS
bench :
cd tools/bench && $(MAKE) $(AM_MAKEFLAGS) bench
mpcheck :
cd tools/mpcheck && $(MAKE) $(AM_MAKEFLAGS) mpcheck
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:

View File

@ -1,6 +1,6 @@
# Makefile for the MPC library (Windows version).
#
# Copyright (C) INRIA - CNRS, 2002, 2004, 2005, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2016, 2017
# Copyright (C) INRIA - CNRS, 2002, 2004, 2005, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2016, 2017, 2018, 2020
#
# This file is part of the MPC Library.
#
@ -50,7 +50,7 @@ CPP = cl.exe
CC = cl.exe
CDEFAULTFLAGS=/O2 /GR- /MD /nologo /EHs
VERSION=1.1.0
VERSION=1.2.0
######################## do not edit below this line ##########################

View File

@ -1,3 +1,10 @@
Changes in version 1.2.0:
- Minimally required library version: MPFR 4.1.0
- New functions: mpc_sum, mpc_dot
- Several functions are more robust with a reduced exponent range
(for example corresponding to IEEE 754 binary formats)
- New tool mpcheck.
Changes in version 1.1.0:
- Minimally required library versions: GMP 5.0.0 and MPFR 3.0.0
- Fixed issues with MPFR 4.0.0

View File

@ -1,4 +1,4 @@
Copyright (C) INRIA 2003, 2005, 2008, 2009, 2011
Copyright (C) INRIA 2003, 2005, 2007, 2008, 2009, 2010, 2011, 2012, 2014, 2015, 2018, 2020
Copying and distribution of this file, with or without modification,
are permitted in any medium without royalty provided the copyright
@ -9,3 +9,107 @@ without any warranty.
GNU MPC is a complex floating-point library with exact rounding.
It is based on the GNU MPFR floating-point library (http://www.mpfr.org/),
which is itself based on the GNU MP library (http://gmplib.org/).
Installing GNU MPC
==================
This is for the impatient, for deeper explanations see the chapter
"Installing GNU MPC" in the Texinfo documentation (type 'info mpc.info').
0. You first need to install GMP, the GNU Multiprecision Arithmetic Library,
see <http://gmplib.org/>, and GNU MPFR, see <http://www.mpfr.org>.
GNU MPC requires GMP version 5.0.0 or later
and GNU MPFR version 4.1.0 or later.
1. In the directory of the GNU MPC archive, type
tar xzf mpc-1.2.0.tar.gz
cd mpc-1.2.0
./configure
make
This assumes that GMP and GNU MPFR are installed in a directory searched
by default by the compiler. Otherwise, use --with-gmp=DIR or
--with-mpfr=DIR with ./configure (see the Texinfo documentation).
2. You should run the test suite, type
make check
If any error occurs, please report it on the mailing list
<mpc-discuss@lists.gforge.inria.fr>, or file a bug at the bug tracker
<https://gforge.inria.fr/tracker/?atid=607&group_id=131&func=browse> .
3. To install the GNU MPC library, type
make install
By default, the files are copied into subdirectories of /usr/local.
You need write permissions on these directories, or pass an alternative
installation directory using the --prefix option to ./configure.
4. You can optionally create documentation, type
make dvi
or
make ps
This requires the Texinfo package (version 4.2 at least).
In case of difficulties, please send a description of the problem to
<mpc-discuss@lists.gforge.inria.fr>.
##############################################################################
Known problems:
===============
When LD_LIBRARY_PATH is set to various paths, it might confuse the configure
script, even with --with-gmp and --with-mpfr options. Then try to unset
LD_LIBRARY_PATH.
##############################################################################
Note for AIX users:
===================
If GMP was built with the 64-bit ABI, before building and testing GNU MPC,
it might be necessary to set the OBJECT_MODE environment variable to 64
by, e.g.,
export OBJECT_MODE=64
This has been tested with the C compiler IBM XL C/C++ Enterprise Edition
V8.0 for AIX, version: 08.00.0000.0021, GMP 4.2.4 and GNU MPFR 2.4.1.
##############################################################################
Note for Windows users:
=======================
There is a special file Makefile.vc for Windows, contributed by Mickaël
Gastineau. This file works both for the Windows Server 2003 R2 Platform SDK,
and for the Windows SDK of Vista. To use it, simply replace "make" by
"nmake /f makefile.vc" in the above instructions:
compilation :
nmake /f makefile.vc GMP=<gmp_install_dir> MPFR=<mpfr_install_dir>
clean :
nmake /f makefile.vc GMP=<gmp_install_dir> MPFR=<mpfr_install_dir> clean
check :
nmake /f makefile.vc GMP=<gmp_install_dir> MPFR=<mpfr_install_dir> check
If you want to compile mpc with mingw in the msys shell, you might need to
add the following to the configure command (or in your environment):
LDFLAGS=-L/usr/local/lib CPPFLAGS=-I/usr/local/include
In addition, you might need to give the following additional argument to
configure (reported for mpc-0.9):
CPP="x86_64-w64-mingw32-gcc -E"
(reported by Sisyphus)

View File

@ -25,9 +25,6 @@ implement mul_karatsuba with three multiplications at precision around p,
instead of two at precision 2*p and one at precision p
requires analysis of error propagation
From Andreas Enge 05 July 2012:
Add support for rounding mode MPFR_RNDA.
From Andreas Enge and Paul Zimmermann 6 July 2012:
Improve speed of Im (atan) for x+i*y with small y, for instance by using
the Taylor series directly. See also the discussion
@ -74,13 +71,12 @@ New functions to implement:
- from Joseph S. Myers <joseph at codesourcery dot com> 19 Mar 2012: mpc_erf,
mpc_erfc, mpc_exp2, mpc_expm1, mpc_log1p, mpc_log2, mpc_lgamma, mpc_tgamma
http://lists.gforge.inria.fr/pipermail/mpc-discuss/2012-March/001090.html
See the article by Pascal Molin (hal.archives-ouvertes.fr/hal-00580855).
- from Andreas Enge and Philippe Théveny 17 July 2008
agm (and complex logarithm with agm ?). For the error analysis, one can
start from Theorem 1 of http://www.lix.polytechnique.fr/Labo/Regis.Dupont/preprints/Dupont_FastEvalMod.ps.gz, and probably the best is to compute AGM(a,b)
as a*AGM(1,b/a) with |b/a| <= 1. In such a way, after one step all values
are in the same quadrant, and no cancellation occurs any more.
- from Andreas Enge 25 June 2009:
correctly rounded roots of unity zeta_n^i
- implement a root-finding algorithm using the Durand-Kerner method
(cf http://en.wikipedia.org/wiki/Durand%E2%80%93Kerner_method).
See also the CEVAL algorithm from Yap and Sagraloff:

193
gcc/mpc/aclocal.m4 vendored
View File

@ -1,6 +1,6 @@
# generated automatically by aclocal 1.15.1 -*- Autoconf -*-
# generated automatically by aclocal 1.16.2 -*- Autoconf -*-
# Copyright (C) 1996-2017 Free Software Foundation, Inc.
# Copyright (C) 1996-2020 Free Software Foundation, Inc.
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -20,7 +20,7 @@ You have another version of autoconf. It may work, but is not guaranteed to.
If you have problems, you may need to regenerate the build system entirely.
To do so, use the procedure documented by the package, typically 'autoreconf'.])])
# Copyright (C) 2002-2017 Free Software Foundation, Inc.
# Copyright (C) 2002-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -32,10 +32,10 @@ To do so, use the procedure documented by the package, typically 'autoreconf'.])
# generated from the m4 files accompanying Automake X.Y.
# (This private macro should not be called outside this file.)
AC_DEFUN([AM_AUTOMAKE_VERSION],
[am__api_version='1.15'
[am__api_version='1.16'
dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
dnl require some minimum version. Point them to the right macro.
m4_if([$1], [1.15.1], [],
m4_if([$1], [1.16.2], [],
[AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
])
@ -51,12 +51,12 @@ m4_define([_AM_AUTOCONF_VERSION], [])
# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
# This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
[AM_AUTOMAKE_VERSION([1.15.1])dnl
[AM_AUTOMAKE_VERSION([1.16.2])dnl
m4_ifndef([AC_AUTOCONF_VERSION],
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
# Copyright (C) 2011-2017 Free Software Foundation, Inc.
# Copyright (C) 2011-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -118,7 +118,7 @@ AC_SUBST([AR])dnl
# AM_AUX_DIR_EXPAND -*- Autoconf -*-
# Copyright (C) 2001-2017 Free Software Foundation, Inc.
# Copyright (C) 2001-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -170,7 +170,7 @@ am_aux_dir=`cd "$ac_aux_dir" && pwd`
# AM_CONDITIONAL -*- Autoconf -*-
# Copyright (C) 1997-2017 Free Software Foundation, Inc.
# Copyright (C) 1997-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -201,7 +201,7 @@ AC_CONFIG_COMMANDS_PRE(
Usually this means the macro was only invoked conditionally.]])
fi])])
# Copyright (C) 1999-2017 Free Software Foundation, Inc.
# Copyright (C) 1999-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -392,13 +392,12 @@ _AM_SUBST_NOTMAKE([am__nodep])dnl
# Generate code to set up dependency tracking. -*- Autoconf -*-
# Copyright (C) 1999-2017 Free Software Foundation, Inc.
# Copyright (C) 1999-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# _AM_OUTPUT_DEPENDENCY_COMMANDS
# ------------------------------
AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
@ -406,49 +405,43 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
# Older Autoconf quotes --file arguments for eval, but not when files
# are listed without --file. Let's play safe and only enable the eval
# if we detect the quoting.
case $CONFIG_FILES in
*\'*) eval set x "$CONFIG_FILES" ;;
*) set x $CONFIG_FILES ;;
esac
# TODO: see whether this extra hack can be removed once we start
# requiring Autoconf 2.70 or later.
AS_CASE([$CONFIG_FILES],
[*\'*], [eval set x "$CONFIG_FILES"],
[*], [set x $CONFIG_FILES])
shift
for mf
# Used to flag and report bootstrapping failures.
am_rc=0
for am_mf
do
# Strip MF so we end up with the name of the file.
mf=`echo "$mf" | sed -e 's/:.*$//'`
# Check whether this is an Automake generated Makefile or not.
# We used to match only the files named 'Makefile.in', but
# some people rename them; so instead we look at the file content.
# Grep'ing the first line is not enough: some people post-process
# each Makefile.in and add a new line on top of each file to say so.
# Grep'ing the whole file is not good either: AIX grep has a line
am_mf=`AS_ECHO(["$am_mf"]) | sed -e 's/:.*$//'`
# Check whether this is an Automake generated Makefile which includes
# dependency-tracking related rules and includes.
# Grep'ing the whole file directly is not great: AIX grep has a line
# limit of 2048, but all sed's we know have understand at least 4000.
if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
dirpart=`AS_DIRNAME("$mf")`
else
continue
sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \
|| continue
am_dirpart=`AS_DIRNAME(["$am_mf"])`
am_filepart=`AS_BASENAME(["$am_mf"])`
AM_RUN_LOG([cd "$am_dirpart" \
&& sed -e '/# am--include-marker/d' "$am_filepart" \
| $MAKE -f - am--depfiles]) || am_rc=$?
done
if test $am_rc -ne 0; then
AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments
for automatic dependency tracking. If GNU make was not used, consider
re-running the configure script with MAKE="gmake" (or whatever is
necessary). You can also try re-running configure with the
'--disable-dependency-tracking' option to at least be able to build
the package (albeit without support for automatic dependency tracking).])
fi
# Extract the definition of DEPDIR, am__include, and am__quote
# from the Makefile without running 'make'.
DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
test -z "$DEPDIR" && continue
am__include=`sed -n 's/^am__include = //p' < "$mf"`
test -z "$am__include" && continue
am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
# Find all dependency output files, they are included files with
# $(DEPDIR) in their names. We invoke sed twice because it is the
# simplest approach to changing $(DEPDIR) to its actual value in the
# expansion.
for file in `sed -n "
s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
# Make sure the directory exists.
test -f "$dirpart/$file" && continue
fdir=`AS_DIRNAME(["$file"])`
AS_MKDIR_P([$dirpart/$fdir])
# echo "creating $dirpart/$file"
echo '# dummy' > "$dirpart/$file"
done
done
AS_UNSET([am_dirpart])
AS_UNSET([am_filepart])
AS_UNSET([am_mf])
AS_UNSET([am_rc])
rm -f conftest-deps.mk
}
])# _AM_OUTPUT_DEPENDENCY_COMMANDS
@ -457,18 +450,17 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
# -----------------------------
# This macro should only be invoked once -- use via AC_REQUIRE.
#
# This code is only required when automatic dependency tracking
# is enabled. FIXME. This creates each '.P' file that we will
# need in order to bootstrap the dependency handling code.
# This code is only required when automatic dependency tracking is enabled.
# This creates each '.Po' and '.Plo' makefile fragment that we'll need in
# order to bootstrap the dependency handling code.
AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
[AC_CONFIG_COMMANDS([depfiles],
[test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
[AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
])
[AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])])
# Do all the work for Automake. -*- Autoconf -*-
# Copyright (C) 1996-2017 Free Software Foundation, Inc.
# Copyright (C) 1996-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -555,8 +547,8 @@ AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
AC_REQUIRE([AC_PROG_MKDIR_P])dnl
# For better backward compatibility. To be removed once Automake 1.9.x
# dies out for good. For more background, see:
# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
# <https://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
# <https://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
AC_SUBST([mkdir_p], ['$(MKDIR_P)'])
# We need awk for the "check" target (and possibly the TAP driver). The
# system "awk" is bad on some platforms.
@ -623,7 +615,7 @@ END
Aborting the configuration process, to ensure you take notice of the issue.
You can download and install GNU coreutils to get an 'rm' implementation
that behaves properly: <http://www.gnu.org/software/coreutils/>.
that behaves properly: <https://www.gnu.org/software/coreutils/>.
If you want to complete the configuration process using your problematic
'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
@ -665,7 +657,7 @@ for _am_header in $config_headers :; do
done
echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
# Copyright (C) 2001-2017 Free Software Foundation, Inc.
# Copyright (C) 2001-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -686,7 +678,7 @@ if test x"${install_sh+set}" != xset; then
fi
AC_SUBST([install_sh])])
# Copyright (C) 2003-2017 Free Software Foundation, Inc.
# Copyright (C) 2003-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -708,7 +700,7 @@ AC_SUBST([am__leading_dot])])
# Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
# From Jim Meyering
# Copyright (C) 1996-2017 Free Software Foundation, Inc.
# Copyright (C) 1996-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -743,7 +735,7 @@ AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
# Check to see how 'make' treats includes. -*- Autoconf -*-
# Copyright (C) 2001-2017 Free Software Foundation, Inc.
# Copyright (C) 2001-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -751,49 +743,42 @@ AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
# AM_MAKE_INCLUDE()
# -----------------
# Check to see how make treats includes.
# Check whether make has an 'include' directive that can support all
# the idioms we need for our automatic dependency tracking code.
AC_DEFUN([AM_MAKE_INCLUDE],
[am_make=${MAKE-make}
cat > confinc << 'END'
[AC_MSG_CHECKING([whether ${MAKE-make} supports the include directive])
cat > confinc.mk << 'END'
am__doit:
@echo this is the am__doit target
@echo this is the am__doit target >confinc.out
.PHONY: am__doit
END
# If we don't find an include directive, just comment out the code.
AC_MSG_CHECKING([for style of include used by $am_make])
am__include="#"
am__quote=
_am_result=none
# First try GNU make style include.
echo "include confinc" > confmf
# Ignore all kinds of additional output from 'make'.
case `$am_make -s -f confmf 2> /dev/null` in #(
*the\ am__doit\ target*)
am__include=include
am__quote=
_am_result=GNU
;;
esac
# Now try BSD make style include.
if test "$am__include" = "#"; then
echo '.include "confinc"' > confmf
case `$am_make -s -f confmf 2> /dev/null` in #(
*the\ am__doit\ target*)
am__include=.include
am__quote="\""
_am_result=BSD
;;
esac
# BSD make does it like this.
echo '.include "confinc.mk" # ignored' > confmf.BSD
# Other make implementations (GNU, Solaris 10, AIX) do it like this.
echo 'include confinc.mk # ignored' > confmf.GNU
_am_result=no
for s in GNU BSD; do
AM_RUN_LOG([${MAKE-make} -f confmf.$s && cat confinc.out])
AS_CASE([$?:`cat confinc.out 2>/dev/null`],
['0:this is the am__doit target'],
[AS_CASE([$s],
[BSD], [am__include='.include' am__quote='"'],
[am__include='include' am__quote=''])])
if test "$am__include" != "#"; then
_am_result="yes ($s style)"
break
fi
AC_SUBST([am__include])
AC_SUBST([am__quote])
AC_MSG_RESULT([$_am_result])
rm -f confinc confmf
])
done
rm -f confinc.* confmf.*
AC_MSG_RESULT([${_am_result}])
AC_SUBST([am__include])])
AC_SUBST([am__quote])])
# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
# Copyright (C) 1997-2017 Free Software Foundation, Inc.
# Copyright (C) 1997-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -832,7 +817,7 @@ fi
# Helper functions for option handling. -*- Autoconf -*-
# Copyright (C) 2001-2017 Free Software Foundation, Inc.
# Copyright (C) 2001-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -861,7 +846,7 @@ AC_DEFUN([_AM_SET_OPTIONS],
AC_DEFUN([_AM_IF_OPTION],
[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
# Copyright (C) 1999-2017 Free Software Foundation, Inc.
# Copyright (C) 1999-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -908,7 +893,7 @@ AC_LANG_POP([C])])
# For backward compatibility.
AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
# Copyright (C) 2001-2017 Free Software Foundation, Inc.
# Copyright (C) 2001-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -927,7 +912,7 @@ AC_DEFUN([AM_RUN_LOG],
# Check to make sure that the build environment is sane. -*- Autoconf -*-
# Copyright (C) 1996-2017 Free Software Foundation, Inc.
# Copyright (C) 1996-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -1008,7 +993,7 @@ AC_CONFIG_COMMANDS_PRE(
rm -f conftest.file
])
# Copyright (C) 2009-2017 Free Software Foundation, Inc.
# Copyright (C) 2009-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -1068,7 +1053,7 @@ AC_SUBST([AM_BACKSLASH])dnl
_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
])
# Copyright (C) 2001-2017 Free Software Foundation, Inc.
# Copyright (C) 2001-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -1096,7 +1081,7 @@ fi
INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
AC_SUBST([INSTALL_STRIP_PROGRAM])])
# Copyright (C) 2006-2017 Free Software Foundation, Inc.
# Copyright (C) 2006-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -1115,7 +1100,7 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
# Check how to create a tarball. -*- Autoconf -*-
# Copyright (C) 2004-2017 Free Software Foundation, Inc.
# Copyright (C) 2004-2020 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,

View File

@ -2,9 +2,9 @@
# Wrapper for Microsoft lib.exe
me=ar-lib
scriptversion=2012-03-01.08; # UTC
scriptversion=2019-07-04.01; # UTC
# Copyright (C) 2010-2014 Free Software Foundation, Inc.
# Copyright (C) 2010-2020 Free Software Foundation, Inc.
# Written by Peter Rosin <peda@lysator.liu.se>.
#
# This program is free software; you can redistribute it and/or modify
@ -18,7 +18,7 @@ scriptversion=2012-03-01.08; # UTC
# 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/>.
# along with this program. If not, see <https://www.gnu.org/licenses/>.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
@ -53,7 +53,7 @@ func_file_conv ()
MINGW*)
file_conv=mingw
;;
CYGWIN*)
CYGWIN* | MSYS*)
file_conv=cygwin
;;
*)
@ -65,7 +65,7 @@ func_file_conv ()
mingw)
file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'`
;;
cygwin)
cygwin | msys)
file=`cygpath -m "$file" || echo "$file"`
;;
wine)
@ -224,7 +224,8 @@ elif test -n "$extract"; then
esac
done
else
$AR -NOLOGO -LIST "$archive" | sed -e 's/\\/\\\\/g' | while read member
$AR -NOLOGO -LIST "$archive" | tr -d '\r' | sed -e 's/\\/\\\\/g' \
| while read member
do
$AR -NOLOGO -EXTRACT:"$member" "$archive" || exit $?
done

View File

@ -1,9 +1,9 @@
#!/bin/sh
# Wrapper for compilers which do not understand '-c -o'.
scriptversion=2012-10-14.11; # UTC
scriptversion=2018-03-07.03; # UTC
# Copyright (C) 1999-2014 Free Software Foundation, Inc.
# Copyright (C) 1999-2020 Free Software Foundation, Inc.
# Written by Tom Tromey <tromey@cygnus.com>.
#
# This program is free software; you can redistribute it and/or modify
@ -17,7 +17,7 @@ scriptversion=2012-10-14.11; # UTC
# 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/>.
# along with this program. If not, see <https://www.gnu.org/licenses/>.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
@ -53,7 +53,7 @@ func_file_conv ()
MINGW*)
file_conv=mingw
;;
CYGWIN*)
CYGWIN* | MSYS*)
file_conv=cygwin
;;
*)
@ -67,7 +67,7 @@ func_file_conv ()
mingw/*)
file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'`
;;
cygwin/*)
cygwin/* | msys/*)
file=`cygpath -m "$file" || echo "$file"`
;;
wine/*)
@ -255,7 +255,8 @@ EOF
echo "compile $scriptversion"
exit $?
;;
cl | *[/\\]cl | cl.exe | *[/\\]cl.exe )
cl | *[/\\]cl | cl.exe | *[/\\]cl.exe | \
icl | *[/\\]icl | icl.exe | *[/\\]icl.exe )
func_cl_wrapper "$@" # Doesn't return...
;;
esac
@ -339,9 +340,9 @@ exit $ret
# Local Variables:
# mode: shell-script
# sh-indentation: 2
# eval: (add-hook 'write-file-hooks 'time-stamp)
# eval: (add-hook 'before-save-hook 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC"
# time-stamp-time-zone: "UTC0"
# time-stamp-end: "; # UTC"
# End:

File diff suppressed because it is too large Load Diff

1793
gcc/mpc/build-aux/config.sub vendored Executable file

File diff suppressed because it is too large Load Diff

View File

@ -1,9 +1,9 @@
#!/bin/sh
# depcomp - compile a program generating dependencies as side-effects
scriptversion=2013-05-30.07; # UTC
scriptversion=2018-03-07.03; # UTC
# Copyright (C) 1999-2014 Free Software Foundation, Inc.
# Copyright (C) 1999-2020 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
@ -16,7 +16,7 @@ scriptversion=2013-05-30.07; # UTC
# 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/>.
# along with this program. If not, see <https://www.gnu.org/licenses/>.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
@ -783,9 +783,9 @@ exit 0
# Local Variables:
# mode: shell-script
# sh-indentation: 2
# eval: (add-hook 'write-file-hooks 'time-stamp)
# eval: (add-hook 'before-save-hook 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC"
# time-stamp-time-zone: "UTC0"
# time-stamp-end: "; # UTC"
# End:

View File

@ -1,7 +1,7 @@
#!/bin/sh
# install - install a program, script, or datafile
scriptversion=2013-12-25.23; # UTC
scriptversion=2018-03-11.20; # UTC
# This originates from X11R5 (mit/util/scripts/install.sh), which was
# later released in X11R6 (xc/config/util/install.sh) with the
@ -271,15 +271,18 @@ do
fi
dst=$dst_arg
# If destination is a directory, append the input filename; won't work
# if double slashes aren't ignored.
# If destination is a directory, append the input filename.
if test -d "$dst"; then
if test "$is_target_a_directory" = never; then
echo "$0: $dst_arg: Is a directory" >&2
exit 1
fi
dstdir=$dst
dst=$dstdir/`basename "$src"`
dstbase=`basename "$src"`
case $dst in
*/) dst=$dst$dstbase;;
*) dst=$dst/$dstbase;;
esac
dstdir_status=0
else
dstdir=`dirname "$dst"`
@ -288,6 +291,11 @@ do
fi
fi
case $dstdir in
*/) dstdirslash=$dstdir;;
*) dstdirslash=$dstdir/;;
esac
obsolete_mkdir_used=false
if test $dstdir_status != 0; then
@ -324,34 +332,43 @@ do
# is incompatible with FreeBSD 'install' when (umask & 300) != 0.
;;
*)
# Note that $RANDOM variable is not portable (e.g. dash); Use it
# here however when possible just to lower collision chance.
tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$
trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0
trap 'ret=$?; rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null; exit $ret' 0
# Because "mkdir -p" follows existing symlinks and we likely work
# directly in world-writeable /tmp, make sure that the '$tmpdir'
# directory is successfully created first before we actually test
# 'mkdir -p' feature.
if (umask $mkdir_umask &&
exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1
$mkdirprog $mkdir_mode "$tmpdir" &&
exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1
then
if test -z "$dir_arg" || {
# Check for POSIX incompatibilities with -m.
# HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or
# other-writable bit of parent directory when it shouldn't.
# FreeBSD 6.1 mkdir -m -p sets mode of existing directory.
ls_ld_tmpdir=`ls -ld "$tmpdir"`
test_tmpdir="$tmpdir/a"
ls_ld_tmpdir=`ls -ld "$test_tmpdir"`
case $ls_ld_tmpdir in
d????-?r-*) different_mode=700;;
d????-?--*) different_mode=755;;
*) false;;
esac &&
$mkdirprog -m$different_mode -p -- "$tmpdir" && {
ls_ld_tmpdir_1=`ls -ld "$tmpdir"`
$mkdirprog -m$different_mode -p -- "$test_tmpdir" && {
ls_ld_tmpdir_1=`ls -ld "$test_tmpdir"`
test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1"
}
}
then posix_mkdir=:
fi
rmdir "$tmpdir/d" "$tmpdir"
rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir"
else
# Remove any dirs left behind by ancient mkdir implementations.
rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null
rmdir ./$mkdir_mode ./-p ./-- "$tmpdir" 2>/dev/null
fi
trap '' 0;;
esac;;
@ -427,14 +444,25 @@ do
else
# Make a couple of temp file names in the proper directory.
dsttmp=$dstdir/_inst.$$_
rmtmp=$dstdir/_rm.$$_
dsttmp=${dstdirslash}_inst.$$_
rmtmp=${dstdirslash}_rm.$$_
# Trap to clean up those temp files at exit.
trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0
# Copy the file name to the temp name.
(umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") &&
(umask $cp_umask &&
{ test -z "$stripcmd" || {
# Create $dsttmp read-write so that cp doesn't create it read-only,
# which would cause strip to fail.
if test -z "$doit"; then
: >"$dsttmp" # No need to fork-exec 'touch'.
else
$doit touch "$dsttmp"
fi
}
} &&
$doit_exec $cpprog "$src" "$dsttmp") &&
# and set any options; do chmod last to preserve setuid bits.
#
@ -493,9 +521,9 @@ do
done
# Local variables:
# eval: (add-hook 'write-file-hooks 'time-stamp)
# eval: (add-hook 'before-save-hook 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC"
# time-stamp-time-zone: "UTC0"
# time-stamp-end: "; # UTC"
# End:

2
gcc/mpc/ltmain.sh → gcc/mpc/build-aux/ltmain.sh Normal file → Executable file
View File

@ -1,4 +1,4 @@
#!/gnu/store/311nvir0pz1mhf0mgsmfrw00qfj7yq0j-bash-4.3.39/bin/sh
#!/bin/sh
## DO NOT EDIT - This file generated from ./build-aux/ltmain.in
## by inline-source v2014-01-03.01

228
gcc/mpc/build-aux/mdate-sh Executable file
View File

@ -0,0 +1,228 @@
#!/bin/sh
# Get modification time of a file or directory and pretty-print it.
scriptversion=2018-03-07.03; # UTC
# Copyright (C) 1995-2020 Free Software Foundation, Inc.
# written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, June 1995
#
# 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 2, 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 <https://www.gnu.org/licenses/>.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
# This file is maintained in Automake, please report
# bugs to <bug-automake@gnu.org> or send patches to
# <automake-patches@gnu.org>.
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
emulate sh
NULLCMD=:
# Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
# is contrary to our usage. Disable this feature.
alias -g '${1+"$@"}'='"$@"'
setopt NO_GLOB_SUBST
fi
case $1 in
'')
echo "$0: No file. Try '$0 --help' for more information." 1>&2
exit 1;
;;
-h | --h*)
cat <<\EOF
Usage: mdate-sh [--help] [--version] FILE
Pretty-print the modification day of FILE, in the format:
1 January 1970
Report bugs to <bug-automake@gnu.org>.
EOF
exit $?
;;
-v | --v*)
echo "mdate-sh $scriptversion"
exit $?
;;
esac
error ()
{
echo "$0: $1" >&2
exit 1
}
# Prevent date giving response in another language.
LANG=C
export LANG
LC_ALL=C
export LC_ALL
LC_TIME=C
export LC_TIME
# Use UTC to get reproducible result.
TZ=UTC0
export TZ
# GNU ls changes its time format in response to the TIME_STYLE
# variable. Since we cannot assume 'unset' works, revert this
# variable to its documented default.
if test "${TIME_STYLE+set}" = set; then
TIME_STYLE=posix-long-iso
export TIME_STYLE
fi
save_arg1=$1
# Find out how to get the extended ls output of a file or directory.
if ls -L /dev/null 1>/dev/null 2>&1; then
ls_command='ls -L -l -d'
else
ls_command='ls -l -d'
fi
# Avoid user/group names that might have spaces, when possible.
if ls -n /dev/null 1>/dev/null 2>&1; then
ls_command="$ls_command -n"
fi
# A 'ls -l' line looks as follows on OS/2.
# drwxrwx--- 0 Aug 11 2001 foo
# This differs from Unix, which adds ownership information.
# drwxrwx--- 2 root root 4096 Aug 11 2001 foo
#
# To find the date, we split the line on spaces and iterate on words
# until we find a month. This cannot work with files whose owner is a
# user named "Jan", or "Feb", etc. However, it's unlikely that '/'
# will be owned by a user whose name is a month. So we first look at
# the extended ls output of the root directory to decide how many
# words should be skipped to get the date.
# On HPUX /bin/sh, "set" interprets "-rw-r--r--" as options, so the "x" below.
set x`$ls_command /`
# Find which argument is the month.
month=
command=
until test $month
do
test $# -gt 0 || error "failed parsing '$ls_command /' output"
shift
# Add another shift to the command.
command="$command shift;"
case $1 in
Jan) month=January; nummonth=1;;
Feb) month=February; nummonth=2;;
Mar) month=March; nummonth=3;;
Apr) month=April; nummonth=4;;
May) month=May; nummonth=5;;
Jun) month=June; nummonth=6;;
Jul) month=July; nummonth=7;;
Aug) month=August; nummonth=8;;
Sep) month=September; nummonth=9;;
Oct) month=October; nummonth=10;;
Nov) month=November; nummonth=11;;
Dec) month=December; nummonth=12;;
esac
done
test -n "$month" || error "failed parsing '$ls_command /' output"
# Get the extended ls output of the file or directory.
set dummy x`eval "$ls_command \"\\\$save_arg1\""`
# Remove all preceding arguments
eval $command
# Because of the dummy argument above, month is in $2.
#
# On a POSIX system, we should have
#
# $# = 5
# $1 = file size
# $2 = month
# $3 = day
# $4 = year or time
# $5 = filename
#
# On Darwin 7.7.0 and 7.6.0, we have
#
# $# = 4
# $1 = day
# $2 = month
# $3 = year or time
# $4 = filename
# Get the month.
case $2 in
Jan) month=January; nummonth=1;;
Feb) month=February; nummonth=2;;
Mar) month=March; nummonth=3;;
Apr) month=April; nummonth=4;;
May) month=May; nummonth=5;;
Jun) month=June; nummonth=6;;
Jul) month=July; nummonth=7;;
Aug) month=August; nummonth=8;;
Sep) month=September; nummonth=9;;
Oct) month=October; nummonth=10;;
Nov) month=November; nummonth=11;;
Dec) month=December; nummonth=12;;
esac
case $3 in
???*) day=$1;;
*) day=$3; shift;;
esac
# Here we have to deal with the problem that the ls output gives either
# the time of day or the year.
case $3 in
*:*) set `date`; eval year=\$$#
case $2 in
Jan) nummonthtod=1;;
Feb) nummonthtod=2;;
Mar) nummonthtod=3;;
Apr) nummonthtod=4;;
May) nummonthtod=5;;
Jun) nummonthtod=6;;
Jul) nummonthtod=7;;
Aug) nummonthtod=8;;
Sep) nummonthtod=9;;
Oct) nummonthtod=10;;
Nov) nummonthtod=11;;
Dec) nummonthtod=12;;
esac
# For the first six month of the year the time notation can also
# be used for files modified in the last year.
if (expr $nummonth \> $nummonthtod) > /dev/null;
then
year=`expr $year - 1`
fi;;
*) year=$3;;
esac
# The result.
echo $day $month $year
# Local Variables:
# mode: shell-script
# sh-indentation: 2
# eval: (add-hook 'before-save-hook 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC0"
# time-stamp-end: "; # UTC"
# End:

View File

@ -1,9 +1,9 @@
#!/bin/sh
# Common wrapper for a few potentially missing GNU programs.
scriptversion=2013-10-28.13; # UTC
scriptversion=2018-03-07.03; # UTC
# Copyright (C) 1996-2014 Free Software Foundation, Inc.
# Copyright (C) 1996-2020 Free Software Foundation, Inc.
# Originally written by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
# This program is free software; you can redistribute it and/or modify
@ -17,7 +17,7 @@ scriptversion=2013-10-28.13; # UTC
# 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/>.
# along with this program. If not, see <https://www.gnu.org/licenses/>.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
@ -101,9 +101,9 @@ else
exit $st
fi
perl_URL=http://www.perl.org/
flex_URL=http://flex.sourceforge.net/
gnu_software_URL=http://www.gnu.org/software
perl_URL=https://www.perl.org/
flex_URL=https://github.com/westes/flex
gnu_software_URL=https://www.gnu.org/software
program_details ()
{
@ -207,9 +207,9 @@ give_advice "$1" | sed -e '1s/^/WARNING: /' \
exit $st
# Local variables:
# eval: (add-hook 'write-file-hooks 'time-stamp)
# eval: (add-hook 'before-save-hook 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC"
# time-stamp-time-zone: "UTC0"
# time-stamp-end: "; # UTC"
# End:

View File

@ -1,9 +1,9 @@
#!/bin/sh
# test-driver - basic testsuite driver script.
scriptversion=2013-07-13.22; # UTC
scriptversion=2018-03-07.03; # UTC
# Copyright (C) 2011-2014 Free Software Foundation, Inc.
# Copyright (C) 2011-2020 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
@ -16,7 +16,7 @@ scriptversion=2013-07-13.22; # UTC
# 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/>.
# along with this program. If not, see <https://www.gnu.org/licenses/>.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
@ -140,9 +140,9 @@ echo ":copy-in-global-log: $gcopy" >> $trs_file
# Local Variables:
# mode: shell-script
# sh-indentation: 2
# eval: (add-hook 'write-file-hooks 'time-stamp)
# eval: (add-hook 'before-save-hook 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC"
# time-stamp-time-zone: "UTC0"
# time-stamp-end: "; # UTC"
# End:

11614
gcc/mpc/build-aux/texinfo.tex Normal file

File diff suppressed because it is too large Load Diff

1807
gcc/mpc/config.sub vendored

File diff suppressed because it is too large Load Diff

331
gcc/mpc/configure vendored
View File

@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.69 for mpc 1.1.0.
# Generated by GNU Autoconf 2.69 for mpc 1.2.0.
#
# Report bugs to <mpc-discuss@lists.gforge.inria.fr>.
#
@ -590,8 +590,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='mpc'
PACKAGE_TARNAME='mpc'
PACKAGE_VERSION='1.1.0'
PACKAGE_STRING='mpc 1.1.0'
PACKAGE_VERSION='1.2.0'
PACKAGE_STRING='mpc 1.2.0'
PACKAGE_BUGREPORT='mpc-discuss@lists.gforge.inria.fr'
PACKAGE_URL=''
@ -669,7 +669,6 @@ am__nodep
AMDEPBACKSLASH
AMDEP_FALSE
AMDEP_TRUE
am__quote
am__include
DEPDIR
OBJEXT
@ -759,7 +758,8 @@ PACKAGE_VERSION
PACKAGE_TARNAME
PACKAGE_NAME
PATH_SEPARATOR
SHELL'
SHELL
am__quote'
ac_subst_files=''
ac_user_opts='
enable_option_checking
@ -1333,7 +1333,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
\`configure' configures mpc 1.1.0 to adapt to many kinds of systems.
\`configure' configures mpc 1.2.0 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@ -1403,7 +1403,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of mpc 1.1.0:";;
short | recursive ) echo "Configuration of mpc 1.2.0:";;
esac
cat <<\_ACEOF
@ -1525,7 +1525,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
mpc configure 1.1.0
mpc configure 1.2.0
generated by GNU Autoconf 2.69
Copyright (C) 2012 Free Software Foundation, Inc.
@ -1948,7 +1948,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by mpc $as_me 1.1.0, which was
It was created by mpc $as_me 1.2.0, which was
generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
@ -2297,13 +2297,8 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
ac_config_headers="$ac_config_headers config.h"
am__api_version='1.15'
ac_aux_dir=
for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
for ac_dir in build-aux "$srcdir"/build-aux; do
if test -f "$ac_dir/install-sh"; then
ac_aux_dir=$ac_dir
ac_install_sh="$ac_aux_dir/install-sh -c"
@ -2319,7 +2314,7 @@ for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
fi
done
if test -z "$ac_aux_dir"; then
as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
as_fn_error $? "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
fi
# These three variables are undocumented and unsupported,
@ -2331,6 +2326,11 @@ ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
ac_config_headers="$ac_config_headers config.h"
am__api_version='1.16'
# Find a good install program. We prefer a C program (faster),
# so one script is as good as another. But avoid the broken or
# incompatible versions:
@ -2815,7 +2815,7 @@ fi
# Define the identity of the package.
PACKAGE='mpc'
VERSION='1.1.0'
VERSION='1.2.0'
cat >>confdefs.h <<_ACEOF
@ -2845,8 +2845,8 @@ MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
# For better backward compatibility. To be removed once Automake 1.9.x
# dies out for good. For more background, see:
# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
# <https://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
# <https://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
mkdir_p='$(MKDIR_P)'
# We need awk for the "check" target (and possibly the TAP driver). The
@ -2897,7 +2897,7 @@ END
Aborting the configuration process, to ensure you take notice of the issue.
You can download and install GNU coreutils to get an 'rm' implementation
that behaves properly: <http://www.gnu.org/software/coreutils/>.
that behaves properly: <https://www.gnu.org/software/coreutils/>.
If you want to complete the configuration process using your problematic
'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
@ -4270,45 +4270,45 @@ DEPDIR="${am__leading_dot}deps"
ac_config_commands="$ac_config_commands depfiles"
am_make=${MAKE-make}
cat > confinc << 'END'
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5
$as_echo_n "checking whether ${MAKE-make} supports the include directive... " >&6; }
cat > confinc.mk << 'END'
am__doit:
@echo this is the am__doit target
@echo this is the am__doit target >confinc.out
.PHONY: am__doit
END
# If we don't find an include directive, just comment out the code.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
$as_echo_n "checking for style of include used by $am_make... " >&6; }
am__include="#"
am__quote=
_am_result=none
# First try GNU make style include.
echo "include confinc" > confmf
# Ignore all kinds of additional output from 'make'.
case `$am_make -s -f confmf 2> /dev/null` in #(
*the\ am__doit\ target*)
am__include=include
am__quote=
_am_result=GNU
;;
esac
# Now try BSD make style include.
if test "$am__include" = "#"; then
echo '.include "confinc"' > confmf
case `$am_make -s -f confmf 2> /dev/null` in #(
*the\ am__doit\ target*)
am__include=.include
am__quote="\""
_am_result=BSD
# BSD make does it like this.
echo '.include "confinc.mk" # ignored' > confmf.BSD
# Other make implementations (GNU, Solaris 10, AIX) do it like this.
echo 'include confinc.mk # ignored' > confmf.GNU
_am_result=no
for s in GNU BSD; do
{ echo "$as_me:$LINENO: ${MAKE-make} -f confmf.$s && cat confinc.out" >&5
(${MAKE-make} -f confmf.$s && cat confinc.out) >&5 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }
case $?:`cat confinc.out 2>/dev/null` in #(
'0:this is the am__doit target') :
case $s in #(
BSD) :
am__include='.include' am__quote='"' ;; #(
*) :
am__include='include' am__quote='' ;;
esac ;; #(
*) :
;;
esac
if test "$am__include" != "#"; then
_am_result="yes ($s style)"
break
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
$as_echo "$_am_result" >&6; }
rm -f confinc confmf
done
rm -f confinc.* confmf.*
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5
$as_echo "${_am_result}" >&6; }
# Check whether --enable-dependency-tracking was given.
if test "${enable_dependency_tracking+set}" = set; then :
@ -12539,85 +12539,6 @@ if test -z "$USER_CFLAGS"; then
if echo $VERSION | grep -c dev >/dev/null 2>&1 ; then
if test "x$GCC" = "xyes" -a "x$compiler" != "xicc"; then
# enable -Werror for myself (Andreas Enge)
if test "x$USER" = "xenge"; then
flag=`echo "-Werror" | $SED 'y% .=/+-(){}<>:*,%_______________%'`
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler accepts the -Werror flag" >&5
$as_echo_n "checking whether the C compiler accepts the -Werror flag... " >&6; }
if eval \${ax_cv_c_check_flag_$flag+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
save_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -Werror"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
main ()
{
;
return 0;
}
_ACEOF
if ac_fn_c_try_compile "$LINENO"; then :
eval "ax_cv_c_check_flag_$flag=yes"
else
eval "ax_cv_c_check_flag_$flag=no"
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
CFLAGS="$save_CFLAGS"
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
fi
eval ac_res=\$ax_cv_c_check_flag_$flag
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if eval "test \"`echo '$ax_cv_c_check_flag_'$flag`\" = yes"; then :
:
CFLAGS="$CFLAGS -Werror"
else
:
fi
fi
@ -13985,7 +13906,7 @@ $as_echo "no" >&6; }
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
# Check for a recent MPFR: we require MPFR 3.0.0 for MPC_RNDA
# Check for a recent MPFR: we require MPFR 4.1.0
# The same remark as above for GMP applies.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for recent MPFR" >&5
$as_echo_n "checking for recent MPFR... " >&6; }
@ -13993,8 +13914,8 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include "mpfr.h"
#if (MPFR_VERSION < MPFR_VERSION_NUM (3,0,0))
# error "Minimal MPFR version is 3.0.0"
#if (MPFR_VERSION < MPFR_VERSION_NUM (4,1,0))
# error "Minimal MPFR version is 4.1.0"
error
#endif
@ -14006,7 +13927,7 @@ else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
as_fn_error $? "MPFR version >= 3.0.0 required" "$LINENO" 5
as_fn_error $? "MPFR version >= 4.1.0 required" "$LINENO" 5
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
@ -14670,7 +14591,7 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for current git version" >&5
$as_echo_n "checking for current git version... " >&6; }
GITVERSION=dd39695
GITVERSION=9ab01ab
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $GITVERSION" >&5
@ -14680,7 +14601,7 @@ fi
fi
ac_config_files="$ac_config_files Makefile src/Makefile tests/Makefile doc/Makefile tools/Makefile tools/bench/Makefile"
ac_config_files="$ac_config_files Makefile src/Makefile tests/Makefile doc/Makefile tools/Makefile tools/bench/Makefile tools/mpcheck/Makefile"
cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
@ -15216,7 +15137,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by mpc $as_me 1.1.0, which was
This file was extended by mpc $as_me 1.2.0, which was
generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@ -15282,7 +15203,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
mpc config.status 1.1.0
mpc config.status 1.2.0
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"
@ -15401,7 +15322,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
#
# INIT-COMMANDS
#
AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"
# The HP-UX ksh and POSIX shell print the target directory to stdout
@ -15705,6 +15626,7 @@ do
"doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
"tools/Makefile") CONFIG_FILES="$CONFIG_FILES tools/Makefile" ;;
"tools/bench/Makefile") CONFIG_FILES="$CONFIG_FILES tools/bench/Makefile" ;;
"tools/mpcheck/Makefile") CONFIG_FILES="$CONFIG_FILES tools/mpcheck/Makefile" ;;
*) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
esac
@ -16304,29 +16226,35 @@ $as_echo "$as_me: executing $ac_file commands" >&6;}
# Older Autoconf quotes --file arguments for eval, but not when files
# are listed without --file. Let's play safe and only enable the eval
# if we detect the quoting.
case $CONFIG_FILES in
*\'*) eval set x "$CONFIG_FILES" ;;
*) set x $CONFIG_FILES ;;
# TODO: see whether this extra hack can be removed once we start
# requiring Autoconf 2.70 or later.
case $CONFIG_FILES in #(
*\'*) :
eval set x "$CONFIG_FILES" ;; #(
*) :
set x $CONFIG_FILES ;; #(
*) :
;;
esac
shift
for mf
# Used to flag and report bootstrapping failures.
am_rc=0
for am_mf
do
# Strip MF so we end up with the name of the file.
mf=`echo "$mf" | sed -e 's/:.*$//'`
# Check whether this is an Automake generated Makefile or not.
# We used to match only the files named 'Makefile.in', but
# some people rename them; so instead we look at the file content.
# Grep'ing the first line is not enough: some people post-process
# each Makefile.in and add a new line on top of each file to say so.
# Grep'ing the whole file is not good either: AIX grep has a line
am_mf=`$as_echo "$am_mf" | sed -e 's/:.*$//'`
# Check whether this is an Automake generated Makefile which includes
# dependency-tracking related rules and includes.
# Grep'ing the whole file directly is not great: AIX grep has a line
# limit of 2048, but all sed's we know have understand at least 4000.
if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
dirpart=`$as_dirname -- "$mf" ||
$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$mf" : 'X\(//\)[^/]' \| \
X"$mf" : 'X\(//\)$' \| \
X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X"$mf" |
sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \
|| continue
am_dirpart=`$as_dirname -- "$am_mf" ||
$as_expr X"$am_mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$am_mf" : 'X\(//\)[^/]' \| \
X"$am_mf" : 'X\(//\)$' \| \
X"$am_mf" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X"$am_mf" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@ -16344,53 +16272,50 @@ $as_echo X"$mf" |
q
}
s/.*/./; q'`
else
continue
am_filepart=`$as_basename -- "$am_mf" ||
$as_expr X/"$am_mf" : '.*/\([^/][^/]*\)/*$' \| \
X"$am_mf" : 'X\(//\)$' \| \
X"$am_mf" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X/"$am_mf" |
sed '/^.*\/\([^/][^/]*\)\/*$/{
s//\1/
q
}
/^X\/\(\/\/\)$/{
s//\1/
q
}
/^X\/\(\/\).*/{
s//\1/
q
}
s/.*/./; q'`
{ echo "$as_me:$LINENO: cd "$am_dirpart" \
&& sed -e '/# am--include-marker/d' "$am_filepart" \
| $MAKE -f - am--depfiles" >&5
(cd "$am_dirpart" \
&& sed -e '/# am--include-marker/d' "$am_filepart" \
| $MAKE -f - am--depfiles) >&5 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } || am_rc=$?
done
if test $am_rc -ne 0; then
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
as_fn_error $? "Something went wrong bootstrapping makefile fragments
for automatic dependency tracking. If GNU make was not used, consider
re-running the configure script with MAKE=\"gmake\" (or whatever is
necessary). You can also try re-running configure with the
'--disable-dependency-tracking' option to at least be able to build
the package (albeit without support for automatic dependency tracking).
See \`config.log' for more details" "$LINENO" 5; }
fi
# Extract the definition of DEPDIR, am__include, and am__quote
# from the Makefile without running 'make'.
DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
test -z "$DEPDIR" && continue
am__include=`sed -n 's/^am__include = //p' < "$mf"`
test -z "$am__include" && continue
am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
# Find all dependency output files, they are included files with
# $(DEPDIR) in their names. We invoke sed twice because it is the
# simplest approach to changing $(DEPDIR) to its actual value in the
# expansion.
for file in `sed -n "
s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
# Make sure the directory exists.
test -f "$dirpart/$file" && continue
fdir=`$as_dirname -- "$file" ||
$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$file" : 'X\(//\)[^/]' \| \
X"$file" : 'X\(//\)$' \| \
X"$file" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X"$file" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
}
/^X\(\/\/\)[^/].*/{
s//\1/
q
}
/^X\(\/\/\)$/{
s//\1/
q
}
/^X\(\/\).*/{
s//\1/
q
}
s/.*/./; q'`
as_dir=$dirpart/$fdir; as_fn_mkdir_p
# echo "creating $dirpart/$file"
echo '# dummy' > "$dirpart/$file"
done
done
{ am_dirpart=; unset am_dirpart;}
{ am_filepart=; unset am_filepart;}
{ am_mf=; unset am_mf;}
{ am_rc=; unset am_rc;}
rm -f conftest-deps.mk
}
;;
"libtool":C)

View File

@ -1,4 +1,4 @@
# Copyright (C) 2008, 2009, 2010, 2011, 2012, 2014, 2016, 2017 INRIA
# Copyright (C) 2008, 2009, 2010, 2011, 2012, 2014, 2016, 2017, 2018, 2020 INRIA
#
# This file is part of GNU MPC.
#
@ -20,8 +20,9 @@
# Process this file with autoconf to produce a configure script.
AC_PREREQ(2.61)
AC_INIT(mpc, 1.1.0, mpc-discuss@lists.gforge.inria.fr)
AC_INIT(mpc, 1.2.0, mpc-discuss@lists.gforge.inria.fr)
AC_CONFIG_SRCDIR([src/mpc-impl.h])
AC_CONFIG_AUX_DIR([build-aux])
AC_CONFIG_HEADER([config.h])
AM_INIT_AUTOMAKE
@ -203,22 +204,22 @@ error
AC_MSG_ERROR([GMP version >= 5.0.0 required])
])
# Check for a recent MPFR: we require MPFR 3.0.0 for MPC_RNDA
# Check for a recent MPFR: we require MPFR 4.1.0
# The same remark as above for GMP applies.
AC_MSG_CHECKING(for recent MPFR)
AC_COMPILE_IFELSE(
[AC_LANG_SOURCE(
[[
#include "mpfr.h"
#if (MPFR_VERSION < MPFR_VERSION_NUM (3,0,0))
# error "Minimal MPFR version is 3.0.0"
#if (MPFR_VERSION < MPFR_VERSION_NUM (4,1,0))
# error "Minimal MPFR version is 4.1.0"
error
#endif
]])],
[AC_MSG_RESULT(yes)],
[
AC_MSG_RESULT(no)
AC_MSG_ERROR([MPFR version >= 3.0.0 required])
AC_MSG_ERROR([MPFR version >= 4.1.0 required])
])
# Check for logging feature
@ -253,5 +254,5 @@ AC_DEFINE_UNQUOTED([MPC_GCC_VERSION], ["$GCC_VERSION"], [Version of gcc])
# Looks for short git hash if the version string contains "dev"
MPC_GITVERSION
AC_CONFIG_FILES([Makefile src/Makefile tests/Makefile doc/Makefile tools/Makefile tools/bench/Makefile])
AC_CONFIG_FILES([Makefile src/Makefile tests/Makefile doc/Makefile tools/Makefile tools/bench/Makefile tools/mpcheck/Makefile])
AC_OUTPUT

View File

@ -1,7 +1,7 @@
# Makefile.in generated by automake 1.15.1 from Makefile.am.
# Makefile.in generated by automake 1.16.2 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2017 Free Software Foundation, Inc.
# Copyright (C) 1994-2020 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -147,7 +147,8 @@ am__v_texidevnull_ = $(am__v_texidevnull_@AM_DEFAULT_V@)
am__v_texidevnull_0 = > /dev/null
am__v_texidevnull_1 =
INFO_DEPS = $(srcdir)/mpc.info
am__TEXINFO_TEX_DIR = $(srcdir)
TEXINFO_TEX = $(top_srcdir)/build-aux/texinfo.tex
am__TEXINFO_TEX_DIR = $(top_srcdir)/build-aux
DVIS = mpc.dvi
PDFS = mpc.pdf
PSS = mpc.ps
@ -192,7 +193,9 @@ am__uninstall_files_from_dir = { \
$(am__cd) "$$dir" && rm -f $$files; }; \
}
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
am__DIST_COMMON = $(srcdir)/Makefile.in mdate-sh texinfo.tex
am__DIST_COMMON = $(srcdir)/Makefile.in \
$(top_srcdir)/build-aux/mdate-sh \
$(top_srcdir)/build-aux/texinfo.tex mdate-sh texinfo.tex
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
@ -340,8 +343,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
@ -409,7 +412,7 @@ mpc.html: mpc.texi $(srcdir)/version.texi
$(srcdir)/version.texi: @MAINTAINER_MODE_TRUE@ $(srcdir)/stamp-vti
$(srcdir)/stamp-vti: mpc.texi $(top_srcdir)/configure
@(dir=.; test -f ./mpc.texi || dir=$(srcdir); \
set `$(SHELL) $(srcdir)/mdate-sh $$dir/mpc.texi`; \
set `$(SHELL) $(top_srcdir)/build-aux/mdate-sh $$dir/mpc.texi`; \
echo "@set UPDATED $$1 $$2 $$3"; \
echo "@set UPDATED-MONTH $$2 $$3"; \
echo "@set EDITION $(VERSION)"; \
@ -526,7 +529,10 @@ ctags CTAGS:
cscope cscopelist:
distdir: $(DISTFILES)
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \

1834
gcc/mpc/doc/mpc.info Normal file

File diff suppressed because it is too large Load Diff

View File

@ -5,7 +5,7 @@
@synindex tp fn
@set MINGMP 5.0.0
@set MINMPFR 3.0.0
@set MINMPFR 4.1.0
@set AUTHORS Andreas Enge, Philippe Th@'eveny, Paul Zimmermann
@ -13,7 +13,7 @@
This manual is for GNU MPC, a library for multiple precision complex arithmetic,
version @value{VERSION} of @value{UPDATED-MONTH}.
Copyright @copyright{} 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2016 INRIA
Copyright @copyright{} 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2016, 2018, 2020 INRIA
@quotation
Permission is granted to copy, distribute and/or modify this document
@ -79,6 +79,20 @@ x
@end macro
@end ifnottex
@c @m{T,N} is $T$ in tex or @math{N} otherwise. This is an easy way to give
@c different forms for math in tex and info. Commas in N or T don't work,
@c but @C{} can be used instead. \, works in info but not in tex.
@c (copied from mpfr.texi)
@iftex
@macro m {T,N}
@tex$\T\$@end tex
@end macro
@end iftex
@ifnottex
@macro m {T,N}
@math{\N\}
@end macro
@end ifnottex
@node Copying
@unnumbered GNU MPC Copying Conditions
@ -874,6 +888,11 @@ Set @var{rop} to @minus{}@var{op} rounded according to @var{rnd}.
Just changes the sign if @var{rop} and @var{op} are the same variable.
@end deftypefun
@deftypefun int mpc_sum (mpc_t @var{rop}, mpc_ptr* @var{op}, unsigned long @var{n}, mpc_rnd_t @var{rnd})
Set @var{rop} to the sum of the elements in the array @var{op} of
length @var{n}, rounded according to @var{rnd}.
@end deftypefun
@deftypefun int mpc_mul (mpc_t @var{rop}, mpc_t @var{op1}, mpc_t @var{op2}, mpc_rnd_t @var{rnd})
@deftypefunx int mpc_mul_ui (mpc_t @var{rop}, mpc_t @var{op1}, unsigned long int @var{op2}, mpc_rnd_t @var{rnd})
@deftypefunx int mpc_mul_si (mpc_t @var{rop}, mpc_t @var{op1}, long int @var{op2}, mpc_rnd_t @var{rnd})
@ -898,6 +917,11 @@ Set @var{rop} to @var{op1}*@var{op2}+@var{op3},
rounded according to @var{rnd}, with only one final rounding.
@end deftypefun
@deftypefun int mpc_dot (mpc_t @var{rop}, mpc_ptr* @var{op1}, mpc_ptr* @var{op2}, unsigned long @var{n}, mpc_rnd_t @var{rnd})
Set @var{rop} to the dot product of the elements in the arrays @var{op1} and
@var{op2}, both of length @var{n}, rounded according to @var{rnd}.
@end deftypefun
@deftypefun int mpc_div (mpc_t @var{rop}, mpc_t @var{op1}, mpc_t @var{op2}, mpc_rnd_t @var{rnd})
@deftypefunx int mpc_div_ui (mpc_t @var{rop}, mpc_t @var{op1}, unsigned long int @var{op2}, mpc_rnd_t @var{rnd})
@deftypefunx int mpc_div_fr (mpc_t @var{rop}, mpc_t @var{op1}, mpfr_t @var{op2}, mpc_rnd_t @var{rnd})
@ -978,12 +1002,25 @@ Set @var{rop} to the natural and base-10 logarithm of @var{op} respectively,
rounded according to @var{rnd} with the precision of @var{rop}.
The principal branch is chosen, with the branch cut on the negative real axis,
so that the imaginary part of the result lies in
@math{]-\pi , \pi]} and @math{]-\pi/log(10) , \pi/log(10)]} respectively.
@iftex
@math{]-\pi , \pi]}
@end iftex
@ifnottex
]-Pi , Pi]
@end ifnottex
and
@iftex
@math{]-\pi/\log(10) , \pi/\log(10)]}
@end iftex
@ifnottex
]-Pi/log(10) , Pi/log(10)]
@end ifnottex
respectively.
@end deftypefun
@deftypefun int mpc_rootofunity (mpc_t @var{rop}, unsigned long int @var{n}, unsigned long int @var{k}, mpc_rnd_t @var{rnd})
Set @var{rop} to the standard primitive @var{n}-th root of unity raised to the power @var{k}, that is,
@math{\exp (2 \pi i k / n)},
@m{\exp (2 \pi i k / n),exp (2 Pi i k / n)},
rounded according to @var{rnd} with the precision of @var{rop}.
@end deftypefun
@ -1042,7 +1079,13 @@ rounded according to @var{rnd} with the precision of @var{rop}.
Set @var{rop} to the inverse hyperbolic sine, inverse hyperbolic cosine,
inverse hyperbolic tangent of @var{op},
rounded according to @var{rnd} with the precision of @var{rop}.
The branch cut of @var{mpc_acosh} is @math{(-\infty, 1)}.
The branch cut of @var{mpc_acosh} is
@iftex
@math{(-\infty, 1)}.
@end iftex
@ifnottex
(-Inf, 1)
@end ifnottex
@end deftypefun
@node Miscellaneous Complex Functions

View File

@ -1,4 +1,4 @@
@set UPDATED 11 January 2018
@set UPDATED-MONTH January 2018
@set EDITION 1.1.0
@set VERSION 1.1.0
@set UPDATED 17 August 2020
@set UPDATED-MONTH August 2020
@set EDITION 1.2.0
@set VERSION 1.2.0

View File

@ -1,4 +1,4 @@
@set UPDATED 11 January 2018
@set UPDATED-MONTH January 2018
@set EDITION 1.1.0
@set VERSION 1.1.0
@set UPDATED 17 August 2020
@set UPDATED-MONTH August 2020
@set EDITION 1.2.0
@set VERSION 1.2.0

View File

@ -1,6 +1,6 @@
# mpc.m4
#
# Copyright (C) 2008, 2009, 2010, 2011, 2012, 2014 INRIA
# Copyright (C) 2008, 2009, 2010, 2011, 2012, 2014, 2018 INRIA
#
# This file is part of GNU MPC.
#
@ -91,10 +91,6 @@ AC_DEFUN([MPC_C_CHECK_WARNINGCFLAGS], [
AC_REQUIRE([AC_PROG_GREP])
if echo $VERSION | grep -c dev >/dev/null 2>&1 ; then
if test "x$GCC" = "xyes" -a "x$compiler" != "xicc"; then
# enable -Werror for myself (Andreas Enge)
if test "x$USER" = "xenge"; then
MPC_C_CHECK_FLAG(-Werror)
fi
MPC_C_CHECK_FLAG(-g)
MPC_C_CHECK_FLAG(-std=c99)
MPC_C_CHECK_FLAG(-Wno-long-long)

View File

@ -1,6 +1,6 @@
## src/Makefile.am -- Process this file with automake to produce Makefile.in
##
## Copyright (C) 2008, 2009, 2010, 2011, 2012, 2016 INRIA
## Copyright (C) 2008, 2009, 2010, 2011, 2012, 2016, 2018, 2020 INRIA
##
## This file is part of GNU MPC.
##
@ -18,19 +18,19 @@
## along with this program. If not, see http://www.gnu.org/licenses/ .
lib_LTLIBRARIES = libmpc.la
libmpc_la_LDFLAGS = $(MPC_LDFLAGS) -version-info 4:0:1
libmpc_la_LDFLAGS = $(MPC_LDFLAGS) -version-info 5:0:2
libmpc_la_SOURCES = mpc-impl.h abs.c acos.c acosh.c add.c add_fr.c \
add_si.c add_ui.c arg.c asin.c asinh.c atan.c atanh.c clear.c \
cmp.c cmp_abs.c cmp_si_si.c conj.c cos.c cosh.c \
div_2si.c div_2ui.c div.c div_fr.c \
div_ui.c exp.c fma.c fr_div.c fr_sub.c get_prec2.c get_prec.c \
div_2si.c div_2ui.c div.c div_fr.c div_ui.c \
dot.c exp.c fma.c fr_div.c fr_sub.c get_prec2.c get_prec.c \
get_version.c get_x.c imag.c init2.c init3.c inp_str.c log.c log10.c \
mem.c mul_2si.c mul_2ui.c mul.c mul_fr.c mul_i.c mul_si.c mul_ui.c \
neg.c norm.c out_str.c pow.c pow_fr.c \
pow_ld.c pow_d.c pow_si.c pow_ui.c pow_z.c proj.c real.c rootofunity.c \
urandom.c set.c \
set_prec.c set_str.c set_x.c set_x_x.c sin.c sin_cos.c sinh.c sqr.c \
sqrt.c strtoc.c sub.c sub_fr.c sub_ui.c swap.c tan.c tanh.c uceil_log2.c \
ui_div.c ui_ui_sub.c
sqrt.c strtoc.c sub.c sub_fr.c sub_ui.c sum.c swap.c tan.c tanh.c \
uceil_log2.c ui_div.c ui_ui_sub.c
libmpc_la_LIBADD = @LTLIBOBJS@

View File

@ -1,7 +1,7 @@
# Makefile.in generated by automake 1.15.1 from Makefile.am.
# Makefile.in generated by automake 1.16.2 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2017 Free Software Foundation, Inc.
# Copyright (C) 1994-2020 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -137,16 +137,16 @@ libmpc_la_DEPENDENCIES = @LTLIBOBJS@
am_libmpc_la_OBJECTS = abs.lo acos.lo acosh.lo add.lo add_fr.lo \
add_si.lo add_ui.lo arg.lo asin.lo asinh.lo atan.lo atanh.lo \
clear.lo cmp.lo cmp_abs.lo cmp_si_si.lo conj.lo cos.lo cosh.lo \
div_2si.lo div_2ui.lo div.lo div_fr.lo div_ui.lo exp.lo fma.lo \
fr_div.lo fr_sub.lo get_prec2.lo get_prec.lo get_version.lo \
get_x.lo imag.lo init2.lo init3.lo inp_str.lo log.lo log10.lo \
mem.lo mul_2si.lo mul_2ui.lo mul.lo mul_fr.lo mul_i.lo \
mul_si.lo mul_ui.lo neg.lo norm.lo out_str.lo pow.lo pow_fr.lo \
pow_ld.lo pow_d.lo pow_si.lo pow_ui.lo pow_z.lo proj.lo \
real.lo rootofunity.lo urandom.lo set.lo set_prec.lo \
div_2si.lo div_2ui.lo div.lo div_fr.lo div_ui.lo dot.lo exp.lo \
fma.lo fr_div.lo fr_sub.lo get_prec2.lo get_prec.lo \
get_version.lo get_x.lo imag.lo init2.lo init3.lo inp_str.lo \
log.lo log10.lo mem.lo mul_2si.lo mul_2ui.lo mul.lo mul_fr.lo \
mul_i.lo mul_si.lo mul_ui.lo neg.lo norm.lo out_str.lo pow.lo \
pow_fr.lo pow_ld.lo pow_d.lo pow_si.lo pow_ui.lo pow_z.lo \
proj.lo real.lo rootofunity.lo urandom.lo set.lo set_prec.lo \
set_str.lo set_x.lo set_x_x.lo sin.lo sin_cos.lo sinh.lo \
sqr.lo sqrt.lo strtoc.lo sub.lo sub_fr.lo sub_ui.lo swap.lo \
tan.lo tanh.lo uceil_log2.lo ui_div.lo ui_ui_sub.lo
sqr.lo sqrt.lo strtoc.lo sub.lo sub_fr.lo sub_ui.lo sum.lo \
swap.lo tan.lo tanh.lo uceil_log2.lo ui_div.lo ui_ui_sub.lo
libmpc_la_OBJECTS = $(am_libmpc_la_OBJECTS)
AM_V_lt = $(am__v_lt_@AM_V@)
am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
@ -168,8 +168,47 @@ am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
am__v_at_0 = @
am__v_at_1 =
DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
am__maybe_remake_depfiles = depfiles
am__depfiles_remade = $(DEPDIR)/logging.Plo ./$(DEPDIR)/abs.Plo \
./$(DEPDIR)/acos.Plo ./$(DEPDIR)/acosh.Plo ./$(DEPDIR)/add.Plo \
./$(DEPDIR)/add_fr.Plo ./$(DEPDIR)/add_si.Plo \
./$(DEPDIR)/add_ui.Plo ./$(DEPDIR)/arg.Plo \
./$(DEPDIR)/asin.Plo ./$(DEPDIR)/asinh.Plo \
./$(DEPDIR)/atan.Plo ./$(DEPDIR)/atanh.Plo \
./$(DEPDIR)/clear.Plo ./$(DEPDIR)/cmp.Plo \
./$(DEPDIR)/cmp_abs.Plo ./$(DEPDIR)/cmp_si_si.Plo \
./$(DEPDIR)/conj.Plo ./$(DEPDIR)/cos.Plo ./$(DEPDIR)/cosh.Plo \
./$(DEPDIR)/div.Plo ./$(DEPDIR)/div_2si.Plo \
./$(DEPDIR)/div_2ui.Plo ./$(DEPDIR)/div_fr.Plo \
./$(DEPDIR)/div_ui.Plo ./$(DEPDIR)/dot.Plo ./$(DEPDIR)/exp.Plo \
./$(DEPDIR)/fma.Plo ./$(DEPDIR)/fr_div.Plo \
./$(DEPDIR)/fr_sub.Plo ./$(DEPDIR)/get_prec.Plo \
./$(DEPDIR)/get_prec2.Plo ./$(DEPDIR)/get_version.Plo \
./$(DEPDIR)/get_x.Plo ./$(DEPDIR)/imag.Plo \
./$(DEPDIR)/init2.Plo ./$(DEPDIR)/init3.Plo \
./$(DEPDIR)/inp_str.Plo ./$(DEPDIR)/log.Plo \
./$(DEPDIR)/log10.Plo ./$(DEPDIR)/mem.Plo ./$(DEPDIR)/mul.Plo \
./$(DEPDIR)/mul_2si.Plo ./$(DEPDIR)/mul_2ui.Plo \
./$(DEPDIR)/mul_fr.Plo ./$(DEPDIR)/mul_i.Plo \
./$(DEPDIR)/mul_si.Plo ./$(DEPDIR)/mul_ui.Plo \
./$(DEPDIR)/neg.Plo ./$(DEPDIR)/norm.Plo \
./$(DEPDIR)/out_str.Plo ./$(DEPDIR)/pow.Plo \
./$(DEPDIR)/pow_d.Plo ./$(DEPDIR)/pow_fr.Plo \
./$(DEPDIR)/pow_ld.Plo ./$(DEPDIR)/pow_si.Plo \
./$(DEPDIR)/pow_ui.Plo ./$(DEPDIR)/pow_z.Plo \
./$(DEPDIR)/proj.Plo ./$(DEPDIR)/real.Plo \
./$(DEPDIR)/rootofunity.Plo ./$(DEPDIR)/set.Plo \
./$(DEPDIR)/set_prec.Plo ./$(DEPDIR)/set_str.Plo \
./$(DEPDIR)/set_x.Plo ./$(DEPDIR)/set_x_x.Plo \
./$(DEPDIR)/sin.Plo ./$(DEPDIR)/sin_cos.Plo \
./$(DEPDIR)/sinh.Plo ./$(DEPDIR)/sqr.Plo ./$(DEPDIR)/sqrt.Plo \
./$(DEPDIR)/strtoc.Plo ./$(DEPDIR)/sub.Plo \
./$(DEPDIR)/sub_fr.Plo ./$(DEPDIR)/sub_ui.Plo \
./$(DEPDIR)/sum.Plo ./$(DEPDIR)/swap.Plo ./$(DEPDIR)/tan.Plo \
./$(DEPDIR)/tanh.Plo ./$(DEPDIR)/uceil_log2.Plo \
./$(DEPDIR)/ui_div.Plo ./$(DEPDIR)/ui_ui_sub.Plo \
./$(DEPDIR)/urandom.Plo
am__mv = mv -f
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
@ -215,8 +254,8 @@ am__define_uniq_tagged_files = \
done | $(am__uniquify_input)`
ETAGS = etags
CTAGS = ctags
am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp \
logging.c
am__DIST_COMMON = $(srcdir)/Makefile.in \
$(top_srcdir)/build-aux/depcomp logging.c
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
@ -343,20 +382,20 @@ top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
lib_LTLIBRARIES = libmpc.la
libmpc_la_LDFLAGS = $(MPC_LDFLAGS) -version-info 4:0:1
libmpc_la_LDFLAGS = $(MPC_LDFLAGS) -version-info 5:0:2
libmpc_la_SOURCES = mpc-impl.h abs.c acos.c acosh.c add.c add_fr.c \
add_si.c add_ui.c arg.c asin.c asinh.c atan.c atanh.c clear.c \
cmp.c cmp_abs.c cmp_si_si.c conj.c cos.c cosh.c \
div_2si.c div_2ui.c div.c div_fr.c \
div_ui.c exp.c fma.c fr_div.c fr_sub.c get_prec2.c get_prec.c \
div_2si.c div_2ui.c div.c div_fr.c div_ui.c \
dot.c exp.c fma.c fr_div.c fr_sub.c get_prec2.c get_prec.c \
get_version.c get_x.c imag.c init2.c init3.c inp_str.c log.c log10.c \
mem.c mul_2si.c mul_2ui.c mul.c mul_fr.c mul_i.c mul_si.c mul_ui.c \
neg.c norm.c out_str.c pow.c pow_fr.c \
pow_ld.c pow_d.c pow_si.c pow_ui.c pow_z.c proj.c real.c rootofunity.c \
urandom.c set.c \
set_prec.c set_str.c set_x.c set_x_x.c sin.c sin_cos.c sinh.c sqr.c \
sqrt.c strtoc.c sub.c sub_fr.c sub_ui.c swap.c tan.c tanh.c uceil_log2.c \
ui_div.c ui_ui_sub.c
sqrt.c strtoc.c sub.c sub_fr.c sub_ui.c sum.c swap.c tan.c tanh.c \
uceil_log2.c ui_div.c ui_ui_sub.c
libmpc_la_LIBADD = @LTLIBOBJS@
all: all-am
@ -380,8 +419,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
@ -437,87 +476,95 @@ mostlyclean-compile:
distclean-compile:
-rm -f *.tab.c
@AMDEP_TRUE@@am__include@ @am__quote@$(DEPDIR)/logging.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/abs.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/acos.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/acosh.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/add.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/add_fr.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/add_si.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/add_ui.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/arg.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/asin.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/asinh.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atan.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atanh.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clear.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmp.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmp_abs.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmp_si_si.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/conj.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cos.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cosh.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/div.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/div_2si.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/div_2ui.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/div_fr.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/div_ui.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/exp.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fma.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fr_div.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fr_sub.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_prec.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_prec2.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_version.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_x.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/imag.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/init2.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/init3.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inp_str.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/log.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/log10.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mem.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul_2si.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul_2ui.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul_fr.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul_i.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul_si.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul_ui.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/neg.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/norm.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/out_str.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow_d.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow_fr.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow_ld.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow_si.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow_ui.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow_z.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/proj.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/real.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rootofunity.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set_prec.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set_str.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set_x.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set_x_x.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sin.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sin_cos.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sinh.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sqr.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sqrt.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strtoc.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sub.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sub_fr.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sub_ui.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/swap.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tan.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tanh.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/uceil_log2.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ui_div.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ui_ui_sub.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/urandom.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@$(DEPDIR)/logging.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/abs.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/acos.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/acosh.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/add.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/add_fr.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/add_si.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/add_ui.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/arg.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/asin.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/asinh.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atan.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atanh.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clear.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmp.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmp_abs.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmp_si_si.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/conj.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cos.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cosh.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/div.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/div_2si.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/div_2ui.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/div_fr.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/div_ui.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dot.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/exp.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fma.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fr_div.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fr_sub.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_prec.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_prec2.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_version.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_x.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/imag.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/init2.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/init3.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inp_str.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/log.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/log10.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mem.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul_2si.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul_2ui.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul_fr.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul_i.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul_si.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mul_ui.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/neg.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/norm.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/out_str.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow_d.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow_fr.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow_ld.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow_si.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow_ui.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pow_z.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/proj.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/real.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rootofunity.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set_prec.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set_str.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set_x.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/set_x_x.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sin.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sin_cos.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sinh.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sqr.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sqrt.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strtoc.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sub.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sub_fr.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sub_ui.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sum.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/swap.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tan.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tanh.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/uceil_log2.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ui_div.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ui_ui_sub.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/urandom.Plo@am__quote@ # am--include-marker
$(am__depfiles_remade):
@$(MKDIR_P) $(@D)
@echo '# dummy' >$@-t && $(am__mv) $@-t $@
am--depfiles: $(am__depfiles_remade)
.c.o:
@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
@ -598,7 +645,10 @@ cscopelist-am: $(am__tagged_files)
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(DISTFILES)
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
@ -671,7 +721,89 @@ clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \
mostlyclean-am
distclean: distclean-am
-rm -rf $(DEPDIR) ./$(DEPDIR)
-rm -f $(DEPDIR)/logging.Plo
-rm -f ./$(DEPDIR)/abs.Plo
-rm -f ./$(DEPDIR)/acos.Plo
-rm -f ./$(DEPDIR)/acosh.Plo
-rm -f ./$(DEPDIR)/add.Plo
-rm -f ./$(DEPDIR)/add_fr.Plo
-rm -f ./$(DEPDIR)/add_si.Plo
-rm -f ./$(DEPDIR)/add_ui.Plo
-rm -f ./$(DEPDIR)/arg.Plo
-rm -f ./$(DEPDIR)/asin.Plo
-rm -f ./$(DEPDIR)/asinh.Plo
-rm -f ./$(DEPDIR)/atan.Plo
-rm -f ./$(DEPDIR)/atanh.Plo
-rm -f ./$(DEPDIR)/clear.Plo
-rm -f ./$(DEPDIR)/cmp.Plo
-rm -f ./$(DEPDIR)/cmp_abs.Plo
-rm -f ./$(DEPDIR)/cmp_si_si.Plo
-rm -f ./$(DEPDIR)/conj.Plo
-rm -f ./$(DEPDIR)/cos.Plo
-rm -f ./$(DEPDIR)/cosh.Plo
-rm -f ./$(DEPDIR)/div.Plo
-rm -f ./$(DEPDIR)/div_2si.Plo
-rm -f ./$(DEPDIR)/div_2ui.Plo
-rm -f ./$(DEPDIR)/div_fr.Plo
-rm -f ./$(DEPDIR)/div_ui.Plo
-rm -f ./$(DEPDIR)/dot.Plo
-rm -f ./$(DEPDIR)/exp.Plo
-rm -f ./$(DEPDIR)/fma.Plo
-rm -f ./$(DEPDIR)/fr_div.Plo
-rm -f ./$(DEPDIR)/fr_sub.Plo
-rm -f ./$(DEPDIR)/get_prec.Plo
-rm -f ./$(DEPDIR)/get_prec2.Plo
-rm -f ./$(DEPDIR)/get_version.Plo
-rm -f ./$(DEPDIR)/get_x.Plo
-rm -f ./$(DEPDIR)/imag.Plo
-rm -f ./$(DEPDIR)/init2.Plo
-rm -f ./$(DEPDIR)/init3.Plo
-rm -f ./$(DEPDIR)/inp_str.Plo
-rm -f ./$(DEPDIR)/log.Plo
-rm -f ./$(DEPDIR)/log10.Plo
-rm -f ./$(DEPDIR)/mem.Plo
-rm -f ./$(DEPDIR)/mul.Plo
-rm -f ./$(DEPDIR)/mul_2si.Plo
-rm -f ./$(DEPDIR)/mul_2ui.Plo
-rm -f ./$(DEPDIR)/mul_fr.Plo
-rm -f ./$(DEPDIR)/mul_i.Plo
-rm -f ./$(DEPDIR)/mul_si.Plo
-rm -f ./$(DEPDIR)/mul_ui.Plo
-rm -f ./$(DEPDIR)/neg.Plo
-rm -f ./$(DEPDIR)/norm.Plo
-rm -f ./$(DEPDIR)/out_str.Plo
-rm -f ./$(DEPDIR)/pow.Plo
-rm -f ./$(DEPDIR)/pow_d.Plo
-rm -f ./$(DEPDIR)/pow_fr.Plo
-rm -f ./$(DEPDIR)/pow_ld.Plo
-rm -f ./$(DEPDIR)/pow_si.Plo
-rm -f ./$(DEPDIR)/pow_ui.Plo
-rm -f ./$(DEPDIR)/pow_z.Plo
-rm -f ./$(DEPDIR)/proj.Plo
-rm -f ./$(DEPDIR)/real.Plo
-rm -f ./$(DEPDIR)/rootofunity.Plo
-rm -f ./$(DEPDIR)/set.Plo
-rm -f ./$(DEPDIR)/set_prec.Plo
-rm -f ./$(DEPDIR)/set_str.Plo
-rm -f ./$(DEPDIR)/set_x.Plo
-rm -f ./$(DEPDIR)/set_x_x.Plo
-rm -f ./$(DEPDIR)/sin.Plo
-rm -f ./$(DEPDIR)/sin_cos.Plo
-rm -f ./$(DEPDIR)/sinh.Plo
-rm -f ./$(DEPDIR)/sqr.Plo
-rm -f ./$(DEPDIR)/sqrt.Plo
-rm -f ./$(DEPDIR)/strtoc.Plo
-rm -f ./$(DEPDIR)/sub.Plo
-rm -f ./$(DEPDIR)/sub_fr.Plo
-rm -f ./$(DEPDIR)/sub_ui.Plo
-rm -f ./$(DEPDIR)/sum.Plo
-rm -f ./$(DEPDIR)/swap.Plo
-rm -f ./$(DEPDIR)/tan.Plo
-rm -f ./$(DEPDIR)/tanh.Plo
-rm -f ./$(DEPDIR)/uceil_log2.Plo
-rm -f ./$(DEPDIR)/ui_div.Plo
-rm -f ./$(DEPDIR)/ui_ui_sub.Plo
-rm -f ./$(DEPDIR)/urandom.Plo
-rm -f Makefile
distclean-am: clean-am distclean-compile distclean-generic \
distclean-tags
@ -717,7 +849,89 @@ install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-am
-rm -rf $(DEPDIR) ./$(DEPDIR)
-rm -f $(DEPDIR)/logging.Plo
-rm -f ./$(DEPDIR)/abs.Plo
-rm -f ./$(DEPDIR)/acos.Plo
-rm -f ./$(DEPDIR)/acosh.Plo
-rm -f ./$(DEPDIR)/add.Plo
-rm -f ./$(DEPDIR)/add_fr.Plo
-rm -f ./$(DEPDIR)/add_si.Plo
-rm -f ./$(DEPDIR)/add_ui.Plo
-rm -f ./$(DEPDIR)/arg.Plo
-rm -f ./$(DEPDIR)/asin.Plo
-rm -f ./$(DEPDIR)/asinh.Plo
-rm -f ./$(DEPDIR)/atan.Plo
-rm -f ./$(DEPDIR)/atanh.Plo
-rm -f ./$(DEPDIR)/clear.Plo
-rm -f ./$(DEPDIR)/cmp.Plo
-rm -f ./$(DEPDIR)/cmp_abs.Plo
-rm -f ./$(DEPDIR)/cmp_si_si.Plo
-rm -f ./$(DEPDIR)/conj.Plo
-rm -f ./$(DEPDIR)/cos.Plo
-rm -f ./$(DEPDIR)/cosh.Plo
-rm -f ./$(DEPDIR)/div.Plo
-rm -f ./$(DEPDIR)/div_2si.Plo
-rm -f ./$(DEPDIR)/div_2ui.Plo
-rm -f ./$(DEPDIR)/div_fr.Plo
-rm -f ./$(DEPDIR)/div_ui.Plo
-rm -f ./$(DEPDIR)/dot.Plo
-rm -f ./$(DEPDIR)/exp.Plo
-rm -f ./$(DEPDIR)/fma.Plo
-rm -f ./$(DEPDIR)/fr_div.Plo
-rm -f ./$(DEPDIR)/fr_sub.Plo
-rm -f ./$(DEPDIR)/get_prec.Plo
-rm -f ./$(DEPDIR)/get_prec2.Plo
-rm -f ./$(DEPDIR)/get_version.Plo
-rm -f ./$(DEPDIR)/get_x.Plo
-rm -f ./$(DEPDIR)/imag.Plo
-rm -f ./$(DEPDIR)/init2.Plo
-rm -f ./$(DEPDIR)/init3.Plo
-rm -f ./$(DEPDIR)/inp_str.Plo
-rm -f ./$(DEPDIR)/log.Plo
-rm -f ./$(DEPDIR)/log10.Plo
-rm -f ./$(DEPDIR)/mem.Plo
-rm -f ./$(DEPDIR)/mul.Plo
-rm -f ./$(DEPDIR)/mul_2si.Plo
-rm -f ./$(DEPDIR)/mul_2ui.Plo
-rm -f ./$(DEPDIR)/mul_fr.Plo
-rm -f ./$(DEPDIR)/mul_i.Plo
-rm -f ./$(DEPDIR)/mul_si.Plo
-rm -f ./$(DEPDIR)/mul_ui.Plo
-rm -f ./$(DEPDIR)/neg.Plo
-rm -f ./$(DEPDIR)/norm.Plo
-rm -f ./$(DEPDIR)/out_str.Plo
-rm -f ./$(DEPDIR)/pow.Plo
-rm -f ./$(DEPDIR)/pow_d.Plo
-rm -f ./$(DEPDIR)/pow_fr.Plo
-rm -f ./$(DEPDIR)/pow_ld.Plo
-rm -f ./$(DEPDIR)/pow_si.Plo
-rm -f ./$(DEPDIR)/pow_ui.Plo
-rm -f ./$(DEPDIR)/pow_z.Plo
-rm -f ./$(DEPDIR)/proj.Plo
-rm -f ./$(DEPDIR)/real.Plo
-rm -f ./$(DEPDIR)/rootofunity.Plo
-rm -f ./$(DEPDIR)/set.Plo
-rm -f ./$(DEPDIR)/set_prec.Plo
-rm -f ./$(DEPDIR)/set_str.Plo
-rm -f ./$(DEPDIR)/set_x.Plo
-rm -f ./$(DEPDIR)/set_x_x.Plo
-rm -f ./$(DEPDIR)/sin.Plo
-rm -f ./$(DEPDIR)/sin_cos.Plo
-rm -f ./$(DEPDIR)/sinh.Plo
-rm -f ./$(DEPDIR)/sqr.Plo
-rm -f ./$(DEPDIR)/sqrt.Plo
-rm -f ./$(DEPDIR)/strtoc.Plo
-rm -f ./$(DEPDIR)/sub.Plo
-rm -f ./$(DEPDIR)/sub_fr.Plo
-rm -f ./$(DEPDIR)/sub_ui.Plo
-rm -f ./$(DEPDIR)/sum.Plo
-rm -f ./$(DEPDIR)/swap.Plo
-rm -f ./$(DEPDIR)/tan.Plo
-rm -f ./$(DEPDIR)/tanh.Plo
-rm -f ./$(DEPDIR)/uceil_log2.Plo
-rm -f ./$(DEPDIR)/ui_div.Plo
-rm -f ./$(DEPDIR)/ui_ui_sub.Plo
-rm -f ./$(DEPDIR)/urandom.Plo
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
@ -738,9 +952,9 @@ uninstall-am: uninstall-libLTLIBRARIES
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \
clean-libLTLIBRARIES clean-libtool cscopelist-am ctags \
ctags-am distclean distclean-compile distclean-generic \
.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \
clean-generic clean-libLTLIBRARIES clean-libtool cscopelist-am \
ctags ctags-am distclean distclean-compile distclean-generic \
distclean-libtool distclean-tags distdir dvi dvi-am html \
html-am info info-am install install-am install-data \
install-data-am install-dvi install-dvi-am install-exec \

View File

@ -1,6 +1,6 @@
/* mpc_acos -- arccosine of a complex number.
Copyright (C) 2009, 2010, 2011, 2012 INRIA
Copyright (C) 2009, 2010, 2011, 2012, 2020 INRIA
This file is part of GNU MPC.
@ -31,6 +31,7 @@ mpc_acos (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
mpfr_exp_t e1, e2;
mpfr_rnd_t rnd_im;
mpc_rnd_t rnd1;
mpfr_exp_t saved_emin, saved_emax;
inex_re = 0;
inex_im = 0;
@ -170,6 +171,11 @@ mpc_acos (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
return MPC_INEX (inex_re, inex_im);
}
saved_emin = mpfr_get_emin ();
saved_emax = mpfr_get_emax ();
mpfr_set_emin (mpfr_get_emin_min ());
mpfr_set_emax (mpfr_get_emax_max ());
/* regular complex argument: acos(z) = Pi/2 - asin(z) */
p_re = mpfr_get_prec (mpc_realref(rop));
p_im = mpfr_get_prec (mpc_imagref(rop));
@ -225,5 +231,11 @@ mpc_acos (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
mpc_clear (z1);
mpfr_clear (pi_over_2);
/* restore the exponent range, and check the range of results */
mpfr_set_emin (saved_emin);
mpfr_set_emax (saved_emax);
inex_re = mpfr_check_range (mpc_realref (rop), inex_re, MPC_RND_RE (rnd));
inex_im = mpfr_check_range (mpc_imagref (rop), inex_im, MPC_RND_IM (rnd));
return MPC_INEX(inex_re, inex_im);
}

View File

@ -1,6 +1,6 @@
/* mpc_asin -- arcsine of a complex number.
Copyright (C) 2009, 2010, 2011, 2012, 2013, 2014 INRIA
Copyright (C) 2009, 2010, 2011, 2012, 2013, 2014, 2020 INRIA
This file is part of GNU MPC.
@ -80,13 +80,192 @@ mpc_asin_special (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd, mpc_ptr z1)
return 1;
}
/* Put in s an approximation of asin(z) using:
asin z = z + 1/2*z^3/3 + (1*3)/(2*4)*z^5/5 + ...
Assume |Re(z)|, |Im(z)| < 1/2.
Return non-zero if we can get the correct result by rounding s:
mpc_set (rop, s, ...) */
static int
mpc_asin_series (mpc_srcptr rop, mpc_ptr s, mpc_srcptr z, mpc_rnd_t rnd)
{
mpc_t w, t;
unsigned long k, err, kx, ky;
mpfr_prec_t p;
mpfr_exp_t ex, ey, e;
/* assume z = (x,y) with |x|,|y| < 2^(-e) with e >= 1, see the error
analysis in algorithms.tex */
ex = mpfr_get_exp (mpc_realref (z));
MPC_ASSERT(ex <= -1);
ey = mpfr_get_exp (mpc_imagref (z));
MPC_ASSERT(ey <= -1);
e = (ex >= ey) ? ex : ey;
e = -e;
/* now e >= 1 */
p = mpfr_get_prec (mpc_realref (s)); /* working precision */
MPC_ASSERT(mpfr_get_prec (mpc_imagref (s)) == p);
mpc_init2 (w, p);
mpc_init2 (t, p);
mpc_set (s, z, MPC_RNDNN);
mpc_sqr (w, z, MPC_RNDNN);
mpc_set (t, z, MPC_RNDNN);
for (k = 1; ;k++)
{
mpfr_exp_t exp_x, exp_y;
mpc_mul (t, t, w, MPC_RNDNN);
mpc_mul_ui (t, t, (2 * k - 1) * (2 * k - 1), MPC_RNDNN);
mpc_div_ui (t, t, (2 * k) * (2 * k + 1), MPC_RNDNN);
exp_x = mpfr_get_exp (mpc_realref (s));
exp_y = mpfr_get_exp (mpc_imagref (s));
if (mpfr_get_exp (mpc_realref (t)) < exp_x - p &&
mpfr_get_exp (mpc_imagref (t)) < exp_y - p)
/* Re(t) < 1/2 ulp(Re(s)) and Im(t) < 1/2 ulp(Im(s)),
thus adding t to s will not change s */
break;
mpc_add (s, s, t, MPC_RNDNN);
}
mpc_clear (w);
mpc_clear (t);
/* check (2k-1)^2 is exactly representable */
MPC_ASSERT(2 * k - 1 <= ULONG_MAX / (2 * k - 1));
/* maximal absolute error on Re(s),Im(s) is:
(5k-3)k/2*2^(-1-p) for e=1
5k/2*2^(-e-p) for e >= 2 */
if (e == 1)
{
MPC_ASSERT(5 * k - 3 <= ULONG_MAX / k);
kx = (5 * k - 3) * k;
}
else
kx = 5 * k;
kx = (kx + 1) / 2; /* takes into account the 1/2 factor in both cases */
/* now (5k-3)k/2 <= kx for e=1, and 5k/2 <= kx for e >= 2, thus
the maximal absolute error on Re(s),Im(s) is bounded by kx*2^(-e-p) */
e = -e;
ky = kx;
/* for the real part, convert the maximal absolute error kx*2^(e-p) into
relative error */
ex = mpfr_get_exp (mpc_realref (s));
/* ulp(Re(s)) = 2^(ex+1-p) */
if (ex+1 > e) /* divide kx by 2^(ex+1-e) */
while (ex+1 > e)
{
kx = (kx + 1) / 2;
ex --;
}
else /* multiply kx by 2^(e-(ex+1)) */
kx <<= e - (ex+1);
/* now the rounding error is bounded by kx*ulp(Re(s)), add the
mathematical error which is bounded by ulp(Re(s)): the first neglected
term is less than 1/2*ulp(Re(s)), and each term decreases by at least
a factor 2, since |z^2| <= 1/2. */
kx ++;
for (err = 0; kx > 2; err ++, kx = (kx + 1) / 2);
/* can we round Re(s) with error less than 2^(EXP(Re(s))-err) ? */
if (!mpfr_can_round (mpc_realref (s), p - err, MPFR_RNDN, MPFR_RNDZ,
mpfr_get_prec (mpc_realref (rop)) +
(MPC_RND_RE(rnd) == MPFR_RNDN)))
return 0;
/* same for the imaginary part */
ey = mpfr_get_exp (mpc_imagref (s));
/* we take for e the exponent of Im(z), which amounts to divide the error by
2^delta where delta is the exponent difference between Re(z) and Im(z)
(see algorithms.tex) */
e = mpfr_get_exp (mpc_imagref (z));
/* ulp(Im(s)) = 2^(ey+1-p) */
if (ey+1 > e) /* divide ky by 2^(ey+1-e) */
while (ey+1 > e)
{
ky = (ky + 1) / 2;
ey --;
}
else /* multiply ky by 2^(e-(ey+1)) */
ky <<= e - (ey+1);
/* now the rounding error is bounded by ky*ulp(Im(s)), add the
mathematical error which is bounded by ulp(Im(s)): the first neglected
term is less than 1/2*ulp(Im(s)), and each term decreases by at least
a factor 2, since |z^2| <= 1/2. */
ky ++;
for (err = 0; ky > 2; err ++, ky = (ky + 1) / 2);
/* can we round Im(s) with error less than 2^(EXP(Im(s))-err) ? */
return mpfr_can_round (mpc_imagref (s), p - err, MPFR_RNDN, MPFR_RNDZ,
mpfr_get_prec (mpc_imagref (rop)) +
(MPC_RND_IM(rnd) == MPFR_RNDN));
}
/* Put in s an approximation of asin(z) for |Re(z)| < 1 and tiny Im(y)
(see algorithms.tex). Assume z = x + i*y:
|Re(asin(z)) - asin(x)| <= Pi*beta^2/(1-beta)
|Im(asin(z)) - y/sqrt(1-x^2)| <= Pi/2*beta^2/(1-beta)
where beta = |y|/(1-|x|).
We assume |x| >= 1/2 > |y| here, thus beta < 1, and the bounds
simplify to 16y^2.
Assume Re(s) and Im(s) have the same precision.
Return non-zero if we can get the correct result by rounding s:
mpc_set (rop, s, ...) */
static int
mpc_asin_tiny (mpc_srcptr rop, mpc_ptr s, mpc_srcptr z, mpc_rnd_t rnd)
{
mpfr_exp_t ey, e1, e2, es;
mpfr_prec_t p = mpfr_get_prec (mpc_realref (s)), err;
ey = mpfr_get_exp (mpc_imagref (z));
MPC_ASSERT(mpfr_get_exp (mpc_realref (z)) >= 0); /* |x| >= 1/2 */
MPC_ASSERT(ey < 0); /* |y| < 1/2 */
e2 = 2 * ey + 4;
/* for |x| >= 0.5, |asin x| >= 0.5, thus no need to compute asin(x)
if 16y^2 >= 1/2 ulp(1) for the target variable */
if (e2 >= - (mpfr_exp_t) mpfr_get_prec (mpc_realref (rop)))
return 0;
/* real part */
mpfr_asin (mpc_realref (s), mpc_realref (z), MPFR_RNDN);
/* check that we can round with error < 16y^2 */
e1 = mpfr_get_exp (mpc_realref (s)) - p;
err = (e1 >= e2) ? 0 : e2 - e1;
if (!mpfr_can_round (mpc_realref (s), p - err, MPFR_RNDN, MPFR_RNDZ,
mpfr_get_prec (mpc_realref (rop)) +
(MPC_RND_RE(rnd) == MPFR_RNDN)))
return 0;
/* now compute the approximate imaginary part y/sqrt(1-x^2) */
mpfr_sqr (mpc_imagref (s), mpc_realref (z), MPFR_RNDN);
/* now Im(s) approximates x^2, with 1/4 <= Im(s) <= 1 and absolute error
less than 2^-p */
mpfr_ui_sub (mpc_imagref (s), 1, mpc_imagref (s), MPFR_RNDN);
/* now Im(s) approximates 1-x^2, with 0 <= Im(s) <= 3/4, assuming p >= 2,
and absolute error less than 2^(1-p) */
mpfr_sqrt (mpc_imagref (s), mpc_imagref (s), MPFR_RNDN); /* sqrt(1-x^2) */
es = mpfr_get_exp (mpc_imagref (s));
/* now Im(s) approximates sqrt(1-x^2), with 0 <= Im(s) <= 7/8,
assuming p >= 3, and absolute error less than 2^-p + 2^(1-p)/s
<= 3*2^-p/s, thus relative error less than 3*2^-p/s^2.
Since |s| >= 2^(es-1), the relative error is less than 3*2^(-p+2-2*es) */
mpfr_div (mpc_imagref (s), mpc_imagref (z), mpc_imagref (s), MPFR_RNDN);
/* now Im(s) approximates y/sqrt(1-x^2), with relative error less than
(3*2^(2-2*es)+2)*2^-p. Since es <= 0, 2-2*es >= 2, thus the relative
error is less than 2^(4-2*es-p) */
err = 4 - 2 * es;
return mpfr_can_round (mpc_imagref (s), p - err, MPFR_RNDN, MPFR_RNDZ,
mpfr_get_prec (mpc_imagref (rop)) +
(MPC_RND_IM(rnd) == MPFR_RNDN));
}
int
mpc_asin (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
{
mpfr_prec_t p, p_re, p_im;
mpfr_rnd_t rnd_re, rnd_im;
mpc_t z1;
int inex, loop = 0;
int inex, inex_re, inex_im, loop = 0;
mpfr_exp_t saved_emin, saved_emax, err, olderr;
/* special values */
if (mpfr_nan_p (mpc_realref (op)) || mpfr_nan_p (mpc_imagref (op)))
@ -112,7 +291,6 @@ mpc_asin (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
if (mpfr_inf_p (mpc_realref (op)) || mpfr_inf_p (mpc_imagref (op)))
{
int inex_re;
if (mpfr_inf_p (mpc_realref (op)))
{
int inf_im = mpfr_inf_p (mpc_imagref (op));
@ -137,8 +315,6 @@ mpc_asin (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
/* pure real argument */
if (mpfr_zero_p (mpc_imagref (op)))
{
int inex_re;
int inex_im;
int s_im;
s_im = mpfr_signbit (mpc_imagref (op));
@ -186,7 +362,6 @@ mpc_asin (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
/* pure imaginary argument */
if (mpfr_zero_p (mpc_realref (op)))
{
int inex_im;
int s;
s = mpfr_signbit (mpc_realref (op));
mpfr_set_ui (mpc_realref (rop), 0, MPFR_RNDN);
@ -197,6 +372,11 @@ mpc_asin (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
return MPC_INEX (0, inex_im);
}
saved_emin = mpfr_get_emin ();
saved_emax = mpfr_get_emax ();
mpfr_set_emin (mpfr_get_emin_min ());
mpfr_set_emax (mpfr_get_emax_max ());
/* regular complex: asin(z) = -i*log(i*z+sqrt(1-z^2)) */
p_re = mpfr_get_prec (mpc_realref(rop));
p_im = mpfr_get_prec (mpc_imagref(rop));
@ -204,17 +384,33 @@ mpc_asin (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
rnd_im = MPC_RND_IM(rnd);
p = p_re >= p_im ? p_re : p_im;
mpc_init2 (z1, p);
olderr = err = 0; /* number of lost bits */
while (1)
{
mpfr_exp_t ex, ey, err;
mpfr_exp_t ex, ey;
loop ++;
p += err - olderr; /* add extra number of lost bits in previous loop */
olderr = err;
p += (loop <= 2) ? mpc_ceil_log2 (p) + 3 : p / 2;
mpfr_set_prec (mpc_realref(z1), p);
mpfr_set_prec (mpc_imagref(z1), p);
/* try special code for 1+i*y with tiny y */
if (loop == 1 && mpc_asin_special (rop, op, rnd, z1))
if (loop == 1 && mpfr_cmp_ui (mpc_realref(op), 1) == 0 &&
mpc_asin_special (rop, op, rnd, z1))
break;
/* try special code for small z */
if (mpfr_get_exp (mpc_realref (op)) <= -1 &&
mpfr_get_exp (mpc_imagref (op)) <= -1 &&
mpc_asin_series (rop, z1, op, rnd))
break;
/* try special code for 1/2 <= |x| < 1 and |y| < 1/2 */
if (mpfr_get_exp (mpc_realref (op)) == 0 &&
mpfr_get_exp (mpc_imagref (op)) <= -1 &&
mpc_asin_tiny (rop, z1, op, rnd))
break;
/* z1 <- z^2 */
@ -224,6 +420,9 @@ mpc_asin (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
ex = mpfr_get_exp (mpc_realref(z1));
mpfr_ui_sub (mpc_realref(z1), 1, mpc_realref(z1), MPFR_RNDN);
mpfr_neg (mpc_imagref(z1), mpc_imagref(z1), MPFR_RNDN);
/* if Re(z1) = 0, we can't determine the relative error */
if (mpfr_zero_p (mpc_realref(z1)))
continue;
ex = ex - mpfr_get_exp (mpc_realref(z1));
ex = (ex <= 0) ? 0 : ex;
/* err(x) <= 2^ex * ulp(x) */
@ -252,7 +451,7 @@ mpc_asin (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
ey = mpfr_get_exp (mpc_imagref(z1));
mpfr_sub (mpc_realref(z1), mpc_realref(z1), mpc_imagref(op), MPFR_RNDN);
mpfr_add (mpc_imagref(z1), mpc_imagref(z1), mpc_realref(op), MPFR_RNDN);
if (mpfr_cmp_ui (mpc_realref(z1), 0) == 0 || mpfr_cmp_ui (mpc_imagref(z1), 0) == 0)
if (mpfr_zero_p (mpc_realref(z1)) || mpfr_zero_p (mpc_imagref(z1)))
continue;
ex -= mpfr_get_exp (mpc_realref(z1)); /* cancellation in x */
ey -= mpfr_get_exp (mpc_imagref(z1)); /* cancellation in y */
@ -286,5 +485,13 @@ mpc_asin (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
inex = mpc_set (rop, z1, rnd);
mpc_clear (z1);
return inex;
/* restore the exponent range, and check the range of results */
mpfr_set_emin (saved_emin);
mpfr_set_emax (saved_emax);
inex_re = mpfr_check_range (mpc_realref (rop), MPC_INEX_RE (inex),
MPC_RND_RE (rnd));
inex_im = mpfr_check_range (mpc_imagref (rop), MPC_INEX_IM (inex),
MPC_RND_IM (rnd));
return MPC_INEX (inex_re, inex_im);
}

View File

@ -1,6 +1,6 @@
/* mpc_atan -- arctangent of a complex number.
Copyright (C) 2009, 2010, 2011, 2012, 2013, 2017 INRIA
Copyright (C) 2009, 2010, 2011, 2012, 2013, 2017, 2020 INRIA
This file is part of GNU MPC.
@ -45,11 +45,9 @@ set_pi_over_2 (mpfr_ptr rop, int s, mpfr_rnd_t rnd)
int
mpc_atan (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
{
int s_re;
int s_im;
int inex_re;
int inex_im;
int inex;
int s_re, s_im;
int inex_re, inex_im, inex;
mpfr_exp_t saved_emin, saved_emax;
inex_re = 0;
inex_im = 0;
@ -216,6 +214,11 @@ mpc_atan (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
return MPC_INEX (inex_re, inex_im);
}
saved_emin = mpfr_get_emin ();
saved_emax = mpfr_get_emax ();
mpfr_set_emin (mpfr_get_emin_min ());
mpfr_set_emax (mpfr_get_emax_max ());
/* regular number argument */
{
mpfr_t a, b, x, y;
@ -391,6 +394,15 @@ mpc_atan (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
inex = mpc_set_fr_fr (rop, x, y, rnd);
mpfr_clears (a, b, x, y, (mpfr_ptr) 0);
return inex;
/* restore the exponent range, and check the range of results */
mpfr_set_emin (saved_emin);
mpfr_set_emax (saved_emax);
inex_re = mpfr_check_range (mpc_realref (rop), MPC_INEX_RE (inex),
MPC_RND_RE (rnd));
inex_im = mpfr_check_range (mpc_imagref (rop), MPC_INEX_IM (inex),
MPC_RND_IM (rnd));
return MPC_INEX (inex_re, inex_im);
}
}

View File

@ -1,6 +1,6 @@
/* mpc_div -- Divide two complex numbers.
Copyright (C) 2002, 2003, 2004, 2005, 2008, 2009, 2010, 2011, 2012 INRIA
Copyright (C) 2002, 2003, 2004, 2005, 2008, 2009, 2010, 2011, 2012, 2020 INRIA
This file is part of GNU MPC.
@ -229,6 +229,7 @@ mpc_div_imag (mpc_ptr rop, mpc_srcptr z, mpc_srcptr w, mpc_rnd_t rnd)
return MPC_INEX(inex_re, inex_im);
}
#define MPFR_EXP(x) ((x)->_mpfr_exp)
int
mpc_div (mpc_ptr a, mpc_srcptr b, mpc_srcptr c, mpc_rnd_t rnd)
@ -243,6 +244,7 @@ mpc_div (mpc_ptr a, mpc_srcptr b, mpc_srcptr c, mpc_rnd_t rnd)
mpfr_rnd_t rnd_re = MPC_RND_RE (rnd), rnd_im = MPC_RND_IM (rnd);
int saved_underflow, saved_overflow;
int tmpsgn;
mpfr_exp_t saved_emin, saved_emax;
/* According to the C standard G.3, there are three types of numbers: */
/* finite (both parts are usual real numbers; contains 0), infinite */
@ -253,9 +255,10 @@ mpc_div (mpc_ptr a, mpc_srcptr b, mpc_srcptr c, mpc_rnd_t rnd)
/* all other divisions that are not finite/finite return nan+i*nan. */
/* Division by 0 could be handled by the following case of division by */
/* a real; we handle it separately instead. */
if (mpc_zero_p (c))
if (mpc_zero_p (c)) /* both Re(c) and Im(c) are zero */
return mpc_div_zero (a, b, c, rnd);
else if (mpc_inf_p (b) && mpc_fin_p (c))
else if (mpc_inf_p (b) && mpc_fin_p (c)) /* either Re(b) or Im(b) is infinite
and both Re(c) and Im(c) are ordinary */
return mpc_div_inf_fin (a, b, c);
else if (mpc_fin_p (b) && mpc_inf_p (c))
return mpc_div_fin_inf (a, b, c);
@ -273,6 +276,13 @@ mpc_div (mpc_ptr a, mpc_srcptr b, mpc_srcptr c, mpc_rnd_t rnd)
mpc_init2 (res, 2);
mpfr_init (q);
/* we perform the division in the largest possible exponent range,
to avoid underflow/overflow in intermediate computations */
saved_emin = mpfr_get_emin ();
saved_emax = mpfr_get_emax ();
mpfr_set_emin (mpfr_get_emin_min ());
mpfr_set_emax (mpfr_get_emax_max ());
/* create the conjugate of c in c_conj without allocating new memory */
mpc_realref (c_conj)[0] = mpc_realref (c)[0];
mpc_imagref (c_conj)[0] = mpc_imagref (c)[0];
@ -312,7 +322,13 @@ mpc_div (mpc_ptr a, mpc_srcptr b, mpc_srcptr c, mpc_rnd_t rnd)
hopefully, the side-effects of mpc_mul do indeed raise the
mpfr exceptions */
if (overflow_prod) {
/* FIXME: in case overflow_norm is also true, the code below is wrong,
since the after division by the norm, we might end up with finite
real and/or imaginary parts. A workaround would be to scale the
inputs (in case the exponents are within the same range). */
int isinf = 0;
/* determine if the real part of res is the maximum or the minimum
representable number */
tmpsgn = mpfr_sgn (mpc_realref(res));
if (tmpsgn > 0)
{
@ -331,6 +347,7 @@ mpc_div (mpc_ptr a, mpc_srcptr b, mpc_srcptr c, mpc_rnd_t rnd)
mpfr_set_inf (mpc_realref(res), tmpsgn);
overflow_re = 1;
}
/* same for the imaginary part */
tmpsgn = mpfr_sgn (mpc_imagref(res));
isinf = 0;
if (tmpsgn > 0)
@ -445,5 +462,11 @@ mpc_div (mpc_ptr a, mpc_srcptr b, mpc_srcptr c, mpc_rnd_t rnd)
if (saved_overflow)
mpfr_set_overflow ();
/* restore the exponent range, and check the range of results */
mpfr_set_emin (saved_emin);
mpfr_set_emax (saved_emax);
inexact_re = mpfr_check_range (mpc_realref (a), inexact_re, rnd_re);
inexact_im = mpfr_check_range (mpc_imagref (a), inexact_im, rnd_im);
return MPC_INEX (inexact_re, inexact_im);
}

88
gcc/mpc/src/dot.c Normal file
View File

@ -0,0 +1,88 @@
/* mpc_dot -- Dot product of two arrays of complex numbers.
Copyright (C) 2018, 2020 INRIA
This file is part of GNU MPC.
GNU MPC is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
Free Software Foundation; either version 3 of the License, or (at your
option) any later version.
GNU MPC 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 Lesser General Public License for
more details.
You should have received a copy of the GNU Lesser General Public License
along with this program. If not, see http://www.gnu.org/licenses/ .
*/
#include <stdio.h> /* for MPC_ASSERT */
#include "mpc-impl.h"
/* res <- x[0]*y[0] + ... + x[n-1]*y[n-1] */
int
mpc_dot (mpc_ptr res, const mpc_ptr *x, const mpc_ptr *y,
unsigned long n, mpc_rnd_t rnd)
{
int inex_re, inex_im;
mpfr_ptr *t;
mpfr_t *z;
unsigned long i;
mpfr_t re_res;
z = (mpfr_t *) malloc (2 * n * sizeof (mpfr_t));
/* warning: when n=0, malloc() might return NULL (e.g., gcc119) */
MPC_ASSERT(n == 0 || z != NULL);
t = (mpfr_ptr *) malloc (2 * n * sizeof(mpfr_ptr));
MPC_ASSERT(n == 0 || t != NULL);
for (i = 0; i < 2 * n; i++)
t[i] = z[i];
/* we first store in z[i] the value of Re(x[i])*Re(y[i])
and in z[n+i] that of -Im(x[i])*Im(y[i]) */
for (i = 0; i < n; i++)
{
mpfr_prec_t prec_x_re = mpfr_get_prec (mpc_realref (x[i]));
mpfr_prec_t prec_x_im = mpfr_get_prec (mpc_imagref (x[i]));
mpfr_prec_t prec_y_re = mpfr_get_prec (mpc_realref (y[i]));
mpfr_prec_t prec_y_im = mpfr_get_prec (mpc_imagref (y[i]));
mpfr_prec_t prec_y_max = MPC_MAX (prec_y_re, prec_y_im);
/* we allocate z[i] with prec_x_re + prec_y_max bits
so that the second loop below does not reallocate */
mpfr_init2 (z[i], prec_x_re + prec_y_max);
mpfr_set_prec (z[i], prec_x_re + prec_y_re);
mpfr_mul (z[i], mpc_realref (x[i]), mpc_realref (y[i]), MPFR_RNDZ);
/* idem for z[n+i]: we allocate with prec_x_im + prec_y_max bits */
mpfr_init2 (z[n+i], prec_x_im + prec_y_max);
mpfr_set_prec (z[n+i], prec_x_im + prec_y_im);
mpfr_mul (z[n+i], mpc_imagref (x[i]), mpc_imagref (y[i]), MPFR_RNDZ);
mpfr_neg (z[n+i], z[n+i], MPFR_RNDZ);
}
/* copy the real part in a temporary variable, since it might be in the
input array */
mpfr_init2 (re_res, mpfr_get_prec (mpc_realref (res)));
inex_re = mpfr_sum (re_res, t, 2 * n, MPC_RND_RE (rnd));
/* we then store in z[i] the value of Re(x[i])*Im(y[i])
and in z[n+i] that of Im(x[i])*Re(y[i]) */
for (i = 0; i < n; i++)
{
mpfr_prec_t prec_x_re = mpfr_get_prec (mpc_realref (x[i]));
mpfr_prec_t prec_x_im = mpfr_get_prec (mpc_imagref (x[i]));
mpfr_prec_t prec_y_re = mpfr_get_prec (mpc_realref (y[i]));
mpfr_prec_t prec_y_im = mpfr_get_prec (mpc_imagref (y[i]));
mpfr_set_prec (z[i], prec_x_re + prec_y_im);
mpfr_mul (z[i], mpc_realref (x[i]), mpc_imagref (y[i]), MPFR_RNDZ);
mpfr_set_prec (z[n+i], prec_x_im + prec_y_re);
mpfr_mul (z[n+i], mpc_imagref (x[i]), mpc_realref (y[i]), MPFR_RNDZ);
}
inex_im = mpfr_sum (mpc_imagref (res), t, 2 * n, MPC_RND_IM (rnd));
mpfr_swap (mpc_realref (res), re_res);
mpfr_clear (re_res);
for (i = 0; i < 2 * n; i++)
mpfr_clear (z[i]);
free (t);
free (z);
return MPC_INEX(inex_re, inex_im);
}

View File

@ -1,6 +1,6 @@
/* mpc_exp -- exponential of a complex number.
Copyright (C) 2002, 2009, 2010, 2011, 2012 INRIA
Copyright (C) 2002, 2009, 2010, 2011, 2012, 2020 INRIA
This file is part of GNU MPC.
@ -28,6 +28,7 @@ mpc_exp (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
int ok = 0;
int inex_re, inex_im;
int saved_underflow, saved_overflow;
mpfr_exp_t saved_emin, saved_emax;
/* special values */
if (mpfr_nan_p (mpc_realref (op)) || mpfr_nan_p (mpc_imagref (op)))
@ -58,7 +59,6 @@ mpc_exp (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
return MPC_INEX(0, 0); /* NaN is exact */
}
if (mpfr_zero_p (mpc_imagref(op)))
/* special case when the input is real
exp(x-i*0) = exp(x) -i*0, even if x is NaN
@ -77,7 +77,6 @@ mpc_exp (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
return MPC_INEX(inex_re, inex_im);
}
if (mpfr_inf_p (mpc_realref (op)))
/* real part is an infinity,
exp(-inf +i*y) = 0*(cos y +i*sin y)
@ -130,6 +129,10 @@ mpc_exp (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
return MPC_INEX(0, 0); /* NaN is exact */
}
saved_emin = mpfr_get_emin ();
saved_emax = mpfr_get_emax ();
mpfr_set_emin (mpfr_get_emin_min ());
mpfr_set_emax (mpfr_get_emax_max ());
/* from now on, both parts of op are regular numbers */
@ -150,7 +153,7 @@ mpc_exp (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
do
{
prec += mpc_ceil_log2 (prec) + 5;
prec += prec / 2 + mpc_ceil_log2 (prec) + 5;
mpfr_set_prec (x, prec);
mpfr_set_prec (y, prec);
@ -199,5 +202,11 @@ mpc_exp (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
if (saved_overflow)
mpfr_set_overflow ();
/* restore the exponent range, and check the range of results */
mpfr_set_emin (saved_emin);
mpfr_set_emax (saved_emax);
inex_re = mpfr_check_range (mpc_realref (rop), inex_re, MPC_RND_RE (rnd));
inex_im = mpfr_check_range (mpc_imagref (rop), inex_im, MPC_RND_IM (rnd));
return MPC_INEX(inex_re, inex_im);
}

View File

@ -1,6 +1,6 @@
/* mpc_get_version -- MPC version
Copyright (C) 2008, 2009, 2010, 2011, 2012, 2017 INRIA
Copyright (C) 2008, 2009, 2010, 2011, 2012, 2017, 2018, 2020 INRIA
This file is part of GNU MPC.
@ -23,5 +23,5 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
const char *
mpc_get_version (void)
{
return "1.1.0";
return "1.2.0";
}

View File

@ -1,7 +1,7 @@
/* mpc_get_dc, mpc_get_ldc -- Transform mpc number into C complex number
mpc_get_str -- Convert a complex number into a string.
Copyright (C) 2009, 2010, 2011 INRIA
Copyright (C) 2009, 2010, 2011, 2020 INRIA
This file is part of GNU MPC.
@ -53,12 +53,12 @@ mpc_get_ldc (mpc_srcptr op, mpc_rnd_t rnd) {
of the locale is used. */
/* mpfr_prec_t can be either int or long int */
#if (__GMP_MP_SIZE_T_INT == 1)
#if (_MPFR_EXP_FORMAT == 2)
#define MPC_EXP_FORMAT_SPEC "i"
#elif (__GMP_MP_SIZE_T_INT == 0)
#elif (_MPFR_EXP_FORMAT == 3)
#define MPC_EXP_FORMAT_SPEC "li"
#else
#error "mpfr_exp_t size not supported"
#error "value of _MPFR_EXP_FORMAT not supported"
#endif
static char *
@ -76,13 +76,13 @@ pretty_zero (mpfr_srcptr zero)
}
static char *
prettify (const char *str, const mp_exp_t expo, int base, int special)
prettify (const char *str, const mpfr_exp_t expo, int base, int special)
{
size_t sz;
char *pretty;
char *p;
const char *s;
mp_exp_t x;
mpfr_exp_t x;
int sign;
sz = strlen (str) + 1; /* + terminal '\0' */
@ -101,10 +101,10 @@ prettify (const char *str, const mp_exp_t expo, int base, int special)
sign = (str[0] == '-' || str[0] == '+');
x = expo - 1; /* expo is the exponent value with decimal point BEFORE
the first digit, we wants decimal point AFTER the first
the first digit, we want decimal point AFTER the first
digit */
if (base == 16)
x <<= 2; /* the output exponent is a binary exponent */
x *= 4; /* the output exponent is a binary exponent */
++sz; /* + decimal point */
@ -112,14 +112,14 @@ prettify (const char *str, const mp_exp_t expo, int base, int special)
{
/* augment sz with the size needed for an exponent written in base
ten */
mp_exp_t xx;
mpfr_exp_t xx;
sz += 3; /* + exponent char + sign + 1 digit */
if (x < 0)
{
/* avoid overflow when changing sign (assuming that, for the
mp_exp_t type, (max value) is greater than (- min value / 10)) */
mpfr_exp_t type, (max value) is greater than (- min value / 10)) */
if (x < -10)
{
xx = - (x / 10);
@ -189,7 +189,7 @@ prettify (const char *str, const mp_exp_t expo, int base, int special)
static char *
get_pretty_str (const int base, const size_t n, mpfr_srcptr x, mpfr_rnd_t rnd)
{
mp_exp_t expo;
mpfr_exp_t expo;
char *ugly;
char *pretty;

View File

@ -1,6 +1,6 @@
/* mpc_log10 -- Take the base-10 logarithm of a complex number.
Copyright (C) 2012 INRIA
Copyright (C) 2012, 2020 INRIA
This file is part of GNU MPC.
@ -37,6 +37,12 @@ mpc_log10 (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
mpfr_prec_t prec;
mpfr_t log10;
mpc_t log;
mpfr_exp_t saved_emin, saved_emax;
saved_emin = mpfr_get_emin ();
saved_emax = mpfr_get_emax ();
mpfr_set_emin (mpfr_get_emin_min ());
mpfr_set_emax (mpfr_get_emax_max ());
mpfr_init2 (log10, 2);
mpc_init2 (log, 2);
@ -143,5 +149,11 @@ mpc_log10 (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
mpfr_clear (log10);
mpc_clear (log);
/* restore the exponent range, and check the range of results */
mpfr_set_emin (saved_emin);
mpfr_set_emax (saved_emax);
inex_re = mpfr_check_range (mpc_realref (rop), inex_re, MPC_RND_RE (rnd));
inex_im = mpfr_check_range (mpc_imagref (rop), inex_im, MPC_RND_IM (rnd));
return MPC_INEX(inex_re, inex_im);
}

View File

@ -1,6 +1,6 @@
/* mpc-impl.h -- Internal include file for mpc.
Copyright (C) 2002, 2004, 2005, 2008, 2009, 2010, 2011, 2012 INRIA
Copyright (C) 2002, 2004, 2005, 2008, 2009, 2010, 2011, 2012, 2020 INRIA
This file is part of GNU MPC.
@ -61,9 +61,9 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
mpfr_copysign (x, y, z, rnd))
/* work around spurious signs in nan */
#define MPFR_ADD_ONE_ULP(x) \
(mpfr_sgn (x) > 0 ? mpfr_nextabove (x) : mpfr_nextbelow (x))
(MPFR_SIGN (x) > 0 ? mpfr_nextabove (x) : mpfr_nextbelow (x))
#define MPFR_SUB_ONE_ULP(x) \
(mpfr_sgn (x) > 0 ? mpfr_nextbelow (x) : mpfr_nextabove (x))
(MPFR_SIGN (x) > 0 ? mpfr_nextbelow (x) : mpfr_nextabove (x))
/* drop unused rounding mode from macros */
#define MPFR_SWAP(a,b) do { mpfr_srcptr tmp; tmp = a; a = b; b = tmp; } while (0)

View File

@ -1,6 +1,6 @@
/* mpc.h -- Include file for mpc.
Copyright (C) 2002, 2003, 2004, 2005, 2007, 2008, 2009, 2010, 2011, 2012, 2016, 2017 INRIA
Copyright (C) 2002, 2003, 2004, 2005, 2007, 2008, 2009, 2010, 2011, 2012, 2016, 2017, 2018, 2020 INRIA
This file is part of GNU MPC.
@ -26,9 +26,9 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
/* Define MPC version number */
#define MPC_VERSION_MAJOR 1
#define MPC_VERSION_MINOR 1
#define MPC_VERSION_MINOR 2
#define MPC_VERSION_PATCHLEVEL 0
#define MPC_VERSION_STRING "1.1.0"
#define MPC_VERSION_STRING "1.2.0"
/* Macros dealing with MPC VERSION */
#define MPC_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c))
@ -42,7 +42,9 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
/* Return values */
/* Transform negative to 2, positive to 1, leave 0 unchanged */
/* Transform negative to 2, positive to 1, leave 0 unchanged.
Warning: since inex is evaluated two times, we should avoid
MPC_INEX(mpc_mul (...), mpc_mul (...)) */
#define MPC_INEX_POS(inex) (((inex) < 0) ? 2 : ((inex) == 0) ? 0 : 1)
/* Transform 2 to negative, 1 to positive, leave 0 unchanged */
#define MPC_INEX_NEG(inex) (((inex) == 2) ? -1 : ((inex) == 0) ? 0 : 1)
@ -152,6 +154,8 @@ __MPC_DECLSPEC int mpc_div_2si (mpc_ptr, mpc_srcptr, long int, mpc_rnd_t);
__MPC_DECLSPEC int mpc_mul_2si (mpc_ptr, mpc_srcptr, long int, mpc_rnd_t);
__MPC_DECLSPEC int mpc_conj (mpc_ptr, mpc_srcptr, mpc_rnd_t);
__MPC_DECLSPEC int mpc_neg (mpc_ptr, mpc_srcptr, mpc_rnd_t);
__MPC_DECLSPEC int mpc_sum (mpc_ptr, const mpc_ptr *, unsigned long, mpc_rnd_t);
__MPC_DECLSPEC int mpc_dot (mpc_ptr, const mpc_ptr *, const mpc_ptr *, unsigned long, mpc_rnd_t);
__MPC_DECLSPEC int mpc_norm (mpfr_ptr, mpc_srcptr, mpfr_rnd_t);
__MPC_DECLSPEC int mpc_abs (mpfr_ptr, mpc_srcptr, mpfr_rnd_t);
__MPC_DECLSPEC int mpc_sqrt (mpc_ptr, mpc_srcptr, mpc_rnd_t);

View File

@ -5,7 +5,7 @@ Copyright (C) 2002, 2004, 2005, 2008, 2009, 2010, 2011, 2012, 2016 INRIA
This file is part of GNU MPC.
GNU MPC is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
he terms of the GNU Lesser General Public License as published by the
Free Software Foundation; either version 3 of the License, or (at your
option) any later version.
@ -366,7 +366,7 @@ mpc_mul_naive (mpc_ptr z, mpc_srcptr x, mpc_srcptr y, mpc_rnd_t rnd)
{
/* computes z=x*y by the schoolbook method, where x and y are assumed
to be finite and without zero parts */
int overlap, inex;
int overlap, inex_re, inex_im;
mpc_t rop;
MPC_ASSERT ( mpfr_regular_p (mpc_realref (x)) && mpfr_regular_p (mpc_imagref (x))
@ -378,22 +378,22 @@ mpc_mul_naive (mpc_ptr z, mpc_srcptr x, mpc_srcptr y, mpc_rnd_t rnd)
rop [0] = z [0];
#if HAVE_MPFR_FMMA
inex = MPC_INEX (mpfr_fmms (mpc_realref (rop), mpc_realref (x), mpc_realref (y), mpc_imagref (x),
mpc_imagref (y), MPC_RND_RE (rnd)),
mpfr_fmma (mpc_imagref (rop), mpc_realref (x), mpc_imagref (y), mpc_imagref (x),
mpc_realref (y), MPC_RND_IM (rnd)));
inex_re = mpfr_fmms (mpc_realref (rop), mpc_realref (x), mpc_realref (y),
mpc_imagref (x), mpc_imagref (y), MPC_RND_RE (rnd));
inex_im = mpfr_fmma (mpc_imagref (rop), mpc_realref (x), mpc_imagref (y),
mpc_imagref (x), mpc_realref (y), MPC_RND_IM (rnd));
#else
inex = MPC_INEX (mpc_fmma (mpc_realref (rop), mpc_realref (x), mpc_realref (y), mpc_imagref (x),
mpc_imagref (y), -1, MPC_RND_RE (rnd)),
mpc_fmma (mpc_imagref (rop), mpc_realref (x), mpc_imagref (y), mpc_imagref (x),
mpc_realref (y), +1, MPC_RND_IM (rnd)));
inex_re = mpc_fmma (mpc_realref (rop), mpc_realref (x), mpc_realref (y),
mpc_imagref (x), mpc_imagref (y), -1, MPC_RND_RE (rnd));
inex_im = mpc_fmma (mpc_imagref (rop), mpc_realref (x), mpc_imagref (y),
mpc_imagref (x), mpc_realref (y), +1, MPC_RND_IM (rnd));
#endif
mpc_set (z, rop, MPC_RNDNN);
if (overlap)
mpc_clear (rop);
return inex;
return MPC_INEX (inex_re, inex_im);
}

View File

@ -1,6 +1,6 @@
/* mpc_pow -- Raise a complex number to the power of another complex number.
Copyright (C) 2009-2015 INRIA
Copyright (C) 2009, 2010, 2011, 2012, 2014, 2015, 2016, 2018, 2020 INRIA
This file is part of GNU MPC.
@ -182,6 +182,7 @@ mpc_pow_exact (mpc_ptr z, mpc_srcptr x, mpfr_srcptr y, mpc_rnd_t rnd,
int x_imag = mpfr_zero_p (mpc_realref(x));
int z_is_y = 0;
mpfr_t copy_of_y;
int inex_im;
if (mpc_realref (z) == y || mpc_imagref (z) == y)
{
@ -403,7 +404,8 @@ mpc_pow_exact (mpc_ptr z, mpc_srcptr x, mpfr_srcptr y, mpc_rnd_t rnd,
}
ret = mpfr_set_z (mpc_realref(z), a, MPC_RND_RE(rnd));
ret = MPC_INEX(ret, mpfr_set_z (mpc_imagref(z), b, MPC_RND_IM(rnd)));
inex_im = mpfr_set_z (mpc_imagref(z), b, MPC_RND_IM(rnd));
ret = MPC_INEX(ret, inex_im);
mpfr_mul_2si (mpc_realref(z), mpc_realref(z), ed, MPC_RND_RE(rnd));
mpfr_mul_2si (mpc_imagref(z), mpc_imagref(z), ed, MPC_RND_IM(rnd));
@ -483,6 +485,8 @@ mpc_pow (mpc_ptr z, mpc_srcptr x, mpc_srcptr y, mpc_rnd_t rnd)
mpc_t t, u;
mpfr_prec_t p, pr, pi, maxprec;
int saved_underflow, saved_overflow;
int inex_re, inex_im;
mpfr_exp_t saved_emin, saved_emax;
/* save the underflow or overflow flags from MPFR */
saved_underflow = mpfr_underflow_p ();
@ -590,7 +594,8 @@ mpc_pow (mpc_ptr z, mpc_srcptr x, mpc_srcptr y, mpc_rnd_t rnd)
s2 = mpfr_signbit (mpc_imagref (x));
ret = mpfr_pow (mpc_realref(z), mpc_realref(x), mpc_realref(y), MPC_RND_RE(rnd));
ret = MPC_INEX(ret, mpfr_set_ui (mpc_imagref(z), 0, MPC_RND_IM(rnd)));
inex_im = mpfr_set_ui (mpc_imagref(z), 0, MPC_RND_IM(rnd));
ret = MPC_INEX(ret, inex_im);
/* the sign of the zero imaginary part is known in some cases
(see algorithm.tex). In such cases we have (x +s*0i)^(y+/-0i)
@ -641,6 +646,11 @@ mpc_pow (mpc_ptr z, mpc_srcptr x, mpc_srcptr y, mpc_rnd_t rnd)
z_real = 1;
}
saved_emin = mpfr_get_emin ();
saved_emax = mpfr_get_emax ();
mpfr_set_emin (mpfr_get_emin_min ());
mpfr_set_emax (mpfr_get_emax_max ());
pr = mpfr_get_prec (mpc_realref(z));
pi = mpfr_get_prec (mpc_imagref(z));
p = (pr > pi) ? pr : pi;
@ -670,11 +680,13 @@ mpc_pow (mpc_ptr z, mpc_srcptr x, mpc_srcptr y, mpc_rnd_t rnd)
if (mpfr_get_exp (mpc_imagref(t)) > (mpfr_exp_t) q)
q = mpfr_get_exp (mpc_imagref(t));
/* if q >= p, we get an error of order 1 on the imaginary part of t,
which is not enough to get the correct sign of exp(t) */
if (q >= p)
/* the signs of the real/imaginary parts of exp(t) are determined by the
quadrant of exp(i*imag(t)), which depends on imag(t) mod (2pi).
We ensure that p >= q + 64 to get enough precision, but this might
be not enough in corner cases (FIXME). */
if (p < q + 64)
{
p = p + 64;
p = q + 64;
goto try_again;
}
@ -682,7 +694,6 @@ mpc_pow (mpc_ptr z, mpc_srcptr x, mpc_srcptr y, mpc_rnd_t rnd)
mpfr_clear_underflow ();
ret_exp = mpc_exp (u, t, MPC_RNDNN);
if (mpfr_underflow_p () || mpfr_overflow_p ()) {
int inex_re, inex_im;
/* under- and overflow flags are set by mpc_exp */
mpc_set (z, u, MPC_RNDNN);
ret = ret_exp;
@ -691,7 +702,12 @@ mpc_pow (mpc_ptr z, mpc_srcptr x, mpc_srcptr y, mpc_rnd_t rnd)
if (mpfr_inf_p (mpc_realref (z)))
inex_re = mpc_fix_inf (mpc_realref (z), MPC_RND_RE(rnd));
if (mpfr_inf_p (mpc_imagref (z)))
{
if (z_real)
inex_im = mpfr_set_ui (mpc_imagref (z), 0, MPC_RND_IM(rnd));
else
inex_im = mpc_fix_inf (mpc_imagref (z), MPC_RND_IM(rnd));
}
ret = MPC_INEX(inex_re,inex_im);
goto exact;
}
@ -790,7 +806,8 @@ mpc_pow (mpc_ptr z, mpc_srcptr x, mpc_srcptr y, mpc_rnd_t rnd)
}
else
{
ret = MPC_INEX (ret, mpfr_set_ui (mpc_imagref (z), 0, MPC_RND_IM (rnd)));
inex_im = mpfr_set_ui (mpc_imagref (z), 0, MPC_RND_IM (rnd));
ret = MPC_INEX (ret, inex_im);
/* warning: mpfr_set_ui does not set Im(z) to -0 if Im(rnd) = RNDD */
if (MPC_RND_IM (rnd) == MPFR_RNDD || sign_zi)
mpc_conj (z, z, MPC_RNDNN);
@ -816,7 +833,10 @@ mpc_pow (mpc_ptr z, mpc_srcptr x, mpc_srcptr y, mpc_rnd_t rnd)
ret = MPC_INEX(0, ret);
}
else
ret = MPC_INEX(mpfr_set_ui (mpc_realref(z), 0, MPC_RND_RE(rnd)), ret);
{
inex_re = mpfr_set_ui (mpc_realref(z), 0, MPC_RND_RE(rnd));
ret = MPC_INEX(inex_re, ret);
}
}
else
ret = mpc_set (z, u, rnd);
@ -830,6 +850,15 @@ mpc_pow (mpc_ptr z, mpc_srcptr x, mpc_srcptr y, mpc_rnd_t rnd)
if (saved_overflow)
mpfr_set_overflow ();
/* restore the exponent range, and check the range of results */
mpfr_set_emin (saved_emin);
mpfr_set_emax (saved_emax);
inex_re = mpfr_check_range (mpc_realref (z), MPC_INEX_RE(ret),
MPC_RND_RE (rnd));
inex_im = mpfr_check_range (mpc_imagref (z), MPC_INEX_IM(ret),
MPC_RND_IM (rnd));
ret = MPC_INEX(inex_re, inex_im);
end:
return ret;
}

View File

@ -1,6 +1,6 @@
/* mpc_sin_cos -- combined sine and cosine of a complex number.
Copyright (C) 2010, 2011, 2012 INRIA
Copyright (C) 2010, 2011, 2012, 2020 INRIA
This file is part of GNU MPC.
@ -343,6 +343,12 @@ mpc_sin_cos (mpc_ptr rop_sin, mpc_ptr rop_cos, mpc_srcptr op,
mpfr_prec_t prec;
int ok;
int inex_re, inex_im, inex_sin, inex_cos, loop = 0;
mpfr_exp_t saved_emin, saved_emax;
saved_emin = mpfr_get_emin ();
saved_emax = mpfr_get_emax ();
mpfr_set_emin (mpfr_get_emin_min ());
mpfr_set_emax (mpfr_get_emax_max ());
prec = 2;
if (rop_sin != NULL)
@ -376,7 +382,6 @@ mpc_sin_cos (mpc_ptr rop_sin, mpc_ptr rop_cos, mpc_srcptr op,
do {
loop ++;
ok = 1;
prec += (loop <= 2) ? mpc_ceil_log2 (prec) + 5 : prec / 2;
mpfr_set_prec (s, prec);
@ -389,6 +394,8 @@ mpc_sin_cos (mpc_ptr rop_sin, mpc_ptr rop_cos, mpc_srcptr op,
mpfr_sin_cos (s, c, mpc_realref(op), MPFR_RNDN);
mpfr_sinh_cosh (sh, ch, mpc_imagref(op), MPFR_RNDN);
ok = 1;
if (rop_sin != NULL) {
/* real part of sine */
mpfr_mul (sch, s, ch, MPFR_RNDN);
@ -458,6 +465,30 @@ mpc_sin_cos (mpc_ptr rop_sin, mpc_ptr rop_cos, mpc_srcptr op,
mpfr_clear (sch);
mpfr_clear (csh);
/* restore the exponent range, and check the range of results */
mpfr_set_emin (saved_emin);
mpfr_set_emax (saved_emax);
if (rop_sin != NULL)
{
inex_re = mpfr_check_range (mpc_realref (rop_sin),
MPC_INEX_RE (inex_sin),
MPC_RND_RE (rnd_sin));
inex_im = mpfr_check_range (mpc_imagref (rop_sin),
MPC_INEX_IM (inex_sin),
MPC_RND_IM (rnd_sin));
inex_sin = MPC_INEX (inex_re, inex_im);
}
if (rop_cos != NULL)
{
inex_re = mpfr_check_range (mpc_realref (rop_cos),
MPC_INEX_RE (inex_cos),
MPC_RND_RE (rnd_cos));
inex_im = mpfr_check_range (mpc_imagref (rop_cos),
MPC_INEX_IM (inex_cos),
MPC_RND_IM (rnd_cos));
inex_cos = MPC_INEX (inex_re, inex_im);
}
return (MPC_INEX12 (inex_sin, inex_cos));
}
}

View File

@ -1,6 +1,6 @@
/* mpc_sqrt -- Take the square root of a complex number.
Copyright (C) 2002, 2008, 2009, 2010, 2011, 2012 INRIA
Copyright (C) 2002, 2008, 2009, 2010, 2011, 2012, 2020 INRIA
This file is part of GNU MPC.
@ -48,6 +48,7 @@ mpc_sqrt (mpc_ptr a, mpc_srcptr b, mpc_rnd_t rnd)
/* we need to know the sign of Im(b) when it is +/-0 */
const mpfr_rnd_t r = im_sgn ? MPFR_RNDD : MPFR_RNDU;
/* rounding mode used when computing t */
mpfr_exp_t saved_emin, saved_emax;
/* special values */
if (!mpc_fin_p (b)) {
@ -202,6 +203,11 @@ mpc_sqrt (mpc_ptr a, mpc_srcptr b, mpc_rnd_t rnd)
}
}
saved_emin = mpfr_get_emin ();
saved_emax = mpfr_get_emax ();
mpfr_set_emin (mpfr_get_emin_min ());
mpfr_set_emax (mpfr_get_emax_max ());
do
{
loops ++;
@ -210,8 +216,11 @@ mpc_sqrt (mpc_ptr a, mpc_srcptr b, mpc_rnd_t rnd)
mpfr_set_prec (t, prec);
/* let b = x + iy */
/* w = sqrt ((|x| + sqrt (x^2 + y^2)) / 2), rounded down */
/* total error bounded by 3 ulps */
inex_w = mpc_abs (w, b, MPFR_RNDD);
/* final error on w bounded by 10 ulps, see algorithms.tex */
inex_w = mpfr_sqr (w, mpc_realref (b), MPFR_RNDD);
inex_w |= mpfr_sqr (t, mpc_imagref (b), MPFR_RNDD);
inex_w |= mpfr_add (w, w, t, MPFR_RNDD);
inex_w |= mpfr_sqrt (w, w, MPFR_RNDD);
if (re_cmp < 0)
inex_w |= mpfr_sub (w, w, mpc_realref (b), MPFR_RNDD);
else
@ -222,7 +231,7 @@ mpc_sqrt (mpc_ptr a, mpc_srcptr b, mpc_rnd_t rnd)
repr_w = mpfr_min_prec (w) <= prec_w;
if (!repr_w)
/* use the usual trick for obtaining the ternary value */
ok_w = mpfr_can_round (w, prec - 2, MPFR_RNDD, MPFR_RNDU,
ok_w = mpfr_can_round (w, prec - 4, MPFR_RNDD, MPFR_RNDU,
prec_w + (rnd_w == MPFR_RNDN));
else {
/* w is representable in the target precision and thus cannot be
@ -230,16 +239,16 @@ mpc_sqrt (mpc_ptr a, mpc_srcptr b, mpc_rnd_t rnd)
if (rnd_w == MPFR_RNDN)
/* If w can be rounded to nearest, then actually no rounding
occurs, and the ternary value is known from inex_w. */
ok_w = mpfr_can_round (w, prec - 2, MPFR_RNDD, MPFR_RNDN, prec_w);
ok_w = mpfr_can_round (w, prec - 4, MPFR_RNDD, MPFR_RNDN, prec_w);
else
/* If w can be rounded down, then any direct rounding and the
ternary flag can be determined from inex_w. */
ok_w = mpfr_can_round (w, prec - 2, MPFR_RNDD, MPFR_RNDD, prec_w);
ok_w = mpfr_can_round (w, prec - 4, MPFR_RNDD, MPFR_RNDD, prec_w);
}
if (!inex_w || ok_w) {
/* t = y / 2w, rounded away */
/* total error bounded by 7 ulps */
/* total error bounded by 16 ulps, see algorithms.tex */
inex_t = mpfr_div (t, mpc_imagref (b), w, r);
if (!inex_t && inex_w)
/* The division was exact, but w was not. */
@ -249,13 +258,13 @@ mpc_sqrt (mpc_ptr a, mpc_srcptr b, mpc_rnd_t rnd)
if (!repr_t)
/* As for w; since t was rounded away, we check whether rounding to 0
is possible. */
ok_t = mpfr_can_round (t, prec - 3, r, MPFR_RNDZ,
ok_t = mpfr_can_round (t, prec - 4, r, MPFR_RNDZ,
prec_t + (rnd_t == MPFR_RNDN));
else {
if (rnd_t == MPFR_RNDN)
ok_t = mpfr_can_round (t, prec - 3, r, MPFR_RNDN, prec_t);
ok_t = mpfr_can_round (t, prec - 4, r, MPFR_RNDN, prec_t);
else
ok_t = mpfr_can_round (t, prec - 3, r, r, prec_t);
ok_t = mpfr_can_round (t, prec - 4, r, r, prec_t);
}
}
}
@ -360,5 +369,11 @@ mpc_sqrt (mpc_ptr a, mpc_srcptr b, mpc_rnd_t rnd)
mpfr_clear (w);
mpfr_clear (t);
/* restore the exponent range, and check the range of results */
mpfr_set_emin (saved_emin);
mpfr_set_emax (saved_emax);
inex_re = mpfr_check_range (mpc_realref (a), inex_re, MPC_RND_RE (rnd));
inex_im = mpfr_check_range (mpc_imagref (a), inex_im, MPC_RND_IM (rnd));
return MPC_INEX (inex_re, inex_im);
}

43
gcc/mpc/src/sum.c Normal file
View File

@ -0,0 +1,43 @@
/* mpc_sum -- Add an array of complex numbers.
Copyright (C) 2018 INRIA
This file is part of GNU MPC.
GNU MPC is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
Free Software Foundation; either version 3 of the License, or (at your
option) any later version.
GNU MPC 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 Lesser General Public License for
more details.
You should have received a copy of the GNU Lesser General Public License
along with this program. If not, see http://www.gnu.org/licenses/ .
*/
#include <stdio.h> /* for MPC_ASSERT */
#include "mpc-impl.h"
int
mpc_sum (mpc_ptr sum, const mpc_ptr *z, unsigned long n, mpc_rnd_t rnd)
{
int inex_re, inex_im;
mpfr_ptr *t;
unsigned long i;
t = (mpfr_ptr *) malloc (n * sizeof(mpfr_t));
/* warning: when n=0, malloc() might return NULL (e.g., gcc119) */
MPC_ASSERT(n == 0 || t != NULL);
for (i = 0; i < n; i++)
t[i] = mpc_realref (z[i]);
inex_re = mpfr_sum (mpc_realref (sum), t, n, MPC_RND_RE (rnd));
for (i = 0; i < n; i++)
t[i] = mpc_imagref (z[i]);
inex_im = mpfr_sum (mpc_imagref (sum), t, n, MPC_RND_IM (rnd));
free (t);
return MPC_INEX(inex_re, inex_im);
}

View File

@ -1,6 +1,6 @@
/* mpc_tan -- tangent of a complex number.
Copyright (C) 2008-2015 INRIA
Copyright (C) 2008, 2009, 2010, 2011, 2012, 2013, 2015, 2020 INRIA
This file is part of GNU MPC.
@ -22,14 +22,78 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
#include <limits.h>
#include "mpc-impl.h"
/* special case where the imaginary part of tan(op) rounds to -1 or 1:
return 1 if |Im(tan(op))| > 1, and -1 if |Im(tan(op))| < 1, return 0
if we can't decide.
The imaginary part is sinh(2*y)/(cos(2*x) + cosh(2*y)) where op = (x,y).
*/
static int
tan_im_cmp_one (mpc_srcptr op)
{
mpfr_t x, c;
int ret = 0;
mpfr_exp_t expc;
mpfr_init2 (x, mpfr_get_prec (mpc_realref (op)));
mpfr_mul_2exp (x, mpc_realref (op), 1, MPFR_RNDN);
mpfr_init2 (c, 32);
mpfr_cos (c, x, MPFR_RNDN);
/* if cos(2x) >= 0, then |sinh(2y)/(cos(2x)+cosh(2y))| < 1 */
if (mpfr_sgn (c) >= 0)
ret = -1; /* |Im(tan(op))| < 1 */
else
{
/* now cos(2x) < 0: |cosh(2y) - sinh(2y)| = exp(-2|y|) */
expc = mpfr_get_exp (c);
mpfr_abs (c, mpc_imagref (op), MPFR_RNDN);
mpfr_mul_si (c, c, -2, MPFR_RNDN);
mpfr_exp (c, c, MPFR_RNDN);
if (mpfr_zero_p (c) || mpfr_get_exp (c) < expc)
ret = 1; /* |Im(tan(op))| > 1 */
}
mpfr_clear (c);
mpfr_clear (x);
return ret;
}
/* special case where the real part of tan(op) underflows to 0:
return 1 if 0 < Re(tan(op)) < 2^(emin-2),
-1 if -2^(emin-2) < Re(tan(op))| < 0, and 0 if we can't decide.
The real part is sin(2*x)/(cos(2*x) + cosh(2*y)) where op = (x,y),
thus has the sign of sin(2*x).
*/
static int
tan_re_cmp_zero (mpc_srcptr op, mpfr_exp_t emin)
{
mpfr_t x, s, c;
int ret = 0;
mpfr_init2 (x, mpfr_get_prec (mpc_realref (op)));
mpfr_mul_2exp (x, mpc_realref (op), 1, MPFR_RNDN);
mpfr_init2 (s, 32);
mpfr_init2 (c, 32);
mpfr_sin (s, x, MPFR_RNDA);
mpfr_mul_2exp (x, mpc_imagref (op), 1, MPFR_RNDN);
mpfr_cosh (c, x, MPFR_RNDZ);
mpfr_sub_ui (c, c, 1, MPFR_RNDZ);
mpfr_div (s, s, c, MPFR_RNDA);
if (mpfr_zero_p (s) || mpfr_get_exp (s) <= emin - 2)
ret = mpfr_sgn (s);
mpfr_clear (s);
mpfr_clear (c);
mpfr_clear (x);
return ret;
}
int
mpc_tan (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
{
mpc_t x, y;
mpfr_prec_t prec;
mpfr_exp_t err;
int ok = 0;
int inex;
int ok;
int inex, inex_re, inex_im;
mpfr_exp_t saved_emin, saved_emax;
/* special values */
if (!mpc_fin_p (op))
@ -80,7 +144,6 @@ mpc_tan (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
/* tan(+Inf +i*Inf) = +/-0 +i */
{
const int sign_re = mpfr_signbit (mpc_realref (op));
int inex_im;
mpfr_set_ui (mpc_realref (rop), 0, MPC_RND_RE (rnd));
mpfr_setsign (mpc_realref (rop), mpc_realref (rop), sign_re, MPFR_RNDN);
@ -106,7 +169,6 @@ mpc_tan (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
{
mpfr_t c;
mpfr_t s;
int inex_im;
mpfr_init (c);
mpfr_init (s);
@ -132,8 +194,6 @@ mpc_tan (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
/* tan(-0 -i*y) = -0 +i*tanh(y), when y is finite. */
/* tan(+0 +i*y) = +0 +i*tanh(y), when y is finite. */
{
int inex_im;
mpfr_set (mpc_realref (rop), mpc_realref (op), MPC_RND_RE (rnd));
inex_im = mpfr_tanh (mpc_imagref (rop), mpc_imagref (op), MPC_RND_IM (rnd));
@ -144,14 +204,17 @@ mpc_tan (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
/* tan(x -i*0) = tan(x) -i*0, when x is finite. */
/* tan(x +i*0) = tan(x) +i*0, when x is finite. */
{
int inex_re;
inex_re = mpfr_tan (mpc_realref (rop), mpc_realref (op), MPC_RND_RE (rnd));
mpfr_set (mpc_imagref (rop), mpc_imagref (op), MPC_RND_IM (rnd));
return MPC_INEX (inex_re, 0);
}
saved_emin = mpfr_get_emin ();
saved_emax = mpfr_get_emax ();
mpfr_set_emin (mpfr_get_emin_min ());
mpfr_set_emax (mpfr_get_emax_max ());
/* ordinary (non-zero) numbers */
/* tan(op) = sin(op) / cos(op).
@ -198,7 +261,7 @@ mpc_tan (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
MPFR_ADD_ONE_ULP (mpc_imagref (x));
MPFR_ADD_ONE_ULP (mpc_realref (y));
MPFR_ADD_ONE_ULP (mpc_imagref (y));
MPC_ASSERT (mpfr_zero_p (mpc_realref (x)) == 0);
if ( mpfr_inf_p (mpc_realref (x)) || mpfr_inf_p (mpc_imagref (x))
|| mpfr_inf_p (mpc_realref (y)) || mpfr_inf_p (mpc_imagref (y))) {
@ -206,7 +269,6 @@ mpc_tan (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
Im(op) was large, in which case the result is
sign(tan(Re(op)))*0 + sign(Im(op))*I,
where sign(tan(Re(op))) = sign(Re(x))*sign(Re(y)). */
int inex_re, inex_im;
mpfr_set_ui (mpc_realref (rop), 0, MPFR_RNDN);
if (mpfr_sgn (mpc_realref (x)) * mpfr_sgn (mpc_realref (y)) < 0)
{
@ -251,15 +313,20 @@ mpc_tan (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
tan(1+14*I) = 1.26e-10 + 1.00*I. For small precision sin(op) and
cos(op) differ only by a factor I, thus after mpc_div x = I and
its real part is zero. */
if (mpfr_zero_p (mpc_realref (x)) || mpfr_zero_p (mpc_imagref (x)))
if (mpfr_zero_p (mpc_realref (x)))
{
err = prec; /* double precision */
continue;
/* since we use an extended exponent range, if real(x) is zero,
this means the real part underflows, and we assume we can round */
ok = tan_re_cmp_zero (op, saved_emin);
if (ok > 0)
MPFR_ADD_ONE_ULP (mpc_realref (x));
else
MPFR_SUB_ONE_ULP (mpc_realref (x));
}
else
{
if (MPC_INEX_RE (inex))
MPFR_ADD_ONE_ULP (mpc_realref (x));
if (MPC_INEX_IM (inex))
MPFR_ADD_ONE_ULP (mpc_imagref (x));
MPC_ASSERT (mpfr_zero_p (mpc_realref (x)) == 0);
ezr = mpfr_get_exp (mpc_realref (x));
@ -273,15 +340,48 @@ mpc_tan (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
ok = (!mpfr_number_p (mpc_realref (x)))
|| mpfr_can_round (mpc_realref(x), prec - err, MPFR_RNDN, MPFR_RNDZ,
MPC_PREC_RE(rop) + (MPC_RND_RE(rnd) == MPFR_RNDN));
}
if (ok)
{
if (MPC_INEX_IM (inex))
MPFR_ADD_ONE_ULP (mpc_imagref (x));
/* Can the imaginary part be rounded? */
ok = (!mpfr_number_p (mpc_imagref (x)))
|| mpfr_can_round (mpc_imagref(x), prec - 6, MPFR_RNDN, MPFR_RNDZ,
MPC_PREC_IM(rop) + (MPC_RND_IM(rnd) == MPFR_RNDN));
/* Special case when Im(x) = +/- 1:
tan z = [sin(2x)+i*sinh(2y)] / [cos(2x) + cosh(2y)]
(formula 4.3.57 of Abramowitz and Stegun) thus for y large
in absolute value the imaginary part is near -1 or +1.
More precisely cos(2x) + cosh(2y) = cosh(2y) + t with |t| <= 1,
thus since cosh(2y) >= exp|2y|/2, then the imaginary part is:
tanh(2y) * 1/(1+u) where u = |cos(2x)/cosh(2y)| <= 2/exp|2y|
thus |im(z) - tanh(2y)| <= 2/exp|2y| * tanh(2y).
Since |tanh(2y)| = (1-exp(-4|y|))/(1+exp(-4|y|)),
we have 1-|tanh(2y)| < 2*exp(-4|y|).
Thus |im(z)-1| < 2/exp|2y| + 2/exp|4y| < 4/exp|2y| < 4/2^|2y|.
If 2^EXP(y) >= p+2, then im(z) rounds to -1 or 1. */
if (ok == 0 && (mpfr_cmp_ui (mpc_imagref(x), 1) == 0 ||
mpfr_cmp_si (mpc_imagref(x), -1) == 0) &&
mpfr_get_exp (mpc_imagref(op)) >= 0 &&
((size_t) mpfr_get_exp (mpc_imagref(op)) >= 8 * sizeof (mpfr_prec_t) ||
((mpfr_prec_t) 1) << mpfr_get_exp (mpc_imagref(op)) >= mpfr_get_prec (mpc_imagref (rop)) + 2))
{
/* subtract one ulp, so that we get the correct inexact flag */
ok = tan_im_cmp_one (op);
if (ok < 0)
MPFR_SUB_ONE_ULP (mpc_imagref(x));
else if (ok > 0)
MPFR_ADD_ONE_ULP (mpc_imagref(x));
}
}
if (ok == 0)
prec += prec / 2;
}
while (ok == 0);
inex = mpc_set (rop, x, rnd);
@ -290,5 +390,13 @@ mpc_tan (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
mpc_clear (x);
mpc_clear (y);
return inex;
/* restore the exponent range, and check the range of results */
mpfr_set_emin (saved_emin);
mpfr_set_emax (saved_emax);
inex_re = mpfr_check_range (mpc_realref (rop), MPC_INEX_RE(inex),
MPC_RND_RE (rnd));
inex_im = mpfr_check_range (mpc_imagref (rop), MPC_INEX_IM(inex),
MPC_RND_IM (rnd));
return MPC_INEX(inex_re, inex_im);
}

View File

@ -1,6 +1,6 @@
## tests/Makefile.am -- Process this file with automake to produce Makefile.in
##
## Copyright (C) 2008, 2009, 2010, 2011, 2012, 2013, 2016 INRIA
## Copyright (C) 2008, 2009, 2010, 2011, 2012, 2013, 2016, 2020 INRIA
##
## This file is part of GNU MPC.
##
@ -17,11 +17,17 @@
## You should have received a copy of the GNU Lesser General Public License
## along with this program. If not, see http://www.gnu.org/licenses/ .
AM_CPPFLAGS = -I$(top_srcdir)/src
AM_CPPFLAGS = -I$(top_srcdir)/src -I$(top_srcdir)
LDADD = libmpc-tests.la $(top_builddir)/src/libmpc.la
# let libtool create an executable instead of a shell script
# useful for tests with valgrind
AM_LDFLAGS = -no-install
# The -L$(top_builddir)/src/.libs option is necessary for some platforms,
# such as HP-UX, when --with-gmp or --with-mpfr is used and an old MPC
# library is already installed in the corresponding lib directories: its
# purpose is to make sure that the local .libs comes first in the library
# search path (otherwise the tests are linked against the old MPC library
# by the LINK command -- see the generated Makefile).
AM_LDFLAGS = -no-install -L$(top_builddir)/src/.libs
# LOADLIBES (documented in the "GNU make" manual and equivalent to LDLIBS)
# enables to compile a program foo.c in the test directory by simply doing
# "make foo".
@ -31,13 +37,13 @@ LOADLIBES=$(DEFS) $(AM_CPPFLAGS) $(CPPFLAGS) $(CFLAGS) \
check_PROGRAMS = tabs tacos tacosh tadd tadd_fr tadd_si tadd_ui targ \
tasin tasinh tatan tatanh tcmp_abs tconj tcos tcosh \
tdiv tdiv_2si tdiv_2ui \
tdiv_fr tdiv_ui texp tfma tfr_div tfr_sub timag tio_str tlog tlog10 \
tdiv tdiv_2si tdiv_2ui tdiv_fr tdiv_ui tdot texp tfma tfr_div tfr_sub \
timag tio_str tlog tlog10 \
tmul tmul_2si tmul_2ui tmul_fr tmul_i tmul_si tmul_ui tneg tnorm tpow \
tpow_d tpow_fr tpow_ld tpow_si tpow_ui tpow_z tprec tproj treal \
treimref trootofunity \
tset tsin tsin_cos tsinh tsqr tsqrt tstrtoc tsub tsub_fr \
tsub_ui tswap ttan ttanh tui_div tui_ui_sub tget_version exceptions
tsub_ui tsum tswap ttan ttanh tui_div tui_ui_sub tget_version exceptions
check_LTLIBRARIES=libmpc-tests.la
libmpc_tests_la_SOURCES = mpc-tests.h check_data.c clear_parameters.c \

View File

@ -1,7 +1,7 @@
# Makefile.in generated by automake 1.15.1 from Makefile.am.
# Makefile.in generated by automake 1.16.2 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2017 Free Software Foundation, Inc.
# Copyright (C) 1994-2020 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -93,20 +93,20 @@ check_PROGRAMS = tabs$(EXEEXT) tacos$(EXEEXT) tacosh$(EXEEXT) \
tatan$(EXEEXT) tatanh$(EXEEXT) tcmp_abs$(EXEEXT) \
tconj$(EXEEXT) tcos$(EXEEXT) tcosh$(EXEEXT) tdiv$(EXEEXT) \
tdiv_2si$(EXEEXT) tdiv_2ui$(EXEEXT) tdiv_fr$(EXEEXT) \
tdiv_ui$(EXEEXT) texp$(EXEEXT) tfma$(EXEEXT) tfr_div$(EXEEXT) \
tfr_sub$(EXEEXT) timag$(EXEEXT) tio_str$(EXEEXT) tlog$(EXEEXT) \
tlog10$(EXEEXT) tmul$(EXEEXT) tmul_2si$(EXEEXT) \
tmul_2ui$(EXEEXT) tmul_fr$(EXEEXT) tmul_i$(EXEEXT) \
tmul_si$(EXEEXT) tmul_ui$(EXEEXT) tneg$(EXEEXT) tnorm$(EXEEXT) \
tpow$(EXEEXT) tpow_d$(EXEEXT) tpow_fr$(EXEEXT) \
tpow_ld$(EXEEXT) tpow_si$(EXEEXT) tpow_ui$(EXEEXT) \
tpow_z$(EXEEXT) tprec$(EXEEXT) tproj$(EXEEXT) treal$(EXEEXT) \
treimref$(EXEEXT) trootofunity$(EXEEXT) tset$(EXEEXT) \
tsin$(EXEEXT) tsin_cos$(EXEEXT) tsinh$(EXEEXT) tsqr$(EXEEXT) \
tsqrt$(EXEEXT) tstrtoc$(EXEEXT) tsub$(EXEEXT) tsub_fr$(EXEEXT) \
tsub_ui$(EXEEXT) tswap$(EXEEXT) ttan$(EXEEXT) ttanh$(EXEEXT) \
tui_div$(EXEEXT) tui_ui_sub$(EXEEXT) tget_version$(EXEEXT) \
exceptions$(EXEEXT)
tdiv_ui$(EXEEXT) tdot$(EXEEXT) texp$(EXEEXT) tfma$(EXEEXT) \
tfr_div$(EXEEXT) tfr_sub$(EXEEXT) timag$(EXEEXT) \
tio_str$(EXEEXT) tlog$(EXEEXT) tlog10$(EXEEXT) tmul$(EXEEXT) \
tmul_2si$(EXEEXT) tmul_2ui$(EXEEXT) tmul_fr$(EXEEXT) \
tmul_i$(EXEEXT) tmul_si$(EXEEXT) tmul_ui$(EXEEXT) \
tneg$(EXEEXT) tnorm$(EXEEXT) tpow$(EXEEXT) tpow_d$(EXEEXT) \
tpow_fr$(EXEEXT) tpow_ld$(EXEEXT) tpow_si$(EXEEXT) \
tpow_ui$(EXEEXT) tpow_z$(EXEEXT) tprec$(EXEEXT) tproj$(EXEEXT) \
treal$(EXEEXT) treimref$(EXEEXT) trootofunity$(EXEEXT) \
tset$(EXEEXT) tsin$(EXEEXT) tsin_cos$(EXEEXT) tsinh$(EXEEXT) \
tsqr$(EXEEXT) tsqrt$(EXEEXT) tstrtoc$(EXEEXT) tsub$(EXEEXT) \
tsub_fr$(EXEEXT) tsub_ui$(EXEEXT) tsum$(EXEEXT) tswap$(EXEEXT) \
ttan$(EXEEXT) ttanh$(EXEEXT) tui_div$(EXEEXT) \
tui_ui_sub$(EXEEXT) tget_version$(EXEEXT) exceptions$(EXEEXT)
subdir = tests
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_c_check_flag.m4 \
@ -225,6 +225,10 @@ tdiv_ui_SOURCES = tdiv_ui.c
tdiv_ui_OBJECTS = tdiv_ui.$(OBJEXT)
tdiv_ui_LDADD = $(LDADD)
tdiv_ui_DEPENDENCIES = libmpc-tests.la $(top_builddir)/src/libmpc.la
tdot_SOURCES = tdot.c
tdot_OBJECTS = tdot.$(OBJEXT)
tdot_LDADD = $(LDADD)
tdot_DEPENDENCIES = libmpc-tests.la $(top_builddir)/src/libmpc.la
texp_SOURCES = texp.c
texp_OBJECTS = texp.$(OBJEXT)
texp_LDADD = $(LDADD)
@ -387,6 +391,10 @@ tsub_ui_SOURCES = tsub_ui.c
tsub_ui_OBJECTS = tsub_ui.$(OBJEXT)
tsub_ui_LDADD = $(LDADD)
tsub_ui_DEPENDENCIES = libmpc-tests.la $(top_builddir)/src/libmpc.la
tsum_SOURCES = tsum.c
tsum_OBJECTS = tsum.$(OBJEXT)
tsum_LDADD = $(LDADD)
tsum_DEPENDENCIES = libmpc-tests.la $(top_builddir)/src/libmpc.la
tswap_SOURCES = tswap.c
tswap_OBJECTS = tswap.$(OBJEXT)
tswap_LDADD = $(LDADD)
@ -421,8 +429,52 @@ am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
am__v_at_0 = @
am__v_at_1 =
DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
am__maybe_remake_depfiles = depfiles
am__depfiles_remade = ./$(DEPDIR)/check_data.Plo \
./$(DEPDIR)/clear_parameters.Plo \
./$(DEPDIR)/close_datafile.Plo ./$(DEPDIR)/comparisons.Plo \
./$(DEPDIR)/copy_parameter.Plo ./$(DEPDIR)/double_rounding.Plo \
./$(DEPDIR)/exceptions.Po ./$(DEPDIR)/init_parameters.Plo \
./$(DEPDIR)/mpfr_flags.Plo ./$(DEPDIR)/open_datafile.Plo \
./$(DEPDIR)/print_parameter.Plo ./$(DEPDIR)/random.Plo \
./$(DEPDIR)/read_data.Plo ./$(DEPDIR)/read_description.Plo \
./$(DEPDIR)/read_line.Plo ./$(DEPDIR)/rounding.Plo \
./$(DEPDIR)/setprec_parameters.Plo ./$(DEPDIR)/tabs.Po \
./$(DEPDIR)/tacos.Po ./$(DEPDIR)/tacosh.Po ./$(DEPDIR)/tadd.Po \
./$(DEPDIR)/tadd_fr.Po ./$(DEPDIR)/tadd_si.Po \
./$(DEPDIR)/tadd_ui.Po ./$(DEPDIR)/targ.Po \
./$(DEPDIR)/tasin.Po ./$(DEPDIR)/tasinh.Po \
./$(DEPDIR)/tatan.Po ./$(DEPDIR)/tatanh.Po \
./$(DEPDIR)/tcmp_abs.Po ./$(DEPDIR)/tconj.Po \
./$(DEPDIR)/tcos.Po ./$(DEPDIR)/tcosh.Po ./$(DEPDIR)/tdiv.Po \
./$(DEPDIR)/tdiv_2si.Po ./$(DEPDIR)/tdiv_2ui.Po \
./$(DEPDIR)/tdiv_fr.Po ./$(DEPDIR)/tdiv_ui.Po \
./$(DEPDIR)/tdot.Po ./$(DEPDIR)/texp.Po ./$(DEPDIR)/tfma.Po \
./$(DEPDIR)/tfr_div.Po ./$(DEPDIR)/tfr_sub.Po \
./$(DEPDIR)/tget_version.Po ./$(DEPDIR)/timag.Po \
./$(DEPDIR)/tio_str.Po ./$(DEPDIR)/tlog.Po \
./$(DEPDIR)/tlog10.Po ./$(DEPDIR)/tmul.Po \
./$(DEPDIR)/tmul_2si.Po ./$(DEPDIR)/tmul_2ui.Po \
./$(DEPDIR)/tmul_fr.Po ./$(DEPDIR)/tmul_i.Po \
./$(DEPDIR)/tmul_si.Po ./$(DEPDIR)/tmul_ui.Po \
./$(DEPDIR)/tneg.Po ./$(DEPDIR)/tnorm.Po \
./$(DEPDIR)/tpl_gmp.Plo ./$(DEPDIR)/tpl_mpc.Plo \
./$(DEPDIR)/tpl_mpfr.Plo ./$(DEPDIR)/tpl_native.Plo \
./$(DEPDIR)/tpow.Po ./$(DEPDIR)/tpow_d.Po \
./$(DEPDIR)/tpow_fr.Po ./$(DEPDIR)/tpow_ld.Po \
./$(DEPDIR)/tpow_si.Po ./$(DEPDIR)/tpow_ui.Po \
./$(DEPDIR)/tpow_z.Po ./$(DEPDIR)/tprec.Po \
./$(DEPDIR)/tproj.Po ./$(DEPDIR)/treal.Po \
./$(DEPDIR)/treimref.Po ./$(DEPDIR)/trootofunity.Po \
./$(DEPDIR)/tset.Po ./$(DEPDIR)/tsin.Po \
./$(DEPDIR)/tsin_cos.Po ./$(DEPDIR)/tsinh.Po \
./$(DEPDIR)/tsqr.Po ./$(DEPDIR)/tsqrt.Po \
./$(DEPDIR)/tstrtoc.Po ./$(DEPDIR)/tsub.Po \
./$(DEPDIR)/tsub_fr.Po ./$(DEPDIR)/tsub_ui.Po \
./$(DEPDIR)/tsum.Po ./$(DEPDIR)/tswap.Po ./$(DEPDIR)/ttan.Po \
./$(DEPDIR)/ttanh.Po ./$(DEPDIR)/tui_div.Po \
./$(DEPDIR)/tui_ui_sub.Po
am__mv = mv -f
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
@ -445,25 +497,25 @@ am__v_CCLD_1 =
SOURCES = $(libmpc_tests_la_SOURCES) exceptions.c tabs.c tacos.c \
tacosh.c tadd.c tadd_fr.c tadd_si.c tadd_ui.c targ.c tasin.c \
tasinh.c tatan.c tatanh.c tcmp_abs.c tconj.c tcos.c tcosh.c \
tdiv.c tdiv_2si.c tdiv_2ui.c tdiv_fr.c tdiv_ui.c texp.c tfma.c \
tfr_div.c tfr_sub.c tget_version.c timag.c tio_str.c tlog.c \
tlog10.c tmul.c tmul_2si.c tmul_2ui.c tmul_fr.c tmul_i.c \
tmul_si.c tmul_ui.c tneg.c tnorm.c tpow.c tpow_d.c tpow_fr.c \
tpow_ld.c tpow_si.c tpow_ui.c tpow_z.c tprec.c tproj.c treal.c \
treimref.c trootofunity.c tset.c tsin.c tsin_cos.c tsinh.c \
tsqr.c tsqrt.c tstrtoc.c tsub.c tsub_fr.c tsub_ui.c tswap.c \
ttan.c ttanh.c tui_div.c tui_ui_sub.c
tdiv.c tdiv_2si.c tdiv_2ui.c tdiv_fr.c tdiv_ui.c tdot.c texp.c \
tfma.c tfr_div.c tfr_sub.c tget_version.c timag.c tio_str.c \
tlog.c tlog10.c tmul.c tmul_2si.c tmul_2ui.c tmul_fr.c \
tmul_i.c tmul_si.c tmul_ui.c tneg.c tnorm.c tpow.c tpow_d.c \
tpow_fr.c tpow_ld.c tpow_si.c tpow_ui.c tpow_z.c tprec.c \
tproj.c treal.c treimref.c trootofunity.c tset.c tsin.c \
tsin_cos.c tsinh.c tsqr.c tsqrt.c tstrtoc.c tsub.c tsub_fr.c \
tsub_ui.c tsum.c tswap.c ttan.c ttanh.c tui_div.c tui_ui_sub.c
DIST_SOURCES = $(libmpc_tests_la_SOURCES) exceptions.c tabs.c tacos.c \
tacosh.c tadd.c tadd_fr.c tadd_si.c tadd_ui.c targ.c tasin.c \
tasinh.c tatan.c tatanh.c tcmp_abs.c tconj.c tcos.c tcosh.c \
tdiv.c tdiv_2si.c tdiv_2ui.c tdiv_fr.c tdiv_ui.c texp.c tfma.c \
tfr_div.c tfr_sub.c tget_version.c timag.c tio_str.c tlog.c \
tlog10.c tmul.c tmul_2si.c tmul_2ui.c tmul_fr.c tmul_i.c \
tmul_si.c tmul_ui.c tneg.c tnorm.c tpow.c tpow_d.c tpow_fr.c \
tpow_ld.c tpow_si.c tpow_ui.c tpow_z.c tprec.c tproj.c treal.c \
treimref.c trootofunity.c tset.c tsin.c tsin_cos.c tsinh.c \
tsqr.c tsqrt.c tstrtoc.c tsub.c tsub_fr.c tsub_ui.c tswap.c \
ttan.c ttanh.c tui_div.c tui_ui_sub.c
tdiv.c tdiv_2si.c tdiv_2ui.c tdiv_fr.c tdiv_ui.c tdot.c texp.c \
tfma.c tfr_div.c tfr_sub.c tget_version.c timag.c tio_str.c \
tlog.c tlog10.c tmul.c tmul_2si.c tmul_2ui.c tmul_fr.c \
tmul_i.c tmul_si.c tmul_ui.c tneg.c tnorm.c tpow.c tpow_d.c \
tpow_fr.c tpow_ld.c tpow_si.c tpow_ui.c tpow_z.c tprec.c \
tproj.c treal.c treimref.c trootofunity.c tset.c tsin.c \
tsin_cos.c tsinh.c tsqr.c tsqrt.c tstrtoc.c tsub.c tsub_fr.c \
tsub_ui.c tsum.c tswap.c ttan.c ttanh.c tui_div.c tui_ui_sub.c
am__can_run_installinfo = \
case $$AM_UPDATE_INFO_DIR in \
n|no|NO) false;; \
@ -674,7 +726,7 @@ RECHECK_LOGS = $(TEST_LOGS)
AM_RECURSIVE_TARGETS = check recheck
TEST_SUITE_LOG = test-suite.log
TEST_EXTENSIONS = @EXEEXT@ .test
LOG_DRIVER = $(SHELL) $(top_srcdir)/test-driver
LOG_DRIVER = $(SHELL) $(top_srcdir)/build-aux/test-driver
LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS)
am__set_b = \
case '$@' in \
@ -689,11 +741,12 @@ am__set_b = \
am__test_logs1 = $(TESTS:=.log)
am__test_logs2 = $(am__test_logs1:@EXEEXT@.log=.log)
TEST_LOGS = $(am__test_logs2:.test.log=.log)
TEST_LOG_DRIVER = $(SHELL) $(top_srcdir)/test-driver
TEST_LOG_DRIVER = $(SHELL) $(top_srcdir)/build-aux/test-driver
TEST_LOG_COMPILE = $(TEST_LOG_COMPILER) $(AM_TEST_LOG_FLAGS) \
$(TEST_LOG_FLAGS)
am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp \
$(top_srcdir)/test-driver
am__DIST_COMMON = $(srcdir)/Makefile.in \
$(top_srcdir)/build-aux/depcomp \
$(top_srcdir)/build-aux/test-driver
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
@ -819,11 +872,17 @@ target_alias = @target_alias@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
AM_CPPFLAGS = -I$(top_srcdir)/src
AM_CPPFLAGS = -I$(top_srcdir)/src -I$(top_srcdir)
LDADD = libmpc-tests.la $(top_builddir)/src/libmpc.la
# let libtool create an executable instead of a shell script
# useful for tests with valgrind
AM_LDFLAGS = -no-install
# The -L$(top_builddir)/src/.libs option is necessary for some platforms,
# such as HP-UX, when --with-gmp or --with-mpfr is used and an old MPC
# library is already installed in the corresponding lib directories: its
# purpose is to make sure that the local .libs comes first in the library
# search path (otherwise the tests are linked against the old MPC library
# by the LINK command -- see the generated Makefile).
AM_LDFLAGS = -no-install -L$(top_builddir)/src/.libs
# LOADLIBES (documented in the "GNU make" manual and equivalent to LDLIBS)
# enables to compile a program foo.c in the test directory by simply doing
# "make foo".
@ -885,8 +944,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
@ -898,6 +957,15 @@ $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
clean-checkPROGRAMS:
@list='$(check_PROGRAMS)'; test -n "$$list" || exit 0; \
echo " rm -f" $$list; \
rm -f $$list || exit $$?; \
test -n "$(EXEEXT)" || exit 0; \
list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
echo " rm -f" $$list; \
rm -f $$list
clean-checkLTLIBRARIES:
-test -z "$(check_LTLIBRARIES)" || rm -f $(check_LTLIBRARIES)
@list='$(check_LTLIBRARIES)'; \
@ -912,15 +980,6 @@ clean-checkLTLIBRARIES:
libmpc-tests.la: $(libmpc_tests_la_OBJECTS) $(libmpc_tests_la_DEPENDENCIES) $(EXTRA_libmpc_tests_la_DEPENDENCIES)
$(AM_V_CCLD)$(LINK) $(libmpc_tests_la_OBJECTS) $(libmpc_tests_la_LIBADD) $(LIBS)
clean-checkPROGRAMS:
@list='$(check_PROGRAMS)'; test -n "$$list" || exit 0; \
echo " rm -f" $$list; \
rm -f $$list || exit $$?; \
test -n "$(EXEEXT)" || exit 0; \
list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
echo " rm -f" $$list; \
rm -f $$list
exceptions$(EXEEXT): $(exceptions_OBJECTS) $(exceptions_DEPENDENCIES) $(EXTRA_exceptions_DEPENDENCIES)
@rm -f exceptions$(EXEEXT)
$(AM_V_CCLD)$(LINK) $(exceptions_OBJECTS) $(exceptions_LDADD) $(LIBS)
@ -1009,6 +1068,10 @@ tdiv_ui$(EXEEXT): $(tdiv_ui_OBJECTS) $(tdiv_ui_DEPENDENCIES) $(EXTRA_tdiv_ui_DEP
@rm -f tdiv_ui$(EXEEXT)
$(AM_V_CCLD)$(LINK) $(tdiv_ui_OBJECTS) $(tdiv_ui_LDADD) $(LIBS)
tdot$(EXEEXT): $(tdot_OBJECTS) $(tdot_DEPENDENCIES) $(EXTRA_tdot_DEPENDENCIES)
@rm -f tdot$(EXEEXT)
$(AM_V_CCLD)$(LINK) $(tdot_OBJECTS) $(tdot_LDADD) $(LIBS)
texp$(EXEEXT): $(texp_OBJECTS) $(texp_DEPENDENCIES) $(EXTRA_texp_DEPENDENCIES)
@rm -f texp$(EXEEXT)
$(AM_V_CCLD)$(LINK) $(texp_OBJECTS) $(texp_LDADD) $(LIBS)
@ -1169,6 +1232,10 @@ tsub_ui$(EXEEXT): $(tsub_ui_OBJECTS) $(tsub_ui_DEPENDENCIES) $(EXTRA_tsub_ui_DEP
@rm -f tsub_ui$(EXEEXT)
$(AM_V_CCLD)$(LINK) $(tsub_ui_OBJECTS) $(tsub_ui_LDADD) $(LIBS)
tsum$(EXEEXT): $(tsum_OBJECTS) $(tsum_DEPENDENCIES) $(EXTRA_tsum_DEPENDENCIES)
@rm -f tsum$(EXEEXT)
$(AM_V_CCLD)$(LINK) $(tsum_OBJECTS) $(tsum_LDADD) $(LIBS)
tswap$(EXEEXT): $(tswap_OBJECTS) $(tswap_DEPENDENCIES) $(EXTRA_tswap_DEPENDENCIES)
@rm -f tswap$(EXEEXT)
$(AM_V_CCLD)$(LINK) $(tswap_OBJECTS) $(tswap_LDADD) $(LIBS)
@ -1195,93 +1262,101 @@ mostlyclean-compile:
distclean-compile:
-rm -f *.tab.c
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/check_data.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clear_parameters.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/close_datafile.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/comparisons.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/copy_parameter.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/double_rounding.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/exceptions.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/init_parameters.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpfr_flags.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/open_datafile.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/print_parameter.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/random.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/read_data.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/read_description.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/read_line.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rounding.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/setprec_parameters.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tabs.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tacos.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tacosh.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tadd.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tadd_fr.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tadd_si.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tadd_ui.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/targ.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tasin.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tasinh.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tatan.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tatanh.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tcmp_abs.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tconj.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tcos.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tcosh.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdiv.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdiv_2si.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdiv_2ui.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdiv_fr.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdiv_ui.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/texp.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tfma.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tfr_div.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tfr_sub.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tget_version.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timag.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tio_str.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tlog.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tlog10.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul_2si.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul_2ui.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul_fr.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul_i.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul_si.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul_ui.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tneg.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tnorm.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpl_gmp.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpl_mpc.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpl_mpfr.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpl_native.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow_d.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow_fr.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow_ld.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow_si.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow_ui.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow_z.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tprec.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tproj.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/treal.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/treimref.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/trootofunity.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tset.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsin.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsin_cos.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsinh.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsqr.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsqrt.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tstrtoc.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsub.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsub_fr.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsub_ui.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tswap.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ttan.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ttanh.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tui_div.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tui_ui_sub.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/check_data.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clear_parameters.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/close_datafile.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/comparisons.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/copy_parameter.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/double_rounding.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/exceptions.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/init_parameters.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpfr_flags.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/open_datafile.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/print_parameter.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/random.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/read_data.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/read_description.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/read_line.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rounding.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/setprec_parameters.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tabs.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tacos.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tacosh.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tadd.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tadd_fr.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tadd_si.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tadd_ui.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/targ.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tasin.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tasinh.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tatan.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tatanh.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tcmp_abs.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tconj.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tcos.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tcosh.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdiv.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdiv_2si.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdiv_2ui.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdiv_fr.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdiv_ui.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdot.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/texp.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tfma.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tfr_div.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tfr_sub.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tget_version.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timag.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tio_str.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tlog.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tlog10.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul_2si.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul_2ui.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul_fr.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul_i.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul_si.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tmul_ui.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tneg.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tnorm.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpl_gmp.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpl_mpc.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpl_mpfr.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpl_native.Plo@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow_d.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow_fr.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow_ld.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow_si.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow_ui.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tpow_z.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tprec.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tproj.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/treal.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/treimref.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/trootofunity.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tset.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsin.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsin_cos.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsinh.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsqr.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsqrt.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tstrtoc.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsub.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsub_fr.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsub_ui.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsum.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tswap.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ttan.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ttanh.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tui_div.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tui_ui_sub.Po@am__quote@ # am--include-marker
$(am__depfiles_remade):
@$(MKDIR_P) $(@D)
@echo '# dummy' >$@-t && $(am__mv) $@-t $@
am--depfiles: $(am__depfiles_remade)
.c.o:
@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
@ -1482,7 +1557,7 @@ $(TEST_SUITE_LOG): $(TEST_LOGS)
fi; \
$$success || exit 1
check-TESTS:
check-TESTS: $(check_PROGRAMS) $(check_LTLIBRARIES)
@list='$(RECHECK_LOGS)'; test -z "$$list" || rm -f $$list
@list='$(RECHECK_LOGS:.log=.trs)'; test -z "$$list" || rm -f $$list
@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
@ -1492,7 +1567,7 @@ check-TESTS:
log_list=`echo $$log_list`; trs_list=`echo $$trs_list`; \
$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) TEST_LOGS="$$log_list"; \
exit $$?;
recheck: all $(check_LTLIBRARIES) $(check_PROGRAMS)
recheck: all $(check_PROGRAMS) $(check_LTLIBRARIES)
@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
@set +e; $(am__set_TESTS_bases); \
bases=`for i in $$bases; do echo $$i; done \
@ -1650,6 +1725,13 @@ tdiv_ui.log: tdiv_ui$(EXEEXT)
--log-file $$b.log --trs-file $$b.trs \
$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
"$$tst" $(AM_TESTS_FD_REDIRECT)
tdot.log: tdot$(EXEEXT)
@p='tdot$(EXEEXT)'; \
b='tdot'; \
$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
--log-file $$b.log --trs-file $$b.trs \
$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
"$$tst" $(AM_TESTS_FD_REDIRECT)
texp.log: texp$(EXEEXT)
@p='texp$(EXEEXT)'; \
b='texp'; \
@ -1923,6 +2005,13 @@ tsub_ui.log: tsub_ui$(EXEEXT)
--log-file $$b.log --trs-file $$b.trs \
$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
"$$tst" $(AM_TESTS_FD_REDIRECT)
tsum.log: tsum$(EXEEXT)
@p='tsum$(EXEEXT)'; \
b='tsum'; \
$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
--log-file $$b.log --trs-file $$b.trs \
$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
"$$tst" $(AM_TESTS_FD_REDIRECT)
tswap.log: tswap$(EXEEXT)
@p='tswap$(EXEEXT)'; \
b='tswap'; \
@ -1987,7 +2076,10 @@ exceptions.log: exceptions$(EXEEXT)
@am__EXEEXT_TRUE@ $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \
@am__EXEEXT_TRUE@ "$$tst" $(AM_TESTS_FD_REDIRECT)
distdir: $(DISTFILES)
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
@ -2018,7 +2110,7 @@ distdir: $(DISTFILES)
fi; \
done
check-am: all-am
$(MAKE) $(AM_MAKEFLAGS) $(check_LTLIBRARIES) $(check_PROGRAMS)
$(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS) $(check_LTLIBRARIES)
$(MAKE) $(AM_MAKEFLAGS) check-TESTS
check: check-am
all-am: Makefile
@ -2063,7 +2155,95 @@ clean-am: clean-checkLTLIBRARIES clean-checkPROGRAMS clean-generic \
clean-libtool mostlyclean-am
distclean: distclean-am
-rm -rf ./$(DEPDIR)
-rm -f ./$(DEPDIR)/check_data.Plo
-rm -f ./$(DEPDIR)/clear_parameters.Plo
-rm -f ./$(DEPDIR)/close_datafile.Plo
-rm -f ./$(DEPDIR)/comparisons.Plo
-rm -f ./$(DEPDIR)/copy_parameter.Plo
-rm -f ./$(DEPDIR)/double_rounding.Plo
-rm -f ./$(DEPDIR)/exceptions.Po
-rm -f ./$(DEPDIR)/init_parameters.Plo
-rm -f ./$(DEPDIR)/mpfr_flags.Plo
-rm -f ./$(DEPDIR)/open_datafile.Plo
-rm -f ./$(DEPDIR)/print_parameter.Plo
-rm -f ./$(DEPDIR)/random.Plo
-rm -f ./$(DEPDIR)/read_data.Plo
-rm -f ./$(DEPDIR)/read_description.Plo
-rm -f ./$(DEPDIR)/read_line.Plo
-rm -f ./$(DEPDIR)/rounding.Plo
-rm -f ./$(DEPDIR)/setprec_parameters.Plo
-rm -f ./$(DEPDIR)/tabs.Po
-rm -f ./$(DEPDIR)/tacos.Po
-rm -f ./$(DEPDIR)/tacosh.Po
-rm -f ./$(DEPDIR)/tadd.Po
-rm -f ./$(DEPDIR)/tadd_fr.Po
-rm -f ./$(DEPDIR)/tadd_si.Po
-rm -f ./$(DEPDIR)/tadd_ui.Po
-rm -f ./$(DEPDIR)/targ.Po
-rm -f ./$(DEPDIR)/tasin.Po
-rm -f ./$(DEPDIR)/tasinh.Po
-rm -f ./$(DEPDIR)/tatan.Po
-rm -f ./$(DEPDIR)/tatanh.Po
-rm -f ./$(DEPDIR)/tcmp_abs.Po
-rm -f ./$(DEPDIR)/tconj.Po
-rm -f ./$(DEPDIR)/tcos.Po
-rm -f ./$(DEPDIR)/tcosh.Po
-rm -f ./$(DEPDIR)/tdiv.Po
-rm -f ./$(DEPDIR)/tdiv_2si.Po
-rm -f ./$(DEPDIR)/tdiv_2ui.Po
-rm -f ./$(DEPDIR)/tdiv_fr.Po
-rm -f ./$(DEPDIR)/tdiv_ui.Po
-rm -f ./$(DEPDIR)/tdot.Po
-rm -f ./$(DEPDIR)/texp.Po
-rm -f ./$(DEPDIR)/tfma.Po
-rm -f ./$(DEPDIR)/tfr_div.Po
-rm -f ./$(DEPDIR)/tfr_sub.Po
-rm -f ./$(DEPDIR)/tget_version.Po
-rm -f ./$(DEPDIR)/timag.Po
-rm -f ./$(DEPDIR)/tio_str.Po
-rm -f ./$(DEPDIR)/tlog.Po
-rm -f ./$(DEPDIR)/tlog10.Po
-rm -f ./$(DEPDIR)/tmul.Po
-rm -f ./$(DEPDIR)/tmul_2si.Po
-rm -f ./$(DEPDIR)/tmul_2ui.Po
-rm -f ./$(DEPDIR)/tmul_fr.Po
-rm -f ./$(DEPDIR)/tmul_i.Po
-rm -f ./$(DEPDIR)/tmul_si.Po
-rm -f ./$(DEPDIR)/tmul_ui.Po
-rm -f ./$(DEPDIR)/tneg.Po
-rm -f ./$(DEPDIR)/tnorm.Po
-rm -f ./$(DEPDIR)/tpl_gmp.Plo
-rm -f ./$(DEPDIR)/tpl_mpc.Plo
-rm -f ./$(DEPDIR)/tpl_mpfr.Plo
-rm -f ./$(DEPDIR)/tpl_native.Plo
-rm -f ./$(DEPDIR)/tpow.Po
-rm -f ./$(DEPDIR)/tpow_d.Po
-rm -f ./$(DEPDIR)/tpow_fr.Po
-rm -f ./$(DEPDIR)/tpow_ld.Po
-rm -f ./$(DEPDIR)/tpow_si.Po
-rm -f ./$(DEPDIR)/tpow_ui.Po
-rm -f ./$(DEPDIR)/tpow_z.Po
-rm -f ./$(DEPDIR)/tprec.Po
-rm -f ./$(DEPDIR)/tproj.Po
-rm -f ./$(DEPDIR)/treal.Po
-rm -f ./$(DEPDIR)/treimref.Po
-rm -f ./$(DEPDIR)/trootofunity.Po
-rm -f ./$(DEPDIR)/tset.Po
-rm -f ./$(DEPDIR)/tsin.Po
-rm -f ./$(DEPDIR)/tsin_cos.Po
-rm -f ./$(DEPDIR)/tsinh.Po
-rm -f ./$(DEPDIR)/tsqr.Po
-rm -f ./$(DEPDIR)/tsqrt.Po
-rm -f ./$(DEPDIR)/tstrtoc.Po
-rm -f ./$(DEPDIR)/tsub.Po
-rm -f ./$(DEPDIR)/tsub_fr.Po
-rm -f ./$(DEPDIR)/tsub_ui.Po
-rm -f ./$(DEPDIR)/tsum.Po
-rm -f ./$(DEPDIR)/tswap.Po
-rm -f ./$(DEPDIR)/ttan.Po
-rm -f ./$(DEPDIR)/ttanh.Po
-rm -f ./$(DEPDIR)/tui_div.Po
-rm -f ./$(DEPDIR)/tui_ui_sub.Po
-rm -f Makefile
distclean-am: clean-am distclean-compile distclean-generic \
distclean-tags
@ -2109,7 +2289,95 @@ install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-am
-rm -rf ./$(DEPDIR)
-rm -f ./$(DEPDIR)/check_data.Plo
-rm -f ./$(DEPDIR)/clear_parameters.Plo
-rm -f ./$(DEPDIR)/close_datafile.Plo
-rm -f ./$(DEPDIR)/comparisons.Plo
-rm -f ./$(DEPDIR)/copy_parameter.Plo
-rm -f ./$(DEPDIR)/double_rounding.Plo
-rm -f ./$(DEPDIR)/exceptions.Po
-rm -f ./$(DEPDIR)/init_parameters.Plo
-rm -f ./$(DEPDIR)/mpfr_flags.Plo
-rm -f ./$(DEPDIR)/open_datafile.Plo
-rm -f ./$(DEPDIR)/print_parameter.Plo
-rm -f ./$(DEPDIR)/random.Plo
-rm -f ./$(DEPDIR)/read_data.Plo
-rm -f ./$(DEPDIR)/read_description.Plo
-rm -f ./$(DEPDIR)/read_line.Plo
-rm -f ./$(DEPDIR)/rounding.Plo
-rm -f ./$(DEPDIR)/setprec_parameters.Plo
-rm -f ./$(DEPDIR)/tabs.Po
-rm -f ./$(DEPDIR)/tacos.Po
-rm -f ./$(DEPDIR)/tacosh.Po
-rm -f ./$(DEPDIR)/tadd.Po
-rm -f ./$(DEPDIR)/tadd_fr.Po
-rm -f ./$(DEPDIR)/tadd_si.Po
-rm -f ./$(DEPDIR)/tadd_ui.Po
-rm -f ./$(DEPDIR)/targ.Po
-rm -f ./$(DEPDIR)/tasin.Po
-rm -f ./$(DEPDIR)/tasinh.Po
-rm -f ./$(DEPDIR)/tatan.Po
-rm -f ./$(DEPDIR)/tatanh.Po
-rm -f ./$(DEPDIR)/tcmp_abs.Po
-rm -f ./$(DEPDIR)/tconj.Po
-rm -f ./$(DEPDIR)/tcos.Po
-rm -f ./$(DEPDIR)/tcosh.Po
-rm -f ./$(DEPDIR)/tdiv.Po
-rm -f ./$(DEPDIR)/tdiv_2si.Po
-rm -f ./$(DEPDIR)/tdiv_2ui.Po
-rm -f ./$(DEPDIR)/tdiv_fr.Po
-rm -f ./$(DEPDIR)/tdiv_ui.Po
-rm -f ./$(DEPDIR)/tdot.Po
-rm -f ./$(DEPDIR)/texp.Po
-rm -f ./$(DEPDIR)/tfma.Po
-rm -f ./$(DEPDIR)/tfr_div.Po
-rm -f ./$(DEPDIR)/tfr_sub.Po
-rm -f ./$(DEPDIR)/tget_version.Po
-rm -f ./$(DEPDIR)/timag.Po
-rm -f ./$(DEPDIR)/tio_str.Po
-rm -f ./$(DEPDIR)/tlog.Po
-rm -f ./$(DEPDIR)/tlog10.Po
-rm -f ./$(DEPDIR)/tmul.Po
-rm -f ./$(DEPDIR)/tmul_2si.Po
-rm -f ./$(DEPDIR)/tmul_2ui.Po
-rm -f ./$(DEPDIR)/tmul_fr.Po
-rm -f ./$(DEPDIR)/tmul_i.Po
-rm -f ./$(DEPDIR)/tmul_si.Po
-rm -f ./$(DEPDIR)/tmul_ui.Po
-rm -f ./$(DEPDIR)/tneg.Po
-rm -f ./$(DEPDIR)/tnorm.Po
-rm -f ./$(DEPDIR)/tpl_gmp.Plo
-rm -f ./$(DEPDIR)/tpl_mpc.Plo
-rm -f ./$(DEPDIR)/tpl_mpfr.Plo
-rm -f ./$(DEPDIR)/tpl_native.Plo
-rm -f ./$(DEPDIR)/tpow.Po
-rm -f ./$(DEPDIR)/tpow_d.Po
-rm -f ./$(DEPDIR)/tpow_fr.Po
-rm -f ./$(DEPDIR)/tpow_ld.Po
-rm -f ./$(DEPDIR)/tpow_si.Po
-rm -f ./$(DEPDIR)/tpow_ui.Po
-rm -f ./$(DEPDIR)/tpow_z.Po
-rm -f ./$(DEPDIR)/tprec.Po
-rm -f ./$(DEPDIR)/tproj.Po
-rm -f ./$(DEPDIR)/treal.Po
-rm -f ./$(DEPDIR)/treimref.Po
-rm -f ./$(DEPDIR)/trootofunity.Po
-rm -f ./$(DEPDIR)/tset.Po
-rm -f ./$(DEPDIR)/tsin.Po
-rm -f ./$(DEPDIR)/tsin_cos.Po
-rm -f ./$(DEPDIR)/tsinh.Po
-rm -f ./$(DEPDIR)/tsqr.Po
-rm -f ./$(DEPDIR)/tsqrt.Po
-rm -f ./$(DEPDIR)/tstrtoc.Po
-rm -f ./$(DEPDIR)/tsub.Po
-rm -f ./$(DEPDIR)/tsub_fr.Po
-rm -f ./$(DEPDIR)/tsub_ui.Po
-rm -f ./$(DEPDIR)/tsum.Po
-rm -f ./$(DEPDIR)/tswap.Po
-rm -f ./$(DEPDIR)/ttan.Po
-rm -f ./$(DEPDIR)/ttanh.Po
-rm -f ./$(DEPDIR)/tui_div.Po
-rm -f ./$(DEPDIR)/tui_ui_sub.Po
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
@ -2130,20 +2398,20 @@ uninstall-am:
.MAKE: check-am install-am install-strip
.PHONY: CTAGS GTAGS TAGS all all-am check check-TESTS check-am clean \
clean-checkLTLIBRARIES clean-checkPROGRAMS clean-generic \
clean-libtool cscopelist-am ctags ctags-am distclean \
distclean-compile distclean-generic distclean-libtool \
distclean-tags distdir dvi dvi-am html html-am info info-am \
install install-am install-data install-data-am install-dvi \
install-dvi-am install-exec install-exec-am install-html \
install-html-am install-info install-info-am install-man \
install-pdf install-pdf-am install-ps install-ps-am \
install-strip installcheck installcheck-am installdirs \
maintainer-clean maintainer-clean-generic mostlyclean \
mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
pdf pdf-am ps ps-am recheck tags tags-am uninstall \
uninstall-am
.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-TESTS \
check-am clean clean-checkLTLIBRARIES clean-checkPROGRAMS \
clean-generic clean-libtool cscopelist-am ctags ctags-am \
distclean distclean-compile distclean-generic \
distclean-libtool distclean-tags distdir dvi dvi-am html \
html-am info info-am install install-am install-data \
install-data-am install-dvi install-dvi-am install-exec \
install-exec-am install-html install-html-am install-info \
install-info-am install-man install-pdf install-pdf-am \
install-ps install-ps-am install-strip installcheck \
installcheck-am installdirs maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-compile \
mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
recheck tags tags-am uninstall uninstall-am
.PRECIOUS: Makefile

View File

@ -2437,9 +2437,6 @@
0 0 10 1 10 0 10 0 10 0b1@536870912 10 0 10 0b1@536870912 N N
0 0 10 1 10 0 10 0b1@536870912 10 0 10 0b1@536870912 10 0 N N
# overflow (reported by Emmanuel Thome)
- + 250 -inf 250 +inf 250 1 250 0 250 -1e-164895850 250 -1e-164895850 N N
# bug found by tgeneric of ui_div
+ + 2 0b1.1@256 2 0b1.1@-2758 34 52349199244 2 0 2 0b1.1@-221 2 -0b1@-3234 U N
@ -2484,3 +2481,8 @@
- - 2 0 2 0x1p-1073741823 2 0x3p-1073741824 2 0x1p-1073741823 2 1 2 -1 Z Z
# (1.5+i)*2^emin/(1+i) gives (1.25 - 0.25*i)*2^emin
- + 2 0x1p-1073741823 2 -0 2 0x3p-1073741824 2 0x1p-1073741823 2 1 2 1 Z Z
# example with exact division (0 -1) which works:
0 0 2 0 2 -1 2 -0x1p50450368 2 0x1p50450368 2 -0x1p50450368 2 -0x1p50450368 N N
# same with larger exponents, which gives (0 -Inf) in revision 389c43d:
0 0 2 0 2 -1 2 -0x1p536870910 2 0x1p536870910 2 -0x1p536870910 2 -0x1p536870910 N N

View File

@ -1,6 +1,6 @@
/* mpc-tests.h -- Tests helper functions.
Copyright (C) 2008, 2009, 2010, 2011, 2012, 2013, 2014 INRIA
Copyright (C) 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2020 INRIA
This file is part of GNU MPC.
@ -104,7 +104,7 @@ extern gmp_randstate_t rands;
extern void test_start (void);
extern void test_end (void);
extern void test_default_random (mpc_ptr, mp_exp_t, mp_exp_t,
extern void test_default_random (mpc_ptr, mpfr_exp_t, mpfr_exp_t,
unsigned int, unsigned int);
void test_random_si (long int *n, unsigned long emax,

View File

@ -85,8 +85,8 @@
0 0 53 1 53 0 53 +1 53 +0 +2 N N
0 0 53 1 53 0 53 +1 53 -0 +2 N N
# overflow
? ? 53 +inf 53 +inf 53 1e100000000 53 1e100000000 1000000000 N N
# overflow: (a+a*I)^n is real for n divisible by 4
? 0 53 +inf 53 0 53 1e100000000 53 1e100000000 1000000000 N N
# underflow
? ? 53 0 53 0 53 1e-100000000 53 1e-100000000 1000000000 N N
# cannot round after one loop

View File

@ -113,6 +113,11 @@
- - 53 0x5a827999fcef30p-54 53 -0x16a09e667f3bcdp-52 25 +0 67 -4 Z D
+ - 53 0x16a09e667f3bcdp-52 53 -0x16a09e667f3bcdp-52 23 -0 68 -4 U D
# z=(-1.95050937e+25,-2.65087379e-39)
+ - 24 0x7.2fb038p-164 24 -0x1.011258p32 24 -0x1.0225d4p64 24 -0xe.6ec760p-132 N N
# z=(-1.89432151e+24,-1.06397210e+09)
? ? 24 0x0.001954c04p0 24 -0x1.407478p40 24 -0x1.912360p80 24 -0x3.f6aed0p28 N N
# bugs fixed in r160 2008-07-15
- + 19 0b11101001001001001100p+39 19 -0b1010110101100111011p-236 19 0b1.101010001010100000p+117 19 -0b1.001110111101100001p-158 N Z
- + 2 0b11p+100 2 -0b11p+100 2 -0 2 -0b11p+203 N Z

View File

@ -28,11 +28,78 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
#include "data_check.tpl"
#include "tgeneric.tpl"
/* test with reduced exponent range */
static void
test_reduced (void)
{
mpfr_exp_t emin = mpfr_get_emin ();
mpfr_exp_t emax = mpfr_get_emax ();
mpc_t x, z, zr;
mpfr_set_emin (-148);
mpfr_set_emax (128);
mpc_init2 (x, 24);
mpc_init2 (z, 24);
mpc_init2 (zr, 24);
mpfr_set_flt (mpc_realref (x), -0x0.01f28c10p0f, MPFR_RNDN);
mpfr_set_flt (mpc_imagref (x), -0x6.79cdd0p-68f, MPFR_RNDN);
mpc_acos (z, x, MPC_RNDNN);
mpfr_set_flt (mpc_realref (zr), 0x1.941242p0f, MPFR_RNDN);
mpfr_set_flt (mpc_imagref (zr), 0x6.79da18p-68f, MPFR_RNDN);
if (mpc_cmp (z, zr))
{
printf ("Incorrect acos with reduced exponent range:\n");
mpfr_printf ("Expected (%Re,%Re)\n", mpc_realref (zr), mpc_imagref (zr));
mpfr_printf ("Got (%Re,%Re)\n", mpc_realref (z), mpc_imagref (z));
exit (1);
}
mpc_clear (x);
mpc_clear (z);
mpc_clear (zr);
mpfr_set_emin (emin);
mpfr_set_emax (emax);
}
/* another test with reduced exponent range */
static void
test_reduced2 (void)
{
mpfr_exp_t emin = mpfr_get_emin ();
mpfr_exp_t emax = mpfr_get_emax ();
mpc_t x, z, zr;
mpfr_set_emin (-1073);
mpfr_set_emax (1024);
mpc_init2 (x, 53);
mpc_init2 (z, 53);
mpc_init2 (zr, 53);
mpfr_set_d (mpc_realref (x), -2.2694475687286223e-15, MPFR_RNDN);
mpfr_set_d (mpc_imagref (x), 2.7236935900137536e-309, MPFR_RNDN);
mpc_acos (z, x, MPC_RNDNN);
mpfr_set_d (mpc_realref (zr), 1.5707963267948988, MPFR_RNDN);
mpfr_set_d (mpc_imagref (zr), -2.7236935900137536e-309, MPFR_RNDN);
if (mpc_cmp (z, zr))
{
printf ("Incorrect acos with reduced exponent range:\n");
mpfr_printf ("Expected (%Re,%Re)\n", mpc_realref (zr), mpc_imagref (zr));
mpfr_printf ("Got (%Re,%Re)\n", mpc_realref (z), mpc_imagref (z));
exit (1);
}
mpc_clear (x);
mpc_clear (z);
mpc_clear (zr);
mpfr_set_emin (emin);
mpfr_set_emax (emax);
}
int
main (void)
{
test_start ();
test_reduced ();
test_reduced2 ();
data_check_template ("acos.dsc", "acos.dat");
tgeneric_template ("acos.dsc", 2, 512, 7, 7);

View File

@ -1,6 +1,6 @@
/* tdiv -- test file for mpc_div.
Copyright (C) 2002, 2008, 2009, 2011, 2013 INRIA
Copyright (C) 2002, 2008, 2009, 2011, 2013, 2020 INRIA
This file is part of GNU MPC.
@ -31,11 +31,49 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
#include "data_check.tpl"
#include "tgeneric.tpl"
static void
bug20200206 (void)
{
mpfr_exp_t emin = mpfr_get_emin ();
mpfr_exp_t emax = mpfr_get_emax ();
mpc_t x, y, z, zr;
mpfr_set_emin (-1073);
mpfr_set_emax (0);
mpc_init2 (x, 53);
mpc_init2 (y, 53);
mpc_init2 (z, 53);
mpc_init2 (zr, 53);
mpfr_set_d (mpc_realref (x), -5.3310997889069899e-216, MPFR_RNDN);
mpfr_set_d (mpc_imagref (x), -4.9188093228194944e-89, MPFR_RNDN);
mpfr_set_d (mpc_realref (y), -3.6801500191882962e-14, MPFR_RNDN);
mpfr_set_d (mpc_imagref (y), 4.5420247980297260e-145, MPFR_RNDN);
mpc_div (z, x, y, MPC_RNDNN);
/* quotient is 1.44844440684571e-202 + 1.33657848108714e-75*I,
where both the real and imaginary parts fit in the exponent range */
mpfr_set_d (mpc_realref (zr), 0x2.d69b18295a8cep-672, MPFR_RNDN);
mpfr_set_d (mpc_imagref (zr), 0x9.ac3e51d39eea8p-252, MPFR_RNDN);
if (mpc_cmp (z, zr))
{
printf ("Incorrect division with reduced exponent range:\n");
mpfr_printf ("Expected (%Re,%Re)\n", mpc_realref (zr), mpc_imagref (zr));
mpfr_printf ("Got (%Re,%Re)\n", mpc_realref (z), mpc_imagref (z));
exit (1);
}
mpc_clear (x);
mpc_clear (y);
mpc_clear (z);
mpc_clear (zr);
mpfr_set_emin (emin);
mpfr_set_emax (emax);
}
int
main (void)
{
test_start ();
bug20200206 ();
data_check_template ("div.dsc", "div.dat");
tgeneric_template ("div.dsc", 2, 1024, 7, 4096);

98
gcc/mpc/tests/tdot.c Normal file
View File

@ -0,0 +1,98 @@
/* tdot -- test file for mpc_dot.
Copyright (C) 2018, 2020 INRIA
This file is part of GNU MPC.
GNU MPC is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
Free Software Foundation; either version 3 of the License, or (at your
option) any later version.
GNU MPC 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 Lesser General Public License for
more details.
You should have received a copy of the GNU Lesser General Public License
along with this program. If not, see http://www.gnu.org/licenses/ .
*/
#include "mpc-tests.h"
static void
check_special (void)
{
mpc_t z[3], res;
mpc_ptr t[3];
int i, inex;
/* z[0] = (1,2), z[1] = (2,3), z[2] = (3,4) */
for (i = 0; i < 3; i++)
{
mpc_init2 (z[i], 17);
mpc_set_ui_ui (z[i], i+1, i+2, MPC_RNDNN);
t[i] = z[i];
}
mpc_init2 (res, 17);
/* dot product of empty vectors is 0 */
inex = mpc_dot (res, t, t, 0, MPC_RNDNN);
MPC_ASSERT (inex == 0);
MPC_ASSERT (mpfr_zero_p (mpc_realref (res)));
MPC_ASSERT (mpfr_zero_p (mpc_imagref (res)));
MPC_ASSERT (mpfr_signbit (mpc_realref (res)) == 0);
MPC_ASSERT (mpfr_signbit (mpc_imagref (res)) == 0);
/* (1,2)*(1,2) = (-3,4) */
inex = mpc_dot (res, t, t, 1, MPC_RNDNN);
MPC_ASSERT (inex == 0);
MPC_ASSERT (mpfr_regular_p (mpc_realref (res)));
MPC_ASSERT (mpfr_regular_p (mpc_imagref (res)));
MPC_ASSERT (mpfr_cmp_si (mpc_realref (res), -3) == 0);
MPC_ASSERT (mpfr_cmp_ui (mpc_imagref (res), 4) == 0);
/* (1,2)*(1,2) + (2,3)*(2,3) = (-8,16) */
inex = mpc_dot (res, t, t, 2, MPC_RNDNN);
MPC_ASSERT (inex == 0);
MPC_ASSERT (mpfr_regular_p (mpc_realref (res)));
MPC_ASSERT (mpfr_regular_p (mpc_imagref (res)));
MPC_ASSERT (mpfr_cmp_si (mpc_realref (res), -8) == 0);
MPC_ASSERT (mpfr_cmp_ui (mpc_imagref (res), 16) == 0);
/* (1,2)*(1,2) + (2,3)*(2,3) + (3,4)*(3,4) = (-15,40) */
inex = mpc_dot (res, t, t, 3, MPC_RNDNN);
MPC_ASSERT (inex == 0);
MPC_ASSERT (mpfr_regular_p (mpc_realref (res)));
MPC_ASSERT (mpfr_regular_p (mpc_imagref (res)));
MPC_ASSERT (mpfr_cmp_si (mpc_realref (res), -15) == 0);
MPC_ASSERT (mpfr_cmp_ui (mpc_imagref (res), 40) == 0);
for (i = 0; i < 3; i++)
mpc_clear (z[i]);
mpc_clear (res);
}
/* bug reported by Trevor Spiteri */
static void
bug20200717 (void)
{
mpc_t a;
mpc_ptr p[1];
mpc_init2 (a, 53);
mpc_set_ui_ui (a, 1, 2, MPC_RNDNN);
p[0] = a;
mpc_dot (a, p, p, 1, MPC_RNDNN);
MPC_ASSERT (mpfr_cmp_si (mpc_realref (a), -3) == 0);
MPC_ASSERT (mpfr_cmp_ui (mpc_imagref (a), 4) == 0);
mpc_clear (a);
}
int
main (void)
{
test_start ();
bug20200717 ();
check_special ();
test_end ();
return 0;
}

View File

@ -1,6 +1,6 @@
/* tmul -- test file for mpc_mul.
Copyright (C) 2002, 2005, 2008, 2009, 2010, 2011, 2012, 2013 INRIA
Copyright (C) 2002, 2005, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2020 INRIA
This file is part of GNU MPC.
@ -130,6 +130,34 @@ check_regular (void)
mpc_clear (y);
}
static void
bug20200206 (void)
{
mpfr_exp_t emin = mpfr_get_emin ();
mpc_t x, y, z;
mpfr_set_emin (-1073);
mpc_init2 (x, 53);
mpc_init2 (y, 53);
mpc_init2 (z, 53);
mpfr_set_d (mpc_realref (x), -6.0344722345057644e-272, MPFR_RNDN);
mpfr_set_d (mpc_imagref (x), -4.8536770224196353e-204, MPFR_RNDN);
mpfr_set_d (mpc_realref (y), 1.3834775731431992e-246, MPFR_RNDN);
mpfr_set_d (mpc_imagref (y), 2.9246270396940562e-124, MPFR_RNDN);
mpc_mul (z, x, y, MPC_RNDNN);
if (mpfr_regular_p (mpc_realref (z)) &&
mpfr_get_exp (mpc_realref (z)) < -1073)
{
printf ("Error, mpc_mul returns an out-of-range exponent:\n");
mpfr_dump (mpc_realref (z));
printf ("Bug most probably in MPFR, please upgrade to MPFR 4.1.0 or later\n");
exit (1);
}
mpc_clear (x);
mpc_clear (y);
mpc_clear (z);
mpfr_set_emin (emin);
}
#ifdef TIMING
static void
@ -199,6 +227,7 @@ main (void)
timemul ();
#endif
bug20200206 ();
check_regular ();
data_check_template ("mul.dsc", "mul.dat");

View File

@ -52,6 +52,39 @@ reuse_bug (void)
}
}
/* at precision 53, mpc_pow gave (inf,-inf), and
at precision 73, it gave (inf,inf) */
static void
bug20200208 (void)
{
mpc_t x, y, z, zr;
mpfr_prec_t prec1 = 53, prec2 = 73;
mpc_init2 (x, prec1);
mpc_init2 (y, prec1);
mpc_init2 (z, prec1);
mpc_init2 (zr, prec2);
mpfr_set_d (mpc_realref (x), 2.0851332234623992e-197, MPFR_RNDN);
mpfr_set_d (mpc_imagref (x), -5.6221457829327427e-17, MPFR_RNDN);
mpfr_set_d (mpc_realref (y), -2.1866902464899554e+138, MPFR_RNDN);
mpfr_set_d (mpc_imagref (y), 2.5932544562430328e-234, MPFR_RNDN);
mpc_pow (z, x, y, MPC_RNDNN);
mpc_pow (zr, x, y, MPC_RNDNN);
if (mpc_cmp (z, zr))
{
printf ("Inconsistent power with different precisions:\n");
mpfr_printf ("prec %lu: (%Re,%Re)\n",
prec1, mpc_realref (z), mpc_imagref (z));
mpfr_printf ("prec %lu: (%Re,%Re)\n",
prec2, mpc_realref (zr), mpc_imagref (zr));
exit (1);
}
mpc_clear (x);
mpc_clear (y);
mpc_clear (z);
mpc_clear (zr);
}
#define MPC_FUNCTION_CALL \
P[0].mpc_inex = mpc_pow (P[1].mpc, P[2].mpc, P[3].mpc, P[4].mpc_rnd)
#define MPC_FUNCTION_CALL_REUSE_OP1 \
@ -67,6 +100,8 @@ main (void)
{
test_start ();
bug20200208 ();
reuse_bug ();
data_check_template ("pow.dsc", "pow.dat");

View File

@ -1,6 +1,6 @@
/* tsqrt -- test file for mpc_sqrt.
Copyright (C) 2008, 2013 INRIA
Copyright (C) 2008, 2013, 2020 INRIA
This file is part of GNU MPC.
@ -28,11 +28,45 @@ along with this program. If not, see http://www.gnu.org/licenses/ .
#include "data_check.tpl"
#include "tgeneric.tpl"
/* check with reduced exponent range */
static void
bug20200207 (void)
{
mpfr_exp_t emin = mpfr_get_emin ();
mpfr_exp_t emax = mpfr_get_emax ();
mpc_t x, z, zr;
mpfr_set_emin (-148);
mpfr_set_emax (128);
mpc_init2 (x, 24);
mpc_init2 (z, 24);
mpc_init2 (zr, 24);
mpfr_set_d (mpc_realref (x), -1.89432151320234e24, MPFR_RNDN);
mpfr_set_d (mpc_imagref (x), -1.06397209600000e9, MPFR_RNDN);
mpc_sqrt (z, x, MPC_RNDNN);
/* square root is 0.00038652126908433 - 1.37634353022868e12*I */
mpfr_set_d (mpc_realref (zr), 0.00038652126908433, MPFR_RNDN);
mpfr_set_d (mpc_imagref (zr), -1.37634353022868e12, MPFR_RNDN);
if (mpc_cmp (z, zr))
{
printf ("Incorrect square root with reduced exponent range:\n");
mpfr_printf ("Expected (%Re,%Re)\n", mpc_realref (zr), mpc_imagref (zr));
mpfr_printf ("Got (%Re,%Re)\n", mpc_realref (z), mpc_imagref (z));
exit (1);
}
mpc_clear (x);
mpc_clear (z);
mpc_clear (zr);
mpfr_set_emin (emin);
mpfr_set_emax (emax);
}
int
main (void)
{
test_start ();
bug20200207 ();
data_check_template ("sqrt.dsc", "sqrt.dat");
tgeneric_template ("sqrt.dsc", 2, 1024, 7, 256);

69
gcc/mpc/tests/tsum.c Normal file
View File

@ -0,0 +1,69 @@
/* tsum -- test file for mpc_sum.
Copyright (C) 2018 INRIA
This file is part of GNU MPC.
GNU MPC is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
Free Software Foundation; either version 3 of the License, or (at your
option) any later version.
GNU MPC 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 Lesser General Public License for
more details.
You should have received a copy of the GNU Lesser General Public License
along with this program. If not, see http://www.gnu.org/licenses/ .
*/
#include "mpc-tests.h"
static void
check_special (void)
{
mpc_t z[3], res;
mpc_ptr t[3];
int i, inex;
for (i = 0; i < 3; i++)
{
mpc_init2 (z[i], 17);
mpc_set_ui_ui (z[i], i+1, i+2, MPC_RNDNN);
t[i] = z[i];
}
mpc_init2 (res, 17);
inex = mpc_sum (res, t, 0, MPC_RNDNN);
MPC_ASSERT (inex == 0);
MPC_ASSERT (mpfr_cmp_ui (mpc_realref (res), 0) == 0);
MPC_ASSERT (mpfr_cmp_ui (mpc_imagref (res), 0) == 0);
inex = mpc_sum (res, t, 1, MPC_RNDNN);
MPC_ASSERT (inex == 0);
MPC_ASSERT (mpfr_cmp_ui (mpc_realref (res), 1) == 0);
MPC_ASSERT (mpfr_cmp_ui (mpc_imagref (res), 2) == 0);
inex = mpc_sum (res, t, 2, MPC_RNDNN);
MPC_ASSERT (inex == 0);
MPC_ASSERT (mpfr_cmp_ui (mpc_realref (res), 3) == 0);
MPC_ASSERT (mpfr_cmp_ui (mpc_imagref (res), 5) == 0);
inex = mpc_sum (res, t, 3, MPC_RNDNN);
MPC_ASSERT (inex == 0);
MPC_ASSERT (mpfr_cmp_ui (mpc_realref (res), 6) == 0);
MPC_ASSERT (mpfr_cmp_ui (mpc_imagref (res), 9) == 0);
for (i = 0; i < 3; i++)
mpc_clear (z[i]);
mpc_clear (res);
}
int
main (void)
{
test_start ();
check_special ();
test_end ();
return 0;
}

View File

@ -1,6 +1,6 @@
/* ttan -- test file for mpc_tan.
Copyright (C) 2008, 2011, 2012, 2013 INRIA
Copyright (C) 2008, 2011, 2012, 2013, 2020 INRIA
This file is part of GNU MPC.
@ -197,6 +197,68 @@ pure_imaginary_argument (void)
mpfr_clear (y);
}
/* test with reduced exponent range */
static void
bug20200211 (void)
{
mpfr_exp_t emin = mpfr_get_emin ();
mpc_t x, z, zr;
mpfr_set_emin (-148);
mpc_init2 (x, 24);
mpc_init2 (z, 24);
mpc_init2 (zr, 24);
mpfr_set_flt (mpc_realref (x), 0x3.b32d48p24, MPFR_RNDN);
mpfr_set_flt (mpc_imagref (x), -0x48.08bd0p0, MPFR_RNDN);
mpc_tan (z, x, MPC_RNDNN);
/* the real part should be 1.8638349976774607754968796608e-63,
but since that underflows, we should get +0 */
mpfr_set_flt (mpc_realref (zr), +0.0f, MPFR_RNDN);
mpfr_set_flt (mpc_imagref (zr), -1.0f, MPFR_RNDN);
if (mpc_cmp (z, zr))
{
printf ("Incorrect tangent with reduced exponent range:\n");
mpfr_printf ("Expected (%Re,%Re)\n", mpc_realref (zr), mpc_imagref (zr));
mpfr_printf ("Got (%Re,%Re)\n", mpc_realref (z), mpc_imagref (z));
exit (1);
}
mpc_clear (x);
mpc_clear (z);
mpc_clear (zr);
mpfr_set_emin (emin);
}
/* test failing with gcc 5.4.0, line 127 of tan.dat */
static void
bug20200301 (void)
{
mpc_t x, z, zr;
int inex;
mpc_init2 (x, 53);
mpc_init2 (z, 53);
mpc_init2 (zr, 53);
mpfr_set_d (mpc_realref (x), 0x4580CBF242683p-3, MPFR_RNDN);
mpfr_set_d (mpc_imagref (x), -0x1B3E8A3660D279p-3, MPFR_RNDN);
inex = mpc_tan (z, x, MPC_RNDNN);
mpfr_set_d (mpc_realref (zr), -0.0, MPFR_RNDN);
mpfr_set_d (mpc_imagref (zr), -1.0, MPFR_RNDN);
if (mpc_cmp (z, zr) != 0 || mpfr_signbit (mpc_realref (z)) == 0 ||
MPC_INEX_RE(inex) <= 0 || MPC_INEX_IM(inex) >= 0)
{
printf ("Incorrect tangent (bug20200301):\n");
mpfr_printf ("Expected (%Re,%Re)\n", mpc_realref (zr), mpc_imagref (zr));
mpfr_printf ("Got (%Re,%Re)\n", mpc_realref (z), mpc_imagref (z));
mpfr_printf ("expected ternary value (+1, -1)\n");
mpfr_printf ("got ternary value (%d, %d)\n", MPC_INEX_RE(inex),
MPC_INEX_IM(inex));
exit (1);
}
mpc_clear (x);
mpc_clear (z);
mpc_clear (zr);
}
#define MPC_FUNCTION_CALL \
P[0].mpc_inex = mpc_tan (P[1].mpc, P[2].mpc, P[3].mpc_rnd)
#define MPC_FUNCTION_CALL_REUSE_OP1 \
@ -210,6 +272,9 @@ main (void)
{
test_start ();
bug20200301 ();
bug20200211 ();
data_check_template ("tan.dsc", "tan.dat");
tgeneric_template ("tan.dsc", 2, 512, 7, 4);

View File

@ -1,6 +1,7 @@
## tools/Makefile.am -- Process this file with automake to produce Makefile.in
##
## Copyright (C) 2014 CNRS
## Copyright (C) 2020 INRIA
##
## This file is part of GNU MPC.
##
@ -17,5 +18,5 @@
## You should have received a copy of the GNU Lesser General Public License
## along with this program. If not, see http://www.gnu.org/licenses/ .
SUBDIRS = bench
SUBDIRS = bench mpcheck

View File

@ -1,7 +1,7 @@
# Makefile.in generated by automake 1.15.1 from Makefile.am.
# Makefile.in generated by automake 1.16.2 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2017 Free Software Foundation, Inc.
# Copyright (C) 1994-2020 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -137,7 +137,7 @@ am__recursive_targets = \
$(RECURSIVE_CLEAN_TARGETS) \
$(am__extra_recursive_targets)
AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
distdir
distdir distdir-am
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
# Read a list of newline-separated strings from the standard input,
# and print each of them once, without duplicates. Input order is
@ -309,7 +309,7 @@ target_alias = @target_alias@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
SUBDIRS = bench
SUBDIRS = bench mpcheck
all: all-recursive
.SUFFIXES:
@ -330,8 +330,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
@ -448,7 +448,10 @@ cscopelist-am: $(am__tagged_files)
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(DISTFILES)
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \

View File

@ -1,7 +1,7 @@
# Makefile.in generated by automake 1.15.1 from Makefile.am.
# Makefile.in generated by automake 1.16.2 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2017 Free Software Foundation, Inc.
# Copyright (C) 1994-2020 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -127,8 +127,9 @@ am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
am__v_at_0 = @
am__v_at_1 =
DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
am__maybe_remake_depfiles = depfiles
am__depfiles_remade = ./$(DEPDIR)/mpcbench.Po
am__mv = mv -f
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
@ -175,7 +176,8 @@ am__define_uniq_tagged_files = \
done | $(am__uniquify_input)`
ETAGS = etags
CTAGS = ctags
am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp
am__DIST_COMMON = $(srcdir)/Makefile.in \
$(top_srcdir)/build-aux/depcomp
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
@ -326,8 +328,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
@ -349,7 +351,13 @@ mostlyclean-compile:
distclean-compile:
-rm -f *.tab.c
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpcbench.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpcbench.Po@am__quote@ # am--include-marker
$(am__depfiles_remade):
@$(MKDIR_P) $(@D)
@echo '# dummy' >$@-t && $(am__mv) $@-t $@
am--depfiles: $(am__depfiles_remade)
.c.o:
@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
@ -430,7 +438,10 @@ cscopelist-am: $(am__tagged_files)
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(DISTFILES)
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
@ -499,7 +510,7 @@ clean: clean-am
clean-am: clean-generic clean-libtool mostlyclean-am
distclean: distclean-am
-rm -rf ./$(DEPDIR)
-rm -f ./$(DEPDIR)/mpcbench.Po
-rm -f Makefile
distclean-am: clean-am distclean-compile distclean-generic \
distclean-tags
@ -545,7 +556,7 @@ install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-am
-rm -rf ./$(DEPDIR)
-rm -f ./$(DEPDIR)/mpcbench.Po
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
@ -566,18 +577,19 @@ uninstall-am:
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \
clean-libtool cscopelist-am ctags ctags-am distclean \
distclean-compile distclean-generic distclean-libtool \
distclean-tags distdir dvi dvi-am html html-am info info-am \
install install-am install-data install-data-am install-dvi \
install-dvi-am install-exec install-exec-am install-html \
install-html-am install-info install-info-am install-man \
install-pdf install-pdf-am install-ps install-ps-am \
install-strip installcheck installcheck-am installdirs \
maintainer-clean maintainer-clean-generic mostlyclean \
mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am
.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \
clean-generic clean-libtool cscopelist-am ctags ctags-am \
distclean distclean-compile distclean-generic \
distclean-libtool distclean-tags distdir dvi dvi-am html \
html-am info info-am install install-am install-data \
install-data-am install-dvi install-dvi-am install-exec \
install-exec-am install-html install-html-am install-info \
install-info-am install-man install-pdf install-pdf-am \
install-ps install-ps-am install-strip installcheck \
installcheck-am installdirs maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-compile \
mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
tags tags-am uninstall uninstall-am
.PRECIOUS: Makefile

View File

@ -0,0 +1,31 @@
## tools/mpcheck/Makefile.am -- Process this file with automake to produce Makefile.in
##
## Copyright (C) 2014 CNRS
## Copyright (C) 2020 INRIA
##
## This file is part of GNU MPC.
##
## GNU MPC is free software; you can redistribute it and/or modify it under
## the terms of the GNU Lesser General Public License as published by the
## Free Software Foundation; either version 3 of the License, or (at your
## option) any later version.
##
## GNU MPC 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 Lesser General Public License for
## more details.
##
## You should have received a copy of the GNU Lesser General Public License
## along with this program. If not, see http://www.gnu.org/licenses/ .
AM_CPPFLAGS = -I$(top_srcdir)/src
AM_DEFAULT_SOURCE_EXT = .c
LDADD = $(top_builddir)/src/libmpc.la -lm
BINARIES = mpcheck-float mpcheck-double mpcheck-longdouble mpcheck-float128
EXTRA_PROGRAMS = $(BINARIES)
CLEANFILES = $(BINARIES)
mpcheck : $(BINARIES)

View File

@ -0,0 +1,639 @@
# Makefile.in generated by automake 1.16.2 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2020 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
@SET_MAKE@
VPATH = @srcdir@
am__is_gnu_make = { \
if test -z '$(MAKELEVEL)'; then \
false; \
elif test -n '$(MAKE_HOST)'; then \
true; \
elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
true; \
else \
false; \
fi; \
}
am__make_running_with_option = \
case $${target_option-} in \
?) ;; \
*) echo "am__make_running_with_option: internal error: invalid" \
"target option '$${target_option-}' specified" >&2; \
exit 1;; \
esac; \
has_opt=no; \
sane_makeflags=$$MAKEFLAGS; \
if $(am__is_gnu_make); then \
sane_makeflags=$$MFLAGS; \
else \
case $$MAKEFLAGS in \
*\\[\ \ ]*) \
bs=\\; \
sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
| sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
esac; \
fi; \
skip_next=no; \
strip_trailopt () \
{ \
flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
}; \
for flg in $$sane_makeflags; do \
test $$skip_next = yes && { skip_next=no; continue; }; \
case $$flg in \
*=*|--*) continue;; \
-*I) strip_trailopt 'I'; skip_next=yes;; \
-*I?*) strip_trailopt 'I';; \
-*O) strip_trailopt 'O'; skip_next=yes;; \
-*O?*) strip_trailopt 'O';; \
-*l) strip_trailopt 'l'; skip_next=yes;; \
-*l?*) strip_trailopt 'l';; \
-[dEDm]) skip_next=yes;; \
-[JT]) skip_next=yes;; \
esac; \
case $$flg in \
*$$target_option*) has_opt=yes; break;; \
esac; \
done; \
test $$has_opt = yes
am__make_dryrun = (target_option=n; $(am__make_running_with_option))
am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
pkgdatadir = $(datadir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkglibexecdir = $(libexecdir)/@PACKAGE@
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_HEADER = $(INSTALL_DATA)
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = @build@
host_triplet = @host@
EXTRA_PROGRAMS = $(am__EXEEXT_1)
subdir = tools/mpcheck
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_c_check_flag.m4 \
$(top_srcdir)/m4/ax_gcc_option.m4 \
$(top_srcdir)/m4/ax_gcc_version.m4 $(top_srcdir)/m4/libtool.m4 \
$(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
$(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
$(top_srcdir)/m4/mpc.m4 $(top_srcdir)/m4/valgrind-tests.m4 \
$(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
am__EXEEXT_1 = mpcheck-float$(EXEEXT) mpcheck-double$(EXEEXT) \
mpcheck-longdouble$(EXEEXT) mpcheck-float128$(EXEEXT)
mpcheck_double_SOURCES = mpcheck-double.c
mpcheck_double_OBJECTS = mpcheck-double.$(OBJEXT)
mpcheck_double_LDADD = $(LDADD)
mpcheck_double_DEPENDENCIES = $(top_builddir)/src/libmpc.la
AM_V_lt = $(am__v_lt_@AM_V@)
am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
am__v_lt_0 = --silent
am__v_lt_1 =
mpcheck_float_SOURCES = mpcheck-float.c
mpcheck_float_OBJECTS = mpcheck-float.$(OBJEXT)
mpcheck_float_LDADD = $(LDADD)
mpcheck_float_DEPENDENCIES = $(top_builddir)/src/libmpc.la
mpcheck_float128_SOURCES = mpcheck-float128.c
mpcheck_float128_OBJECTS = mpcheck-float128.$(OBJEXT)
mpcheck_float128_LDADD = $(LDADD)
mpcheck_float128_DEPENDENCIES = $(top_builddir)/src/libmpc.la
mpcheck_longdouble_SOURCES = mpcheck-longdouble.c
mpcheck_longdouble_OBJECTS = mpcheck-longdouble.$(OBJEXT)
mpcheck_longdouble_LDADD = $(LDADD)
mpcheck_longdouble_DEPENDENCIES = $(top_builddir)/src/libmpc.la
AM_V_P = $(am__v_P_@AM_V@)
am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
am__v_P_0 = false
am__v_P_1 = :
AM_V_GEN = $(am__v_GEN_@AM_V@)
am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
am__v_GEN_0 = @echo " GEN " $@;
am__v_GEN_1 =
AM_V_at = $(am__v_at_@AM_V@)
am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
am__v_at_0 = @
am__v_at_1 =
DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)
depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
am__maybe_remake_depfiles = depfiles
am__depfiles_remade = ./$(DEPDIR)/mpcheck-double.Po \
./$(DEPDIR)/mpcheck-float.Po ./$(DEPDIR)/mpcheck-float128.Po \
./$(DEPDIR)/mpcheck-longdouble.Po
am__mv = mv -f
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
$(AM_CFLAGS) $(CFLAGS)
AM_V_CC = $(am__v_CC_@AM_V@)
am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
am__v_CC_0 = @echo " CC " $@;
am__v_CC_1 =
CCLD = $(CC)
LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
$(AM_LDFLAGS) $(LDFLAGS) -o $@
AM_V_CCLD = $(am__v_CCLD_@AM_V@)
am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
am__v_CCLD_0 = @echo " CCLD " $@;
am__v_CCLD_1 =
SOURCES = mpcheck-double.c mpcheck-float.c mpcheck-float128.c \
mpcheck-longdouble.c
DIST_SOURCES = mpcheck-double.c mpcheck-float.c mpcheck-float128.c \
mpcheck-longdouble.c
am__can_run_installinfo = \
case $$AM_UPDATE_INFO_DIR in \
n|no|NO) false;; \
*) (install-info --version) >/dev/null 2>&1;; \
esac
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
# Read a list of newline-separated strings from the standard input,
# and print each of them once, without duplicates. Input order is
# *not* preserved.
am__uniquify_input = $(AWK) '\
BEGIN { nonempty = 0; } \
{ items[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in items) print i; }; } \
'
# Make sure the list of sources is unique. This is necessary because,
# e.g., the same source file might be shared among _SOURCES variables
# for different programs/libraries.
am__define_uniq_tagged_files = \
list='$(am__tagged_files)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | $(am__uniquify_input)`
ETAGS = etags
CTAGS = ctags
am__DIST_COMMON = $(srcdir)/Makefile.in \
$(top_srcdir)/build-aux/depcomp README
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
AR = @AR@
AS = @AS@
AUTOCONF = @AUTOCONF@
AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
CC = @CC@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
DLLTOOL = @DLLTOOL@
DSYMUTIL = @DSYMUTIL@
DUMPBIN = @DUMPBIN@
ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
GCC_VERSION = @GCC_VERSION@
GITVERSION = @GITVERSION@
GREP = @GREP@
HASGIT = @HASGIT@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LD = @LD@
LDFLAGS = @LDFLAGS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
LIPO = @LIPO@
LN_S = @LN_S@
LTLIBOBJS = @LTLIBOBJS@
LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
MAINT = @MAINT@
MAKEINFO = @MAKEINFO@
MANIFEST_TOOL = @MANIFEST_TOOL@
MKDIR_P = @MKDIR_P@
MPC_LDFLAGS = @MPC_LDFLAGS@
MPC_LOG_H = @MPC_LOG_H@
NM = @NM@
NMEDIT = @NMEDIT@
OBJDUMP = @OBJDUMP@
OBJEXT = @OBJEXT@
OTOOL = @OTOOL@
OTOOL64 = @OTOOL64@
PACKAGE = @PACKAGE@
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_URL = @PACKAGE_URL@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
RANLIB = @RANLIB@
SED = @SED@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
STRIP = @STRIP@
VALGRIND = @VALGRIND@
VALGRIND_OPTS = @VALGRIND_OPTS@
VERSION = @VERSION@
abs_builddir = @abs_builddir@
abs_srcdir = @abs_srcdir@
abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
ac_ct_AR = @ac_ct_AR@
ac_ct_CC = @ac_ct_CC@
ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
am__include = @am__include@
am__leading_dot = @am__leading_dot@
am__quote = @am__quote@
am__tar = @am__tar@
am__untar = @am__untar@
bindir = @bindir@
build = @build@
build_alias = @build_alias@
build_cpu = @build_cpu@
build_os = @build_os@
build_vendor = @build_vendor@
builddir = @builddir@
datadir = @datadir@
datarootdir = @datarootdir@
docdir = @docdir@
dvidir = @dvidir@
exec_prefix = @exec_prefix@
host = @host@
host_alias = @host_alias@
host_cpu = @host_cpu@
host_os = @host_os@
host_vendor = @host_vendor@
htmldir = @htmldir@
includedir = @includedir@
infodir = @infodir@
install_sh = @install_sh@
libdir = @libdir@
libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
oldincludedir = @oldincludedir@
pdfdir = @pdfdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
sysconfdir = @sysconfdir@
target_alias = @target_alias@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
AM_CPPFLAGS = -I$(top_srcdir)/src
AM_DEFAULT_SOURCE_EXT = .c
LDADD = $(top_builddir)/src/libmpc.la -lm
BINARIES = mpcheck-float mpcheck-double mpcheck-longdouble mpcheck-float128
CLEANFILES = $(BINARIES)
all: all-am
.SUFFIXES:
.SUFFIXES: .c .lo .o .obj
$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
&& { if test -f $@; then exit 0; else break; fi; }; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu tools/mpcheck/Makefile'; \
$(am__cd) $(top_srcdir) && \
$(AUTOMAKE) --gnu tools/mpcheck/Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
mpcheck-double$(EXEEXT): $(mpcheck_double_OBJECTS) $(mpcheck_double_DEPENDENCIES) $(EXTRA_mpcheck_double_DEPENDENCIES)
@rm -f mpcheck-double$(EXEEXT)
$(AM_V_CCLD)$(LINK) $(mpcheck_double_OBJECTS) $(mpcheck_double_LDADD) $(LIBS)
mpcheck-float$(EXEEXT): $(mpcheck_float_OBJECTS) $(mpcheck_float_DEPENDENCIES) $(EXTRA_mpcheck_float_DEPENDENCIES)
@rm -f mpcheck-float$(EXEEXT)
$(AM_V_CCLD)$(LINK) $(mpcheck_float_OBJECTS) $(mpcheck_float_LDADD) $(LIBS)
mpcheck-float128$(EXEEXT): $(mpcheck_float128_OBJECTS) $(mpcheck_float128_DEPENDENCIES) $(EXTRA_mpcheck_float128_DEPENDENCIES)
@rm -f mpcheck-float128$(EXEEXT)
$(AM_V_CCLD)$(LINK) $(mpcheck_float128_OBJECTS) $(mpcheck_float128_LDADD) $(LIBS)
mpcheck-longdouble$(EXEEXT): $(mpcheck_longdouble_OBJECTS) $(mpcheck_longdouble_DEPENDENCIES) $(EXTRA_mpcheck_longdouble_DEPENDENCIES)
@rm -f mpcheck-longdouble$(EXEEXT)
$(AM_V_CCLD)$(LINK) $(mpcheck_longdouble_OBJECTS) $(mpcheck_longdouble_LDADD) $(LIBS)
mostlyclean-compile:
-rm -f *.$(OBJEXT)
distclean-compile:
-rm -f *.tab.c
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpcheck-double.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpcheck-float.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpcheck-float128.Po@am__quote@ # am--include-marker
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpcheck-longdouble.Po@am__quote@ # am--include-marker
$(am__depfiles_remade):
@$(MKDIR_P) $(@D)
@echo '# dummy' >$@-t && $(am__mv) $@-t $@
am--depfiles: $(am__depfiles_remade)
.c.o:
@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $<
.c.obj:
@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
.c.lo:
@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
mostlyclean-libtool:
-rm -f *.lo
clean-libtool:
-rm -rf .libs _libs
ID: $(am__tagged_files)
$(am__define_uniq_tagged_files); mkid -fID $$unique
tags: tags-am
TAGS: tags
tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
set x; \
here=`pwd`; \
$(am__define_uniq_tagged_files); \
shift; \
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
if test $$# -gt 0; then \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
"$$@" $$unique; \
else \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$$unique; \
fi; \
fi
ctags: ctags-am
CTAGS: ctags
ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
$(am__define_uniq_tagged_files); \
test -z "$(CTAGS_ARGS)$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$unique
GTAGS:
here=`$(am__cd) $(top_builddir) && pwd` \
&& $(am__cd) $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) "$$here"
cscopelist: cscopelist-am
cscopelist-am: $(am__tagged_files)
list='$(am__tagged_files)'; \
case "$(srcdir)" in \
[\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
*) sdir=$(subdir)/$(srcdir) ;; \
esac; \
for i in $$list; do \
if test -f "$$i"; then \
echo "$(subdir)/$$i"; \
else \
echo "$$sdir/$$i"; \
fi; \
done >> $(top_builddir)/cscope.files
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d "$(distdir)/$$file"; then \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
|| exit 1; \
fi; \
done
check-am: all-am
check: check-am
all-am: Makefile
installdirs:
install: install-am
install-exec: install-exec-am
install-data: install-data-am
uninstall: uninstall-am
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
installcheck: installcheck-am
install-strip:
if test -z '$(STRIP)'; then \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
install; \
else \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
fi
mostlyclean-generic:
clean-generic:
-test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
distclean-generic:
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
clean: clean-am
clean-am: clean-generic clean-libtool mostlyclean-am
distclean: distclean-am
-rm -f ./$(DEPDIR)/mpcheck-double.Po
-rm -f ./$(DEPDIR)/mpcheck-float.Po
-rm -f ./$(DEPDIR)/mpcheck-float128.Po
-rm -f ./$(DEPDIR)/mpcheck-longdouble.Po
-rm -f Makefile
distclean-am: clean-am distclean-compile distclean-generic \
distclean-tags
dvi: dvi-am
dvi-am:
html: html-am
html-am:
info: info-am
info-am:
install-data-am:
install-dvi: install-dvi-am
install-dvi-am:
install-exec-am:
install-html: install-html-am
install-html-am:
install-info: install-info-am
install-info-am:
install-man:
install-pdf: install-pdf-am
install-pdf-am:
install-ps: install-ps-am
install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-am
-rm -f ./$(DEPDIR)/mpcheck-double.Po
-rm -f ./$(DEPDIR)/mpcheck-float.Po
-rm -f ./$(DEPDIR)/mpcheck-float128.Po
-rm -f ./$(DEPDIR)/mpcheck-longdouble.Po
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-am
mostlyclean-am: mostlyclean-compile mostlyclean-generic \
mostlyclean-libtool
pdf: pdf-am
pdf-am:
ps: ps-am
ps-am:
uninstall-am:
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \
clean-generic clean-libtool cscopelist-am ctags ctags-am \
distclean distclean-compile distclean-generic \
distclean-libtool distclean-tags distdir dvi dvi-am html \
html-am info info-am install install-am install-data \
install-data-am install-dvi install-dvi-am install-exec \
install-exec-am install-html install-html-am install-info \
install-info-am install-man install-pdf install-pdf-am \
install-ps install-ps-am install-strip installcheck \
installcheck-am installdirs maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-compile \
mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
tags tags-am uninstall uninstall-am
.PRECIOUS: Makefile
mpcheck : $(BINARIES)
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:

View File

@ -0,0 +1,4 @@
The mpcheck tool provides tests to check the MPC library against the
C library. It is meant as a tool for MPC developers, or for people who
want to assert the accuracy of the C library.

View File

@ -0,0 +1,244 @@
/* mpcheck-double -- compare mpc functions against "double complex"
from the GNU libc implementation
Copyright (C) 2020 INRIA
This file is part of GNU MPC.
GNU MPC is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
Free Software Foundation; either version 3 of the License, or (at your
option) any later version.
GNU MPC 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 Lesser General Public License for
more details.
You should have received a copy of the GNU Lesser General Public License
along with this program. If not, see http://www.gnu.org/licenses/ .
*/
/* the GNU libc provides the following functions (as of 2.31),
with 'f' suffix for the float/binary32 version, with no suffix
for the double/binary64 version, with 'l' suffix for the long double
version, and with 'f128' suffix for the __float128 version:
cabs casinh cexp csinh
cacos catan clog csqrt
cacosh catanh clog10 ctan
carg ccos cpow ctanh
casin ccosh csin
*/
#define _GNU_SOURCE /* for clog10 */
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <complex.h>
#include <sys/types.h>
#include <unistd.h>
#include <assert.h>
#ifdef __GNUC__
#include <gnu/libc-version.h>
#endif
#include "mpc.h"
#define PRECISION 53
#define EMAX 1024
#define TYPE double
#define SUFFIX
#define mpc_get_type mpc_get_dc
#define mpc_set_type mpc_set_dc
#define mpfr_set_type mpfr_set_d
gmp_randstate_t state;
mpz_t expz; /* global variable used in mpcheck_random */
unsigned long seed = 0;
int verbose = 0;
mpfr_exp_t emin, emax;
#include "mpcheck-common.c"
#define FOO add
#define CFOO(x,y) (x+y)
#include "mpcheck-template3.c"
#define FOO sub
#define CFOO(x,y) (x-y)
#include "mpcheck-template3.c"
#define FOO mul
#define CFOO(x,y) (x*y)
#include "mpcheck-template3.c"
#define FOO div
#define CFOO(x,y) (x/y)
#include "mpcheck-template3.c"
#define FOO pow
#include "mpcheck-template3.c"
#define FOO abs
#include "mpcheck-template2.c"
#define FOO arg
#include "mpcheck-template2.c"
#define FOO sqrt
#include "mpcheck-template1.c"
#define FOO acos
#include "mpcheck-template1.c"
#define FOO acosh
#include "mpcheck-template1.c"
#define FOO asin
#include "mpcheck-template1.c"
#define FOO asinh
#include "mpcheck-template1.c"
#define FOO atan
#include "mpcheck-template1.c"
#define FOO atanh
#include "mpcheck-template1.c"
#define FOO cos
#include "mpcheck-template1.c"
#define FOO cosh
#include "mpcheck-template1.c"
#define FOO exp
#include "mpcheck-template1.c"
#define FOO log
#include "mpcheck-template1.c"
#define FOO log10
#include "mpcheck-template1.c"
#define FOO sin
#include "mpcheck-template1.c"
#define FOO sinh
#include "mpcheck-template1.c"
/* use reduced exponent range for tan and tanh */
#define FOO_EMIN -8
#define FOO_EMAX 8
#define FOO tan
#include "mpcheck-template1.c"
#define FOO tanh
#include "mpcheck-template1.c"
#undef FOO_EMIN
#undef FOO_EMAX
int
main (int argc, char *argv[])
{
mpfr_prec_t p = PRECISION; /* precision of 'double' */
unsigned long n = 1000000; /* default number of random tests per function */
while (argc >= 2 && argv[1][0] == '-')
{
if (argc >= 3 && strcmp (argv[1], "-p") == 0)
{
p = atoi (argv[2]);
argc -= 2;
argv += 2;
}
else if (argc >= 3 && strcmp (argv[1], "-seed") == 0)
{
seed = atoi (argv[2]);
argc -= 2;
argv += 2;
}
else if (argc >= 3 && strcmp (argv[1], "-num") == 0)
{
n = atoi (argv[2]);
argc -= 2;
argv += 2;
}
else if (strcmp (argv[1], "-v") == 0)
{
verbose ++;
argc --;
argv ++;
}
else if (strcmp (argv[1], "-check") == 0)
{
recheck = 1;
argc --;
argv ++;
}
else
{
fprintf (stderr, "Unknown option %s\n", argv[1]);
exit (1);
}
}
/* set exponent range */
emin = -EMAX - PRECISION + 4; /* should be -1073 */
emax = EMAX;
mpfr_set_emin (emin);
mpfr_set_emax (emax);
gmp_randinit_default (state);
mpz_init (expz);
printf ("Using GMP %s, MPFR %s\n", gmp_version, mpfr_get_version ());
#ifdef __GNUC__
printf ("GNU libc version: %s\n", gnu_get_libc_version ());
printf ("GNU libc release: %s\n", gnu_get_libc_release ());
#endif
if (seed == 0)
seed = getpid ();
printf ("Using random seed %lu\n", seed);
/* (complex,complex) -> complex */
test_add (p, n);
test_sub (p, n);
test_mul (p, n);
test_div (p, n);
test_pow (p, n);
/* complex -> real */
test_abs (p, n);
test_arg (p, n);
/* complex -> complex */
test_sqrt (p, n);
test_acos (p, n);
test_acosh (p, n);
test_asin (p, n);
test_asinh (p, n);
test_atan (p, n);
test_atanh (p, n);
test_cos (p, n);
test_cosh (p, n);
test_exp (p, n);
test_log (p, n);
test_log10 (p, n);
test_sin (p, n);
test_sinh (p, n);
test_tan (p, n);
test_tanh (p, n);
gmp_randclear (state);
mpz_clear (expz);
report_maximal_errors ();
return 0;
}

View File

@ -0,0 +1,249 @@
/* mpcheck-float -- compare mpc functions against "float complex"
from the GNU libc implementation
Copyright (C) 2020 INRIA
This file is part of GNU MPC.
GNU MPC is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
Free Software Foundation; either version 3 of the License, or (at your
option) any later version.
GNU MPC 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 Lesser General Public License for
more details.
You should have received a copy of the GNU Lesser General Public License
along with this program. If not, see http://www.gnu.org/licenses/ .
*/
/* the GNU libc provides the following functions (as of 2.31),
with 'f' suffix for the float/binary32 version, with no suffix
for the double/binary64 version, with 'l' suffix for the long double
version, and with 'f128' suffix for the __float128 version:
cabs casinh cexp csinh
cacos catan clog csqrt
cacosh catanh clog10 ctan
carg ccos cpow ctanh
casin ccosh csin
*/
#define _GNU_SOURCE /* for clog10 */
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <complex.h>
#include <sys/types.h>
#include <unistd.h>
#include <assert.h>
#include "mpc.h"
#ifdef __GNUC__
#include <gnu/libc-version.h>
#endif
#define PRECISION 24
#define EMAX 128
#define TYPE float
#define SUFFIX f
#define mpfr_set_type mpfr_set_flt
static TYPE complex
mpc_get_type (mpc_t x, mpc_rnd_t rnd)
{
/* there is no mpc_get_fltc function */
return (TYPE complex) mpc_get_dc (x, rnd);
}
static int
mpc_set_type (mpc_t x, TYPE complex y, mpc_rnd_t rnd)
{
/* there is no mpc_set_fltc function */
return mpc_set_dc (x, (double complex) y, rnd);
}
gmp_randstate_t state;
mpz_t expz; /* global variable used in mpcheck_random */
unsigned long seed = 0;
int verbose = 0;
mpfr_exp_t emin, emax;
#include "mpcheck-common.c"
#define FOO add
#define CFOO(x,y) (x+y)
#include "mpcheck-template3.c"
#define FOO sub
#define CFOO(x,y) (x-y)
#include "mpcheck-template3.c"
#define FOO mul
#define CFOO(x,y) (x*y)
#include "mpcheck-template3.c"
#define FOO div
#define CFOO(x,y) (x/y)
#include "mpcheck-template3.c"
#define FOO pow
#include "mpcheck-template3.c"
#define FOO abs
#include "mpcheck-template2.c"
#define FOO arg
#include "mpcheck-template2.c"
#define FOO sqrt
#include "mpcheck-template1.c"
#define FOO acos
#include "mpcheck-template1.c"
#define FOO acosh
#include "mpcheck-template1.c"
#define FOO asin
#include "mpcheck-template1.c"
#define FOO asinh
#include "mpcheck-template1.c"
#define FOO atan
#include "mpcheck-template1.c"
#define FOO atanh
#include "mpcheck-template1.c"
#define FOO cos
#include "mpcheck-template1.c"
#define FOO cosh
#include "mpcheck-template1.c"
#define FOO exp
#include "mpcheck-template1.c"
#define FOO log
#include "mpcheck-template1.c"
#define FOO log10
#include "mpcheck-template1.c"
#define FOO sin
#include "mpcheck-template1.c"
#define FOO sinh
#include "mpcheck-template1.c"
#define FOO tan
#include "mpcheck-template1.c"
#define FOO tanh
#include "mpcheck-template1.c"
int
main (int argc, char *argv[])
{
mpfr_prec_t p = PRECISION; /* precision of 'float' */
unsigned long n = 1000000; /* default number of random tests per function */
while (argc >= 2 && argv[1][0] == '-')
{
if (argc >= 3 && strcmp (argv[1], "-p") == 0)
{
p = atoi (argv[2]);
argc -= 2;
argv += 2;
}
else if (argc >= 3 && strcmp (argv[1], "-seed") == 0)
{
seed = atoi (argv[2]);
argc -= 2;
argv += 2;
}
else if (argc >= 3 && strcmp (argv[1], "-num") == 0)
{
n = atoi (argv[2]);
argc -= 2;
argv += 2;
}
else if (strcmp (argv[1], "-v") == 0)
{
verbose ++;
argc --;
argv ++;
}
else if (strcmp (argv[1], "-check") == 0)
{
recheck = 1;
argc --;
argv ++;
}
else
{
fprintf (stderr, "Unknown option %s\n", argv[1]);
exit (1);
}
}
/* set exponent range */
emin = -EMAX - PRECISION + 4; /* should be -148 */
emax = EMAX;
mpfr_set_emin (emin);
mpfr_set_emax (emax);
gmp_randinit_default (state);
mpz_init (expz);
printf ("Using GMP %s, MPFR %s\n", gmp_version, mpfr_get_version ());
#ifdef __GNUC__
printf ("GNU libc version: %s\n", gnu_get_libc_version ());
printf ("GNU libc release: %s\n", gnu_get_libc_release ());
#endif
if (seed == 0)
seed = getpid ();
printf ("Using random seed %lu\n", seed);
/* (complex,complex) -> complex */
test_add (p, n);
test_sub (p, n);
test_mul (p, n);
test_div (p, n);
test_pow (p, n);
/* complex -> real */
test_abs (p, n);
test_arg (p, n);
/* complex -> complex */
test_sqrt (p, n);
test_acos (p, n);
test_acosh (p, n);
test_asin (p, n);
test_asinh (p, n);
test_atan (p, n);
test_atanh (p, n);
test_cos (p, n);
test_cosh (p, n);
test_exp (p, n);
test_log (p, n);
test_log10 (p, n);
test_sin (p, n);
test_sinh (p, n);
test_tan (p, n);
test_tanh (p, n);
gmp_randclear (state);
mpz_clear (expz);
report_maximal_errors ();
return 0;
}

View File

@ -0,0 +1,254 @@
/* mpcheck-float128 -- compare mpc functions against "__float128 complex"
from the GNU libc implementation
Copyright (C) 2020 INRIA
This file is part of GNU MPC.
GNU MPC is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
Free Software Foundation; either version 3 of the License, or (at your
option) any later version.
GNU MPC 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 Lesser General Public License for
more details.
You should have received a copy of the GNU Lesser General Public License
along with this program. If not, see http://www.gnu.org/licenses/ .
*/
/* the GNU libc provides the following functions (as of 2.31),
with 'f' suffix for the float/binary32 version, with no suffix
for the double/binary64 version, with 'l' suffix for the long double
version, and with 'f128' suffix for the __float128 version:
cabs casinh cexp csinh
cacos catan clog csqrt
cacosh catanh clog10 ctan
carg ccos cpow ctanh
casin ccosh csin
*/
#define _GNU_SOURCE /* for clog10 */
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <complex.h>
#include <sys/types.h>
#include <unistd.h>
#include <assert.h>
#define MPFR_WANT_FLOAT128
#include "mpc.h"
#ifdef __GNUC__
#include <gnu/libc-version.h>
#endif
#define PRECISION 113
#define EMAX 16384
#define TYPE _Float128
#define SUFFIX f128
#define mpfr_set_type mpfr_set_float128
static TYPE complex
mpc_get_type (mpc_t z, mpc_rnd_t rnd)
{
TYPE x, y;
/* there is no mpc_get_float128c function */
x = mpfr_get_float128 (mpc_realref (z), MPC_RND_RE(rnd));
y = mpfr_get_float128 (mpc_imagref (z), MPC_RND_IM(rnd));
return x + I * y;
}
static int
mpc_set_type (mpc_t x, TYPE complex y, mpc_rnd_t rnd)
{
/* there is no mpc_set_float128c function */
mpfr_set_float128 (mpc_realref (x), crealf128 (y), MPC_RND_RE(rnd));
mpfr_set_float128 (mpc_imagref (x), cimagf128 (y), MPC_RND_IM(rnd));
}
gmp_randstate_t state;
mpz_t expz; /* global variable used in mpcheck_random */
unsigned long seed = 0;
int verbose = 0;
mpfr_exp_t emin, emax;
#include "mpcheck-common.c"
#define FOO add
#define CFOO(x,y) (x+y)
#include "mpcheck-template3.c"
#define FOO sub
#define CFOO(x,y) (x-y)
#include "mpcheck-template3.c"
#define FOO mul
#define CFOO(x,y) (x*y)
#include "mpcheck-template3.c"
#define FOO div
#define CFOO(x,y) (x/y)
#include "mpcheck-template3.c"
#define FOO pow
#include "mpcheck-template3.c"
#define FOO abs
#include "mpcheck-template2.c"
#define FOO arg
#include "mpcheck-template2.c"
#define FOO sqrt
#include "mpcheck-template1.c"
#define FOO acos
#include "mpcheck-template1.c"
#define FOO acosh
#include "mpcheck-template1.c"
#define FOO asin
#include "mpcheck-template1.c"
#define FOO asinh
#include "mpcheck-template1.c"
#define FOO atan
#include "mpcheck-template1.c"
#define FOO atanh
#include "mpcheck-template1.c"
#define FOO cos
#include "mpcheck-template1.c"
#define FOO cosh
#include "mpcheck-template1.c"
#define FOO exp
#include "mpcheck-template1.c"
#define FOO log
#include "mpcheck-template1.c"
#define FOO log10
#include "mpcheck-template1.c"
#define FOO sin
#include "mpcheck-template1.c"
#define FOO sinh
#include "mpcheck-template1.c"
#define FOO tan
#include "mpcheck-template1.c"
#define FOO tanh
#include "mpcheck-template1.c"
int
main (int argc, char *argv[])
{
mpfr_prec_t p = PRECISION; /* precision of 'double' */
unsigned long n = 1000000; /* default number of random tests per function */
while (argc >= 2 && argv[1][0] == '-')
{
if (argc >= 3 && strcmp (argv[1], "-p") == 0)
{
p = atoi (argv[2]);
argc -= 2;
argv += 2;
}
else if (argc >= 3 && strcmp (argv[1], "-seed") == 0)
{
seed = atoi (argv[2]);
argc -= 2;
argv += 2;
}
else if (argc >= 3 && strcmp (argv[1], "-num") == 0)
{
n = atoi (argv[2]);
argc -= 2;
argv += 2;
}
else if (strcmp (argv[1], "-v") == 0)
{
verbose ++;
argc --;
argv ++;
}
else if (strcmp (argv[1], "-check") == 0)
{
recheck = 1;
argc --;
argv ++;
}
else
{
fprintf (stderr, "Unknown option %s\n", argv[1]);
exit (1);
}
}
/* set exponent range */
emin = -EMAX - 64 + 4; /* should be -16444 like for long double */
emax = EMAX;
mpfr_set_emin (emin);
mpfr_set_emax (emax);
gmp_randinit_default (state);
mpz_init (expz);
printf ("Using GMP %s, MPFR %s\n", gmp_version, mpfr_get_version ());
#ifdef __GNUC__
printf ("GNU libc version: %s\n", gnu_get_libc_version ());
printf ("GNU libc release: %s\n", gnu_get_libc_release ());
#endif
if (seed == 0)
seed = getpid ();
printf ("Using random seed %lu\n", seed);
/* (complex,complex) -> complex */
test_add (p, n);
test_sub (p, n);
test_mul (p, n);
test_div (p, n);
test_pow (p, n);
/* complex -> real */
test_abs (p, n);
test_arg (p, n);
/* complex -> complex */
test_sqrt (p, n);
test_acos (p, n);
test_acosh (p, n);
test_asin (p, n);
test_asinh (p, n);
test_atan (p, n);
test_atanh (p, n);
test_cos (p, n);
test_cosh (p, n);
test_exp (p, n);
test_log (p, n);
test_log10 (p, n);
test_sin (p, n);
test_sinh (p, n);
test_tan (p, n);
test_tanh (p, n);
gmp_randclear (state);
mpz_clear (expz);
report_maximal_errors ();
return 0;
}

View File

@ -0,0 +1,237 @@
/* mpcheck-longdouble -- compare mpc functions against "long double complex"
from the GNU libc implementation
Copyright (C) 2020 INRIA
This file is part of GNU MPC.
GNU MPC is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
Free Software Foundation; either version 3 of the License, or (at your
option) any later version.
GNU MPC 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 Lesser General Public License for
more details.
You should have received a copy of the GNU Lesser General Public License
along with this program. If not, see http://www.gnu.org/licenses/ .
*/
/* the GNU libc provides the following functions (as of 2.31),
with 'f' suffix for the float/binary32 version, with no suffix
for the double/binary64 version, with 'l' suffix for the long double
version, and with 'f128' suffix for the __float128 version:
cabs casinh cexp csinh
cacos catan clog csqrt
cacosh catanh clog10 ctan
carg ccos cpow ctanh
casin ccosh csin
*/
#define _GNU_SOURCE /* for clog10 */
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <complex.h>
#include <sys/types.h>
#include <unistd.h>
#include <assert.h>
#include "mpc.h"
#ifdef __GNUC__
#include <gnu/libc-version.h>
#endif
#define PRECISION 64
#define EMAX 16384
#define TYPE long double
#define SUFFIX l
#define mpc_get_type mpc_get_ldc
#define mpc_set_type mpc_set_ldc
#define mpfr_set_type mpfr_set_ld
gmp_randstate_t state;
mpz_t expz; /* global variable used in mpcheck_random */
unsigned long seed = 0;
int verbose = 0;
mpfr_exp_t emin, emax;
#include "mpcheck-common.c"
#define FOO add
#define CFOO(x,y) (x+y)
#include "mpcheck-template3.c"
#define FOO sub
#define CFOO(x,y) (x-y)
#include "mpcheck-template3.c"
#define FOO mul
#define CFOO(x,y) (x*y)
#include "mpcheck-template3.c"
#define FOO div
#define CFOO(x,y) (x/y)
#include "mpcheck-template3.c"
#define FOO pow
#include "mpcheck-template3.c"
#define FOO abs
#include "mpcheck-template2.c"
#define FOO arg
#include "mpcheck-template2.c"
#define FOO sqrt
#include "mpcheck-template1.c"
#define FOO acos
#include "mpcheck-template1.c"
#define FOO acosh
#include "mpcheck-template1.c"
#define FOO asin
#include "mpcheck-template1.c"
#define FOO asinh
#include "mpcheck-template1.c"
#define FOO atan
#include "mpcheck-template1.c"
#define FOO atanh
#include "mpcheck-template1.c"
#define FOO cos
#include "mpcheck-template1.c"
#define FOO cosh
#include "mpcheck-template1.c"
#define FOO exp
#include "mpcheck-template1.c"
#define FOO log
#include "mpcheck-template1.c"
#define FOO log10
#include "mpcheck-template1.c"
#define FOO sin
#include "mpcheck-template1.c"
#define FOO sinh
#include "mpcheck-template1.c"
#define FOO tan
#include "mpcheck-template1.c"
#define FOO tanh
#include "mpcheck-template1.c"
int
main (int argc, char *argv[])
{
mpfr_prec_t p = PRECISION; /* precision of 'double' */
unsigned long n = 1000000; /* default number of random tests per function */
while (argc >= 2 && argv[1][0] == '-')
{
if (argc >= 3 && strcmp (argv[1], "-p") == 0)
{
p = atoi (argv[2]);
argc -= 2;
argv += 2;
}
else if (argc >= 3 && strcmp (argv[1], "-seed") == 0)
{
seed = atoi (argv[2]);
argc -= 2;
argv += 2;
}
else if (argc >= 3 && strcmp (argv[1], "-num") == 0)
{
n = atoi (argv[2]);
argc -= 2;
argv += 2;
}
else if (strcmp (argv[1], "-v") == 0)
{
verbose ++;
argc --;
argv ++;
}
else if (strcmp (argv[1], "-check") == 0)
{
recheck = 1;
argc --;
argv ++;
}
else
{
fprintf (stderr, "Unknown option %s\n", argv[1]);
exit (1);
}
}
/* set exponent range */
emin = -EMAX - PRECISION + 4; /* should be -16444 */
emax = EMAX;
mpfr_set_emin (emin);
mpfr_set_emax (emax);
gmp_randinit_default (state);
mpz_init (expz);
printf ("Using GMP %s, MPFR %s\n", gmp_version, mpfr_get_version ());
#ifdef __GNUC__
printf ("GNU libc version: %s\n", gnu_get_libc_version ());
printf ("GNU libc release: %s\n", gnu_get_libc_release ());
#endif
if (seed == 0)
seed = getpid ();
printf ("Using random seed %lu\n", seed);
/* (complex,complex) -> complex */
test_add (p, n);
test_sub (p, n);
test_mul (p, n);
test_div (p, n);
test_pow (p, n);
/* complex -> real */
test_abs (p, n);
test_arg (p, n);
/* complex -> complex */
test_sqrt (p, n);
test_acos (p, n);
test_acosh (p, n);
test_asin (p, n);
test_asinh (p, n);
test_atan (p, n);
test_atanh (p, n);
test_cos (p, n);
test_cosh (p, n);
test_exp (p, n);
test_log (p, n);
test_log10 (p, n);
test_sin (p, n);
test_sinh (p, n);
test_tan (p, n);
test_tanh (p, n);
gmp_randclear (state);
mpz_clear (expz);
report_maximal_errors ();
return 0;
}