This is the mail archive of the
mailing list for the Cygwin project.
Re: std::arg() bug : not repetitive ?
- From: Dave Korn <dave dot korn dot cygwin at googlemail dot com>
- To: cygwin at cygwin dot com
- Date: Wed, 02 Sep 2009 01:54:39 +0100
- Subject: Re: std::arg() bug : not repetitive ?
- References: <4A9DAED9.email@example.com>
Angelo Graziosi wrote:
> Dave Korn wrote:
>> IIUC this is basically fixed in GCC
>> HEAD now and 4.5.0 shouldn't suffer the same problem.
> Just for completeness...
> With 4.5-20090827 snapshot, it does:
> $ g++-4.5 arg_bug.cpp -o0 -o arg_bug
> $ ./arg_bug.exe
Thanks for checking up on this. It's possible we might need to add some
kind of fpu mode init to the CRT. On the other hand, comment #127 in the PR
suggests to me that maybe we need to use the new command-line flag. Hang on a
minute... "-fexcess-precision=standard" works only for C and ObjC.
> $ g++-4 comp_2.cc -o0 -o comp_2 -I /usr/include/octave-3.2.0/octave
> $ ./comp_2.exe
> $ g++-4 comp_2.cc -o0 -o comp_2 -I /usr/include/octave-3.2.0/octave -fexcess-pr
> cc1plus: sorry, unimplemented: -fexcess-precision=standard for C++
Bah. Still, at least the -ffloat-store workaround still helps, for this
case at any rate. Also, if you get GCC to use SSE instructions, there's no
issue with excess precision:
> $ g++-4 comp_2.cc -o0 -o comp_2 -I /usr/include/octave-3.2.0/octave -march=pent
> ium4 -msse -mfpmath=sse
> $ ./comp_2.exe
However it does look like it's not going to get fully fixed for C++ until
someone with some serious language-lawyering skills can spend some time
defining the exact semantics.
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple