libgmp3 problem on IA64
Quoted 4 lines · Jr.
For the past couple days i have been investigating an odd segfault in Sawfish. For some reason, some people were not seeing it, but once it starts, it is perfectly reproducable, even after eliminating any state Sawfish saves (Unix domain socket, configuration files, etc.).
Some co-workers started investigating this today, and found a patch from Red Hat which apparently was not shared with bug-gmp. Even with the patch gmp still fails 19 out of 21 of its tests, so i'm not sure the patch accomplishes much. We're still investigating the issue. Anyway, i have attached the patch (by Philipp Knirsch <[email protected]>).
Signature · 4 lines
Eric Gillespie, Jr. <*> [email protected] Software Developer Progeny Linux Systems - http://progeny.com "I don't know what a Sawfish Window Manager is."
longlong.h +3 -3
@@ -157,14 +157,14 @@#endif /* LONGLONG_STANDALONE */ #endif /* hppa */ -#if defined (__ia64) &&W_TYPE_SIZE ==64 +#if defined (__ia64) && !defined(NO_ASM ) &&W_TYPE_SIZE ==64 #if defined (__GNUC__)#define umul_ppmm (ph, pl, m0, m1) \ do { \ UDItype __m0 = (m0), __m1 = (m1); \ __asm__ ("xma.hu %0 = %1, %2, f0" \ - : "=e" (ph) \ - : "e" (m0), "e" (m1)); \ + : "=f" (ph) \ + : "f" (m0), "f" (m1)); \ (pl) = __m0 * __m1; \ } while (0)#endif
mpn/Makefile.am +1 -1
@@ -36,7 +36,7 @@ libmpn_la_LIBADD = $(OFILES) libmpn_la_DEPENDENCIES = $(OFILES) -TARG_DIST = a29k alpha arm clipper cray generic hppa i960 lisp m68k m88k \ +TARG_DIST = a29k alpha arm clipper cray generic hppa i960 ia64 lisp m68k m88k \ mips2 mips3 ns32k pa64 pa64w power powerpc32 powerpc64 pyr sh sparc32 \ sparc64 thumb vax x86 z8000 z8000x
mpn/ia64/gmp-mparam.h +27 -0
@@ -0,0 +1,27 @@ +/* gmp-mparam.h -- Compiler/machine parameter header file. + +Copyright (C) 1991, 1993, 1994 Free Software Foundation, Inc. + +This file is part of the GNU MP Library. + +The GNU MP Library is free software; you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation; either version 2.1 of the License, or (at your +option) any later version. + +The GNU MP Library is distributed in the hope that it will be useful, but +WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY +or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public +License for more details. + +You should have received a copy of the GNU Lesser General Public License +along with the GNU MP Library; see the file COPYING.LIB. If not, write to +the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, +MA 02111-1307, USA. */ + +#define BITS_PER_MP_LIMB 64 +#define BYTES_PER_MP_LIMB 8 +#define BITS_PER_LONGINT 64 +#define BITS_PER_INT 32 +#define BITS_PER_SHORTINT 16 +#define BITS_PER_CHAR 8
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line · Jr.
Eric> Some co-workers started investigating this today, and found a Eric> patch from Red Hat which apparently was not shared with Eric> bug-gmp. Even with the patch gmp still fails 19 out of 21 of Eric> its tests, so i'm not sure the patch accomplishes much.
For what it's worth: I just tried gmp-3.1.1-4.src.rpm from the Red Hat "roswell" beta and it passes all tests. As far as I can tell, there are no ia64-specific patches other than the one you mentioned.
--david
Quoted 2 lines · Jr.
[2. text/plain; gmp-3.1.1-ia64.patch]...
Thanks, I think the gcc register flags changed at some point.