libgmp

Thomas Bodlien creative-software-design at t-online.de
Sun Oct 11 07:14:05 PDT 2015


On 11.10.2015, at 03:13, Rainer Müller <raimue at macports.org> wrote:
> 
> On 2015-10-11 00:24, Thomas Bodlien wrote:
>> can it be, that the compiler is creating Haswell specific machine-code?
> 
> Yes, very likely. MacPorts does not pass any -march or -mtune arguments
> by default to the compiler. The gmp port even disables archive_sites to
> force a build on the local machine. The Portfile points to ticket in
> Trac [1], which is inaccessible at the moment.
> 
> 
> The crash log tells us it was an illegal instruction:
> 
>  Exception Type: EXC_BAD_INSTRUCTION (SIGILL)
>  Exception Codes: 0x0000000000000001, 0x0000000000000000
>  Exception Note: EXC_CORPSE_NOTIFY
> 
> The instruction can be found at this location:
> 
>  Thread 8 Crashed:
>  0 libgmp.10.dylib 0x000000010005bfa9 __gmpn_sqr_basecase + 9
> 
> In the libgmp.10.dylib I built locally, there is no suspicious
> instruction at this location:
> 
>  $ otool -tv /opt/local/lib/libgmp.10.dylib |grep -A6 ^___gmpn_sqr_basecase:
>  ___gmpn_sqr_basecase:
>  0000000000025b40	cmpq	$0x2, %rdx
>  0000000000025b44	jae	0x25b54
>  0000000000025b46	movq	(%rsi), %rax
>  0000000000025b49	mulq	%rax
>  0000000000025b4c	movq	%rax, (%rdi)
>  0000000000025b4f	movq	%rdx, 0x8(%rdi)
> 
> Can you check this in the version you are shipping?
> 
> Rainer
> 
> [1] http://trac.macports.org/ticket/41614 <http://trac.macports.org/ticket/41614>

This is, what I am getting:

$ otool -tv /Volumes/SSD/SRC/Mac/Compute\ PI/libgmp.10.dylib  |grep -A6 ^___gmpn_sqr_basecase:
___gmpn_sqr_basecase:
0000000000028fa0	cmpq	$0x2, %rdx
0000000000028fa4	jae	0x28fb6
0000000000028fa6	movq	(%rsi), %rdx
0000000000028fa9	mulxq	%rdx, %rax, %rdx
0000000000028fae	movq	%rax, (%rdi)
0000000000028fb1	movq	%rdx, 0x8(%rdi)

Regards


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-users/attachments/20151011/93d264b8/attachment.html>


More information about the macports-users mailing list