]> www.ginac.de Git - cln.git/log
cln.git
5 years agoDistribute INSTALL.generic.
Bruno Haible [Sat, 26 Oct 2019 14:53:38 +0000 (16:53 +0200)]
Distribute INSTALL.generic.

5 years agoRevamp and simplify autoconfiguration.
Bruno Haible [Sat, 26 Oct 2019 14:52:28 +0000 (16:52 +0200)]
Revamp and simplify autoconfiguration.

- New file autogen.sh.
- Put build scripts in build-aux/ not autoconf/.
- Install lib-*.m4 and config.rpath through gnulib module 'havelib'.
- Install 'test-driver' through automake.

5 years agoAdded e2k arch support.
Michael Shigorin [Mon, 2 Sep 2019 08:08:55 +0000 (11:08 +0300)]
Added e2k arch support.

About the CPU: https://en.wikipedia.org/wiki/Elbrus_2000
About the Linux port: https://www.altlinux.org/Ports/e2k

5 years agoFix warnings from gcc's -Wshift-overflow.
Bruno Haible [Mon, 7 Jan 2019 06:52:12 +0000 (07:52 +0100)]
Fix warnings from gcc's -Wshift-overflow.

Reported by David van der Spoel <spoel@xray.bmc.uu.se>.

* src/base/cl_macros.h (bit, bitm, minus_bit, minus_bitm): Shift an unsigned
value, not a signed value.

6 years agoAdd support for riscv64 platform.
Manuel A. Fernandez Montecelo [Thu, 3 May 2018 21:28:36 +0000 (23:28 +0200)]
Add support for riscv64 platform.

6 years agoUpdate to recently found large Mersenne prime.
Richard Kreckel [Sun, 18 Mar 2018 11:12:26 +0000 (12:12 +0100)]
Update to recently found large Mersenne prime.

6 years agoSupport MIPS release 6.
YunQiang Su [Sun, 18 Mar 2018 11:05:51 +0000 (12:05 +0100)]
Support MIPS release 6.

MIPS release 6 is not full compatible with the previous releases, it removes
some instructions and changes encoding of some instruction.
the `multu' is included.

MIPS r6 drops `lo' and `hi' registers, and then removes `multu'/`mfhi'/`mflo'.
Instead it uses `mulu' to compute the low part and `muhu' to compute
the high part.

7 years agoUpdate known-to-work-with compilers.
Richard Kreckel [Thu, 4 May 2017 22:17:07 +0000 (00:17 +0200)]
Update known-to-work-with compilers.

And while at it, remove some workarounds for ancient compilers.

8 years agoUpdate to recently found large Mersenne prime.
Richard Kreckel [Thu, 11 Feb 2016 22:23:57 +0000 (23:23 +0100)]
Update to recently found large Mersenne prime.

10 years agoFinalize CLN 1.3.4 release. cln_1-3-4
Richard Kreckel [Thu, 16 Oct 2014 06:12:32 +0000 (06:12 +0000)]
Finalize CLN 1.3.4 release.

10 years agoRemove workarounds for obsolete compilers.
Richard Kreckel [Mon, 13 Oct 2014 19:42:11 +0000 (19:42 +0000)]
Remove workarounds for obsolete compilers.

10 years agoFix support for Mips*.
Richard Kreckel [Sat, 11 Oct 2014 22:40:03 +0000 (22:40 +0000)]
Fix support for Mips*.

Patch by YunQiang Su <wzssyqa@gmail.com> (cf. Debian bug#748325).

10 years agoJanitorial clean-up.
Richard Kreckel [Sat, 11 Oct 2014 22:24:25 +0000 (22:24 +0000)]
Janitorial clean-up.

Remove some unused variables and convert files with CRNL line endings
to files with NL line endings.

10 years agoMake float_format(uintE) more precise.
Richard Kreckel [Sat, 11 Oct 2014 22:15:37 +0000 (22:15 +0000)]
Make float_format(uintE) more precise.

Due to a typo in the binary representation lfo ln(10)/ln(2), this
function could preduce slightly wrong sizes for really huge arguments.

10 years agoFix floating-point input from decimal string.
Richard Kreckel [Sat, 11 Oct 2014 22:03:21 +0000 (22:03 +0000)]
Fix floating-point input from decimal string.

A bug was introduced in 3480230e: The divide-and-conquer method multiplies
with a power of the base, but this power is one too much if there is a
decimal point. This may happen because digits_to_I(...) is also called
from read_float(...). As a result, the number containd spurious zeros
(in the base used for reading it).

Thanks to Thomas Luthe <tluthe@physik.uni-bielefeld.de>.

10 years agoUse 8-byte word alignment on arm64.
Richard Kreckel [Fri, 19 Sep 2014 20:40:20 +0000 (20:40 +0000)]
Use 8-byte word alignment on arm64.

The previous patch cb76b5eb used 4-byte word alignment.
Thanks to Peter Green and Hector Oron for pointing out that
8-byte alignment should be used (cf. Debian bug #757623).

10 years agoFix support for Mips64.
Richard Kreckel [Thu, 22 May 2014 07:52:56 +0000 (07:52 +0000)]
Fix support for Mips64.

Yunquiang Su <wzssyqa@gmail.com> proposed to use 64 bit [su]intD and
long [su]intC on mips64 and mips64el.

While at it, cleaned up the AArch64 definitions from cb76b5eb.

10 years agoAdd AArch64 support.
Marcin Juszkiewicz [Wed, 23 Apr 2014 20:00:38 +0000 (20:00 +0000)]
Add AArch64 support.

While building Fedora 21 for AArch64 we found out that your software is
not building for us. Attached is a fix which adds this architecture in
all required places.

10 years agoRevert "Convert complex numbers to real numbers if imaginary part is floating-point...
Richard Kreckel [Thu, 16 Jan 2014 22:00:42 +0000 (22:00 +0000)]
Revert "Convert complex numbers to real numbers if imaginary part is floating-point 0.0."

This reverts commit 536a0ac50f6c90198982267943af4d551612a9d9.

Cf. <http://www.ginac.de/pipermail/ginac-devel/2014-January/002086.html/>.

10 years agoConvert complex numbers to real numbers if imaginary part is floating-point 0.0.
Richard Kreckel [Mon, 13 Jan 2014 21:49:04 +0000 (21:49 +0000)]
Convert complex numbers to real numbers if imaginary part is floating-point 0.0.

This conversion worked only for rational imaginary parts.

11 years agoMinor fixes for recent CLang.
Richard Kreckel [Sat, 19 Oct 2013 07:19:57 +0000 (07:19 +0000)]
Minor fixes for recent CLang.

Needed for CLang 3.2.

11 years agoAdd subdir-objects to Automake options.
Richard Kreckel [Fri, 11 Oct 2013 21:18:53 +0000 (21:18 +0000)]
Add subdir-objects to Automake options.

This option is needed to keep automake 1.14 happy.

11 years agoFinalize CLN 1.3.3 release. cln_1-3-3
Richard Kreckel [Sun, 21 Jul 2013 21:01:24 +0000 (21:01 +0000)]
Finalize CLN 1.3.3 release.

* Removed some obsolete Makefile.devel.
* Updated autoconf tools.
* Updated version and copyright information.

11 years agoAvoid compiler warning.
Richard Kreckel [Sat, 20 Jul 2013 12:29:41 +0000 (12:29 +0000)]
Avoid compiler warning.

11 years agoSupport for Texinfo-5.0.
Richard Kreckel [Fri, 19 Jul 2013 21:44:30 +0000 (21:44 +0000)]
Support for Texinfo-5.0.

Changed some @itemx into @item. Surround the "Detailed Node Listing"
section of the info page menu with @detailmenu flag.

11 years agoSupport x32 ABI.
Daniel Schepler [Fri, 15 Feb 2013 21:59:24 +0000 (22:59 +0100)]
Support x32 ABI.

Fix autoconf test checking whether mp_limb_t needs to be long long,
which is needed on x32.

11 years agoUpdate to recently found large Mersenne prime.
Richard Kreckel [Fri, 8 Feb 2013 21:06:00 +0000 (22:06 +0100)]
Update to recently found large Mersenne prime.

12 years agoFix some conversions to cl_SF, cl_FF, and cl_DF.
Richard Kreckel [Tue, 9 Oct 2012 06:24:29 +0000 (08:24 +0200)]
Fix some conversions to cl_SF, cl_FF, and cl_DF.

Some conversions failed to properly overflow/underflow with very large
exponents because of premature exponent truncation.

12 years agoFix integer input with leading zeros in power-of-two base.
Richard Kreckel [Sat, 6 Oct 2012 20:44:34 +0000 (22:44 +0200)]
Fix integer input with leading zeros in power-of-two base.

Reading leading '0' characters in integers of base 2, 4, 8, 16, or 32
could result in a NUDS with leading zero digits. This is against the
rules. The result was a misbehaving cl_I down the road.

Thanks to Morgan Deters <mdeters@cs.nyu.edu> of the CVC4 team.

12 years agoDetect s390x and sparc64 as 32-bit architectures.
Richard Kreckel [Sun, 1 Apr 2012 20:38:54 +0000 (22:38 +0200)]
Detect s390x and sparc64 as 32-bit architectures.

CLN fails to build on s390x and sparc64 as it detects them as 32-bit
architectures, due to __s390__ and __sparc__ matching respectively both
s390 and s390x, and both sparc and sparc64. The patch below fixes the
issue. (Reported as Debian bug#639494.)

Thanks to Aurelien Jarno <aurel32@debian.org>.

12 years agoAvoid input stream fail state when reading number at EOF.
Richard Kreckel [Sun, 18 Mar 2012 23:35:03 +0000 (00:35 +0100)]
Avoid input stream fail state when reading number at EOF.

istream::get() puts the stream in fail state when trying to read at
EOF. This is best avoided by first peek()ing what is available.

12 years agoFix bug in converting cl_LF to float, double.
Richard Kreckel [Fri, 2 Mar 2012 22:40:34 +0000 (23:40 +0100)]
Fix bug in converting cl_LF to float, double.

13 years agoFinalize CLN 1.3.2 release. cln_1-3-2
Richard Kreckel [Sun, 8 May 2011 20:26:25 +0000 (22:26 +0200)]
Finalize CLN 1.3.2 release.

13 years agoFix scale_float for large factors on x86.
Richard Kreckel [Tue, 12 Apr 2011 08:00:36 +0000 (10:00 +0200)]
Fix scale_float for large factors on x86.

The routine scale_float(cl_LF, cl_I) in file cl_LF_scale_I.cc had not
been adapted to 64-bit exponents on systems where uintD is 32 bit.

Reported by Michael Miller <millermj@lemoyne.edu>.

13 years agoUpdate documentation about infrastructure requirements.
Richard Kreckel [Sat, 9 Apr 2011 08:32:38 +0000 (10:32 +0200)]
Update documentation about infrastructure requirements.

13 years agoSupport for MSVC.
Richard Kreckel [Sat, 9 Apr 2011 08:04:39 +0000 (10:04 +0200)]
Support for MSVC.

This patch works around problems MSVC has with extern "C" declarations
inside namespace cln. As a result, it should work with MS 32-bit compiler
version 16.00.30319.01.

Thanks to Jan Rheinländer <jrheinlaender@gmx.de>.

13 years agoFix yet another dependent base C++ language issue.
Richard Kreckel [Wed, 2 Feb 2011 22:44:15 +0000 (23:44 +0100)]
Fix yet another dependent base C++ language issue.

13 years agoFix compilation with clang.
Richard Kreckel [Wed, 2 Feb 2011 08:39:05 +0000 (09:39 +0100)]
Fix compilation with clang.

This resolves some depending names that GCC generously accepts.

Thanks to Pawel Worach <pawel.worach@gmail.com>.

14 years agoConfigure: be more cross-compilation friendly.
Alexei Sheplyakov [Tue, 1 Jun 2010 07:45:08 +0000 (09:45 +0200)]
Configure: be more cross-compilation friendly.

Rewrite CL_GMP_SET_UINTD so it works for cross-compilation too.

14 years agoFix the documentation build failure (wrong texinfo).
Alexei Sheplyakov [Tue, 1 Jun 2010 07:42:45 +0000 (09:42 +0200)]
Fix the documentation build failure (wrong texinfo).

Building PDF, PostScript, and DVI versions of the documentation fails
with the following error message(s):
../../doc/cln.texi:1170: Argument of @asis has an extra }.
<inserted text>
                @par
<to be read again>
                   }
According to texinfo maintainer @itemize @asis is illegal, one should
use @itemize @w{} instead.
See <http://lists.gnu.org/archive/html/bug-texinfo/2009-03/msg00016.html>.

14 years agoRemove 'auto' keyword used as storage specifier.
Richard Kreckel [Mon, 10 May 2010 06:59:44 +0000 (08:59 +0200)]
Remove 'auto' keyword used as storage specifier.

That obsolete keyword is being rededicated in C++-0x to another use.

15 years agoFinalize CLN 1.3.1 release. cln_1-3-1
Richard Kreckel [Thu, 24 Sep 2009 07:48:03 +0000 (09:48 +0200)]
Finalize CLN 1.3.1 release.

15 years agoRemove cl_null_string defintion.
Richard Kreckel [Fri, 11 Sep 2009 22:05:29 +0000 (00:05 +0200)]
Remove cl_null_string defintion.

It's been unused since the last release.

15 years agoAdd support for Renesas SH CPU (sh4).
Richard Kreckel [Fri, 11 Sep 2009 21:07:25 +0000 (23:07 +0200)]
Add support for Renesas SH CPU (sh4).

This defines cl_word_alignment for sh4.
Thanks to Nobuhiro Iwamatsu <iwamatsu@nigauri.org>.

15 years agoFix double_approx(const cl_RA& x) on 64-Bit platforms.
Richard Kreckel [Fri, 11 Sep 2009 20:54:27 +0000 (22:54 +0200)]
Fix double_approx(const cl_RA& x) on 64-Bit platforms.

When we extended immediate types on 64-bit platforms back for CLN
1.2.0, we broke the assumption that integers 2^53..2^55-1 are
bignums. This lead to segfaults when approximating a non-integer cl_RA
to double, as reported by Igor Khavkine <igor.kh@gmail.com>.

15 years agoFinalize release 1.3.0. cln_1-3-0
Richard Kreckel [Tue, 30 Jun 2009 21:58:30 +0000 (23:58 +0200)]
Finalize release 1.3.0.

15 years agoFix build breakage on Sparc.
Richard Kreckel [Mon, 22 Jun 2009 21:12:46 +0000 (23:12 +0200)]
Fix build breakage on Sparc.

With 7da4d3ae46279298acd5d65637499caab7b57071, the code that sed-converted
the $ to # in all the Sparc assembler files was removed. Let's hope that
we won't need it again.

15 years agoMake the pi teaser program install.
Richard Kreckel [Sun, 10 May 2009 20:39:04 +0000 (22:39 +0200)]
Make the pi teaser program install.

15 years agoCorrectly forward-declare cl_print_* helpers.
Richard Kreckel [Sun, 10 May 2009 20:38:23 +0000 (22:38 +0200)]
Correctly forward-declare cl_print_* helpers.

cl_print_flags and friends were declared class in cln/io.h but class
elsewhere. Some compilers didn't like it.

15 years agoPrepare for CLN 1.3.0 release.
Richard Kreckel [Mon, 16 Feb 2009 22:08:41 +0000 (23:08 +0100)]
Prepare for CLN 1.3.0 release.

Set version number and update copyright strings.

15 years agoPrefer GMP's multiplication routine (if GMP version >= 4.0).
Richard Kreckel [Sun, 15 Feb 2009 21:16:11 +0000 (22:16 +0100)]
Prefer GMP's multiplication routine (if GMP version >= 4.0).

Recent GMP multiplication routines (mpn_mul) are somewhat faster than CLN's.
For huge operands, this is due to better tuned FFT. For medium-sized operands
it's due to more algorithms (Toom 3-way.) For small operands, I couldn't find
a difference. Let's just use mpn_mul if it's available.

For huge binsplit sums, this can half the runtimes, on amd64.

15 years agoGit-ify some documentation.
Richard B. Kreckel [Thu, 29 Jan 2009 07:44:09 +0000 (08:44 +0100)]
Git-ify some documentation.

We don't need that ChangeLog any more, since git already provides a patchset view.

15 years agoOverride automake's DEFAULT_INCLUDES.
Richard B. Kreckel [Sat, 24 Jan 2009 21:27:54 +0000 (22:27 +0100)]
Override automake's DEFAULT_INCLUDES.

Automake adds all kinds of subdirectories to -I, the list of directories
to be searched for header files. However, CLN's header files are not
supposed to be included without the cln/ subdirectory, so adding
-Iinclude/cln can lead to conflicts with other header files. (The
problem at hand was a conflict between CLN's string.h and the C
library's string.h).

15 years agoFix compilation with GCC 4.4.
Richard B. Kreckel [Sun, 21 Dec 2008 19:10:23 +0000 (20:10 +0100)]
Fix compilation with GCC 4.4.

Use std::iostream functions instead of EOF and cl_EOF macros.
This enables us to get rid of the freadchar and funreadchar functions.
While at it, removed the extra signatures introduced for CLN-1.2.0
compatibilty. After all, the soname has been bumped.

Also updated largest known Mersenne prime in examples/perfnum.cc.

16 years ago[build] Added some files to DISTCLEANFILES to please `make distcheck'.
Alexei Sheplyakov [Mon, 10 Nov 2008 09:12:31 +0000 (12:12 +0300)]
[build] Added some files to DISTCLEANFILES to please `make distcheck'.

16 years ago[build] Correctly set CLN version for auto* tools.
Alexei Sheplyakov [Mon, 10 Nov 2008 08:55:27 +0000 (11:55 +0300)]
[build] Correctly set CLN version for auto* tools.

The only effect of this change is correct tarball name. There's no actual
code changes.

16 years agoList all source files so CLN builds from tarballs produced by 'make dist'.
Alexei Sheplyakov [Mon, 10 Nov 2008 08:50:53 +0000 (11:50 +0300)]
List all source files so CLN builds from tarballs produced by 'make dist'.

16 years agobuild scripts: automatically set proper rpath for linking with GMP.
Alexei Sheplyakov [Sat, 8 Nov 2008 16:29:33 +0000 (19:29 +0300)]
build scripts: automatically set proper rpath for linking with GMP.

16 years agocl_asm_GF2.cc: fix compilation error on SPARC.
Alexei Sheplyakov [Tue, 23 Sep 2008 12:42:38 +0000 (16:42 +0400)]
cl_asm_GF2.cc: fix compilation error on SPARC.

The code itself seems to be broken, so probably I should remove it...

16 years agobuild: require automake version at least 1.10
Alexei Sheplyakov [Tue, 23 Sep 2008 12:38:15 +0000 (16:38 +0400)]
build: require automake version at least 1.10

Previous versions don't define MKDIR_P and some other useful things. Since
automake 1.10 was released 2+ years ago this requirment is reasonable.

16 years ago[BUGFIX] cln/config.h: fix include guard.
Alexei Sheplyakov [Sun, 21 Sep 2008 13:37:21 +0000 (17:37 +0400)]
[BUGFIX] cln/config.h: fix include guard.

16 years ago[BUGFIX]: cl_asm_.cc: fix include paths.
Alexei Sheplyakov [Sun, 21 Sep 2008 13:38:52 +0000 (17:38 +0400)]
[BUGFIX]: cl_asm_.cc: fix include paths.

Proper fix would be to remove that file. YMMV, but on "modern" CPUs (k7,
pentium[234], k8) gcc generated code works 1.5 -- 2 times faster.

16 years agocl_{GV,SV}: use std::size_t for size of vectors (instead of obscure uintC).
Alexei Sheplyakov [Mon, 22 Sep 2008 08:55:01 +0000 (12:55 +0400)]
cl_{GV,SV}: use std::size_t for size of vectors (instead of obscure uintC).

16 years agoEquip vectors (cl_[SG]V_*) with STL-alike size() method.
Alexei Sheplyakov [Mon, 15 Sep 2008 21:26:08 +0000 (01:26 +0400)]
Equip vectors (cl_[SG]V_*) with STL-alike size() method.

16 years agobuild: define EXTRA_PROGRAMS to shut up automake warnings.
Alexei Sheplyakov [Sun, 7 Sep 2008 16:17:27 +0000 (20:17 +0400)]
build: define EXTRA_PROGRAMS to shut up automake warnings.

16 years agoFix programs for timing 2-adic operations: tests/time{div,recip}2adic.cc
Alexei Sheplyakov [Sun, 7 Sep 2008 16:14:55 +0000 (20:14 +0400)]
Fix programs for timing 2-adic operations: tests/time{div,recip}2adic.cc

At least they compile and run now. TODO: deobfuscate the code and provide
helpful usage messages.

16 years ago[bugfix] Actually compile in version info into the library.
Alexei Sheplyakov [Sun, 7 Sep 2008 15:33:11 +0000 (19:33 +0400)]
[bugfix] Actually compile in version info into the library.

src/base/cl_version.cc: don't #include "cl_sysdep.h", so the version info
actually gets compiled into the library.

Due to the changes introduced in 7da4d3ae ("build: switch to ordinary auto*
tools system") including "cln/version.h" after "cl_config.h" is no-op (yes,
this is intended).

16 years ago[bugfix] build: generate cl_config.h properly.
Alexei Sheplyakov [Sun, 7 Sep 2008 13:18:04 +0000 (17:18 +0400)]
[bugfix] build: generate cl_config.h properly.

cl_config.h file was useless due to stupid typo (#ifdef instead of #ifndef,
introduced in 7da4d3ae). Fix it.

16 years agobenchmarks: time{catalan,euler,exp1,zeta3}.cc actually compile and work now.
Alexei Sheplyakov [Sun, 7 Sep 2008 14:39:54 +0000 (18:39 +0400)]
benchmarks: time{catalan,euler,exp1,zeta3}.cc actually compile and work now.

These benchmarks use internal CLN functions. Even worse -- they expect to
find these functions in the global namespace. Declare internal CLN functions
in the namespace cln.

16 years ago[bugfix] Public headers need GMP_DEMANDS_UINTD_* macros.
Alexei Sheplyakov [Sun, 7 Sep 2008 07:56:58 +0000 (11:56 +0400)]
[bugfix] Public headers need GMP_DEMANDS_UINTD_* macros.

Put them back into cln/config.h.in (until a better solution is found).

16 years agoImprove installation instructions.
Alexei Sheplyakov [Wed, 27 Aug 2008 12:19:03 +0000 (16:19 +0400)]
Improve installation instructions.

16 years ago[bugfix] install intparam.h (auto-generated) header.
Alexei Sheplyakov [Wed, 27 Aug 2008 06:28:14 +0000 (10:28 +0400)]
[bugfix] install intparam.h (auto-generated) header.

Actually it's a bad idea to expose those defines to user, but CLN public
headers depend on them.

16 years agoRemove libtool bits from the repository.
Alexei Sheplyakov [Wed, 27 Aug 2008 06:12:17 +0000 (10:12 +0400)]
Remove libtool bits from the repository.

This makes packagers' life a bit easier.

16 years agodon't expose configure generated headers to users.
Alexei Sheplyakov [Wed, 27 Aug 2008 05:51:35 +0000 (09:51 +0400)]
don't expose configure generated headers to users.

Those HAVE_FOO collide with #define's introduced by a package which uses
CLN. The result is very funny (debugging this is not, though).

16 years agocln.texi: display copyright information in the info file, ...
Alexei Sheplyakov [Tue, 27 May 2008 06:35:54 +0000 (10:35 +0400)]
cln.texi: display copyright information in the info file, ...

... use @ifnottex instead of @ifinfo so relevant pages are included into
the HTML version of the manual.

16 years agotests: test_I_io: ignore read_integer() failures on woe32.
Alexei Sheplyakov [Tue, 27 May 2008 13:39:19 +0000 (17:39 +0400)]
tests: test_I_io: ignore read_integer() failures on woe32.

The test always fail on woe32, so ignore errors (but print relevant info).

16 years agobuild: compile benchmark programs too.
Alexei Sheplyakov [Tue, 26 Aug 2008 16:59:31 +0000 (20:59 +0400)]
build: compile benchmark programs too.

16 years agobuild: switch to ordinary auto* tools system.
Alexei Sheplyakov [Sat, 23 Aug 2008 18:33:09 +0000 (22:33 +0400)]
build: switch to ordinary auto* tools system.

Benefits:

1. If a header file gets modified, all dependent stuff gets rebuilt.
   No need for 'make clean' after each header modification, no more
   spurious errors, no more spurious rebuilds.
2. No more errors due to redefined preprocessor, compiler, and linker
   FLAGS.
3. Build scripts don't try to build every *.cc file which happen to
   lurk in the source directory.

16 years agotests: #include <iostream> and using namespace std; for std::cout and std::endl
Alexei Sheplyakov [Sat, 23 Aug 2008 18:22:56 +0000 (22:22 +0400)]
tests: #include <iostream> and using namespace std; for std::cout and std::endl

Otherwise timing programs fail to compile.

16 years agoFix header paths braindamage in the tests directory too.
Alexei Sheplyakov [Sat, 23 Aug 2008 16:09:17 +0000 (20:09 +0400)]
Fix header paths braindamage in the tests directory too.

16 years agobuild: don't insist on turning on optimization.
Alexei Sheplyakov [Sat, 23 Aug 2008 15:11:28 +0000 (19:11 +0400)]
build: don't insist on turning on optimization.

Since there's no CL_REQUIRE/CL_PROVIDE junk any more, optimization is
not mandatory.

16 years agoUse paths relative the `src' directory in the #include directives.
Alexei Sheplyakov [Sat, 23 Aug 2008 14:49:10 +0000 (18:49 +0400)]
Use paths relative the `src' directory in the #include directives.

Typical CLN source file starts with

 // General includes.
 #include "cl_sysdep.h"

 // Specification.
 #include "cl_2DS.h"

 // Implementation.

 #include "cl_2D.h"
 #include "cl_DS.h"

It takes a while to figure out which files are included. So, use paths relative
to the `src' directory, like this:

 // General includes.
 #include "base/cl_sysdep.h"

 // Specification.
 #include "src/base/digitseq/cl_2DS.h"

 // Implementation.

 #include "base/digit/cl_2D.h"
 #include "base/digitseq/cl_DS.h"

This makes CLN less hacker hostile.

16 years agobump library version, since CLN doesn't export global object ctors any more.
Alexei Sheplyakov [Thu, 21 Aug 2008 19:50:07 +0000 (23:50 +0400)]
bump library version, since CLN doesn't export global object ctors any more.

Those cl_module__blah__firstglobalfun functions don't even exist any more.

16 years agoremove CL_REQUIRE/CL_PROVIDE macro and associated autoconf tests.
Alexei Sheplyakov [Thu, 21 Aug 2008 18:44:01 +0000 (22:44 +0400)]
remove CL_REQUIRE/CL_PROVIDE macro and associated autoconf tests.

16 years agoReplace CL_REQUIRE/CL_PROVIDE(cl_UP) with portable code.
Alexei Sheplyakov [Thu, 21 Aug 2008 16:01:23 +0000 (20:01 +0400)]
Replace CL_REQUIRE/CL_PROVIDE(cl_UP) with portable code.

The order of initialization of non-local objects in different compilation units
is not specified in C++. Hence special care should be taken to avoid static
initialization order fiasco. CLN solved the problem with some evil (GCC
specific, and even GCC-version-specific) hack. Replace it with a technique
similar to one used in STL to initialize std::cout and friends.

16 years agoReplace CL_REQUIRE/CL_PROVIDE(cl_UP_no_ring) with portable code.
Alexei Sheplyakov [Thu, 21 Aug 2008 15:51:59 +0000 (19:51 +0400)]
Replace CL_REQUIRE/CL_PROVIDE(cl_UP_no_ring) with portable code.

The order of initialization of non-local objects in different compilation units
is not specified in C++. Hence special care should be taken to avoid static
initialization order fiasco. CLN solved the problem with some evil (GCC
specific, and even GCC-version-specific) hack. Replace it with a technique
similar to one used in STL to initialize std::cout and friends.

16 years agoReplace CL_REQUIRE/CL_PROVIDE(cl_UP_named) with portable code.
Alexei Sheplyakov [Thu, 21 Aug 2008 15:49:28 +0000 (19:49 +0400)]
Replace CL_REQUIRE/CL_PROVIDE(cl_UP_named) with portable code.

The order of initialization of non-local objects in different compilation units
is not specified in C++. Hence special care should be taken to avoid static
initialization order fiasco. CLN solved the problem with some evil (GCC
specific, and even GCC-version-specific) hack. Replace it with a technique
similar to one used in STL to initialize std::cout and friends.

16 years agoReplace CL_REQUIRE/CL_PROVIDE(cl_UP_unnamed) with portable code.
Alexei Sheplyakov [Thu, 21 Aug 2008 15:32:14 +0000 (19:32 +0400)]
Replace CL_REQUIRE/CL_PROVIDE(cl_UP_unnamed) with portable code.

The order of initialization of non-local objects in different compilation units
is not specified in C++. Hence special care should be taken to avoid static
initialization order fiasco. CLN solved the problem with some evil (GCC
specific, and even GCC-version-specific) hack. Replace it with a technique
similar to one used in STL to initialize std::cout and friends.

16 years agoGet rid CL_REQUIRE/CL_PROVIDE(cl_F_epsneg), it is not really necessary.
Alexei Sheplyakov [Thu, 21 Aug 2008 12:06:02 +0000 (16:06 +0400)]
Get rid CL_REQUIRE/CL_PROVIDE(cl_F_epsneg), it is not really necessary.

Move static variables [SFDL]F_negative_epsilon into LF_negative_epsilon()
function (which is the only user of those variables) in order to avoid
possible static order initialization problems. While at it, make
LF_negative_epsilon() function static.

16 years agoGet rid CL_REQUIRE/CL_PROVIDE(cl_F_epspos), it is not really necessary.
Alexei Sheplyakov [Thu, 21 Aug 2008 12:06:02 +0000 (16:06 +0400)]
Get rid CL_REQUIRE/CL_PROVIDE(cl_F_epspos), it is not really necessary.

Move static variables [SFDL]F_epsilon into LF_epsilon() function (which
is the only user of those variables) in order to avoid possible static
order initialization problems. While at it, make LF_epsilon() function
static.

16 years agoGet rid CL_REQUIRE/CL_PROVIDE(cl_F_leastneg), it is not really necessary.
Alexei Sheplyakov [Thu, 21 Aug 2008 12:06:02 +0000 (16:06 +0400)]
Get rid CL_REQUIRE/CL_PROVIDE(cl_F_leastneg), it is not really necessary.

Move static variables least_negative_[SFDL]F into least_negative_LF() function
(which is the only user of those variables) in order to avoid possible static
order initialization problems. While at it, make least_negative_LF() function
static.

16 years agoGet rid CL_REQUIRE/CL_PROVIDE(cl_F_leastpos), it is not really necessary.
Alexei Sheplyakov [Thu, 21 Aug 2008 12:06:02 +0000 (16:06 +0400)]
Get rid CL_REQUIRE/CL_PROVIDE(cl_F_leastpos), it is not really necessary.

Move static variables least_positive_[SFDL]F into least_positive_LF() function
(which is the only user of those variables) in order to avoid possible static
order initialization problems. While at it, make least_positive_LF() function
static.

16 years agoGet rid CL_REQUIRE/CL_PROVIDE(cl_F_mostneg), it is not really necessary.
Alexei Sheplyakov [Thu, 21 Aug 2008 12:06:02 +0000 (16:06 +0400)]
Get rid CL_REQUIRE/CL_PROVIDE(cl_F_mostneg), it is not really necessary.

Move static variables most_negative_[SFDL]F into most_negative_LF() function
(which is the only user of those variables) in order to avoid possible static
order initialization problems. While at it, make most_negative_LF() function
static.

16 years agoGet rid CL_REQUIRE/CL_PROVIDE(cl_F_mostpos), it is not really necessary.
Alexei Sheplyakov [Thu, 21 Aug 2008 12:06:02 +0000 (16:06 +0400)]
Get rid CL_REQUIRE/CL_PROVIDE(cl_F_mostpos), it is not really necessary.

Move static variables most_positive_[SFDL]F into most_positive_LF() function
(which is the only user of those variables) in order to avoid possible static
order initialization problems. While at it, make most_positive_LF() function
static.

16 years agoGet rid of CL_REQUIRE/CL_PROVIDE(cl_fmt_floatstring)...
Alexei Sheplyakov [Thu, 21 Aug 2008 14:34:06 +0000 (18:34 +0400)]
Get rid of CL_REQUIRE/CL_PROVIDE(cl_fmt_floatstring)...

The code doesn't seem to initialize any static objects at all.

16 years agoGet rid of CL_REQUIRE/CL_PROVIDE(cl_F_catalanconst_var).
Alexei Sheplyakov [Thu, 21 Aug 2008 16:44:33 +0000 (20:44 +0400)]
Get rid of CL_REQUIRE/CL_PROVIDE(cl_F_catalanconst_var).

Turn cl_[SDFL]F_catalanconst global variables into functions (which return
a reference to the static value) in order to avoid static initialization
order problems.

16 years agoGet rid of CL_REQUIRE/CL_PROVIDE(cl_F_eulerconst_var).
Alexei Sheplyakov [Thu, 21 Aug 2008 16:27:17 +0000 (20:27 +0400)]
Get rid of CL_REQUIRE/CL_PROVIDE(cl_F_eulerconst_var).

Turn cl_[SDFL]F_eulerconst global variables into functions (which return
a reference to the static value) in order to avoid static initialization
order problems.

16 years agoGet rid of CL_REQUIRE/CL_PROVIDE(cl_F_exp1_var).
Alexei Sheplyakov [Thu, 21 Aug 2008 14:16:31 +0000 (18:16 +0400)]
Get rid of CL_REQUIRE/CL_PROVIDE(cl_F_exp1_var).

Turn cl_[SDFL]F_exp1 global variables into functions (which return a reference
to the static value) in order to avoid static initialization order problems.

16 years agoGet rid of CL_REQUIRE/CL_PROVIDE(cl_F_ln10_var).
Alexei Sheplyakov [Thu, 21 Aug 2008 14:14:24 +0000 (18:14 +0400)]
Get rid of CL_REQUIRE/CL_PROVIDE(cl_F_ln10_var).

Turn cl_[SDFL]F_ln10 global variables into functions (which return a constant
reference to the static value) in order to avoid static initialization order
problems.

16 years agoGet rid of CL_REQUIRE/CL_PROVIDE(cl_F_ln2_var).
Alexei Sheplyakov [Thu, 21 Aug 2008 14:12:39 +0000 (18:12 +0400)]
Get rid of CL_REQUIRE/CL_PROVIDE(cl_F_ln2_var).

Turn cl_[SDFL]F_ln2 global variables into functions (which return a constant
reference to the static value) in order to avoid static initialization order
problems.