[Gmp-commit] /var/hg/gmp: 2 new changesets

mercurial at gmplib.org mercurial at gmplib.org
Tue Nov 22 08:15:49 UTC 2016


details:   /var/hg/gmp/rev/31b74f38440e
changeset: 17128:31b74f38440e
user:      Niels M?ller <nisse at lysator.liu.se>
date:      Tue Nov 22 09:11:33 2016 +0100
description:
Drop "mini-gmp/"-prefix from filenames in mini-gmp/ChangeLog.

And move a ChangeLog entry for Makefile.am back to top-level ChangeLog.

details:   /var/hg/gmp/rev/afda1bbf3ee3
changeset: 17129:afda1bbf3ee3
user:      Niels M?ller <nisse at lysator.liu.se>
date:      Tue Nov 22 09:15:19 2016 +0100
description:
Added test to mini-gmp t-invert, for mpn_invert_3by2 bug.

* mini-gmp/tests/t-invert.c (test_3by2, test_2by1): New functions,
extracted from testmain.
(testmain): Add test with inputs which triggered the
mpn_invert_3by2 bug (see 2016-11-16 entry).

diffstat:

 ChangeLog                 |    5 +
 mini-gmp/ChangeLog        |  381 ++++++++++++++++++++++-----------------------
 mini-gmp/tests/t-invert.c |  125 ++++++++++-----
 3 files changed, 272 insertions(+), 239 deletions(-)

diffs (truncated from 853 to 300 lines):

diff -r a616287e1855 -r afda1bbf3ee3 ChangeLog
--- a/ChangeLog	Mon Nov 21 23:51:15 2016 +0100
+++ b/ChangeLog	Tue Nov 22 09:15:19 2016 +0100
@@ -4302,6 +4302,11 @@
 
 2012-04-10 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
+	* Makefile.am (check-mini-gmp): Use $(MAKE).
+	(clean-mini-gmp): New target.
+	(clean-local, distclean-local): New automake targets. Depend on
+	clean-mini-gmp.
+
 	* gen-fac_ui.c (mpz_root): Remove.
 
 2012-04-07  Torbjorn Granlund  <tege at gmplib.org>
diff -r a616287e1855 -r afda1bbf3ee3 mini-gmp/ChangeLog
--- a/mini-gmp/ChangeLog	Mon Nov 21 23:51:15 2016 +0100
+++ b/mini-gmp/ChangeLog	Tue Nov 22 09:15:19 2016 +0100
@@ -1,3 +1,10 @@
+2016-11-22  Niels Möller  <nisse at lysator.liu.se>
+
+	* tests/t-invert.c (test_3by2, test_2by1): New functions,
+	extracted from testmain.
+	(testmain): Add test with inputs which triggered the
+	mpn_invert_3by2 bug (see 2016-11-16 entry).
+
 2016-11-20  Niels Möller  <nisse at lysator.liu.se>
 
 	* tests/t-signed.c: Reorganize testcase, to avoid undefined
@@ -24,199 +31,197 @@
 
 2016-11-16  Niels Möller  <nisse at lysator.liu.se>
 
-	* mini-gmp/mini-gmp.c (mpn_invert_3by2): Fix arithmetic overflow
+	* mini-gmp.c (mpn_invert_3by2): Fix arithmetic overflow
 	bug, and improve documentation of the algorithm.
 
 2016-11-15  Niels Möller  <nisse at lysator.liu.se>
 
-	* mini-gmp/tests/t-limbs.c (testmain): Skip tests with zero
-	product.
+	* tests/t-limbs.c (testmain): Skip tests with zero product.
 
-	* mini-gmp/tests/hex-random.c (hex_random_init): Added fflush
-	call.
+	* tests/hex-random.c (hex_random_init): Added fflush call.
 
 2016-11-15  Torbjörn Granlund  <tg at gmplib.org>
 
-	* mini-gmp/tests/Makefile (TESTS): New variable, allowing separation of
+	* tests/Makefile (TESTS): New variable, allowing separation of
 	compilation and running of tests.
-	* mini-gmp/tests/run-tests: Allow empty tests list.
+	* tests/run-tests: Allow empty tests list.
 
 2016-11-01  Torbjörn Granlund  <tg at gmplib.org>
 
-	* mini-gmp/tests/hex-random.c: Reinstate gmp.h inclusion.
+	* tests/hex-random.c: Reinstate gmp.h inclusion.
 
 2016-08-22  Niels Möller  <nisse at lysator.liu.se>
 
-	* mini-gmp/mini-gmp.c (mpn_set_str_other): Always return size >=
-	1, with unnormalized result in the case the input digits are all
-	zero. Fixes crash on a large number of leading zeros, reported by
-	Axel Miller.
+	* mini-gmp.c (mpn_set_str_other): Always return size >= 1, with
+	unnormalized result in the case the input digits are all zero.
+	Fixes crash on a large number of leading zeros, reported by Axel
+	Miller.
 	(mpz_set_str): Normalize as needed, after above change. Return
 	failure for inputs string with no digits, i.e., empty except for
 	optional sign, base prefix and white space.
 
 2016-01-01 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c: Silence warnings due to (un)signed types.
-	* mini-gmp/tests/testutils.c: Likewise.
-	* mini-gmp/tests/t-logops.c: Likewise.
-	* mini-gmp/tests/t-cmp_d.c: Likewise.
-	* mini-gmp/tests/t-reuse.c: Likewise.
-	* mini-gmp/tests/t-cong.c: Likewise.
+	* mini-gmp.c: Silence warnings due to (un)signed types.
+	* tests/testutils.c: Likewise.
+	* tests/t-logops.c: Likewise.
+	* tests/t-cmp_d.c: Likewise.
+	* tests/t-reuse.c: Likewise.
+	* tests/t-cong.c: Likewise.
 
 2015-11-13 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c: Lazy allocation for mpz_t.
+	* mini-gmp.c: Lazy allocation for mpz_t.
 	(mpz_rootrem): Exploit lazy allocation to avoid init2.
 
 2015-11-06 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c (mpn_com, mpn_neg): New functions.
-	* mini-gmp/mini-gmp.h: Declare them.
-	* mini-gmp/mini-gmp.c (mpz_div_r_2exp): Use mpn_neg.
+	* mini-gmp.c (mpn_com, mpn_neg): New functions.
+	* mini-gmp.h: Declare them.
+	* mini-gmp.c (mpz_div_r_2exp): Use mpn_neg.
 
 2015-10-29 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c: Removed a typo (spotted by Paul Zimmermann).
+	* mini-gmp.c: Removed a typo (spotted by Paul Zimmermann).
 
 2015-05-30 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.h: Declare mpn_zero_p.
-	* mini-gmp/mini-gmp.c: Define mpn_zero_p as a function, not a macro.
+	* mini-gmp.h: Declare mpn_zero_p.
+	* mini-gmp.c: Define mpn_zero_p as a function, not a macro.
 
 2014-08-27  Niels Möller  <nisse at lysator.liu.se>
 
-	* mini-gmp/mini-gmp.c (mpz_abs_sub_bit): Do full normalization,
+	* mini-gmp.c (mpz_abs_sub_bit): Do full normalization,
 	needed if mpz_clrbit clears the most significant one bit.
 
 2014-07-28 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c: Remove some useless variables.
+	* mini-gmp.c: Remove some useless variables.
 
 2014-05-20 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c: +1 in the init2 argument before setbit.
+	* mini-gmp.c: +1 in the init2 argument before setbit.
 
 2014-05-15 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c: Micro-optimisations.
+	* mini-gmp.c: Micro-optimisations.
 
 2014-03-12 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c (mpz_probab_prime_p): Micro-optimisation.
+	* mini-gmp.c (mpz_probab_prime_p): Micro-optimisation.
 
 2014-03-06  Niels Möller  <nisse at lysator.liu.se>
 
-	* mini-gmp/mini-gmp.c (gmp_millerrabin): New internal function.
+	* mini-gmp.c (gmp_millerrabin): New internal function.
 	(mpz_probab_prime_p): New function.
-	* mini-gmp/mini-gmp.h (mpz_probab_prime_p): Declare it.
-	* mini-gmp/tests/t-pprime_p.c: New test program.
-	* mini-gmp/tests/Makefile (CHECK_PROGRAMS): Added t-pprime_p.
+	* mini-gmp.h (mpz_probab_prime_p): Declare it.
+	* tests/t-pprime_p.c: New test program.
+	* tests/Makefile (CHECK_PROGRAMS): Added t-pprime_p.
 
 2014-03-03  Niels Möller  <nisse at lysator.liu.se>
 
-	* mini-gmp/mini-gmp.c (mpz_congruent_p): New function.
-	* mini-gmp/mini-gmp.h: Declare it.
-	* mini-gmp/tests/t-cong.c: New file, based on tests/mpz/t-cong.c.
-	* mini-gmp/tests/Makefile (CHECK_PROGRAMS): Added t-cong.
+	* mini-gmp.c (mpz_congruent_p): New function.
+	* mini-gmp.h: Declare it.
+	* tests/t-cong.c: New file, based on tests/mpz/t-cong.c.
+	* tests/Makefile (CHECK_PROGRAMS): Added t-cong.
 
-	* mini-gmp/tests/testutils.c (dump): New function. Deleted static
+	* tests/testutils.c (dump): New function. Deleted static
 	functions in other files.
 	(mpz_set_str_or_abort): Moved function here, from...
-	* mini-gmp/tests/t-cmp_d.c: ... old location.
+	* tests/t-cmp_d.c: ... old location.
 
-	* mini-gmp/tests/t-reuse.c (dump3): Renamed, from ...
+	* tests/t-reuse.c (dump3): Renamed, from ...
 	(dump): ...old name.
 
 2014-02-21 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c (mpn_sqrtrem): New function.
-	* mini-gmp/mini-gmp.h: Declare it.
-	* mini-gmp/tests/t-sqrt.c: Test it.
+	* mini-gmp.c (mpn_sqrtrem): New function.
+	* mini-gmp.h: Declare it.
+	* tests/t-sqrt.c: Test it.
 
 2014-02-15 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c (mpz_div_qr): init + set = init_set .
+	* mini-gmp.c (mpz_div_qr): init + set = init_set .
 
 2014-02-10 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/tests/t-limbs.c: New test for mpz_limbs_*.
-	* mini-gmp/tests/Makefile (CHECK_PROGRAMS): Add it.
+	* tests/t-limbs.c: New test for mpz_limbs_*.
+	* tests/Makefile (CHECK_PROGRAMS): Add it.
 
 2014-02-08 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c (mpz_realloc2, mpz_limbs_read, mpz_limbs_modify
+	* mini-gmp.c (mpz_realloc2, mpz_limbs_read, mpz_limbs_modify
 	mpz_limbs_write, mpz_limbs_finish, mpz_roinit_n): New functions.
 	(mpn_perfect_square_p): New function.
-	* mini-gmp/mini-gmp.h: Declare them.
+	* mini-gmp.h: Declare them.
 
-	* mini-gmp/tests/t-mul.c: Use roinit and limbs_read to test mpn.
-	* mini-gmp/tests/t-sqrt.c: Test also mpn_perfect_square_p.
+	* tests/t-mul.c: Use roinit and limbs_read to test mpn.
+	* tests/t-sqrt.c: Test also mpn_perfect_square_p.
 
 2014-02-03 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c (mpn_rootrem): Allow NULL argument.
+	* mini-gmp.c (mpn_rootrem): Allow NULL argument.
 
-	* mini-gmp/mini-gmp.c (mpn_zero): New function.
+	* mini-gmp.c (mpn_zero): New function.
 	(mpz_perfect_square_p): New function.
-	* mini-gmp/mini-gmp.h: Declare them.
+	* mini-gmp.h: Declare them.
 
-	* mini-gmp/tests/t-sqrt.c: Test mpz_perfect_square_p.
-	* mini-gmp/tests/t-root.c: Test also 1-th root, allow perfect powers.
+	* tests/t-sqrt.c: Test mpz_perfect_square_p.
+	* tests/t-root.c: Test also 1-th root, allow perfect powers.
 
 2014-01-23 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/tests/t-aorsmul.c: New file, test for mpz_{add,sub}mul{,_ui}
-	* mini-gmp/tests/Makefile: Add t-aorsmul.
+	* tests/t-aorsmul.c: New file, test for mpz_{add,sub}mul{,_ui}
+	* tests/Makefile: Add t-aorsmul.
 
 2014-01-19 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c (mpn_popcount): New function.
+	* mini-gmp.c (mpn_popcount): New function.
 	(mpz_popcount): Use it.
 	(mpz_addmul_ui, mpz_addmul, mpz_submul_ui, mpz_submul): Added.
-	* mini-gmp/mini-gmp.h: Declare them.
+	* mini-gmp.h: Declare them.
 
 2014-01-16  Niels Möller  <nisse at lysator.liu.se>
 
-	* mini-gmp/mini-gmp.c (mp_bits_per_limb): New const value.
-	* mini-gmp/mini-gmp.h: Declare it.
+	* mini-gmp.c (mp_bits_per_limb): New const value.
+	* mini-gmp.h: Declare it.
 
 2013-03-13 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c: Write loops in a cleaner way.
+	* mini-gmp.c: Write loops in a cleaner way.
 
 2013-02-27 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c (mpz_div_q_2exp): Adjust only if needed.
+	* mini-gmp.c (mpz_div_q_2exp): Adjust only if needed.
 	(mpn_common_scan): New service function to unify scan loops.
 	(mpz_scan0, mpz_scan1): Simplify by using mpn_common_scan.
 	(mpz_make_odd): Simplify, assume in-place operation on positive.
 	(mpn_scan0, mpn_scan1): New functions.
-	* mini-gmp/mini-gmp.h (mpn_scan0, mpn_scan1): New declarations.
-	* mini-gmp/tests/t-scan.c: Test also mpn_scan0 and mpn_scan1.
+	* mini-gmp.h (mpn_scan0, mpn_scan1): New declarations.
+	* tests/t-scan.c: Test also mpn_scan0 and mpn_scan1.
 
 2013-02-25  Niels Möller  <nisse at lysator.liu.se>
 
-	* mini-gmp/tests/t-double.c (testmain): Declare double variables
-	as volatile, to drop extended precision.
+	* tests/t-double.c (testmain): Declare double variables as
+	volatile, to drop extended precision.
 
-	* mini-gmp/tests/testutils.c (testfree): New function. Use it
-	everywhere where test programs deallocate storage allocated via
-	the mini-gmp allocation functions, including uses of mpz_get_str
-	for various test failure messages.
+	* tests/testutils.c (testfree): New function. Use it everywhere
+	where test programs deallocate storage allocated via the mini-gmp
+	allocation functions, including uses of mpz_get_str for various
+	test failure messages.
 
 2013-02-19 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c: Move asserts to work-around a compiler bug.
+	* mini-gmp.c: Move asserts to work-around a compiler bug.
 	(mpz_export): Reorder branches.
 	(mpz_mul_ui): Avoid temporary allocation (mpn_mul_1 can work in-place).
 
-	* mini-gmp/tests/t-reuse.c: Fix typo causing the same negation
-	condition to be applied to all operands. (See 2013-02-03, Torbjorn)
+	* tests/t-reuse.c: Fix typo causing the same negation condition to
+	be applied to all operands. (See 2013-02-03, Torbjorn)
 
 2013-02-17 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c (mpz_mul): Read sizes just once.
+	* mini-gmp.c (mpz_mul): Read sizes just once.


More information about the gmp-commit mailing list