Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/external/lgpl3/gmp/dist initial import of GMP 6.2.1. from t...



details:   https://anonhg.NetBSD.org/src/rev/10bce8d7ef1a
branches:  trunk
changeset: 984570:10bce8d7ef1a
user:      mrg <mrg%NetBSD.org@localhost>
date:      Sun Jul 11 21:14:44 2021 +0000

description:
initial import of GMP 6.2.1.  from their NEWS:

Changes between GMP version 6.2.0 and 6.2.1

  BUGS FIXED
  * A possible overflow of type int is avoided for mpz_cmp on huge operands.
  * Overflows are more carefully detected and reported for mpz_pow_ui.
  * A bug in longlong.h for aarch64 sub_ddmmss, not affecting GMP, was healed.

  FEATURES
  * C90 compliance.
  * Initial support for Darwin on arm64, and improved portability.
  * Support for more processors.

diffstat:

 external/lgpl3/gmp/dist/ChangeLog                                                   |   201 +
 external/lgpl3/gmp/dist/Makefile.am                                                 |     9 +-
 external/lgpl3/gmp/dist/NEWS                                                        |    25 +
 external/lgpl3/gmp/dist/configure.ac                                                |    27 +-
 external/lgpl3/gmp/dist/demos/calc/calc.c                                           |  2715 ++++++---
 external/lgpl3/gmp/dist/demos/calc/calc.h                                           |   175 +-
 external/lgpl3/gmp/dist/doc/gmp.info                                                |   302 +-
 external/lgpl3/gmp/dist/doc/gmp.info-1                                              |    24 +-
 external/lgpl3/gmp/dist/doc/gmp.info-2                                              |   Bin 
 external/lgpl3/gmp/dist/doc/gmp.texi                                                |     4 +-
 external/lgpl3/gmp/dist/doc/stamp-vti                                               |     8 +-
 external/lgpl3/gmp/dist/doc/version.texi                                            |     8 +-
 external/lgpl3/gmp/dist/mini-gmp/ChangeLog                                          |   673 ++
 external/lgpl3/gmp/dist/mini-gmp/mini-gmp.c                                         |    10 +-
 external/lgpl3/gmp/dist/mini-gmp/mini-gmp.h                                         |     5 +-
 external/lgpl3/gmp/dist/mini-gmp/mini-mpq.c                                         |    10 +-
 external/lgpl3/gmp/dist/mini-gmp/tests/hex-random.h                                 |     2 +-
 external/lgpl3/gmp/dist/mini-gmp/tests/run-tests                                    |    30 +-
 external/lgpl3/gmp/dist/mini-gmp/tests/t-double.c                                   |     6 +-
 external/lgpl3/gmp/dist/mini-gmp/tests/t-mpq_double.c                               |    11 +-
 external/lgpl3/gmp/dist/mini-gmp/tests/t-mpq_muldiv_2exp.c                          |     2 +-
 external/lgpl3/gmp/dist/mini-gmp/tests/t-mpq_str.c                                  |    14 +-
 external/lgpl3/gmp/dist/mini-gmp/tests/t-str.c                                      |    14 +-
 external/lgpl3/gmp/dist/mpn/arm64/arm64-defs.m4                                     |    53 +
 external/lgpl3/gmp/dist/mpn/arm64/bdiv_q_1.asm                                      |    12 +-
 external/lgpl3/gmp/dist/mpn/arm64/darwin.m4                                         |    50 +
 external/lgpl3/gmp/dist/mpn/arm64/invert_limb.asm                                   |     4 +-
 external/lgpl3/gmp/dist/mpn/arm64/lshift.asm                                        |    31 +-
 external/lgpl3/gmp/dist/mpn/arm64/lshiftc.asm                                       |    31 +-
 external/lgpl3/gmp/dist/mpn/arm64/rshift.asm                                        |    31 +-
 external/lgpl3/gmp/dist/mpn/generic/compute_powtab.c                                |    24 +-
 external/lgpl3/gmp/dist/mpn/generic/dcpi1_bdiv_q.c                                  |     3 +-
 external/lgpl3/gmp/dist/mpn/generic/gcd_22.c                                        |     2 +-
 external/lgpl3/gmp/dist/mpn/generic/get_str.c                                       |     4 +-
 external/lgpl3/gmp/dist/mpn/generic/hgcd2.c                                         |    24 +-
 external/lgpl3/gmp/dist/mpn/generic/mul_fft.c                                       |     9 +-
 external/lgpl3/gmp/dist/mpn/generic/set_str.c                                       |     6 +-
 external/lgpl3/gmp/dist/mpn/generic/strongfibo.c                                    |     4 +
 external/lgpl3/gmp/dist/mpn/generic/toom_interpolate_12pts.c                        |    58 +-
 external/lgpl3/gmp/dist/mpn/generic/toom_interpolate_16pts.c                        |    34 +-
 external/lgpl3/gmp/dist/mpn/powerpc64/mode64/p9/addmul_2.asm                        |    31 +-
 external/lgpl3/gmp/dist/mpn/powerpc64/mode64/p9/mul_2.asm                           |    31 +-
 external/lgpl3/gmp/dist/mpn/x86/fat/fat.c                                           |    35 +-
 external/lgpl3/gmp/dist/mpn/x86_64/bd2/gcd_22.asm                                   |     2 +-
 external/lgpl3/gmp/dist/mpn/x86_64/fat/fat.c                                        |     5 +-
 external/lgpl3/gmp/dist/mpn/x86_64/skylake/gmp-mparam.h                             |    19 +-
 external/lgpl3/gmp/dist/mpn/x86_64/x86_64-defs.m4                                   |    18 +
 external/lgpl3/gmp/dist/mpn/x86_64/zen2/gmp-mparam.h                                |    21 +-
 external/lgpl3/gmp/dist/mpq/cmp.c                                                   |     3 +-
 external/lgpl3/gmp/dist/mpz/cmp.c                                                   |    12 +-
 external/lgpl3/gmp/dist/mpz/millerrabin.c                                           |    12 +-
 external/lgpl3/gmp/dist/mpz/mul.c                                                   |    16 +-
 external/lgpl3/gmp/dist/mpz/n_pow_ui.c                                              |    24 +-
 external/lgpl3/gmp/dist/tests/cxx/t-assign.cc                                       |    12 +-
 external/lgpl3/gmp/dist/tests/cxx/t-constr.cc                                       |    28 +-
 external/lgpl3/gmp/dist/tests/cxx/t-do-exceptions-work-at-all-with-this-compiler.cc |     2 +-
 external/lgpl3/gmp/dist/tests/cxx/t-ops2z.cc                                        |    14 +-
 external/lgpl3/gmp/dist/tests/cxx/t-rand.cc                                         |     2 +-
 external/lgpl3/gmp/dist/tests/devel/Makefile.am                                     |    18 +-
 external/lgpl3/gmp/dist/tests/devel/Makefile.in                                     |   155 +-
 external/lgpl3/gmp/dist/tests/devel/gen-test-longlong_h.c                           |   140 +
 external/lgpl3/gmp/dist/tests/misc.c                                                |     9 +-
 external/lgpl3/gmp/dist/tests/misc/t-locale.c                                       |     4 +-
 external/lgpl3/gmp/dist/tests/mpf/t-conv.c                                          |    25 +-
 external/lgpl3/gmp/dist/tests/mpf/t-get_d_2exp.c                                    |    12 +-
 external/lgpl3/gmp/dist/tests/mpf/t-trunc.c                                         |     4 +-
 external/lgpl3/gmp/dist/tests/mpn/t-gcd_11.c                                        |     3 +
 external/lgpl3/gmp/dist/tests/mpn/t-gcd_22.c                                        |     3 +
 external/lgpl3/gmp/dist/tests/mpn/t-gcdext_1.c                                      |     3 +
 external/lgpl3/gmp/dist/tests/mpz/Makefile.am                                       |     2 +-
 external/lgpl3/gmp/dist/tests/mpz/Makefile.in                                       |    48 +-
 external/lgpl3/gmp/dist/tests/mpz/convert.c                                         |    23 +-
 external/lgpl3/gmp/dist/tests/mpz/io.c                                              |    15 +-
 external/lgpl3/gmp/dist/tests/mpz/reuse.c                                           |    36 +-
 external/lgpl3/gmp/dist/tests/mpz/t-bit.c                                           |   405 +
 external/lgpl3/gmp/dist/tests/mpz/t-get_d.c                                         |     9 +-
 external/lgpl3/gmp/dist/tests/mpz/t-mul.c                                           |     5 +-
 external/lgpl3/gmp/dist/tests/refmpn.c                                              |     4 +-
 external/lgpl3/gmp/dist/tests/spinner.c                                             |     2 +-
 external/lgpl3/gmp/dist/tune/speed.c                                                |     6 +-
 external/lgpl3/gmp/dist/tune/speed.h                                                |     6 +-
 external/lgpl3/gmp/dist/tune/time.c                                                 |    17 +-
 external/lgpl3/gmp/dist/tune/tune-gcd-p.c                                           |     3 +-
 external/lgpl3/gmp/dist/tune/tuneup.c                                               |    17 +-
 84 files changed, 4351 insertions(+), 1565 deletions(-)

diffs (truncated from 7801 to 300 lines):

diff -r 362b7cbdc841 -r 10bce8d7ef1a external/lgpl3/gmp/dist/ChangeLog
--- a/external/lgpl3/gmp/dist/ChangeLog Sun Jul 11 21:07:44 2021 +0000
+++ b/external/lgpl3/gmp/dist/ChangeLog Sun Jul 11 21:14:44 2021 +0000
@@ -1,3 +1,204 @@
+2020-11-13 Marco Bodrato <bodrato%mail.dm.unipi.it@localhost>
+
+       * Version 6.2.1 released.
+
+       * gmp-h.in (__GNU_MP_VERSION_PATCHLEVEL): Bump version info.
+       * Makefile.am (LIBGMP_LT_*, LIBGMPXX_LT_*): Bump revision info.
+
+2020-11-10 Marco Bodrato <bodrato%mail.dm.unipi.it@localhost>
+
+       * configure.ac (fat_path): Add bd1, goldmont,silvermont for CPUVEC.
+       * mpn/x86_64/fat/fat.c: Add more CPUs.
+       * mpn/x86/fat/fat.c: Add more CPUs.
+
+2020-11-01 Marco Bodrato <bodrato%mail.dm.unipi.it@localhost>
+
+       * configure.ac: X86_{,64_}PATTERN: GMP_ASM_COFF_TYPE for all ABIs;
+       * mpn/x86_64/x86_64-defs.m4 (COFF_TYPE): Copy from mpn/x86/x86-defs.m4
+       as suggested by Jeremy Drake.
+
+       * tests/misc/t-locale.c (nl_langinfo): No redefine on __TERMUX__,
+       spotted by Sanselme and Glisse.
+       * configure.ac: Consider *-*-msys as *-*-mingw* (except on arm* |
+       aarch64*), as suggested by Ralph Peterson.
+       * Makefile.am (EXTRA_DIST): Add mini-gmp/ChangeLog.
+
+2020-10-30 Marco Bodrato <bodrato%mail.dm.unipi.it@localhost>
+
+       * tests/mpf/t-get_d_2exp.c: Test also the case zero.
+       * tests/mpz/t-get_d.c: Likewise.
+       * tests/mpf/t-trunc.c: Use mpf_size.
+
+       * tests/mpf/t-conv.c: Some more tests on zero.
+
+2020-10-25 Marco Bodrato <bodrato%mail.dm.unipi.it@localhost>
+
+       * configfsf.guess: Updated to version 2020-10-22, from gnulib.
+
+2020-10-17 Marco Bodrato <bodrato%mail.dm.unipi.it@localhost>
+
+       * tests/devel/Makefile.am: Remove redundancies.
+
+       * tests/mpz/io.c: Test out-of-range bases for mpz_out_str.
+
+2020-10-15  Torbjörn Granlund  <tg%gmplib.org@localhost>
+
+       * configure.ac: Recognise zen3.
+       * config.guess: Recognise zen3.
+
+2020-10-14 Marco Bodrato <bodrato%mail.dm.unipi.it@localhost>
+
+       * doc/gmp.texi (Number sequences): Remove redundancy. (spotted: TonyMcC)
+
+       * configfsf.sub: Updated to version 2020-10-13, from gnulib.
+       * configfsf.guess: Updated to version 2020-09-19, from gnulib.
+
+2020-10-06  Niels Möller  <nisse%lysator.liu.se@localhost>
+
+       * Makefile.am: Better support for make check-mini-gmp on wine or cygwin.
+
+2020-09-22  Torbjörn Granlund  <tg%gmplib.org@localhost>
+
+       * tests/mpz/t-mul.c: Print GMP_CHECK_FFT.
+
+       * longlong.h (x86 umul_ppmm): Fix typo.
+
+2020-09-21  Torbjörn Granlund  <tg%gmplib.org@localhost>
+
+       * mpz/n_pow_ui.c: Detect and report overflow.
+
+2020-07-04  Torbjörn Granlund  <tg%gmplib.org@localhost>
+
+       * mpn/arm64/bdiv_q_1.asm: Use LEA_HI/LEA_LO
+       * mpn/arm64/invert_limb.asm: Likewise.
+
+       * mpn/arm64/arm64-defs.m4: New file.
+       * mpn/arm64/darwin.m4: New file.
+       * configure.ac: Use arm64/arm64-defs.m4 and arm64/darwin.m4.
+
+2020-06-20  Torbjörn Granlund  <tg%gmplib.org@localhost>
+
+       * longlong.h (add_sssaaaa arm32/arm64): Generalise allowed operands
+       when using adds for sub and subs for add, while disallowing 0.
+       (sub_ddmmss ppc64): Disallow 0 when using addic.  Also disallow
+       constants for register-only middle addic operand.
+       (C add_sssaaaa and sub_ddmmss): Use more temps to make operation more
+       well-defined.
+
+2020-06-18  Torbjörn Granlund  <tg%gmplib.org@localhost>
+
+       * tests/devel/gen-test-longlong_h.c: New file.
+       * tests/devel/Makefile.am: Compile and use gen-test-longlong_h.c.
+
+2020-06-10  Torbjörn Granlund  <tg%gmplib.org@localhost>
+
+       * configure.ac: Recognise armcortexa55.
+
+2020-05-25  Torbjörn Granlund  <tg%gmplib.org@localhost>
+
+       * tests/cxx/t-assign.cc: Use reference parameter for 'catch'.
+       * tests/cxx/t-constr.cc: Likewise.
+       * tests/cxx/t-ops2z.cc: Likewise.
+       * tests/cxx/t-rand.cc: Likewise.
+       * tests/cxx/t-do-exceptions-work-at-all-with-this-compiler.cc: Likewise.
+
+       * tune/speed.c: Undo 2020-05-24 _POSIX_C_SOURCE change, it breaks on
+       many broken systems.
+       * tune/freq.c: Likewise.
+       * tune/time.c: Likewise.
+       * tune/tuneup.c: Likewise.
+
+       * tests/devel/try.c: Revert 2020-05-24 changes.
+
+2020-05-21  Torbjörn Granlund  <tg%gmplib.org@localhost>
+
+       * tune/freq.c (_POSIX_C_SOURCE): Define.
+
+       * tune/tuneup.c (print_define_with_speedup): Fall back from snprintf to
+       sprintf for C90.
+       (_POSIX_C_SOURCE): Define.
+       (max_opsize): Set by #define instead of const size_t to please C90.
+       (n_measurements): Likewise.
+       (speed_mpn_pre_set_str): Adhere to C90 declaration rules.
+
+       * tune/tune-gcd-p.c: Back out 2020-01-10 change to comply to C90.
+
+       * tune/time.c (speed_endtime): Cast printf args to right type.
+       (_POSIX_C_SOURCE): Define.
+
+       * tune/speed.h (CACHE_LINE_SIZE): Do #undef before defining.
+       (SPEED_ROUTINE_MPN_GCD_1): Provide dummy first argument for standard
+       compliance.
+       (SPEED_ROUTINE_MPN_HGCD2): Adhere to C90 declaration rules.
+
+       * tune/speed.c (main): Cast printf args to right type.
+       (_POSIX_C_SOURCE): Define.
+
+       * tests/mpz/reuse.c: Avoid using non-standard function fileno().
+       * tests/spinner.c: Likewise.
+
+       * tests/mpz/convert.c (str_casecmp): New function.
+       (main): Use it instead of non-standard strcasecmp.
+
+       * tests/misc.c (tests_start): Fall back from snprintf to sprintf for
+       C90.
+
+       * tests/devel/try.c: Avoid getpagesize and use POSIX sysconf instead.
+       (_POSIX_C_SOURCE): Define.
+
+       * mpn/generic/mod_1_1.c: Don't use C++ comments.
+
+       * mpn/generic/get_d.c: Add clarifying parens.
+
+2020-05-18  Torbjörn Granlund  <tg%gmplib.org@localhost>
+
+       * mpn/generic/toom_interpolate_12pts.c (DO_mpn_addlsh_n): Define only
+       when needed.
+       * mpn/generic/toom_interpolate_16pts.c: Likewise.
+
+2020-05-17 Marco Bodrato <bodrato%mail.dm.unipi.it@localhost>
+
+       * mpz/cmp.c: Avoid overflow on int even for huge sizes.
+       * mpq/cmp.c: Likewise.
+
+       * mpn/generic/mul_fft.c (mpn_fft_mul_modF_K):
+       Fully handle carry propagation in basecase multiplication.
+
+2020-05-16  Torbjörn Granlund  <tg%gmplib.org@localhost>
+
+       * mpn/generic/hgcd2.c (tabp): Combine several undefined tabp
+       variable definitions with a macro.
+
+       * mpn/generic/gcd_22.c: Avoid C99 constructs.
+
+2020-05-12  Torbjörn Granlund  <tg%gmplib.org@localhost>
+
+       * mpn/generic/compute_powtab.c: Avoid C99 constructs.
+       * mpn/generic/get_str.c: Likewise.
+       * mpn/generic/set_str.c: Likewise.
+
+       * gmp-impl.h (memset): Move ASSERT to before decls.
+       * tests/refmpn.c: Likewise.
+
+       * mpn/generic/hgcd2.c (tabp): Combine several undefined tabp variable
+       definitions with a macro.
+
+       * mpn/generic/strongfibo.c: Avoid defining helper function when unused.
+
+       * mpn/generic/dcpi1_bdiv_q.c (mpn_dcpi1_bdiv_q_n_itch): Disable unused
+       static function.
+
+       * mpz/mul.c: Add some {} to suppress warning.
+
+       * tests/mpn/t-gcd_11.c: Exit main() properly.
+       * tests/mpn/t-gcd_22.c: Likewise.
+       * tests/mpn/t-gcdext_1.c: Likewise.
+
+2020-04-28  Torbjörn Granlund  <tg%gmplib.org@localhost>
+
+       * tests/mpz/reuse.c (realloc_if_reducing): New function.
+       (INVOKE_RRS, etc): Use realloc_if_reducing.
+
 2020-01-17  Torbjörn Granlund  <tg%gmplib.org@localhost>
 
        * Version 6.2.0 released.
diff -r 362b7cbdc841 -r 10bce8d7ef1a external/lgpl3/gmp/dist/Makefile.am
--- a/external/lgpl3/gmp/dist/Makefile.am       Sun Jul 11 21:07:44 2021 +0000
+++ b/external/lgpl3/gmp/dist/Makefile.am       Sun Jul 11 21:14:44 2021 +0000
@@ -90,6 +90,7 @@
 #        6.1.1   13:1:3    9:1:5     -
 #        6.1.2   13:2:3    9:2:5     -
 #        6.2.0   14:0:4   10:0:6     -
+#        6.2.1   14:1:4   10:1:6     -
 #
 # Starting at 3:0:0 is a slight abuse of the versioning system, but it
 # ensures we're past soname libgmp.so.2, which was used on Debian GNU/Linux
@@ -103,11 +104,11 @@
 # libgmpxx.so.3.0.4) incrementing, to make it clear which GMP it's from.
 
 LIBGMP_LT_CURRENT    = 14
-LIBGMP_LT_REVISION   = 0
+LIBGMP_LT_REVISION   = 1
 LIBGMP_LT_AGE        = 4
 
 LIBGMPXX_LT_CURRENT  = 10
-LIBGMPXX_LT_REVISION = 0
+LIBGMPXX_LT_REVISION = 1
 LIBGMPXX_LT_AGE      = 6
 
 
@@ -412,7 +413,7 @@
 
 # Distribute mini-gmp. Test sources copied by dist-hook.
 EXTRA_DIST += mini-gmp/README mini-gmp/mini-gmp.c mini-gmp/mini-gmp.h \
-             mini-gmp/mini-mpq.c mini-gmp/mini-mpq.h \
+             mini-gmp/ChangeLog mini-gmp/mini-mpq.c mini-gmp/mini-mpq.h \
              mini-gmp/tests/Makefile mini-gmp/tests/run-tests
 
 # Avoid: CVS - cvs directories
@@ -436,7 +437,7 @@
        abs_srcdir="`cd $(srcdir) && pwd`" ; \
        $(MKDIR_P) mini-gmp/tests \
        && cd mini-gmp/tests \
-       && TEST_LIBRARY_PATH="../../.libs"  \
+       && TEST_SHLIB_DIR="${abs_top_builddir}/.libs" \
           $(MAKE) -f "$$abs_srcdir/mini-gmp/tests/Makefile" \
                VPATH="$$abs_srcdir/mini-gmp/tests" \
                srcdir="$$abs_srcdir/mini-gmp/tests" \
diff -r 362b7cbdc841 -r 10bce8d7ef1a external/lgpl3/gmp/dist/NEWS
--- a/external/lgpl3/gmp/dist/NEWS      Sun Jul 11 21:07:44 2021 +0000
+++ b/external/lgpl3/gmp/dist/NEWS      Sun Jul 11 21:14:44 2021 +0000
@@ -3,6 +3,31 @@
 Verbatim copying and distribution of this entire article is permitted in any
 medium, provided this notice is preserved.
 
+Changes between GMP version 6.2.0 and 6.2.1
+
+  BUGS FIXED
+  * A possible overflow of type int is avoided for mpz_cmp on huge operands.
+
+  * Overflows are more carefully detected and reported for mpz_pow_ui.
+
+  * A bug in longlong.h for aarch64 sub_ddmmss, not affecting GMP, was healed.
+
+  * mini-gmp: mpz_out_str and mpq_out_str now correctly handle out of
+    range bases.
+
+  FEATURES
+  * C90 compliance.
+
+  * Initial support for Darwin on arm64, and improved portability.
+
+  * Support for more processors.
+
+  SPEEDUPS
+  * None, except indirectly through recognition of new CPUs.
+
+  MISC
+  * None.
+
 Changes between GMP version 6.1.* and 6.2.0
 
   BUGS FIXED
diff -r 362b7cbdc841 -r 10bce8d7ef1a external/lgpl3/gmp/dist/configure.ac
--- a/external/lgpl3/gmp/dist/configure.ac      Sun Jul 11 21:07:44 2021 +0000
+++ b/external/lgpl3/gmp/dist/configure.ac      Sun Jul 11 21:14:44 2021 +0000
@@ -35,7 +35,7 @@
 AC_COPYRIGHT(GMP_COPYRIGHT)
 AH_TOP(/*GMP_COPYRIGHT*/)
 
-AC_REVISION($Revision: 1.1.1.3 $)
+AC_REVISION($Revision: 1.1.1.4 $)
 AC_PREREQ(2.59)
 AC_INIT(GNU MP, GMP_VERSION, [gmp-bugs%gmplib.org@localhost, see https://gmplib.org/manual/Reporting-Bugs.html], gmp)
 AC_CONFIG_SRCDIR(gmp-impl.h)
@@ -722,7 +722,7 @@
        gcc_cflags_neon="-mfpu=neon"



Home | Main Index | Thread Index | Old Index