gmp 4.3.0 tests fail on Mac OS X 10.5

Marcus Calhoun-Lopez marcuscalhounlopez at mac.com
Wed May 6 21:08:01 CEST 2009


For me, all tests passed once I applied the patch to gmp-4.3.0-20090505.

-Marcus

Torbjorn Granlund writes:

> Either the hardware is wrong, or *both* the assembler and disassembler
> are broken and get the offset wrong.  I don't know if there is a  
> better
> disassembler available; otool makes it difficult to check if the  
> offset
> is wrong (which I strongly suspect).
>
> I got a crazy idea: Perhaps the .Lfoo labels confuses Apple's  
> programs.
> (We really should use L(foo) in the GMP assembly, to make the labels
> more short-lived.)
>
> Please try this patch:
>
> diff -r bcf4178f4ccc mpn/x86/p6/aors_n.asm
> --- a/mpn/x86/p6/aors_n.asm	Wed May 06 14:13:24 2009 +0200
> +++ b/mpn/x86/p6/aors_n.asm	Wed May 06 18:44:18 2009 +0200
> @@ -90,7 +90,7 @@
>  	ret_internal
>  ')
>
> -.Lend:
> +L(end):
>  	sbb	%eax, %eax
>  	neg	%eax
>  	pop	%ebx
> @@ -99,8 +99,8 @@
>  	ret
>
>  	ALIGN(16)
> -.Loop:
> -	jecxz	.Lend
> +L(top):
> +	jecxz	L(end)
>  L(ent):
>  Zdisp(	mov,	0,(up,n,4), %eax)
>  Zdisp(	ADCSBB,	0,(vp,n,4), %eax)
> @@ -135,7 +135,7 @@
>  	mov	%edx, 28(rp,n,4)
>
>  	lea	8(n), n
> -	jmp	.Loop
> +	jmp	L(top)
>
>  EPILOGUE()
>
>
> -- 
> Torbjörn



More information about the gmp-bugs mailing list