This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: GCC 3.3.1 problem with printf %Lg %Lg and -m128bit-long-double compile option
- From: "Gerrit P. Haase" <gp at familiehaase dot de>
- To: mathias dot wagner at philips dot com
- Cc: cygwin at cygwin dot com
- Date: Thu, 27 May 2004 20:58:59 +0200
- Subject: Re: GCC 3.3.1 problem with printf %Lg %Lg and -m128bit-long-double compile option
- Organization: Esse keine toten Tiere
- References: <OFFB435626.E532FF68-ONC1256EA0.003FCC45-C1256EA0.00405F9A@philips.com>
- Reply-to: "Gerrit @ cygwin" <cygwin at cygwin dot com>
Hallo mathias,
> GCC 3.3.1 has a problem when printing multiple long double variables using
> printf and the -m128bit-long-double compile option on a Pentium-based
> machine.
Seems to be a bug in gcc, for bug reporting instructions, please see:
http://gcc.gnu.org/bugs.html.
> compile the code below with
> gcc -m128bit-long-double test.c
> and with
> gcc test.c
> The later will print stuff correctly in both printf statements, whereas
> the former will print fine only as long as the printf statement contains a
> single long double variable only, but will issue garbage when printing
> more than one long double variable in the same printf statement.
> #include <stdlib.h>
> #include <stdio.h>
> #include <string.h>
> #include <math.h>
> int
> main( int argc, char *argv[] )
> {
> long double first_long_double_variable = 5.6;
> long double second_long_double_variable = 9.3;
> printf ("here comes a long double %Lg\n", first_long_double_variable);
> printf ("here come TWO long doubles %Lg %Lg\n",
> first_long_double_variable, second_long_double_variable);
> }
> Installation Info as copied from cygcheck.out:
Please don't send cygcheck output inline an email, send it as
attachment.
Gerrit
--
=^..^=
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/