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

mercurial at gmplib.org mercurial at gmplib.org
Tue Nov 15 13:50:17 UTC 2016


details:   /var/hg/gmp/rev/cda0dda0a833
changeset: 17103:cda0dda0a833
user:      Torbjorn Granlund <tg at gmplib.org>
date:      Tue Nov 15 14:49:54 2016 +0100
description:
Separate out mini-gmp entries.

details:   /var/hg/gmp/rev/01388568886c
changeset: 17104:01388568886c
user:      Torbjorn Granlund <tg at gmplib.org>
date:      Tue Nov 15 14:50:04 2016 +0100
description:
Separate out mini-gmp entries.

diffstat:

 ChangeLog          |  403 --------------------------------------------
 mini-gmp/ChangeLog |  482 +++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 482 insertions(+), 403 deletions(-)

diffs (truncated from 1217 to 300 lines):

diff -r 56aa2e31fb8f -r 01388568886c ChangeLog
--- a/ChangeLog	Tue Nov 15 12:58:15 2016 +0100
+++ b/ChangeLog	Tue Nov 15 14:50:04 2016 +0100
@@ -1,7 +1,5 @@
 2016-11-01  Torbjörn Granlund  <tg at gmplib.org>
 
-	* mini-gmp/tests/hex-random.c: Reinstate gmp.h inclusion.
-
 	* mpn/generic/dive_1.c: Remove a forgotten dummy while-loop.  (Spotted
 	by Peter Barfuss.)
 
@@ -62,16 +60,6 @@
 	* longlong.h (umul_ppmm from __umulsidi3): Protect with do ...
 	while (0).
 
-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.
-	(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-06-02  Torbjörn Granlund  <tg at gmplib.org>
 	    Vincent Lefevre <vincent at vinc17.net>
 
@@ -163,12 +151,6 @@
 	* mpz/primorial_ui.c (LOOP_ON_SIEVE_CONTINUE): Define prime locally.
 
 	* gen-fac.c: Use unsigned types for sizes.
-	* mini-gmp/mini-gmp.c: Silence wanrings 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.
 
 	* mpn/generic/invert.c: Use MPN_FILL macro.
 	* mpn/generic/invertappr.c: Likewise.
@@ -248,10 +230,6 @@
 
 2015-11-13 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c: Lazy allocation for mpz_t.
-	(mpz_rootrem): Exploit lazy allocation to avoid init2.
-	* mpz/set.c: Use MPZ_NEWALLOC.
-
 	* mpq/init.c: Remove conditional code for __CHECKER__.
 	* mpq/set.c: Shorten scope of local variables.
 	* mpq/set_den.c: Likewise.
@@ -337,10 +315,6 @@
 	* mpz/iset.c: Likewise.
 	* mpz/iset_str.c: Likewise.
 
-	* 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.
-
 2015-11-04  Torbjörn Granlund  <torbjorng at google.com>
 
 	* mpz/xor.c: Use MPZ_REALLOC.
@@ -377,7 +351,6 @@
 	* demos/perl/GMP.xs: Likewise.
 	* tests/mpf/t-pow_ui.c: Use reference value to check the size.
 
-	* mini-gmp/mini-gmp.c: Removed a typo (spotted by Paul Zimmermann).
 	* doc/gmp.texi (Floating-point): Remove "infinite precision" claim.
 
 	* gmp-h.in: Update version.
@@ -763,9 +736,6 @@
 	* tests/mpn/t-div.c: Likewise.
 	* tests/mpn/t-minvert.c: Likewise.
 
-	* mini-gmp/mini-gmp.h: Declare mpn_zero_p.
-	* mini-gmp/mini-gmp.c: Define mpn_zero_p as a function, not a macro.
-
 2015-05-28  Niels Möller  <nisse at lysator.liu.se>
 
 	* doc/gmp.texi (Low-level Functions): Document mpn_divexact_1 and
@@ -1124,11 +1094,6 @@
 
 	* mpn/arm64/mod_34lsub1.asm: New file.
 
-2014-08-27  Niels Möller  <nisse at lysator.liu.se>
-
-	* mini-gmp/mini-gmp.c (mpz_abs_sub_bit): Do full normalization,
-	needed if mpz_clrbit clears the most significant one bit.
-
 2014-08-23  Torbjörn Granlund  <tege at gmplib.org>
 
 	* mpn/arm64/bdiv_dbm1c.asm: New file.
@@ -1165,8 +1130,6 @@
 
 	* tests/mpf/t-fits.c: use ui_sub instead of sub_ui+neg.
 
-	* mini-gmp/mini-gmp.c: Remove some useless variables.
-
 2014-07-27  Torbjörn Granlund  <tege at gmplib.org>
 
 	* mpn/x86/k7/gcd_1.asm: Use LEAL.
@@ -1307,7 +1270,6 @@
 
 	* gen-fac.c: +1 in the init2 argument before setbit.
 	* gen-fib.c: Likewise. (Thanks Niels)
-	* mini-gmp/mini-gmp.c: Likewise.
 	* rand/randmts.c: Likewise.
 
 	* mpn/generic/invert.c: Remove unused TMP_MARK.
@@ -1316,8 +1278,6 @@
 
 2014-05-15 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
-	* mini-gmp/mini-gmp.c: Micro-optimisations.
-
 	* gen-fib.c: Use mpz_setbit.
 	* gen-psqr.c: Skip even numbers when looking for primes.
 
@@ -1408,10 +1368,6 @@
 	* mpn/Makefile.am (TARG_DIST): Purge removed directories.
 	* doc/gmp.texi: Remove special mentions of removed architectures.
 
-2014-03-12 Marco Bodrato <bodrato at mail.dm.unipi.it>
-
-	* mini-gmp/mini-gmp.c (mpz_probab_prime_p): Micro-optimisation.
-
 2014-03-12  Torbjorn Granlund  <tege at gmplib.org>
 
 	* mpn/x86/bd2/gmp-mparam.h: New file.
@@ -1423,27 +1379,6 @@
 	(check_primes): New function.
 	(main): Call them. Also use TESTS_REPS.
 
-	* mini-gmp/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.
-
-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/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.
-
-	* mini-gmp/tests/t-reuse.c (dump3): Renamed, from ...
-	(dump): ...old name.
-
 2014-03-01  Niels Möller  <nisse at lysator.liu.se>
 
 	* mpn/generic/sec_powm.c (mpn_sec_powm): Clarify comment and
@@ -1466,12 +1401,6 @@
 	(x86 cpuid, 2 variants): Zero ecx for the benefit of new BMI2 feature
 	test.
 
-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.
-
 2014-02-17  Niels Möller  <nisse at lysator.liu.se>
 
 	* mpn/generic/div_qr_1.c (mpn_div_qr_1): Revert yesterday's fix.
@@ -1495,7 +1424,6 @@
 
 	* doc/gmp.texi (mpz_roinit_n, MPZ_ROINIT_N): Document that
 	at least a readable limb is required.
-	* mini-gmp/mini-gmp.c (mpz_div_qr): init + set = init_set .
 
 2014-02-14  Niels Möller  <nisse at lysator.liu.se>
 
@@ -1520,11 +1448,6 @@
 	* tune/tuneup.c (tune_powm_sec): Likewise. Also deleted code
 	fiddling with the high exponent bits.
 
-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.
-
 2014-02-09  Niels Möller  <nisse at lysator.liu.se>
 
 	* tune/tuneup.c (tune_powm_sec): Avoid timing of the nonsensical
@@ -1536,16 +1459,6 @@
 	(mpn_sec_powm): Deleted handling of winsize > initial ebi. For
 	now, replaced with an ASSERT_ALWAYS.
 
-2014-02-08 Marco Bodrato <bodrato at mail.dm.unipi.it>
-
-	* mini-gmp/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/tests/t-mul.c: Use roinit and limbs_read to test mpn.
-	* mini-gmp/tests/t-sqrt.c: Test also mpn_perfect_square_p.
-
 2014-02-08  Niels Möller  <nisse at lysator.liu.se>
 
 	* mpn/generic/sec_invert.c (mpn_cnd_neg_itch): #if:ed out unused
@@ -1561,17 +1474,6 @@
 	* doc/gmp.texi (Low-level Functions): Document mpn_sec_add_1 and
 	mpn_sec_sub_1.
 
-2014-02-03 Marco Bodrato <bodrato at mail.dm.unipi.it>
-
-	* mini-gmp/mini-gmp.c (mpn_rootrem): Allow NULL argument.
-
-	* mini-gmp/mini-gmp.c (mpn_zero): New function.
-	(mpz_perfect_square_p): New function.
-	* mini-gmp/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.
-
 2014-01-29  Torbjorn Granlund  <tege at gmplib.org>
 
 	* doc/gmp.texi (Floating-point Functions): Revise.
@@ -1617,9 +1519,6 @@
 	* printf/repl-vsnprintf.c: Feed case 'z' in switch (type) with case 'z'
 	in switch (fchar).
 
-	* mini-gmp/tests/t-aorsmul.c: New file, test for mpz_{add,sub}mul{,_ui}
-	* mini-gmp/tests/Makefile: Add t-aorsmul.
-
 2014-01-21 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
 	* acinclude.m4 (GMP_FUNC_VSNPRINTF): Get rid of varargs.
@@ -1677,13 +1576,6 @@
 	* mpz/clear.c: Add cast to avoid overflow of (later ignored) argument.
 	* mpf/clear.c: Likewise.
 
-2014-01-19 Marco Bodrato <bodrato at mail.dm.unipi.it>
-
-	* mini-gmp/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.
-
 2014-01-18  Niels Möller  <nisse at lysator.liu.se>
 
 	* tests/mpn/t-aors_1.c: Test also mpn_sec_add_1 and mpn_sec_sub_1.
@@ -1719,9 +1611,6 @@
 	(SPEED_ROUTINE_MPN_SEC_MINVERT): New macro.
 	* tune/speed.c (routine): Added mpn_sec_minvert.
 
-	* mini-gmp/mini-gmp.c (mp_bits_per_limb): New const value.
-	* mini-gmp/mini-gmp.h: Declare it.
-
 2014-01-12  Marc Glisse  <marc.glisse at inria.fr>
 
 	* demos/expr/expr.h: Add extern "C" for C++.
@@ -3018,7 +2907,6 @@
 2013-03-13 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
 	* mpz/cong_2exp.c: Write loops in a cleaner way.
-	* mini-gmp/mini-gmp.c: Likewise.
 	* gmp-impl.h (mpz_zero_p): Likewise.
 
 2013-03-12  Niels Möller  <nisse at lysator.liu.se>
@@ -3185,16 +3073,6 @@
 	* tune/common.c (speed_measure): Increase repetition count if we
 	get a zero measurement.
 
-2013-02-27 Marco Bodrato <bodrato at mail.dm.unipi.it>
-
-	* mini-gmp/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.
-
 2013-02-26  Niels Möller  <nisse at lysator.liu.se>
 
 	* tests/mpz/t-limbs.c (check_roinit): Test MPZ_ROINIT_N only if
@@ -3202,14 +3080,6 @@
 
 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.
-
-	* 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.
-
 	* mpz/limbs_finish.c (mpz_limbs_finish): New file and function.
 	* mpz/limbs_modify.c (mpz_limbs_modify): New file and function.
 	* mpz/limbs_read.c (mpz_limbs_read): New file and function.


More information about the gmp-commit mailing list