Annotation of OpenXM/src/gmp/gmp.diff, Revision 1.1
1.1 ! ohara 1: # $OpenXM$
! 2: diff -ubB mpn/generic/addsub_n.c.orig mpn/generic/addsub_n.c
! 3: --- mpn/generic/addsub_n.c.orig 2006-03-15 00:57:54.000000000 +0900
! 4: +++ mpn/generic/addsub_n.c 2007-04-04 01:20:05.000000000 +0900
! 5: @@ -58,13 +58,13 @@
! 6: for (off = 0; off < n; off += PART_SIZE)
! 7: {
! 8: this_n = MIN (n - off, PART_SIZE);
! 9: -#if HAVE_NATIVE_mpn_add_nc || !HAVE_NATIVE_mpn_add_n
! 10: +#if HAVE_NATIVE_mpn_add_nc
! 11: acyo = mpn_add_nc (r1p + off, s1p + off, s2p + off, this_n, acyo);
! 12: #else
! 13: acyn = mpn_add_n (r1p + off, s1p + off, s2p + off, this_n);
! 14: acyo = acyn + mpn_add_1 (r1p + off, r1p + off, this_n, acyo);
! 15: #endif
! 16: -#if HAVE_NATIVE_mpn_sub_nc || !HAVE_NATIVE_mpn_sub_n
! 17: +#if HAVE_NATIVE_mpn_sub_nc
! 18: scyo = mpn_sub_nc (r2p + off, s1p + off, s2p + off, this_n, scyo);
! 19: #else
! 20: scyn = mpn_sub_n (r2p + off, s1p + off, s2p + off, this_n);
! 21: @@ -81,13 +81,13 @@
! 22: for (off = 0; off < n; off += PART_SIZE)
! 23: {
! 24: this_n = MIN (n - off, PART_SIZE);
! 25: -#if HAVE_NATIVE_mpn_sub_nc || !HAVE_NATIVE_mpn_sub_n
! 26: +#if HAVE_NATIVE_mpn_sub_nc
! 27: scyo = mpn_sub_nc (r2p + off, s1p + off, s2p + off, this_n, scyo);
! 28: #else
! 29: scyn = mpn_sub_n (r2p + off, s1p + off, s2p + off, this_n);
! 30: scyo = scyn + mpn_sub_1 (r2p + off, r2p + off, this_n, scyo);
! 31: #endif
! 32: -#if HAVE_NATIVE_mpn_add_nc || !HAVE_NATIVE_mpn_add_n
! 33: +#if HAVE_NATIVE_mpn_add_nc
! 34: acyo = mpn_add_nc (r1p + off, s1p + off, s2p + off, this_n, acyo);
! 35: #else
! 36: acyn = mpn_add_n (r1p + off, s1p + off, s2p + off, this_n);
! 37: @@ -105,13 +105,13 @@
! 38: for (off = 0; off < n; off += PART_SIZE)
! 39: {
! 40: this_n = MIN (n - off, PART_SIZE);
! 41: -#if HAVE_NATIVE_mpn_add_nc || !HAVE_NATIVE_mpn_add_n
! 42: +#if HAVE_NATIVE_mpn_add_nc
! 43: acyo = mpn_add_nc (tp, s1p + off, s2p + off, this_n, acyo);
! 44: #else
! 45: acyn = mpn_add_n (tp, s1p + off, s2p + off, this_n);
! 46: acyo = acyn + mpn_add_1 (tp, tp, this_n, acyo);
! 47: #endif
! 48: -#if HAVE_NATIVE_mpn_sub_nc || !HAVE_NATIVE_mpn_sub_n
! 49: +#if HAVE_NATIVE_mpn_sub_nc
! 50: scyo = mpn_sub_nc (r2p + off, s1p + off, s2p + off, this_n, scyo);
! 51: #else
! 52: scyn = mpn_sub_n (r2p + off, s1p + off, s2p + off, this_n);
! 53: diff -ubB mpz/set_d.c.orig mpz/set_d.c
! 54: --- mpz/set_d.c.orig 2006-03-15 00:57:54.000000000 +0900
! 55: +++ mpz/set_d.c 2007-04-04 01:19:53.000000000 +0900
! 56: @@ -56,6 +56,9 @@
! 57: if (ALLOC(r) < rn)
! 58: _mpz_realloc (r, rn);
! 59:
! 60: + if (rn <= 0)
! 61: + rn = 0;
! 62: +
! 63: rp = PTR (r);
! 64:
! 65: switch (rn)
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>