sparc64 gcc4/asm illegal operands, Re: CVS: cvs.openbsd.org: ports

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

sparc64 gcc4/asm illegal operands, Re: CVS: cvs.openbsd.org: ports

Stuart Henderson-10
Looks like these "Illegal operands" errors from the assembler started after
the move to gcc4, the offending asm code looks like

fdtox   %f12, %f9
fdtox   %f10, %f15
fdtox   %f8, %f9
fdtox   %f12, %f7

Any suggestions?


On 2011/11/14 04:05, Stuart Henderson wrote:
> CVSROOT: /cvs
> Module name: ports
> Changes by: [hidden email] 2011/11/14 04:05:08
>
> Modified files:
> comms/xastir   : Makefile
>
> Log message:
> BROKEN on sparc64, Illegal operands error while building draw_symbols.c

Reply | Threaded
Open this post in threaded view
|

Re: sparc64 gcc4/asm illegal operands, Re: CVS: cvs.openbsd.org: ports

Miod Vallat
> Looks like these "Illegal operands" errors from the assembler started after
> the move to gcc4, the offending asm code looks like
>
> fdtox   %f12, %f9
> fdtox   %f10, %f15
> fdtox   %f8, %f9
> fdtox   %f12, %f7
>
> Any suggestions?

I have started to investigate this. This sounds like the good `oh wait,
coercing a mutiple-register value into a single register type uses a
different register number on big-endian platforms? but it works on x86!'
recurring bug which has been biting us in subtle cases since gcc 2.95.

In the meantime I'd suggest compiling this port with -fno-tree-ter on
sparc64 (and maybe all BE64 platforms).

Index: Makefile
===================================================================
RCS file: /cvs/ports/comms/xastir/Makefile,v
retrieving revision 1.26
diff -u -p -r1.26 Makefile
--- Makefile 14 Nov 2011 11:05:08 -0000 1.26
+++ Makefile 23 May 2012 20:13:29 -0000
@@ -1,7 +1,5 @@
 # $OpenBSD: Makefile,v 1.26 2011/11/14 11:05:08 sthen Exp $
 
-BROKEN-sparc64= illegal operands building draw_symbols.c
-
 COMMENT= X amateur station tracking and info reporting
 
 DISTNAME= xastir-1.8.2
@@ -22,6 +20,9 @@ AUTOCONF_VERSION= 2.59
 AUTOMAKE_VERSION= 1.9
 USE_GROFF = Yes
 MAKE_ENV+=MOTIFLIB='-L${LOCALBASE}/lib -lXm'
+.if ${MACHINE} == "sparc64"
+MAKE_FLAGS= CFLAGS="${CFLAGS} -fno-tree-ter"
+.endif
 
 CONFIGURE_ARGS= --with-shapelib \
  --with-pcre \

>
>
> On 2011/11/14 04:05, Stuart Henderson wrote:
> > CVSROOT: /cvs
> > Module name: ports
> > Changes by: [hidden email] 2011/11/14 04:05:08
> >
> > Modified files:
> > comms/xastir   : Makefile
> >
> > Log message:
> > BROKEN on sparc64, Illegal operands error while building draw_symbols.c