diff options
author | Kevin Ryde <user42@zip.com.au> | 2000-10-21 22:36:48 +0200 |
---|---|---|
committer | Kevin Ryde <user42@zip.com.au> | 2000-10-21 22:36:48 +0200 |
commit | 1cf82e91f12d15c42480287ffd8a0129b9115809 (patch) | |
tree | fcaf322e0548a64c9164126830268b7be8cf4fd1 | |
parent | 5053c1ea781951ac68dfd0576e01028ec8bbcbd0 (diff) | |
download | gmp-1cf82e91f12d15c42480287ffd8a0129b9115809.tar.gz |
* * (__gmp_allocate_func etc): Rename from _mp_allocate_func etc.
(__gmp_default_allocate etc): Rename from _mp_default_allocate etc.
56 files changed, 121 insertions, 121 deletions
@@ -30,10 +30,10 @@ MA 02111-1307, USA. */ #endif -void * (*_mp_allocate_func) _PROTO ((size_t)) = _mp_default_allocate; -void * (*_mp_reallocate_func) _PROTO ((void *, size_t, size_t)) - = _mp_default_reallocate; -void (*_mp_free_func) _PROTO ((void *, size_t)) = _mp_default_free; +void * (*__gmp_allocate_func) _PROTO ((size_t)) = __gmp_default_allocate; +void * (*__gmp_reallocate_func) _PROTO ((void *, size_t, size_t)) + = __gmp_default_reallocate; +void (*__gmp_free_func) _PROTO ((void *, size_t)) = __gmp_default_free; /* Default allocation functions. In case of failure to allocate/reallocate @@ -41,9 +41,9 @@ void (*_mp_free_func) _PROTO ((void *, size_t)) = _mp_default_free; void * #if __STDC__ -_mp_default_allocate (size_t size) +__gmp_default_allocate (size_t size) #else -_mp_default_allocate (size) +__gmp_default_allocate (size) size_t size; #endif { @@ -74,9 +74,9 @@ _mp_default_allocate (size) void * #if __STDC__ -_mp_default_reallocate (void *oldptr, size_t old_size, size_t new_size) +__gmp_default_reallocate (void *oldptr, size_t old_size, size_t new_size) #else -_mp_default_reallocate (oldptr, old_size, new_size) +__gmp_default_reallocate (oldptr, old_size, new_size) void *oldptr; size_t old_size; size_t new_size; @@ -129,9 +129,9 @@ _mp_default_reallocate (oldptr, old_size, new_size) void #if __STDC__ -_mp_default_free (void *blk_ptr, size_t blk_size) +__gmp_default_free (void *blk_ptr, size_t blk_size) #else -_mp_default_free (blk_ptr, blk_size) +__gmp_default_free (blk_ptr, blk_size) void *blk_ptr; size_t blk_size; #endif diff --git a/mp_set_fns.c b/mp_set_fns.c index c070644e0..2744047bf 100644 --- a/mp_set_fns.c +++ b/mp_set_fns.c @@ -36,13 +36,13 @@ mp_set_memory_functions (alloc_func, realloc_func, free_func) #endif { if (alloc_func == 0) - alloc_func = _mp_default_allocate; + alloc_func = __gmp_default_allocate; if (realloc_func == 0) - realloc_func = _mp_default_reallocate; + realloc_func = __gmp_default_reallocate; if (free_func == 0) - free_func = _mp_default_free; + free_func = __gmp_default_free; - _mp_allocate_func = alloc_func; - _mp_reallocate_func = realloc_func; - _mp_free_func = free_func; + __gmp_allocate_func = alloc_func; + __gmp_reallocate_func = realloc_func; + __gmp_free_func = free_func; } diff --git a/mpbsd/itom.c b/mpbsd/itom.c index f91006146..11e6ac0ff 100644 --- a/mpbsd/itom.c +++ b/mpbsd/itom.c @@ -34,9 +34,9 @@ itom (n) MINT *x; mp_ptr xp; - x = (MINT *) (*_mp_allocate_func) (sizeof (MINT)); + x = (MINT *) (*__gmp_allocate_func) (sizeof (MINT)); x->_mp_alloc = 1; - x->_mp_d = xp = (mp_ptr) (*_mp_allocate_func) (BYTES_PER_MP_LIMB); + x->_mp_d = xp = (mp_ptr) (*__gmp_allocate_func) (BYTES_PER_MP_LIMB); if (n > 0) { x->_mp_size = 1; diff --git a/mpbsd/mfree.c b/mpbsd/mfree.c index 71fe5769e..72b0e927f 100644 --- a/mpbsd/mfree.c +++ b/mpbsd/mfree.c @@ -31,6 +31,6 @@ mfree (m) MINT *m; #endif { - (*_mp_free_func) (m->_mp_d, m->_mp_alloc * BYTES_PER_MP_LIMB); - (*_mp_free_func) (m, sizeof (MINT)); + (*__gmp_free_func) (m->_mp_d, m->_mp_alloc * BYTES_PER_MP_LIMB); + (*__gmp_free_func) (m, sizeof (MINT)); } diff --git a/mpbsd/min.c b/mpbsd/min.c index 6b2228bca..3a9a35383 100644 --- a/mpbsd/min.c +++ b/mpbsd/min.c @@ -66,7 +66,7 @@ min (dest) mp_size_t dest_size; alloc_size = 100; - str = (char *) (*_mp_allocate_func) (alloc_size); + str = (char *) (*__gmp_allocate_func) (alloc_size); str_size = 0; /* Skip whitespace. */ @@ -91,7 +91,7 @@ min (dest) { size_t old_alloc_size = alloc_size; alloc_size = alloc_size * 3 / 2; - str = (char *) (*_mp_reallocate_func) (str, old_alloc_size, alloc_size); + str = (char *) (*__gmp_reallocate_func) (str, old_alloc_size, alloc_size); } dig = digit_value_in_base (c, 10); if (dig < 0) @@ -109,6 +109,6 @@ min (dest) dest_size = mpn_set_str (dest->_mp_d, (unsigned char *) str, str_size, 10); dest->_mp_size = negative ? -dest_size : dest_size; - (*_mp_free_func) (str, alloc_size); + (*__gmp_free_func) (str, alloc_size); return; } diff --git a/mpbsd/mtox.c b/mpbsd/mtox.c index 554fa36ac..e01de3dfa 100644 --- a/mpbsd/mtox.c +++ b/mpbsd/mtox.c @@ -43,7 +43,7 @@ mtox (x) if (xsize == 0) { - str = (unsigned char *) (*_mp_allocate_func) (2); + str = (unsigned char *) (*__gmp_allocate_func) (2); str[0] = '0'; str[1] = 0; return (char *) str; @@ -55,7 +55,7 @@ mtox (x) TMP_MARK (marker); str_size = ((size_t) (xsize * BITS_PER_MP_LIMB * __mp_bases[16].chars_per_bit_exactly)) + 3; - str = (unsigned char *) (*_mp_allocate_func) (str_size); + str = (unsigned char *) (*__gmp_allocate_func) (str_size); s = str; if (xsign < 0) diff --git a/mpbsd/xtom.c b/mpbsd/xtom.c index f0b8b9808..baa45e6c2 100644 --- a/mpbsd/xtom.c +++ b/mpbsd/xtom.c @@ -65,7 +65,7 @@ xtom (str) mp_size_t xsize; int c; int negative; - MINT *x = (MINT *) (*_mp_allocate_func) (sizeof (MINT)); + MINT *x = (MINT *) (*__gmp_allocate_func) (sizeof (MINT)); TMP_DECL (marker); /* Skip whitespace. */ @@ -106,7 +106,7 @@ xtom (str) xsize = str_size / __mp_bases[16].chars_per_limb + 1; x->_mp_alloc = xsize; - x->_mp_d = (mp_ptr) (*_mp_allocate_func) (xsize * BYTES_PER_MP_LIMB); + x->_mp_d = (mp_ptr) (*__gmp_allocate_func) (xsize * BYTES_PER_MP_LIMB); xsize = mpn_set_str (x->_mp_d, (unsigned char *) begs, str_size, 16); x->_mp_size = negative ? -xsize : xsize; diff --git a/mpf/clear.c b/mpf/clear.c index 9e74153ab..a81b4d55e 100644 --- a/mpf/clear.c +++ b/mpf/clear.c @@ -31,5 +31,5 @@ mpf_clear (m) mpf_ptr m; #endif { - (*_mp_free_func) (m->_mp_d, (m->_mp_prec + 1) * BYTES_PER_MP_LIMB); + (*__gmp_free_func) (m->_mp_d, (m->_mp_prec + 1) * BYTES_PER_MP_LIMB); } diff --git a/mpf/dump.c b/mpf/dump.c index a4fadcc7a..9f026ecd3 100644 --- a/mpf/dump.c +++ b/mpf/dump.c @@ -44,5 +44,5 @@ mpf_dump (u) printf ("-0.%se%ld\n", str + 1, exp); else printf ("0.%se%ld\n", str, exp); - (*_mp_free_func) (str, 0);/* ??? broken alloc interface, pass what size ??? */ + (*__gmp_free_func) (str, 0);/* ??? broken alloc interface, pass what size ??? */ } diff --git a/mpf/get_str.c b/mpf/get_str.c index e2a1601a3..e989c326a 100644 --- a/mpf/get_str.c +++ b/mpf/get_str.c @@ -107,7 +107,7 @@ mpf_get_str (digit_ptr, exp, base, n_digits, u) { /* We didn't get a string from the user. Allocate one (and return a pointer to it) with space for `-' and terminating null. */ - digit_ptr = (char *) (*_mp_allocate_func) (n_digits + 2); + digit_ptr = (char *) (*__gmp_allocate_func) (n_digits + 2); } if (usize == 0) diff --git a/mpf/init.c b/mpf/init.c index 7111993e5..d5c12f354 100644 --- a/mpf/init.c +++ b/mpf/init.c @@ -31,7 +31,7 @@ mpf_init (r) #endif { mp_size_t prec = __gmp_default_fp_limb_precision; - r->_mp_d = (mp_ptr) (*_mp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); + r->_mp_d = (mp_ptr) (*__gmp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); r->_mp_prec = prec; r->_mp_size = 0; r->_mp_exp = 0; diff --git a/mpf/init2.c b/mpf/init2.c index a21c61a51..1b2744a27 100644 --- a/mpf/init2.c +++ b/mpf/init2.c @@ -34,7 +34,7 @@ mpf_init2 (r, prec_in_bits) mp_size_t prec; prec = (MAX (53, prec_in_bits) + 2 * BITS_PER_MP_LIMB - 1)/BITS_PER_MP_LIMB; - r->_mp_d = (mp_ptr) (*_mp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); + r->_mp_d = (mp_ptr) (*__gmp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); r->_mp_prec = prec; r->_mp_size = 0; r->_mp_exp = 0; diff --git a/mpf/inp_str.c b/mpf/inp_str.c index 7d9625b21..4e959f58c 100644 --- a/mpf/inp_str.c +++ b/mpf/inp_str.c @@ -45,7 +45,7 @@ mpf_inp_str (rop, stream, base) stream = stdin; alloc_size = 100; - str = (char *) (*_mp_allocate_func) (alloc_size); + str = (char *) (*__gmp_allocate_func) (alloc_size); str_size = 0; nread = 0; @@ -63,7 +63,7 @@ mpf_inp_str (rop, stream, base) { size_t old_alloc_size = alloc_size; alloc_size = alloc_size * 3 / 2; - str = (char *) (*_mp_reallocate_func) (str, old_alloc_size, alloc_size); + str = (char *) (*__gmp_reallocate_func) (str, old_alloc_size, alloc_size); } if (c == EOF || isspace (c)) break; @@ -76,7 +76,7 @@ mpf_inp_str (rop, stream, base) { size_t old_alloc_size = alloc_size; alloc_size = alloc_size * 3 / 2; - str = (char *) (*_mp_reallocate_func) (str, old_alloc_size, alloc_size); + str = (char *) (*__gmp_reallocate_func) (str, old_alloc_size, alloc_size); } str[str_size] = 0; @@ -84,6 +84,6 @@ mpf_inp_str (rop, stream, base) if (retval == -1) return 0; /* error */ - (*_mp_free_func) (str, alloc_size); + (*__gmp_free_func) (str, alloc_size); return str_size + nread; } diff --git a/mpf/iset.c b/mpf/iset.c index f72846d5c..b5f4d37c9 100644 --- a/mpf/iset.c +++ b/mpf/iset.c @@ -36,7 +36,7 @@ mpf_init_set (r, s) mp_size_t prec; prec = __gmp_default_fp_limb_precision; - r->_mp_d = (mp_ptr) (*_mp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); + r->_mp_d = (mp_ptr) (*__gmp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); r->_mp_prec = prec; prec++; /* lie not to lose precision in assignment */ diff --git a/mpf/iset_d.c b/mpf/iset_d.c index 5a4cfecbf..77a26ae95 100644 --- a/mpf/iset_d.c +++ b/mpf/iset_d.c @@ -32,7 +32,7 @@ mpf_init_set_d (r, val) #endif { mp_size_t prec = __gmp_default_fp_limb_precision; - r->_mp_d = (mp_ptr) (*_mp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); + r->_mp_d = (mp_ptr) (*__gmp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); r->_mp_prec = prec; mpf_set_d (r, val); diff --git a/mpf/iset_si.c b/mpf/iset_si.c index 993eef6e5..02c9ce635 100644 --- a/mpf/iset_si.c +++ b/mpf/iset_si.c @@ -32,7 +32,7 @@ mpf_init_set_si (r, val) #endif { mp_size_t prec = __gmp_default_fp_limb_precision; - r->_mp_d = (mp_ptr) (*_mp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); + r->_mp_d = (mp_ptr) (*__gmp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); r->_mp_prec = prec; if (val > 0) diff --git a/mpf/iset_str.c b/mpf/iset_str.c index fba94be30..99301fa0c 100644 --- a/mpf/iset_str.c +++ b/mpf/iset_str.c @@ -33,7 +33,7 @@ mpf_init_set_str (r, s, base) #endif { mp_size_t prec = __gmp_default_fp_limb_precision; - r->_mp_d = (mp_ptr) (*_mp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); + r->_mp_d = (mp_ptr) (*__gmp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); r->_mp_prec = prec; r->_mp_size = 0; r->_mp_exp = 0; diff --git a/mpf/iset_ui.c b/mpf/iset_ui.c index f33c02c80..13f7afb20 100644 --- a/mpf/iset_ui.c +++ b/mpf/iset_ui.c @@ -32,7 +32,7 @@ mpf_init_set_ui (r, val) #endif { mp_size_t prec = __gmp_default_fp_limb_precision; - r->_mp_d = (mp_ptr) (*_mp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); + r->_mp_d = (mp_ptr) (*__gmp_allocate_func) ((prec + 1) * BYTES_PER_MP_LIMB); r->_mp_prec = prec; r->_mp_d[0] = val; r->_mp_size = val != 0; diff --git a/mpf/set_prc.c b/mpf/set_prc.c index 70a6aa141..aa67e7cf9 100644 --- a/mpf/set_prc.c +++ b/mpf/set_prc.c @@ -46,7 +46,7 @@ mpf_set_prec (x, prec_in_bits) MPN_COPY_INCR (xp, xp + offset, prec + 1); } - x->_mp_d = (mp_ptr) (*_mp_reallocate_func) + x->_mp_d = (mp_ptr) (*__gmp_reallocate_func) (x->_mp_d, (x->_mp_prec + 1) * BYTES_PER_MP_LIMB, (prec + 1) * BYTES_PER_MP_LIMB); x->_mp_prec = prec; diff --git a/mpf/tests/t-conv.c b/mpf/tests/t-conv.c index 23597de94..960184b4c 100644 --- a/mpf/tests/t-conv.c +++ b/mpf/tests/t-conv.c @@ -84,7 +84,7 @@ main (argc, argv) sprintf (buf, "0.%s@%ld", str, bexp); MPF_SET_STR_OR_ABORT (y, buf, -base); - (*_mp_free_func) (str, 0); + (*__gmp_free_func) (str, 0); mpf_reldiff (rerr, x, y); if (mpf_cmp (rerr, max_rerr) > 0) diff --git a/mpfr/clear.c b/mpfr/clear.c index 371c1a766..dfa4771c5 100644 --- a/mpfr/clear.c +++ b/mpfr/clear.c @@ -32,5 +32,5 @@ mpfr_clear (m) mpfr_ptr m; #endif { - (*_mp_free_func) (m->_mp_d, ((m->_mp_prec>>3) + 1)); + (*__gmp_free_func) (m->_mp_d, ((m->_mp_prec>>3) + 1)); } diff --git a/mpfr/get_str.c b/mpfr/get_str.c index e100b300e..7cd7d5d00 100644 --- a/mpfr/get_str.c +++ b/mpfr/get_str.c @@ -60,7 +60,7 @@ char *mpfr_get_str(str, expptr, base, n, op, rnd_mode) neg = (SIGN(op)<0) ? 1 : 0; if (!NOTZERO(op)) { - if (str==NULL) str0=str=(*_mp_allocate_func)(neg + n + 2); + if (str==NULL) str0=str=(*__gmp_allocate_func)(neg + n + 2); if (SIGN(op)<0) *str++ = '-'; for (f=0;f<n;f++) *str++ = '0'; *expptr = 1; @@ -196,7 +196,7 @@ char *mpfr_get_str(str, expptr, base, n, op, rnd_mode) /* computes the number of characters needed */ q = neg + n + 2; /* n+1 may not be enough for 100000... */ - if (str==NULL) str0=str=(*_mp_allocate_func)(q); + if (str==NULL) str0=str=(*__gmp_allocate_func)(q); if (neg) *str++='-'; mpz_get_str(str, base, bz); /* n digits of mantissa */ if (strlen(str)==n+1) f++; /* possible due to rounding */ diff --git a/mpfr/init.c b/mpfr/init.c index e416511c7..37f03536c 100644 --- a/mpfr/init.c +++ b/mpfr/init.c @@ -42,7 +42,7 @@ mpfr_init2 (x, p) xsize = (p - 1)/BITS_PER_MP_LIMB + 1; x -> _mp_prec = p; - x -> _mp_d = (mp_ptr) (*_mp_allocate_func) + x -> _mp_d = (mp_ptr) (*__gmp_allocate_func) (xsize * BYTES_PER_MP_LIMB); x -> _mp_size = xsize; x -> _mp_exp = 0; /* avoids uninitialized memory reads for zero */ diff --git a/mpfr/mpfr.h b/mpfr/mpfr.h index 9f25eba2f..78034affb 100644 --- a/mpfr/mpfr.h +++ b/mpfr/mpfr.h @@ -102,7 +102,7 @@ typedef __gmp_const __mpfr_struct *mpfr_srcptr; /* reallocates the mantissa of x to q bits and sets the precision to q */ #define _mpfr_realloc(x, q) { \ - (x)->_mp_d = (mp_ptr) (*_mp_reallocate_func) \ + (x)->_mp_d = (mp_ptr) (*__gmp_reallocate_func) \ ((x)->_mp_d, (x)->_mp_prec>>3 + 1, (q)>>3 + 1); \ (x)->_mp_prec = q; } diff --git a/mpfr/out_str.c b/mpfr/out_str.c index aeaf64bd2..d6221776b 100644 --- a/mpfr/out_str.c +++ b/mpfr/out_str.c @@ -60,6 +60,6 @@ mpfr_out_str (stream, base, n_digits, op, rnd_mode) fprintf(stream, "%s", s); } - (*_mp_free_func)(s0, l); + (*__gmp_free_func)(s0, l); return l; } diff --git a/mpfr/set_prec.c b/mpfr/set_prec.c index d85eac3c3..418efe8eb 100644 --- a/mpfr/set_prec.c +++ b/mpfr/set_prec.c @@ -42,7 +42,7 @@ mpfr_set_prec (x, p) xsize = (p - 1)/BITS_PER_MP_LIMB + 1; /* new limb size */ if (xsize > ABSSIZE(x)) { - x -> _mp_d = (mp_ptr) (*_mp_reallocate_func) + x -> _mp_d = (mp_ptr) (*__gmp_reallocate_func) (x -> _mp_d, ABSSIZE(x)*BYTES_PER_MP_LIMB, xsize * BYTES_PER_MP_LIMB); SIZE(x) = xsize; /* new number of allocated limbs */ } diff --git a/mpn/generic/mul_fft.c b/mpn/generic/mul_fft.c index e34c23189..af8c2e2fd 100644 --- a/mpn/generic/mul_fft.c +++ b/mpn/generic/mul_fft.c @@ -675,7 +675,7 @@ mpn_mul_fft (op, pl, n, nl, m, ml, k) pl,pl,K,nprime,nprime,2.0*(double)N/Nprime/K); printf(" temp space %ld\n", 2*K*(nprime+1))); - A = _MP_ALLOCATE_FUNC_LIMBS (2*K*(nprime+1)); + A = __GMP_ALLOCATE_FUNC_LIMBS (2*K*(nprime+1)); B = A+K*(nprime+1); Ap = TMP_ALLOC_MP_PTRS (K); Bp = TMP_ALLOC_MP_PTRS (K); @@ -703,7 +703,7 @@ mpn_mul_fft (op, pl, n, nl, m, ml, k) } mpn_mul_fft_internal(op,n,m,pl,k,K,Ap,Bp,A,B,nprime,l,Mp,_fft_l,T,0); TMP_FREE(marker); - _MP_FREE_FUNC_LIMBS (A, 2*K*(nprime+1)); + __GMP_FREE_FUNC_LIMBS (A, 2*K*(nprime+1)); } @@ -737,11 +737,11 @@ mpn_mul_fft_full (op, n, nl, m, ml) TRACE (printf ("mpn_mul_fft_full nl=%ld ml=%ld -> pl=%ld k=%d\n", nl, ml, pl, k)); - pad_op = _MP_ALLOCATE_FUNC_LIMBS (pl+1); + pad_op = __GMP_ALLOCATE_FUNC_LIMBS (pl+1); mpn_mul_fft (pad_op, pl, n, nl, m, ml, k); ASSERT (mpn_zero_p (pad_op+nl+ml, pl+1-(nl+ml))); MPN_COPY (op, pad_op, nl+ml); - _MP_FREE_FUNC_LIMBS (pad_op, pl+1); + __GMP_FREE_FUNC_LIMBS (pad_op, pl+1); } diff --git a/mpn/generic/mul_n.c b/mpn/generic/mul_n.c index 5bece91e7..e314ddd23 100644 --- a/mpn/generic/mul_n.c +++ b/mpn/generic/mul_n.c @@ -1326,9 +1326,9 @@ mpn_mul_n (p, a, b, n) * multiplication will take much longer than malloc()/free(). */ mp_limb_t wsLen, *ws; wsLen = 2 * n + 3 * BITS_PER_MP_LIMB; - ws = (mp_ptr) (*_mp_allocate_func) ((size_t) wsLen * sizeof (mp_limb_t)); + ws = (mp_ptr) (*__gmp_allocate_func) ((size_t) wsLen * sizeof (mp_limb_t)); mpn_toom3_mul_n (p, a, b, n, ws); - (*_mp_free_func) (ws, (size_t) wsLen * sizeof (mp_limb_t)); + (*__gmp_free_func) (ws, (size_t) wsLen * sizeof (mp_limb_t)); } #if WANT_FFT || TUNE_PROGRAM_BUILD else diff --git a/mpq/clear.c b/mpq/clear.c index ed0c0b8fd..b9100fd93 100644 --- a/mpq/clear.c +++ b/mpq/clear.c @@ -30,8 +30,8 @@ mpq_clear (m) MP_RAT *m; #endif { - (*_mp_free_func) (m->_mp_num._mp_d, + (*__gmp_free_func) (m->_mp_num._mp_d, m->_mp_num._mp_alloc * BYTES_PER_MP_LIMB); - (*_mp_free_func) (m->_mp_den._mp_d, + (*__gmp_free_func) (m->_mp_den._mp_d, m->_mp_den._mp_alloc * BYTES_PER_MP_LIMB); } diff --git a/mpq/init.c b/mpq/init.c index faeb60ea7..aa2fce8dd 100644 --- a/mpq/init.c +++ b/mpq/init.c @@ -31,10 +31,10 @@ mpq_init (x) #endif { x->_mp_num._mp_alloc = 1; - x->_mp_num._mp_d = (mp_ptr) (*_mp_allocate_func) (BYTES_PER_MP_LIMB); + x->_mp_num._mp_d = (mp_ptr) (*__gmp_allocate_func) (BYTES_PER_MP_LIMB); x->_mp_num._mp_size = 0; x->_mp_den._mp_alloc = 1; - x->_mp_den._mp_d = (mp_ptr) (*_mp_allocate_func) (BYTES_PER_MP_LIMB); + x->_mp_den._mp_d = (mp_ptr) (*__gmp_allocate_func) (BYTES_PER_MP_LIMB); x->_mp_den._mp_d[0] = 1; x->_mp_den._mp_size = 1; } diff --git a/mpz/array_init.c b/mpz/array_init.c index 3d96418de..f7db7b97b 100644 --- a/mpz/array_init.c +++ b/mpz/array_init.c @@ -37,7 +37,7 @@ mpz_array_init (arr, arr_size, nbits) mp_size_t nlimbs; nlimbs = (nbits + BITS_PER_MP_LIMB - 1) / BITS_PER_MP_LIMB; - p = (mp_ptr) (*_mp_allocate_func) (arr_size * nlimbs * BYTES_PER_MP_LIMB); + p = (mp_ptr) (*__gmp_allocate_func) (arr_size * nlimbs * BYTES_PER_MP_LIMB); for (i = 0; i < arr_size; i++) { diff --git a/mpz/clear.c b/mpz/clear.c index ad649021e..ade6c54a0 100644 --- a/mpz/clear.c +++ b/mpz/clear.c @@ -31,5 +31,5 @@ mpz_clear (m) mpz_ptr m; #endif { - (*_mp_free_func) (m->_mp_d, m->_mp_alloc * BYTES_PER_MP_LIMB); + (*__gmp_free_func) (m->_mp_d, m->_mp_alloc * BYTES_PER_MP_LIMB); } diff --git a/mpz/dump.c b/mpz/dump.c index 3fccb9d04..096483a34 100644 --- a/mpz/dump.c +++ b/mpz/dump.c @@ -40,5 +40,5 @@ mpz_dump (u) str = mpz_get_str (0, 10, u); printf ("%s\n", str); - (*_mp_free_func) (str, 0);/* ??? broken alloc interface, pass what size ??? */ + (*__gmp_free_func) (str, 0);/* ??? broken alloc interface, pass what size ??? */ } diff --git a/mpz/get_str.c b/mpz/get_str.c index 9c46e594b..d8e42b29e 100644 --- a/mpz/get_str.c +++ b/mpz/get_str.c @@ -67,7 +67,7 @@ mpz_get_str (res_str, base, x) { /* We didn't get a string from the user. Allocate one (and return a pointer to it). */ - res_str = (char *) (*_mp_allocate_func) (str_size); + res_str = (char *) (*__gmp_allocate_func) (str_size); /* Make str, the variable used for raw result from mpn_get_str, point to the same string, but just after a possible minus sign. */ str = (unsigned char *) res_str + 1; diff --git a/mpz/init.c b/mpz/init.c index 5735cb22a..13596de84 100644 --- a/mpz/init.c +++ b/mpz/init.c @@ -31,6 +31,6 @@ mpz_init (x) #endif { x->_mp_alloc = 1; - x->_mp_d = (mp_ptr) (*_mp_allocate_func) (BYTES_PER_MP_LIMB); + x->_mp_d = (mp_ptr) (*__gmp_allocate_func) (BYTES_PER_MP_LIMB); x->_mp_size = 0; } diff --git a/mpz/inp_str.c b/mpz/inp_str.c index 7a6e36365..c7eb234e3 100644 --- a/mpz/inp_str.c +++ b/mpz/inp_str.c @@ -124,7 +124,7 @@ mpz_inp_str (x, stream, base) } alloc_size = 100; - str = (char *) (*_mp_allocate_func) (alloc_size); + str = (char *) (*__gmp_allocate_func) (alloc_size); str_size = 0; for (;;) @@ -134,7 +134,7 @@ mpz_inp_str (x, stream, base) { size_t old_alloc_size = alloc_size; alloc_size = alloc_size * 3 / 2; - str = (char *) (*_mp_reallocate_func) (str, old_alloc_size, alloc_size); + str = (char *) (*__gmp_reallocate_func) (str, old_alloc_size, alloc_size); } dig = digit_value_in_base (c, base); if (dig < 0) @@ -149,7 +149,7 @@ mpz_inp_str (x, stream, base) if (str_size == 0) { x->_mp_size = 0; - (*_mp_free_func) (str, alloc_size); + (*__gmp_free_func) (str, alloc_size); return nread; } @@ -162,6 +162,6 @@ mpz_inp_str (x, stream, base) xsize = mpn_set_str (x->_mp_d, (unsigned char *) str, str_size, base); x->_mp_size = negative ? -xsize : xsize; - (*_mp_free_func) (str, alloc_size); + (*__gmp_free_func) (str, alloc_size); return str_size + nread; } diff --git a/mpz/iset.c b/mpz/iset.c index 662d8b996..b473175f5 100644 --- a/mpz/iset.c +++ b/mpz/iset.c @@ -39,7 +39,7 @@ mpz_init_set (w, u) size = ABS (usize); w->_mp_alloc = MAX (size, 1); - w->_mp_d = (mp_ptr) (*_mp_allocate_func) (w->_mp_alloc * BYTES_PER_MP_LIMB); + w->_mp_d = (mp_ptr) (*__gmp_allocate_func) (w->_mp_alloc * BYTES_PER_MP_LIMB); wp = w->_mp_d; up = u->_mp_d; diff --git a/mpz/iset_d.c b/mpz/iset_d.c index 2f4545015..446d13f66 100644 --- a/mpz/iset_d.c +++ b/mpz/iset_d.c @@ -33,7 +33,7 @@ mpz_init_set_d (dest, val) #endif { dest->_mp_alloc = 1; - dest->_mp_d = (mp_ptr) (*_mp_allocate_func) (BYTES_PER_MP_LIMB); + dest->_mp_d = (mp_ptr) (*__gmp_allocate_func) (BYTES_PER_MP_LIMB); dest->_mp_size = 0; mpz_set_d (dest, val); } diff --git a/mpz/iset_si.c b/mpz/iset_si.c index 96110b890..8d503e84e 100644 --- a/mpz/iset_si.c +++ b/mpz/iset_si.c @@ -33,7 +33,7 @@ mpz_init_set_si (x, val) #endif { x->_mp_alloc = 1; - x->_mp_d = (mp_ptr) (*_mp_allocate_func) (BYTES_PER_MP_LIMB); + x->_mp_d = (mp_ptr) (*__gmp_allocate_func) (BYTES_PER_MP_LIMB); if (val > 0) { x->_mp_d[0] = val; diff --git a/mpz/iset_str.c b/mpz/iset_str.c index c90c5886d..399265a67 100644 --- a/mpz/iset_str.c +++ b/mpz/iset_str.c @@ -38,7 +38,7 @@ mpz_init_set_str (x, str, base) #endif { x->_mp_alloc = 1; - x->_mp_d = (mp_ptr) (*_mp_allocate_func) (BYTES_PER_MP_LIMB); + x->_mp_d = (mp_ptr) (*__gmp_allocate_func) (BYTES_PER_MP_LIMB); /* if str has no digits mpz_set_str leaves x->_mp_size unset */ x->_mp_size = 0; diff --git a/mpz/iset_ui.c b/mpz/iset_ui.c index b85748b81..062bab043 100644 --- a/mpz/iset_ui.c +++ b/mpz/iset_ui.c @@ -33,7 +33,7 @@ mpz_init_set_ui (x, val) #endif { x->_mp_alloc = 1; - x->_mp_d = (mp_ptr) (*_mp_allocate_func) (BYTES_PER_MP_LIMB); + x->_mp_d = (mp_ptr) (*__gmp_allocate_func) (BYTES_PER_MP_LIMB); x->_mp_d[0] = val; x->_mp_size = val != 0; } @@ -85,10 +85,10 @@ mult (u, v, w) free_me_size = w->_mp_alloc; } else - (*_mp_free_func) (wp, w->_mp_alloc * BYTES_PER_MP_LIMB); + (*__gmp_free_func) (wp, w->_mp_alloc * BYTES_PER_MP_LIMB); w->_mp_alloc = wsize; - wp = (mp_ptr) (*_mp_allocate_func) (wsize * BYTES_PER_MP_LIMB); + wp = (mp_ptr) (*__gmp_allocate_func) (wsize * BYTES_PER_MP_LIMB); w->_mp_d = wp; } else @@ -126,6 +126,6 @@ mult (u, v, w) w->_mp_size = sign_product < 0 ? -wsize : wsize; if (free_me != NULL) - (*_mp_free_func) (free_me, free_me_size * BYTES_PER_MP_LIMB); + (*__gmp_free_func) (free_me, free_me_size * BYTES_PER_MP_LIMB); TMP_FREE (marker); } diff --git a/mpz/powm_ui.c b/mpz/powm_ui.c index 73373ed32..f4e8a2dc8 100644 --- a/mpz/powm_ui.c +++ b/mpz/powm_ui.c @@ -115,9 +115,9 @@ mpz_powm_ui (res, base, exp, mod) free_me_size = res->_mp_alloc; } else - (*_mp_free_func) (rp, res->_mp_alloc * BYTES_PER_MP_LIMB); + (*__gmp_free_func) (rp, res->_mp_alloc * BYTES_PER_MP_LIMB); - rp = (mp_ptr) (*_mp_allocate_func) (size * BYTES_PER_MP_LIMB); + rp = (mp_ptr) (*__gmp_allocate_func) (size * BYTES_PER_MP_LIMB); res->_mp_alloc = size; res->_mp_d = rp; } @@ -243,6 +243,6 @@ mpz_powm_ui (res, base, exp, mod) res->_mp_size = rsize; if (free_me != NULL) - (*_mp_free_func) (free_me, free_me_size * BYTES_PER_MP_LIMB); + (*__gmp_free_func) (free_me, free_me_size * BYTES_PER_MP_LIMB); TMP_FREE (marker); } diff --git a/mpz/realloc.c b/mpz/realloc.c index 0004fe00f..6382f6112 100644 --- a/mpz/realloc.c +++ b/mpz/realloc.c @@ -35,7 +35,7 @@ _mpz_realloc (m, new_size) if (new_size == 0) new_size = 1; - m->_mp_d = (mp_ptr) (*_mp_reallocate_func) (m->_mp_d, + m->_mp_d = (mp_ptr) (*__gmp_reallocate_func) (m->_mp_d, m->_mp_alloc * BYTES_PER_MP_LIMB, new_size * BYTES_PER_MP_LIMB); m->_mp_alloc = new_size; diff --git a/mpz/sqrt.c b/mpz/sqrt.c index 71a37da54..f86cece13 100644 --- a/mpz/sqrt.c +++ b/mpz/sqrt.c @@ -57,10 +57,10 @@ mpz_sqrt (root, op) free_me_size = root->_mp_alloc; } else - (*_mp_free_func) (root_ptr, root->_mp_alloc * BYTES_PER_MP_LIMB); + (*__gmp_free_func) (root_ptr, root->_mp_alloc * BYTES_PER_MP_LIMB); root->_mp_alloc = root_size; - root_ptr = (mp_ptr) (*_mp_allocate_func) (root_size * BYTES_PER_MP_LIMB); + root_ptr = (mp_ptr) (*__gmp_allocate_func) (root_size * BYTES_PER_MP_LIMB); root->_mp_d = root_ptr; } else @@ -81,6 +81,6 @@ mpz_sqrt (root, op) root->_mp_size = root_size; if (free_me != NULL) - (*_mp_free_func) (free_me, free_me_size * BYTES_PER_MP_LIMB); + (*__gmp_free_func) (free_me, free_me_size * BYTES_PER_MP_LIMB); TMP_FREE (marker); } diff --git a/mpz/sqrtrem.c b/mpz/sqrtrem.c index c9688cc63..48a894445 100644 --- a/mpz/sqrtrem.c +++ b/mpz/sqrtrem.c @@ -77,10 +77,10 @@ msqrt (op, root, rem) free_me_size = root->_mp_alloc; } else - (*_mp_free_func) (root_ptr, root->_mp_alloc * BYTES_PER_MP_LIMB); + (*__gmp_free_func) (root_ptr, root->_mp_alloc * BYTES_PER_MP_LIMB); root->_mp_alloc = root_size; - root_ptr = (mp_ptr) (*_mp_allocate_func) (root_size * BYTES_PER_MP_LIMB); + root_ptr = (mp_ptr) (*__gmp_allocate_func) (root_size * BYTES_PER_MP_LIMB); root->_mp_d = root_ptr; } else @@ -106,6 +106,6 @@ msqrt (op, root, rem) rem->_mp_size = rem_size; if (free_me != NULL) - (*_mp_free_func) (free_me, free_me_size * BYTES_PER_MP_LIMB); + (*__gmp_free_func) (free_me, free_me_size * BYTES_PER_MP_LIMB); TMP_FREE (marker); } diff --git a/mpz/tests/convert.c b/mpz/tests/convert.c index 47b855b5d..3a83c4e02 100644 --- a/mpz/tests/convert.c +++ b/mpz/tests/convert.c @@ -58,7 +58,7 @@ main (argc, argv) str = mpz_get_str ((char *) 0, base, op1); MPZ_SET_STR_OR_ABORT (op2, str, base); - (*_mp_free_func) (str, 0); + (*__gmp_free_func) (str, 0); if (mpz_cmp (op1, op2)) { diff --git a/mpz/tests/t-mul.c b/mpz/tests/t-mul.c index 104606cfd..fae574aec 100644 --- a/mpz/tests/t-mul.c +++ b/mpz/tests/t-mul.c @@ -134,10 +134,10 @@ mpz_refmul (w, u, v) free_me_size = w->_mp_alloc; } else - (*_mp_free_func) (wp, w->_mp_alloc * BYTES_PER_MP_LIMB); + (*__gmp_free_func) (wp, w->_mp_alloc * BYTES_PER_MP_LIMB); w->_mp_alloc = wsize; - wp = (mp_ptr) (*_mp_allocate_func) (wsize * BYTES_PER_MP_LIMB); + wp = (mp_ptr) (*__gmp_allocate_func) (wsize * BYTES_PER_MP_LIMB); w->_mp_d = wp; } else @@ -165,7 +165,7 @@ mpz_refmul (w, u, v) wsize = _mpn_mul_classic (wp, up, usize, vp, vsize); w->_mp_size = sign_product < 0 ? -wsize : wsize; if (free_me != NULL) - (*_mp_free_func) (free_me, free_me_size * BYTES_PER_MP_LIMB); + (*__gmp_free_func) (free_me, free_me_size * BYTES_PER_MP_LIMB); TMP_FREE (marker); } @@ -137,7 +137,7 @@ gmp_randinit (va_alist) /* Allocate algorithm specific data. */ rstate->data.bbs = (__gmp_rand_data_bbs *) - (*_mp_allocate_func) (sizeof (__gmp_rand_data_bbs)); + (*__gmp_allocate_func) (sizeof (__gmp_rand_data_bbs)); mpz_init (rstate->data.bbs->bi); /* The Blum integer. */ mpz_mul (rstate->data.bbs->bi, p, q); @@ -38,13 +38,13 @@ gmp_randclear (rstate) mpz_clear (rstate->algdata.lc->a); if (rstate->algdata.lc->m2exp == 0) mpz_clear (rstate->algdata.lc->m); - (*_mp_free_func) (rstate->algdata.lc, sizeof (*rstate->algdata.lc)); + (*__gmp_free_func) (rstate->algdata.lc, sizeof (*rstate->algdata.lc)); break; #if 0 case GMP_RAND_ALG_BBS: mpz_clear (rstate->algdata.bbs->bi); - (*_mp_free_func) (rstate->algdata.bbs, sizeof (*rstate->algdata.bbs)); + (*__gmp_free_func) (rstate->algdata.bbs, sizeof (*rstate->algdata.bbs)); break; #endif /* 0 */ @@ -38,7 +38,7 @@ gmp_randinit_lc (gmp_randstate_t rstate, /* Allocate algorithm specific data. */ rstate->algdata.lc = (__gmp_randata_lc *) - (*_mp_allocate_func) (sizeof (__gmp_randata_lc)); + (*__gmp_allocate_func) (sizeof (__gmp_randata_lc)); mpz_init_set (rstate->algdata.lc->a, a); rstate->algdata.lc->c = c; diff --git a/randlc2x.c b/randlc2x.c index 97b39f22e..49e121ec7 100644 --- a/randlc2x.c +++ b/randlc2x.c @@ -36,7 +36,7 @@ gmp_randinit_lc_2exp (gmp_randstate_t rstate, /* Allocate algorithm specific data. */ rstate->algdata.lc = (__gmp_randata_lc *) - (*_mp_allocate_func) (sizeof (__gmp_randata_lc)); + (*__gmp_allocate_func) (sizeof (__gmp_randata_lc)); mpz_init_set (rstate->algdata.lc->a, a); rstate->algdata.lc->c = c; diff --git a/tune/common.c b/tune/common.c index 1764ce1e2..957a1ea8b 100644 --- a/tune/common.c +++ b/tune/common.c @@ -332,19 +332,19 @@ align_pointer (void *p, size_t align) /* Note that memory allocated with this function can never be freed, because the start address of the block allocated is discarded. */ void * -_mp_allocate_func_aligned (size_t bytes, size_t align) +__gmp_allocate_func_aligned (size_t bytes, size_t align) { - return align_pointer ((*_mp_allocate_func) (bytes + align-1), align); + return align_pointer ((*__gmp_allocate_func) (bytes + align-1), align); } void * -_mp_allocate_or_reallocate (void *ptr, size_t oldsize, size_t newsize) +__gmp_allocate_or_reallocate (void *ptr, size_t oldsize, size_t newsize) { if (ptr == NULL) - return (*_mp_allocate_func) (newsize); + return (*__gmp_allocate_func) (newsize); else - return (*_mp_reallocate_func) (ptr, oldsize, newsize); + return (*__gmp_reallocate_func) (ptr, oldsize, newsize); } @@ -385,7 +385,7 @@ mpz_init_set_n (mpz_ptr z, mp_srcptr p, mp_size_t size) MPN_NORMALIZE (p, size); ALLOC(z) = MAX (size, 1); - PTR(z) = _MP_ALLOCATE_FUNC_LIMBS (ALLOC(z)); + PTR(z) = __GMP_ALLOCATE_FUNC_LIMBS (ALLOC(z)); SIZ(z) = size; MPN_COPY (PTR(z), p, size); } @@ -936,7 +936,7 @@ speed_noop_wxys (struct speed_params *s) /* Compare these to see how much malloc/free costs and then how much - _mp_default_allocate/free and mpz_init/clear add. mpz_init/clear or + __gmp_default_allocate/free and mpz_init/clear add. mpz_init/clear or mpq_init/clear will be doing a 1 limb allocate, so use that as the size when including them in comparisons. */ @@ -960,23 +960,23 @@ speed_malloc_realloc_free (struct speed_params *s) } double -speed_mp_allocate_free (struct speed_params *s) +speed__gmp_allocate_free (struct speed_params *s) { size_t bytes = s->size * BYTES_PER_MP_LIMB; SPEED_ROUTINE_ALLOC_FREE (void *p, - p = (*_mp_allocate_func) (bytes); - (*_mp_free_func) (p, bytes)); + p = (*__gmp_allocate_func) (bytes); + (*__gmp_free_func) (p, bytes)); } double -speed_mp_allocate_reallocate_free (struct speed_params *s) +speed__gmp_allocate_reallocate_free (struct speed_params *s) { size_t bytes = s->size * BYTES_PER_MP_LIMB; SPEED_ROUTINE_ALLOC_FREE (void *p, - p = (*_mp_allocate_func) (BYTES_PER_MP_LIMB); - p = (*_mp_reallocate_func) (p, bytes, BYTES_PER_MP_LIMB); - (*_mp_free_func) (p, bytes)); + p = (*__gmp_allocate_func) (BYTES_PER_MP_LIMB); + p = (*__gmp_reallocate_func) (p, bytes, BYTES_PER_MP_LIMB); + (*__gmp_free_func) (p, bytes)); } double diff --git a/tune/speed.c b/tune/speed.c index 2fe9fc42e..664731e9b 100644 --- a/tune/speed.c +++ b/tune/speed.c @@ -217,8 +217,8 @@ const struct routine_t { { "malloc_free", speed_malloc_free }, { "malloc_realloc_free", speed_malloc_realloc_free }, - { "mp_allocate_free", speed_mp_allocate_free }, - { "mp_allocate_reallocate_free", speed_mp_allocate_reallocate_free }, + { "mp_allocate_free", speed__gmp_allocate_free }, + { "mp_allocate_reallocate_free", speed__gmp_allocate_reallocate_free }, { "mpz_init_clear", speed_mpz_init_clear }, { "mpq_init_clear", speed_mpq_init_clear }, { "mpf_init_clear", speed_mpf_init_clear }, @@ -546,9 +546,9 @@ run_gnuplot (int argc, char *argv[]) FILE *fp; int i; - plot_filename = (char *) (*_mp_allocate_func) + plot_filename = (char *) (*__gmp_allocate_func) (strlen (option_gnuplot_basename) + 20); - data_filename = (char *) (*_mp_allocate_func) + data_filename = (char *) (*__gmp_allocate_func) (strlen (option_gnuplot_basename) + 20); sprintf (plot_filename, "%s.gnuplot", option_gnuplot_basename); @@ -884,7 +884,7 @@ main (int argc, char *argv[]) if (size_num == size_allocnum) { size_array = (struct size_array_t *) - _mp_allocate_or_reallocate + __gmp_allocate_or_reallocate (size_array, size_allocnum * sizeof(size_array[0]), (size_allocnum+10) * sizeof(size_array[0])); @@ -959,7 +959,7 @@ main (int argc, char *argv[]) srandom (option_seed); srand48 (option_seed); - choice = (struct choice_t *) (*_mp_allocate_func) + choice = (struct choice_t *) (*__gmp_allocate_func) ((argc - optind) * sizeof(choice[0])); for ( ; optind < argc; optind++) { diff --git a/tune/speed.h b/tune/speed.h index 3eaaf0feb..e86065699 100644 --- a/tune/speed.h +++ b/tune/speed.h @@ -126,8 +126,8 @@ double speed_modlimb_invert_mul1 _PROTO ((struct speed_params *s)); double speed_modlimb_invert_loop _PROTO ((struct speed_params *s)); double speed_modlimb_invert_cond _PROTO ((struct speed_params *s)); double speed_modlimb_invert_arith _PROTO ((struct speed_params *s)); -double speed_mp_allocate_free _PROTO ((struct speed_params *s)); -double speed_mp_allocate_reallocate_free _PROTO ((struct speed_params *s)); +double speed__gmp_allocate_free _PROTO ((struct speed_params *s)); +double speed__gmp_allocate_reallocate_free _PROTO ((struct speed_params *s)); double speed_mpf_init_clear _PROTO ((struct speed_params *s)); @@ -227,10 +227,10 @@ void noop_wxys _PROTO ((mp_ptr wp, mp_srcptr xp, mp_srcptr yp, void mpn_cache_fill _PROTO ((mp_srcptr ptr, mp_size_t size)); void mpn_cache_fill_dummy _PROTO ((mp_limb_t n)); mp_ptr speed_tmp_alloc_adjust _PROTO ((void *ptr, mp_size_t align)); -void *_mp_allocate_or_reallocate _PROTO ((void *ptr, +void *__gmp_allocate_or_reallocate _PROTO ((void *ptr, size_t oldsize, size_t newsize)); void *align_pointer _PROTO ((void *p, size_t align)); -void *_mp_allocate_func_aligned _PROTO ((size_t bytes, size_t align)); +void *__gmp_allocate_func_aligned _PROTO ((size_t bytes, size_t align)); void speed_cache_fill _PROTO ((struct speed_params *s)); void speed_operand_src _PROTO ((struct speed_params *s, mp_ptr ptr, mp_size_t size)); diff --git a/tune/tuneup.c b/tune/tuneup.c index 0d2f1b6d5..a9854e6d0 100644 --- a/tune/tuneup.c +++ b/tune/tuneup.c @@ -139,7 +139,7 @@ add_dat (mp_size_t size, double d) if (ndat == allocdat) { - dat = (struct dat_t *) _mp_allocate_or_reallocate + dat = (struct dat_t *) __gmp_allocate_or_reallocate (dat, allocdat * sizeof(dat[0]), (allocdat+ALLOCDAT_STEP) * sizeof(dat[0])); allocdat += ALLOCDAT_STEP; |