Subject: Re: gcc internal error during firefox build?
To: NetBSD port-sparc mailing list <port-sparc@netbsd.org>
From: Julian Coleman <jdc@coris.org.uk>
List: port-sparc
Date: 08/01/2004 16:24:04
> Looks like the relevant compiler code has not been changed vs. the gcc 3.3.3
> import, and seems to be a generic va_arg() handling problem. Could you try
> to make a shorter example failing the same way and submit that to fsf
> bugzilla?

See:

  http://mail-index.NetBSD.org/port-sparc/2004/01/02/0000.html

where I wrote:

> The g++ compiler that is in current will crash (internal compiler error)
> when trying to convert a va_arg() to a double (e.g. the attached code).
> Both MozillaFirebird and KDE (qt3-libs) have code like this, so it's not
> possible to compile these packages for sparc.  I raised gcc bug 13173 for
> this, but it's not going to be fixed on the 3.3 branch.
 
>   - - 8< - - - - - - - - - - - - - Cut here - - - - - - - - - - - - - >8 - -
> 
>   $ cat zz.C
>   #include <stdarg.h>
>   static void parse_va(va_list ap) { double val = va_arg(ap, double); }
> 
>   $ g++ -c -o zz.o zz.C
>   zz.C: In function `void parse_va(char*)':
>   zz.C:2: internal compiler error: in convert_move, at expr.c:565
>   Please submit a full bug report,
>   with preprocessed source if appropriate.
>   See <URL:http://www.netbsd.org/Misc/send-pr.html> for instructions.

As the code will compile if gcc thinks it's C and not C++, it may be
possible to strip ut the va_arg() parsing code into C.

J

-- 
  My other computer also runs NetBSD    /        Sailing at Newbiggin
        http://www.netbsd.org/        /   http://www.newbigginsailingclub.org/