Bill Allombert on Wed, 28 Oct 2009 23:24:39 +0100


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: Bug#49: Problem with installing PARI with Suse Linux 9.1.: invalid operands for a div operation


On Tue, Oct 27, 2009 at 04:43:47PM -0700, Ilya Zakharevich wrote:
> On Tue, 23 May 2006 at 13:55:44 +0200, Bill Allombert wrote:
> >> On Wed, Nov 16, 2005 at 10:50:42PM +0100, Bill Allombert wrote:
> 
> >> Hello, we finally identified this bug as an instance of the bug
> >> 2.2.3-F45 fixed in the development branch, and we fixed it in PARI
> >> 2.1.8/CVS:
> >>
> >> BA  1- ix86 inline assembler compilation problem [divll] [2.2.3 F45]
> >>
> >> So this bug will be fixed in the next stable release.
> 
> > Since the new stable version 2.3.0 has been released and fix this
> > problem, I am closing this bug report.
> 
> Do you still have this patch available?  Math::Pari is still plagued
> by this problem (since it may use older PARI distributions...).

I see: this was part of PARI 2.1.8 which had not been released.
This is still available in the branch 'release-2-1-patches'
of the SVN repository as change 7304 which you can retrieve by

svn diff -c 7304 svn://pari.math.u-bordeaux.fr/pari/branches/release-2-1-patches/

which give

Index: src/kernel/ix86/level0.h
===================================================================
--- src/kernel/ix86/level0.h	(révision 7303)
+++ src/kernel/ix86/level0.h	(révision 7304)
@@ -173,7 +173,7 @@
 ({ ulong __value, __arg1 = (a), __arg2 = (b); \
    __asm__ ("divl %4" \
         : "=a" /* %eax */ (__value), "=d" /* %edx */ (hiremainder) \
-        : "0" /* %eax */ (__arg1), "1" /* %edx */ (hiremainder), "g" (__arg2)); \
+        : "0" /* %eax */ (__arg1), "1" /* %edx */ (hiremainder), "mr" (__arg2)); \
    __value; \
 })

Cheers,
Bill.