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

Re: Need help porting GMP to AMD64



Hi John,

attached patch made "gmp-4.1.2" work perfectly for me...

(taken from http://bugs.gentoo.org/show_bug.cgi?id=29201)


-- 
	Stefan Palm

	
--- longlong.old	2003-10-14 18:52:52.000000000 -0400
+++ longlong.h	2003-10-14 18:53:52.000000000 -0400
@@ -715,8 +715,10 @@
   } while (0)
 #define count_trailing_zeros(count, x)					\
   do {									\
+    UDItype __cbtmp;							\
     ASSERT ((x) != 0);							\
-    __asm__ ("bsfq %1,%0" : "=r" (count) : "rm" ((UDItype)(x)));	\
+    __asm__ ("bsfq %1,%0" : "=r" (__cbtmp) : "rm" ((UDItype)(x)));	\
+   (count) = __cbtmp;							\
   } while (0)
 #endif /* x86_64 */
 

Reply to: