[Bug target/14776] -mfpmath=sse causes movapd from non-16-byte aligned address

hubicka at ucw dot cz gcc-bugzilla@gcc.gnu.org
Tue Mar 30 14:51:00 GMT 2004


------- Additional Comments From hubicka at ucw dot cz  2004-03-30 14:51 -------
Subject: Re:  New: -mfpmath=sse causes movapd from non-16-byte aligned address

> gcc -g -O2 -march=pentium4 -mfpmath=sse -c movapd_align_bug.c
> 
> objdump -dS movapd_align_bug.o:
> 
>         xfp->m[0].x = -sin_lon;
>   42:   f2 0f 10 05 00 00 00    movsd  0x0,%xmm0
>   49:   00 
>   4a:   f2 0f 10 4d b0          movsd  0xffffffb0(%ebp),%xmm1
>   4f:   66 0f 29 45 88          movapd %xmm0,0xffffff88(%ebp) <- ILLEGAL
>   54:   66 0f 57 c8             xorpd  %xmm0,%xmm1

GCC manages to conclude to spill out the temporary negative zero used to
expand negations and then it hits the usual problem of stack frame being
missaligned in main on cygwin and few other runtimes.

I am quite surprised that register alloc didn't rematerialized the
counstant tought...  It is perfect candidate for that.

Honza
>         xfp->m[1].x =  cos_lon;
>         xfp->m[2].x = 0.0;
> 
> -- 
>            Summary: -mfpmath=sse causes movapd from non-16-byte aligned
>                     address
>            Product: gcc
>            Version: 3.4.0
>             Status: UNCONFIRMED
>           Severity: normal
>           Priority: P2
>          Component: optimization
>         AssignedTo: unassigned at gcc dot gnu dot org
>         ReportedBy: ford at vss dot fsi dot com
>                 CC: gcc-bugs at gcc dot gnu dot org
>  GCC build triplet: i686-pc-cygwin
>   GCC host triplet: i686-pc-cygwin
> GCC target triplet: i686-pc-cygwin
> 
> 
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14776


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14776



More information about the Gcc-bugs mailing list