summaryrefslogtreecommitdiff
path: root/mpz/import.c
diff options
context:
space:
mode:
authorKevin Ryde <user42@zip.com.au>2002-11-01 23:49:00 +0100
committerKevin Ryde <user42@zip.com.au>2002-11-01 23:49:00 +0100
commitbaaea8a6c8d032501cfb2a277f8452f2f5d00ba8 (patch)
treef063b1267f8f198c720be4b738345f3c3daa14fc /mpz/import.c
parent894a35dea677ba82d950266047c187c22dcc73d1 (diff)
downloadgmp-baaea8a6c8d032501cfb2a277f8452f2f5d00ba8.tar.gz
* mpz/import.c, mpz/export.c: Use char* subract from NULL to get
pointer alignment, for the benefit of Cray vector systems. (This is an improvement, but -hnofastmd is required or the optimizer still gets it wrong.)
Diffstat (limited to 'mpz/import.c')
-rw-r--r--mpz/import.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mpz/import.c b/mpz/import.c
index aedd2dad4..b0c325205 100644
--- a/mpz/import.c
+++ b/mpz/import.c
@@ -58,7 +58,7 @@ mpz_import (mpz_ptr z, size_t count, int order,
mask out the nail bits in the input data. */
if (nail == 0 && GMP_NAIL_BITS == 0)
{
- unsigned align = ((unsigned long) (char *) data) % sizeof (mp_limb_t);
+ unsigned align = ((char *) data - (char *) NULL) % sizeof (mp_limb_t);
if (order == -1
&& size == sizeof (mp_limb_t)