1 /* THIS IS AN INTERNAL FUNCTION WITH A MUTABLE INTERFACE. IT IS NOT SAFE TO
2 CALL THIS FUNCTION DIRECTLY. IN FACT, IT IS ALMOST GUARANTEED THAT THIS
3 FUNCTION WILL CHANGE OR DISAPPEAR IN A FUTURE GNU MP RELEASE.
6 Copyright 1996, 2000-2002, 2005 Free Software Foundation, Inc.
8 This file is part of the GNU MP Library.
10 The GNU MP Library is free software; you can redistribute it and/or modify
11 it under the terms of either:
13 * the GNU Lesser General Public License as published by the Free
14 Software Foundation; either version 3 of the License, or (at your
15 option) any later version.
19 * the GNU General Public License as published by the Free Software
20 Foundation; either version 2 of the License, or (at your option) any
23 or both in parallel, as here.
25 The GNU MP Library is distributed in the hope that it will be useful, but
26 WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
27 or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
30 You should have received copies of the GNU General Public License and the
31 GNU Lesser General Public License along with the GNU MP Library. If not,
32 see https://www.gnu.org/licenses/. */
38 #if GMP_NUMB_BITS % 4 == 0
40 mpn_dump (mp_srcptr ptr
, mp_size_t n
)
42 MPN_NORMALIZE (ptr
, n
);
50 if ((ptr
[n
] >> GMP_LIMB_BITS
/ 2) != 0)
52 printf ("%lX", (unsigned long) (ptr
[n
] >> GMP_LIMB_BITS
/ 2));
53 printf ("%0*lX", (GMP_LIMB_BITS
/ 2 / 4), (unsigned long) ptr
[n
]);
57 printf ("%lX", (unsigned long) ptr
[n
]);
63 printf ("%0*lX", (GMP_NUMB_BITS
- GMP_LIMB_BITS
/ 2) / 4,
64 (unsigned long) (ptr
[n
] >> GMP_LIMB_BITS
/ 2));
65 printf ("%0*lX", GMP_LIMB_BITS
/ 2 / 4, (unsigned long) ptr
[n
]);
67 printf ("%0*lX", GMP_NUMB_BITS
/ 4, (unsigned long) ptr
[n
]);
77 mpn_recdump (mp_ptr p
, mp_size_t n
)
83 mpn_rshift (p
, p
, n
, 4);
90 mpn_dump (mp_srcptr p
, mp_size_t n
)
95 tp
= TMP_ALLOC_LIMBS (n
);